diff --git a/configure.ac b/configure.ac index e997722..bb3b3a3 100644 --- a/configure.ac +++ b/configure.ac @@ -7,7 +7,7 @@ # information. This file is offered as-is, without any warranty. AC_PREREQ([2.69]) -AC_INIT([Project: Starfighter], [2.1], [diligentcircle@riseup.net], [starfighter]) +AC_INIT([Project: Starfighter], [2.1.1], [diligentcircle@riseup.net], [starfighter]) AM_INIT_AUTOMAKE([foreign -Wall -Werror]) AC_CONFIG_SRCDIR([src/Starfighter.c]) AC_CONFIG_HEADERS([config.h]) diff --git a/data/credits.txt b/data/credits.txt index ae965ca..b22853e 100644 --- a/data/credits.txt +++ b/data/credits.txt @@ -65,5 +65,5 @@ 350 Project: Starfighter 020 Copyright 2003 Parallel Realities 020 Copyright 2012 Guus Sliepen, Astrid S. de Wijn and others -020 Copyright 2015-2019 Layla Marchant +020 Copyright 2015-2020 Layla Marchant 120 pr-starfighter.github.io diff --git a/locale/en.po b/locale/en.po index 93bd1c7..32110ea 100644 --- a/locale/en.po +++ b/locale/en.po @@ -1,7 +1,7 @@ # Project: Starfighter Translatable Text # Copyright (C) 2003 Parallel Relaities # Copyright (C) 2011, 2012, 2013 Guus Sliepen -# Copyright (C) 2012, 2015-2019 Layla Marchant +# Copyright (C) 2012, 2015-2020 Layla Marchant # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -20,7 +20,7 @@ # msgid "" msgstr "" -"Project-Id-Version: 2.0.1\n" +"Project-Id-Version: 2.1.1\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2020-03-06 19:09-0500\n" "PO-Revision-Date: 2020-03-06 19:22-0500\n" diff --git a/locale/pr-starfighter.pot b/locale/pr-starfighter.pot index 5e47b24..3a8d64e 100644 --- a/locale/pr-starfighter.pot +++ b/locale/pr-starfighter.pot @@ -1,7 +1,7 @@ # Project: Starfighter Translatable Text # Copyright (C) 2003 Parallel Relaities # Copyright (C) 2011, 2012, 2013 Guus Sliepen -# Copyright (C) 2012, 2015-2019 Layla Marchant +# Copyright (C) 2012, 2015-2020 Layla Marchant # # This program is free software: you can redistribute it and/or modify # it under the terms of the GNU General Public License as published by @@ -21,7 +21,7 @@ #, fuzzy msgid "" msgstr "" -"Project-Id-Version: 2.0.1\n" +"Project-Id-Version: 2.1.1\n" "Report-Msgid-Bugs-To: \n" "POT-Creation-Date: 2020-03-06 19:09-0500\n" "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n" diff --git a/src/Starfighter.c b/src/Starfighter.c index 30f3892..7fe2aad 100644 --- a/src/Starfighter.c +++ b/src/Starfighter.c @@ -2,7 +2,7 @@ Project: Starfighter Copyright (C) 2003 Parallel Realities Copyright (C) 2011, 2012 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/alien.c b/src/alien.c index bb6eea4..3f2e2de 100644 --- a/src/alien.c +++ b/src/alien.c @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011, 2012 Guus Sliepen -Copyright (C) 2012, 2015-2019 Layla Marchant +Copyright (C) 2012, 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/alien.h b/src/alien.h index b5f97e5..29857b6 100644 --- a/src/alien.h +++ b/src/alien.h @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/audio.c b/src/audio.c index 944fe7f..909bdfe 100644 --- a/src/audio.c +++ b/src/audio.c @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011, 2012 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/audio.h b/src/audio.h index 2d87786..81a744b 100644 --- a/src/audio.h +++ b/src/audio.h @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011, 2012 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/bullet.c b/src/bullet.c index 260ac31..8db22be 100644 --- a/src/bullet.c +++ b/src/bullet.c @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011, 2012 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/bullet.h b/src/bullet.h index 05cfff1..3fb3867 100644 --- a/src/bullet.h +++ b/src/bullet.h @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/cargo.c b/src/cargo.c index 37dd9a6..21b53ec 100644 --- a/src/cargo.c +++ b/src/cargo.c @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/cargo.h b/src/cargo.h index 1c6682f..8de1d1c 100644 --- a/src/cargo.h +++ b/src/cargo.h @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/collectable.c b/src/collectable.c index 8a8ddfb..aee07d5 100644 --- a/src/collectable.c +++ b/src/collectable.c @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011, 2012 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/collectable.h b/src/collectable.h index 4d1233a..632ded5 100644 --- a/src/collectable.h +++ b/src/collectable.h @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/colors.c b/src/colors.c index 9f47940..5a837d8 100644 --- a/src/colors.c +++ b/src/colors.c @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011, 2012, 2013 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/colors.h b/src/colors.h index 8c3a842..2ff015e 100644 --- a/src/colors.h +++ b/src/colors.h @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/cutscene.c b/src/cutscene.c index 8e24626..369fbdd 100644 --- a/src/cutscene.c +++ b/src/cutscene.c @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011, 2012, 2013 Guus Sliepen -Copyright (C) 2012, 2015-2019 Layla Marchant +Copyright (C) 2012, 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/cutscene.h b/src/cutscene.h index e845e76..860d599 100644 --- a/src/cutscene.h +++ b/src/cutscene.h @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/defs.c b/src/defs.c index 2883743..87dcb30 100644 --- a/src/defs.c +++ b/src/defs.c @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011, 2012 Guus Sliepen -Copyright (C) 2012, 2015-2019 Layla Marchant +Copyright (C) 2012, 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/defs.h b/src/defs.h index 3b3ae25..74ca83c 100644 --- a/src/defs.h +++ b/src/defs.h @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011, 2012 Guus Sliepen -Copyright (C) 2012, 2015-2019 Layla Marchant +Copyright (C) 2012, 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License @@ -802,6 +802,14 @@ enum { DIFFICULTY_MAX }; +// Engine state values (used for engine.done) +enum { + ENGINE_RUNNING = 0, + ENGINE_CLOSING, + ENGINE_SYSEXIT, + ENGINE_FORMATION +}; + extern const char * const systemBackground[]; extern const int rate2reload[6]; diff --git a/src/engine.c b/src/engine.c index dd466c0..4ab0669 100644 --- a/src/engine.c +++ b/src/engine.c @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011, 2012, 2013 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/engine.h b/src/engine.h index 6352fcc..4c3f26e 100644 --- a/src/engine.h +++ b/src/engine.h @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/event.c b/src/event.c index f77fd7d..1c95147 100644 --- a/src/event.c +++ b/src/event.c @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011, 2012, 2013 Guus Sliepen -Copyright (C) 2012, 2015-2019 Layla Marchant +Copyright (C) 2012, 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/event.h b/src/event.h index f201d72..bf8fad3 100644 --- a/src/event.h +++ b/src/event.h @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/explosion.c b/src/explosion.c index bdec005..a30c9f3 100644 --- a/src/explosion.c +++ b/src/explosion.c @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/explosion.h b/src/explosion.h index e45be19..2a72cdd 100644 --- a/src/explosion.h +++ b/src/explosion.h @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/game.c b/src/game.c index 6fb6f4a..d63f0c8 100644 --- a/src/game.c +++ b/src/game.c @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011, 2012, 2013 Guus Sliepen -Copyright (C) 2012, 2014-2019 Layla Marchant +Copyright (C) 2012, 2014-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License @@ -1444,11 +1444,12 @@ static void game_doPlayer() if (engine.keyState[KEY_ESCAPE]) { - if ((engine.done == 0) && (engine.gameSection == SECTION_GAME) && + if ((engine.done == ENGINE_RUNNING) && + (engine.gameSection == SECTION_GAME) && (mission.remainingObjectives1 == 0)) { audio_playSound(SFX_FLY, screen->w / 2, screen->h / 2); - engine.done = 2; + engine.done = ENGINE_SYSEXIT; engine.missionCompleteTimer = (SDL_GetTicks() - 1); } } @@ -1467,7 +1468,7 @@ static void game_doPlayer() ymoved = 1; } - if (engine.done == 0) + if (engine.done == ENGINE_RUNNING) { if (game.difficulty == DIFFICULTY_ORIGINAL) { @@ -2541,7 +2542,7 @@ int game_mainLoop() engine.smx = 0; engine.smy = 0; - engine.done = 0; + engine.done = ENGINE_RUNNING; engine.counter = (SDL_GetTicks() + 1000); engine.counter2 = (SDL_GetTicks() + 1000); @@ -2581,7 +2582,7 @@ int game_mainLoop() engine.keyState[KEY_ALTFIRE] = 0; player_flushInput(); - while (engine.done != 1) + while (engine.done != ENGINE_CLOSING) { renderer_update(); @@ -2605,13 +2606,16 @@ int game_mainLoop() ((game.difficulty == DIFFICULTY_ORIGINAL) || (game.difficulty == DIFFICULTY_NIGHTMARE) || (game.area == MISN_INTERCEPTION) || - (game.area == MISN_ELLESH) || (game.area == MISN_MARS) || - (mission_checkFailed()) || (collectable_numGood() <= 0))) + (game.area == MISN_ELLESH) || + (game.area == MISN_MARS) || + (mission_checkFailed()) || + (collectable_numGood() <= 0) || + (engine.done == ENGINE_SYSEXIT))) { if ((!mission_checkFailed()) && (game.area != MISN_VENUS)) { player_leaveSector(); - if ((engine.done == 2) && + if ((engine.done == ENGINE_SYSEXIT) && (game.area != MISN_DORIM) && (game.area != MISN_SIVEDI)) { @@ -2654,7 +2658,7 @@ int game_mainLoop() } else { - engine.done = 1; + engine.done = ENGINE_CLOSING; } } else @@ -2668,7 +2672,7 @@ int game_mainLoop() audio_setMusicVolume(engine.musicVolume); if (SDL_GetTicks() >= engine.missionCompleteTimer) { - engine.done = 1; + engine.done = ENGINE_CLOSING; } } } @@ -2716,7 +2720,7 @@ int game_mainLoop() game_delayFrame(); } - if (!engine.done) + if (engine.done == ENGINE_RUNNING) audio_resumeMusic(); } diff --git a/src/game.h b/src/game.h index 58a788d..684fc40 100644 --- a/src/game.h +++ b/src/game.h @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/gfx.c b/src/gfx.c index e69a8b0..ccae18c 100644 --- a/src/gfx.c +++ b/src/gfx.c @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011, 2012, 2013 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/gfx.h b/src/gfx.h index c7add0b..9cb46c8 100644 --- a/src/gfx.h +++ b/src/gfx.h @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/info.c b/src/info.c index e29cdc8..cdfae6d 100644 --- a/src/info.c +++ b/src/info.c @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011, 2012, 2013 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/info.h b/src/info.h index 1b4a0db..3de8eb8 100644 --- a/src/info.h +++ b/src/info.h @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/intermission.c b/src/intermission.c index b6bafe0..1341785 100644 --- a/src/intermission.c +++ b/src/intermission.c @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011, 2012, 2013 Guus Sliepen -Copyright (C) 2012, 2015-2019 Layla Marchant +Copyright (C) 2012, 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License @@ -1442,7 +1442,7 @@ int intermission() gfx_faceSprites[FS_KLINE] = gfx_loadImage("gfx/face_kline.png"); gfx_faceSprites[FS_CREW] = gfx_loadImage("gfx/face_crew.png"); - engine.done = 0; + engine.done = ENGINE_RUNNING; engine.keyState[KEY_FIRE] = 0; engine.ssx = 0; engine.ssy = 0; @@ -1539,9 +1539,9 @@ int intermission() player_flushInput(); engine.keyState[KEY_FIRE] = engine.keyState[KEY_ALTFIRE] = 0; - engine.done = 0; + engine.done = ENGINE_RUNNING; - while (!engine.done) + while (engine.done == ENGINE_RUNNING) { renderer_update(); @@ -1595,7 +1595,7 @@ int intermission() { game.area = intermission_planets[game.stationedPlanet].missionNumber; rtn = 2; - engine.done = 1; + engine.done = ENGINE_CLOSING; } else { @@ -1679,7 +1679,7 @@ int intermission() case 7: rtn = 0; - engine.done = 1; + engine.done = ENGINE_CLOSING; break; case 8: @@ -1714,7 +1714,7 @@ int intermission() { game.area = MISN_INTERCEPTION; rtn = 2; - engine.done = 1; + engine.done = ENGINE_CLOSING; } } diff --git a/src/intermission.h b/src/intermission.h index 03d513e..6614ada 100644 --- a/src/intermission.h +++ b/src/intermission.h @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/mission.c b/src/mission.c index 93bbd3d..aa9eaf9 100644 --- a/src/mission.c +++ b/src/mission.c @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011, 2012, 2013 Guus Sliepen -Copyright (C) 2012, 2015-2019 Layla Marchant +Copyright (C) 2012, 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License @@ -1174,7 +1174,7 @@ void mission_showStartScreen() renderer_update(); player_flushInput(); - engine.done = 0; + engine.done = ENGINE_RUNNING; engine.keyState[KEY_FIRE] = 0; engine.keyState[KEY_ALTFIRE] = 0; engine.keyState[KEY_ESCAPE] = 0; @@ -1293,7 +1293,7 @@ void mission_showFinishedScreen() renderer_update(); player_flushInput(); - engine.done = 0; + engine.done = ENGINE_RUNNING; engine.keyState[KEY_FIRE] = 0; while (1) diff --git a/src/mission.h b/src/mission.h index 301fba0..5292fe1 100644 --- a/src/mission.h +++ b/src/mission.h @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/player.c b/src/player.c index 993fa68..6279532 100644 --- a/src/player.c +++ b/src/player.c @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011, 2012, 2013 Guus Sliepen -Copyright (C) 2012, 2015-2019 Layla Marchant +Copyright (C) 2012, 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License @@ -392,10 +392,10 @@ void player_leaveSector() engine.keyState[KEY_FIRE] = 0; engine.keyState[KEY_ALTFIRE] = 0; - if (engine.done == 0) - engine.done = 3; + if (engine.done == ENGINE_RUNNING) + engine.done = ENGINE_FORMATION; - if (engine.done == 3) + if (engine.done == ENGINE_FORMATION) { player.face = 0; if (player.x > -100) @@ -410,18 +410,18 @@ void player_leaveSector() if (player.x <= -100) { - engine.done = 2; + engine.done = ENGINE_SYSEXIT; audio_playSound(SFX_FLY, screen->w / 2, screen->h / 2); } } - if (engine.done == 2) + if (engine.done == ENGINE_SYSEXIT) { player.face = 0; player.x += WARP_SPEED; engine.ssx -= 0.2; if (player.x > (2 * screen->w)) - engine.done = 1; + engine.done = ENGINE_CLOSING; } } diff --git a/src/player.h b/src/player.h index e0c7a3c..67574c4 100644 --- a/src/player.h +++ b/src/player.h @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/radio.c b/src/radio.c index 655becb..189ccb5 100644 --- a/src/radio.c +++ b/src/radio.c @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011, 2012, 2013 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/radio.h b/src/radio.h index 5b849f3..301abef 100644 --- a/src/radio.h +++ b/src/radio.h @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/renderer.c b/src/renderer.c index 6a97906..ee0e110 100644 --- a/src/renderer.c +++ b/src/renderer.c @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011, 2012, 2013 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/renderer.h b/src/renderer.h index af042bd..3aea81b 100644 --- a/src/renderer.h +++ b/src/renderer.h @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/save.c b/src/save.c index a729ab2..82579ed 100644 --- a/src/save.c +++ b/src/save.c @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011, 2012, 2013 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/save.h b/src/save.h index 37d0a7b..e02480c 100644 --- a/src/save.h +++ b/src/save.h @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/screen.c b/src/screen.c index 8eed821..086fa7f 100644 --- a/src/screen.c +++ b/src/screen.c @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011, 2012, 2013 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/screen.h b/src/screen.h index 188778c..158ee1d 100644 --- a/src/screen.h +++ b/src/screen.h @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/ship.c b/src/ship.c index 178def8..da38562 100644 --- a/src/ship.c +++ b/src/ship.c @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011, 2012 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/ship.h b/src/ship.h index 3099983..7a6a0f3 100644 --- a/src/ship.h +++ b/src/ship.h @@ -1,5 +1,5 @@ /* -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/shop.c b/src/shop.c index 1398a36..7cdff8f 100644 --- a/src/shop.c +++ b/src/shop.c @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011, 2012, 2013 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/shop.h b/src/shop.h index 025d195..1e6e6b6 100644 --- a/src/shop.h +++ b/src/shop.h @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/structs.h b/src/structs.h index 270e01a..49061b3 100644 --- a/src/structs.h +++ b/src/structs.h @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011, 2012, 2013 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/title.c b/src/title.c index 9055966..06a5e8d 100644 --- a/src/title.c +++ b/src/title.c @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011, 2012, 2013 Guus Sliepen -Copyright (C) 2012, 2015-2019 Layla Marchant +Copyright (C) 2012, 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License @@ -252,7 +252,7 @@ int title_show() 5, 0, FONT_WHITE, 0, copyrightText); gfx_renderString("Copyright Guus Sliepen, Astrid S. de Wijn and others 2012", 5, MENU_SPACING, FONT_WHITE, 0, copyrightText); - gfx_renderString("Copyright 2015-2019 Layla Marchant", + gfx_renderString("Copyright 2015-2020 Layla Marchant", 5, 2 * MENU_SPACING, FONT_WHITE, 0, copyrightText); snprintf(buildVersion, STRMAX_SHORT, "Version %s", VERSION ); @@ -295,7 +295,7 @@ int title_show() screen_drawBackground(); - engine.done = 0; + engine.done = ENGINE_RUNNING; player_flushInput(); engine.keyState[KEY_FIRE] = engine.keyState[KEY_ALTFIRE] = 0; @@ -431,7 +431,7 @@ int title_show() selectedOption = 1; } else if (selectedOption == 3) - engine.done = 1; + engine.done = ENGINE_CLOSING; else if (selectedOption == 4) { menuType = MENU_OPTIONS; @@ -439,7 +439,7 @@ int title_show() } else if (selectedOption == 5) { - engine.done = 1; + engine.done = ENGINE_CLOSING; } else if (selectedOption == 6) { @@ -449,15 +449,15 @@ int title_show() selectedOption = 1; } else - engine.done = 1; + engine.done = ENGINE_CLOSING; } else if (selectedOption == 7) - engine.done = 1; + engine.done = ENGINE_CLOSING; break; case MENU_DIFFICULTY: if (selectedOption == 1) - engine.done = 1; + engine.done = ENGINE_CLOSING; else if (selectedOption == 2) { game.difficulty++; @@ -474,7 +474,7 @@ int title_show() case MENU_LOAD: if (selectedOption != listLength) { - engine.done = 1; + engine.done = ENGINE_CLOSING; continueSaveSlot = selectedOption - 1; selectedOption = 3; } @@ -653,7 +653,7 @@ void title_showCredits() fclose(fp); - engine.done = 0; + engine.done = ENGINE_RUNNING; engine.keyState[KEY_ESCAPE] = 0; engine.keyState[KEY_FIRE] = 0; diff --git a/src/title.h b/src/title.h index 3b8a253..82364cf 100644 --- a/src/title.h +++ b/src/title.h @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/weapons.c b/src/weapons.c index cf20918..acd45dd 100644 --- a/src/weapons.c +++ b/src/weapons.c @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011, 2013 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/weapons.h b/src/weapons.h index 451e4c3..b2d07c5 100644 --- a/src/weapons.h +++ b/src/weapons.h @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/window.c b/src/window.c index 6131917..5c885c2 100644 --- a/src/window.c +++ b/src/window.c @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011, 2012, 2013 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License diff --git a/src/window.h b/src/window.h index 1a2633a..020670d 100644 --- a/src/window.h +++ b/src/window.h @@ -1,7 +1,7 @@ /* Copyright (C) 2003 Parallel Realities Copyright (C) 2011 Guus Sliepen -Copyright (C) 2015-2019 Layla Marchant +Copyright (C) 2015-2020 Layla Marchant This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License