Changeset 3370 for code/trunk/src/core/GameMode.h
- Timestamp:
- Jul 30, 2009, 2:10:44 PM (16 years ago)
- Location:
- code/trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
code/trunk
- Property svn:mergeinfo changed
/code/branches/resource (added) merged: 3328,3336-3340,3342-3350,3352-3366
- Property svn:mergeinfo changed
-
code/trunk/src/core/GameMode.h
r2896 r3370 41 41 class _CoreExport GameMode 42 42 { 43 friend class Game; 44 43 45 public: 44 46 static bool showsGraphics() { return bShowsGraphics_s; } … … 47 49 static bool isStandalone() { return bIsStandalone_s; } 48 50 static bool isMaster() { return bIsMaster_s; } 49 static void setShowsGraphics(bool val) { bShowsGraphics_s = val; updateIsMaster(); } 51 50 52 static void setHasServer (bool val) { bHasServer_s = val; updateIsMaster(); } 51 53 static void setIsClient (bool val) { bIsClient_s = val; updateIsMaster(); } 52 54 static void setIsStandalone (bool val) { bIsStandalone_s = val; updateIsMaster(); } 53 static void updateIsMaster () { bIsMaster_s = (bHasServer_s || bIsStandalone_s); }54 55 55 56 private: … … 57 58 GameMode(const GameMode& inst); 58 59 ~GameMode(); 60 61 static void updateIsMaster() 62 { 63 bIsMaster_s = (bHasServer_s || bIsStandalone_s); 64 } 59 65 60 66 static bool bShowsGraphics_s; //!< global variable that tells whether to show graphics
Note: See TracChangeset
for help on using the changeset viewer.