3232#define __GAMEINFO_H__
3333
3434#include " Common/Snapshot.h"
35+ #include " Common/Money.h"
3536#include " GameNetwork/NetworkDefs.h"
3637#include " GameNetwork/FirewallHelper.h"
3738
@@ -193,6 +194,13 @@ class GameInfo
193194 inline Int getMapContentsMask ( void ) const ; // /< Get the map contents mask
194195 void setSeed ( Int seed ); // /< Set the random seed for the game
195196 inline Int getSeed ( void ) const ; // /< Get the game seed
197+ inline Int getUseStats ( void ) const ; // /< Does this game count towards gamespy stats?
198+ inline void setUseStats ( Int useStats );
199+
200+ inline UnsignedShort getSuperweaponRestriction ( void ) const ; // /< Get any optional limits on superweapons
201+ void setSuperweaponRestriction ( UnsignedShort restriction ); // /< Set the optional limits on superweapons
202+ inline const Money & getStartingCash (void ) const ;
203+ void setStartingCash ( const Money & startingCash );
196204
197205 void setSlotPointer ( Int index, GameSlot *slot ); // /< Set the slot info pointer
198206
@@ -222,6 +230,9 @@ class GameInfo
222230 Bool isPlayerPreorder (Int index);
223231 void markPlayerAsPreorder (Int index);
224232
233+ inline Bool oldFactionsOnly (void ) const ;
234+ inline void setOldFactionsOnly ( Bool oldFactionsOnly );
235+
225236protected:
226237 Int m_preorderMask;
227238 Int m_crcInterval;
@@ -239,6 +250,10 @@ class GameInfo
239250 UnsignedInt m_mapSize;
240251 Int m_mapMask;
241252 Int m_seed;
253+ Int m_useStats;
254+ Money m_startingCash;
255+ UnsignedShort m_superweaponRestriction;
256+ Bool m_oldFactionsOnly; // Only USA, China, GLA -- not USA Air Force General, GLA Toxic General, et al
242257};
243258
244259extern GameInfo *TheGameInfo;
@@ -254,6 +269,12 @@ Bool GameInfo::isInGame( void ) const { return m_inGame; }
254269void GameInfo::setInGame ( void ) { m_inGame = true ; }
255270Bool GameInfo::isGameInProgress ( void ) const { return m_inProgress; }
256271void GameInfo::setGameInProgress ( Bool inProgress ) { m_inProgress = inProgress; }
272+ Int GameInfo::getUseStats ( void ) const { return m_useStats; }
273+ void GameInfo::setUseStats ( Int useStats ) { m_useStats = useStats; }
274+ const Money&GameInfo::getStartingCash ( void ) const { return m_startingCash; }
275+ UnsignedShort GameInfo::getSuperweaponRestriction ( void ) const { return m_superweaponRestriction; }
276+ Bool GameInfo::oldFactionsOnly (void ) const { return m_oldFactionsOnly; }
277+ void GameInfo::setOldFactionsOnly ( Bool oldFactionsOnly ) { m_oldFactionsOnly = oldFactionsOnly; }
257278
258279AsciiString GameInfoToAsciiString ( const GameInfo *game );
259280Bool ParseAsciiStringToGameInfo ( GameInfo *game, AsciiString options );
@@ -284,5 +305,6 @@ class SkirmishGameInfo : public GameInfo, public Snapshot
284305};
285306
286307extern SkirmishGameInfo *TheSkirmishGameInfo;
308+ extern SkirmishGameInfo *TheChallengeGameInfo;
287309
288310#endif // __GAMEINFO_H__
0 commit comments