summaryrefslogtreecommitdiff
path: root/build/test.lua
diff options
context:
space:
mode:
authorSimon Robertshaw <simon@hardwired.org.uk>2011-05-30 19:11:34 (GMT)
committer Simon Robertshaw <simon@hardwired.org.uk>2011-05-30 19:11:34 (GMT)
commitb0659e3dd190070fdc8b1b5bb404e411825e205a (patch)
tree7353a8e151cdc53de4be6621bd6279a04238a482 /build/test.lua
parentd5f1a4cfd073f87d636e6975c28d42b8a7456840 (diff)
downloadpowder-b0659e3dd190070fdc8b1b5bb404e411825e205a.zip
powder-b0659e3dd190070fdc8b1b5bb404e411825e205a.tar.gz
Step code registration, just an example at the moment
Diffstat (limited to 'build/test.lua')
-rw-r--r--build/test.lua12
1 files changed, 12 insertions, 0 deletions
diff --git a/build/test.lua b/build/test.lua
new file mode 100644
index 0000000..f57f02b
--- /dev/null
+++ b/build/test.lua
@@ -0,0 +1,12 @@
+tpt.register_step("do_step")
+numberthing = 0
+increment = 2
+function do_step()
+ numberthing = numberthing + increment;
+ if numberthing >= 400 then
+ increment = -2
+ elseif numberthing < 4 then
+ increment = 2
+ end
+ tpt.drawtext(numberthing, 50, "Oh my god, this is amazing", 255, 255, 255, 255)
+end