Add tasks for all the new languages
This commit is contained in:
parent
9dc3c2bb62
commit
bba7bfd280
13208 changed files with 134745 additions and 0 deletions
13
Task/Include-a-file/Lingo/include-a-file.lingo
Normal file
13
Task/Include-a-file/Lingo/include-a-file.lingo
Normal file
|
|
@ -0,0 +1,13 @@
|
|||
-- load Lingo code from file
|
||||
fp = xtra("fileIO").new()
|
||||
fp.openFile(_movie.path&"someinclude.ls", 1)
|
||||
code = fp.readFile()
|
||||
fp.closeFile()
|
||||
|
||||
-- create new script member, assign loaded code
|
||||
m = new(#script)
|
||||
m.name = "someinclude"
|
||||
m.scriptText = code
|
||||
|
||||
-- use it instantly in the current script (i.e. the script that contained the above include code)
|
||||
script("someinclude").foo()
|
||||
Loading…
Add table
Add a link
Reference in a new issue