parseManager/textadventure.dms

34 lines
682 B
Plaintext

ENTRY MAIN
[MAIN]{
//Check for version compatibility
if _VERSION>=3.4 then GOTO("define")|GOTO("nodefine")
::nodefine::
print("We cannot use the filesystem or the extendedDefine module! Exiting program!")
QUIT()
::define::
USING filesystem as bin
USING extendedDefine
setVar("name","Thread Test")
newThread("LoopTest")
in = getInput("Enter Something: ")
file = bin.new(in)
file:tofile("WeCanWriteEm.txt")
tt = test(1,2)
"Test: $tt$"
"We are here now"
"why no work"
"?"
}
[test:function(a,b)]{
print("This works right? $a$ $b$")
return True
}
[LoopTest]{
a=0
name = getVar("name")
::loop::
a=a+1
test("$name$ $a$")
sleep(1)
GOTO("loop")
}