diff options
Diffstat (limited to 'src/main.moon')
| -rw-r--r-- | src/main.moon | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/src/main.moon b/src/main.moon new file mode 100644 index 0000000..b90c819 --- /dev/null +++ b/src/main.moon @@ -0,0 +1,36 @@ +--Theme: repair +--Game: drydock - repair space ships (?) +require "ext" +print("Hello, world!") +ss = require "startscreen" +game = require "game" +state = require "global" +level_1 = require "level1" +complete = require "complete" +mod = ... + +state.win = am.window { + title: "ggj20", + width: state.screen_width, + height: state.screen_height, + clear_color: vec4(0, 0, 0, 1) +} + + +r1 = ss.gen_scene! +--r1\append(complete.starfield!) +state.win.scene = r1 +r1\action(coroutine.create(() -> + while true + if state.win\key_down("space") + state.win.scene = am.group! ^ {game.gen_scene!, level_1.setup_level!} + coroutine.yield! +)) + + + +-- This is a comment +-- to make sure that errors +-- are rewritten correctly + +--error("success!") |
