Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

Ignore:
Timestamp:
Jul 30, 2009, 2:10:44 PM (15 years ago)
Author:
rgrieder
Message:

Merged resource branch back to the trunk. Changes:

  • Automated graphics loading by evaluating whether a GameState requires it
  • Using native Tcl library (x3n)

Windows users: Update your dependency package!

Location:
code/trunk
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • code/trunk

  • code/trunk/src/core/GameMode.h

    r2896 r3370  
    4141    class _CoreExport GameMode
    4242    {
     43        friend class Game;
     44
    4345        public:
    4446            static bool showsGraphics() { return bShowsGraphics_s; }
     
    4749            static bool isStandalone()  { return bIsStandalone_s; }
    4850            static bool isMaster()      { return bIsMaster_s; }
    49             static void setShowsGraphics(bool val) { bShowsGraphics_s = val; updateIsMaster(); }
     51
    5052            static void setHasServer    (bool val) { bHasServer_s     = val; updateIsMaster(); }
    5153            static void setIsClient     (bool val) { bIsClient_s      = val; updateIsMaster(); }
    5254            static void setIsStandalone (bool val) { bIsStandalone_s  = val; updateIsMaster(); }
    53             static void updateIsMaster  ()         { bIsMaster_s      = (bHasServer_s || bIsStandalone_s); }
    5455
    5556        private:
     
    5758            GameMode(const GameMode& inst);
    5859            ~GameMode();
     60
     61            static void updateIsMaster()
     62            {
     63                bIsMaster_s = (bHasServer_s || bIsStandalone_s);
     64            }
    5965
    6066            static bool bShowsGraphics_s;                   //!< global variable that tells whether to show graphics
Note: See TracChangeset for help on using the changeset viewer.