diff options
-rw-r--r-- | 3de.c | 8 |
1 files changed, 6 insertions, 2 deletions
@@ -89,7 +89,7 @@ int entrypoint(int argc, const char** argv, Arena* a) { Colour blue = make_aliceblue(); Player p; Services s; - int editing = 0; + int editing = 0, pause = 0; (void)argc; (void)argv; init_maths(); @@ -134,7 +134,11 @@ int entrypoint(int argc, const char** argv, Arena* a) { editing = !editing; cfg_mouse(app, editing); } - if (!editing) + if (app->key_states[key_escape] & key_state_just_pressed) { + pause = !pause; + cfg_mouse(app, pause); + } + if (!editing && !pause) update_player(&p, &s); ren_begin(&r, app->fb, depth, app->w, app->h); ren_clearc(&r, make_colour(0xc3c3c3, 0xff)); |