aboutsummaryrefslogtreecommitdiffstats
path: root/src/core/Game.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/Game.h')
-rw-r--r--src/core/Game.h46
1 files changed, 39 insertions, 7 deletions
diff --git a/src/core/Game.h b/src/core/Game.h
index 002033a0..4052eb00 100644
--- a/src/core/Game.h
+++ b/src/core/Game.h
@@ -3,16 +3,39 @@
enum eLevelName {
LEVEL_IGNORE = -1, // beware, this is only used in CPhysical's m_nZoneLevel
LEVEL_GENERIC = 0,
- LEVEL_INDUSTRIAL,
- LEVEL_COMMERCIAL,
- LEVEL_SUBURBAN,
+ LEVEL_BEACH,
+ LEVEL_MAINLAND,
+
NUM_LEVELS
};
+enum eAreaName {
+ AREA_MAIN_MAP,
+ AREA_HOTEL,
+ AREA_MANSION,
+ AREA_BANK,
+ AREA_MALL,
+ AREA_STRIP_CLUB,
+ AREA_LAWYERS,
+ AREA_COFFEE_SHOP,
+ AREA_CONCERT_HALL,
+ AREA_STUDIO,
+ AREA_RIFLE_RANGE,
+ AREA_BIKER_BAR,
+ AREA_POLICE_STATION,
+ AREA_EVERYWHERE,
+ AREA_DIRT,
+ AREA_BLOOD,
+ AREA_OVALRING,
+ AREA_MALIBU_CLUB,
+ AREA_PRINT_WORKS
+};
+
class CGame
{
public:
static eLevelName currLevel;
+ static int32 currArea;
static bool bDemoMode;
static bool nastyGame;
static bool frenchGame;
@@ -25,25 +48,34 @@ public:
static bool playingIntro;
static char aDatFile[32];
+#ifndef MASTER
+ static CVector PlayerCoords;
+ static bool8 VarUpdatePlayerCoords;
+#endif
+
static bool InitialiseOnceBeforeRW(void);
static bool InitialiseRenderWare(void);
static void ShutdownRenderWare(void);
static bool InitialiseOnceAfterRW(void);
static void FinalShutdown(void);
-#if GTA_VERSION <= GTA3_PS2_160
- static bool Initialise(void);
-#else
static bool Initialise(const char *datFile);
-#endif
static bool ShutDown(void);
static void ReInitGameObjectVariables(void);
static void ReloadIPLs(void);
static void ShutDownForRestart(void);
static void InitialiseWhenRestarting(void);
static void Process(void);
+
+ static void InitAfterFocusLoss(void);
+
+ static bool IsInInterior(void) { return currArea != AREA_MAIN_MAP; }
+ static bool CanSeeWaterFromCurrArea(void);
+ static bool CanSeeOutSideFromCurrArea(void);
// NB: these do something on PS2
static void TidyUpMemory(bool, bool);
static void DrasticTidyUpMemory(bool);
static void ProcessTidyUpMemory(void);
};
+
+inline bool IsAreaVisible(int area) { return area == CGame::currArea || area == AREA_EVERYWHERE; }