#include <time.h>
#include <SDL.h>
-#ifdef LINUX
+#ifndef WIN32
#include <pwd.h>
#include <sys/types.h>
#include <ctype.h>
strcpy(filename, st_dir);
/* Open the high score file: */
-#ifdef LINUX
-
+#ifndef WIN32
strcat(filename, "/highscore");
#else
-#ifdef WIN32
-
strcat(filename, "/st_highscore.dat");
#endif
-#endif
/* Try opening the file: */
#include <SDL.h>
#include <SDL_image.h>
-#ifdef LINUX
+#ifndef LINUX
#include <pwd.h>
#include <sys/types.h>
#include <ctype.h>
December 20, 2003 - March 15, 2004
*/
-#ifdef LINUX
+#ifndef WIN32
#include <pwd.h>
#include <sys/types.h>
#include <ctype.h>
#include <SDL.h>
#include <SDL_image.h>
-#ifdef LINUX
+#ifndef WIN32
#include <pwd.h>
#include <sys/types.h>
#include <ctype.h>
#include <SDL_opengl.h>
#endif
-#ifdef LINUX
+#ifndef WIN32
#include <pwd.h>
#include <sys/stat.h>
#include <sys/types.h>
strcat(st_save_dir,"/save");
/* Create them. In the case they exist they won't destroy anything. */
-#ifdef LINUX
-
+#ifndef WIN32
mkdir(st_dir, 0755);
mkdir(st_save_dir, 0755);
sprintf(str, "%s/levels", st_dir);
mkdir(str, 0755);
#else
- #ifdef WIN32
-
mkdir(st_dir);
mkdir(st_save_dir);
sprintf(str, "%s/levels", st_dir);
mkdir(str);
#endif
-#endif
}
#include <SDL.h>
#include <SDL_image.h>
-#ifdef LINUX
+#ifndef WIN32
#include <pwd.h>
#include <sys/types.h>
#include <ctype.h>
break;
case SDLK_LCTRL:
case SDLK_RETURN:
- if (!tux_moving)
- enter_level = true;
+ enter_level = true;
break;
default:
break;
{
float speed = 4.5;
- if (enter_level)
+ if (enter_level && !tux_moving)
{
for(Levels::iterator i = levels.begin(); i != levels.end(); ++i)
{