Skip to content

Commit

Permalink
sync
Browse files Browse the repository at this point in the history
  • Loading branch information
AtomicSponge committed Jan 15, 2025
1 parent 19c4b5c commit 139bd52
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
2 changes: 1 addition & 1 deletion build.sh
Original file line number Diff line number Diff line change
Expand Up @@ -25,4 +25,4 @@ cp -r ${ASSETS_DIR}/shield.png ${BUILD_DIR}
cp -r ${ASSETS_DIR}/shield.wav ${BUILD_DIR}
cp -r ${ASSETS_DIR}/ship.png ${BUILD_DIR}
cp -r ${ASSETS_DIR}/spawn_asteroids.sdf ${BUILD_DIR}
cp -r ${ASSETS_DIR}/title.bmp ${BUILD_DIR}
cp -r ${ASSETS_DIR}/title.png ${BUILD_DIR}
4 changes: 3 additions & 1 deletion src/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -64,10 +64,12 @@ int main(int argc, char **argv) {
/* ********************************* */
/* Title screen handler - ESC exits demo - any other key starts game */
slv::add_handler<slv::SCOPE_A, slv::EVENT_KEY_DOWN, slv::handler::key>([](const int& key, ALLEGRO_DISPLAY* display) {
#if !defined(__EMSCRIPTEN__)
if (key == ALLEGRO_KEY_ESCAPE) {
//slv::stop_game(); // Stop the game loop.
slv::stop_game(); // Stop the game loop.
return;
}
#endif

slv::engine::load_scene("game_scene");
});
Expand Down

0 comments on commit 139bd52

Please sign in to comment.