diff --git a/src/main.h b/src/main.h index 20aa3b0..3bce8da 100644 --- a/src/main.h +++ b/src/main.h @@ -21,13 +21,6 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. #include "common.h" #include -App app; -Camera camera; -Colors colors; -Dev dev; -Entity *self; -Game game; -World world; extern void awardTrophies(void); extern void cleanup(void); extern void doTrophyAlerts(void); @@ -44,3 +37,10 @@ extern void presentScene(void); extern void saveScreenshot(char *name); extern void saveTrophyScreenshot(void); +App app; +Camera camera; +Colors colors; +Dev dev; +Entity *self; +Game game; +World world; diff --git a/src/system/i18n.c b/src/system/i18n.c index 5328afa..d0bef87 100644 --- a/src/system/i18n.c +++ b/src/system/i18n.c @@ -19,12 +19,15 @@ Foundation, 51 Franklin Street, Suite 500, Boston, MA 02110-1335, USA. #include "i18n.h" -static HashTable table; - +char *getTranslatedString(char *); +void setLanguage(char *, char *); +void cleanupLanguage(void); static int hashCode(char *); static void put(char *, char *); static void initTable(void); +static HashTable table; + void setLanguage(char *applicationName, char *languageCode) { char language[MAX_LINE_LENGTH], c[MAX_LINE_LENGTH]; diff --git a/src/system/i18n.h b/src/system/i18n.h index e375cf9..a40d207 100644 --- a/src/system/i18n.h +++ b/src/system/i18n.h @@ -23,8 +23,4 @@ Foundation, 51 Franklin Street, Suite 500, Boston, MA 02110-1335, USA. #include #endif -char *getTranslatedString(char *); -void setLanguage(char *, char *); -void cleanupLanguage(void); #define TABLE_SIZE 255 - diff --git a/src/test/atlasTest.c b/src/test/atlasTest.c index 78e8461..2b670e5 100644 --- a/src/test/atlasTest.c +++ b/src/test/atlasTest.c @@ -40,7 +40,7 @@ void initAtlasTest(void) createScreenshotFolder(); - test = 1; + test = 2; switch (test) { diff --git a/src/util/util.c b/src/util/util.c index 0a6ca1a..e35b9cf 100644 --- a/src/util/util.c +++ b/src/util/util.c @@ -65,8 +65,8 @@ char *timeToString(int seconds, int showHours) { int hours, minutes; - minutes = seconds / 60; hours = seconds / (FPS * FPS); + minutes = (seconds / FPS) % FPS; seconds %= FPS; if (showHours) diff --git a/tools/tidyHeaders.sh b/tools/tidyHeaders.sh index ae4a31f..d9eced2 100755 --- a/tools/tidyHeaders.sh +++ b/tools/tidyHeaders.sh @@ -230,7 +230,7 @@ function recurseDir($dir) { recurseDir("$dir/$file"); } - else if (strstr($file, ".h") !== FALSE) + else if (strstr($file, ".h") !== FALSE && strstr($file, "main.h") === FALSE) { cleanHeader("$dir/$file"); }