00001
00002
00003
00004 #ifndef __OGAME_H
00005 #define __OGAME_H
00006
00007 #ifndef __WINDOWS_
00008 #include <WINDOWS.H>
00009 #endif
00010
00011 #ifndef __ALL_H
00012 #include <ALL.H>
00013 #endif
00014
00015 #ifndef __OCONFIG_H
00016 #include <OCONFIG.H>
00017 #endif
00018
00019
00020
00021 enum {
00022 GAME_PREGAME=1,
00023 GAME_SINGLE_PLAYER,
00024 GAME_TUTORIAL,
00025 GAME_TEST,
00026 };
00027
00028
00029
00035 class Game {
00036 public:
00037 char init_flag;
00038 char started_flag;
00039 char game_mode;
00040 char game_has_ended;
00041
00042 public:
00043 Game();
00044
00045 int init(int loadGameCall=0);
00046 void deinit(int loadGameCall=0);
00047
00048 void main_menu();
00049
00050 int write_file(File* filePtr);
00051 int read_file(File* filePtr);
00052
00053 private:
00054 void run_main_menu_option(int optionId);
00055 void new_game();
00056 void play_scenario();
00057 void credit();
00058 void disp_version();
00059
00060
00061 void scenario_menu();
00062
00063 void scenario_init();
00064 void scenario_report(int refreshFlag);
00065 int scenario_detect();
00066
00067 void loadgame_menu();
00068 void loadgame_init();
00069 void loadgame_report(int refreshFlag);
00070 int loadgame_detect();
00071
00072 public:
00073 void hall_of_fame();
00074
00075 void scenario_deinit();
00076 void loadgame_deinit();
00077
00078
00079
00080
00081 int generator(int genMode);
00082 void gen_disp(int refreshFlag);
00083 void gen_detect();
00084 };
00085
00086 extern Game game;
00087
00088
00089 #endif