Emergency 20 Dokumentation  4.2.0
Application-inl.h
Go to the documentation of this file.
1 // Copyright (C) 2012-2018 Promotion Software GmbH
2 
3 
4 //[-------------------------------------------------------]
5 //[ Includes ]
6 //[-------------------------------------------------------]
8 
9 
10 //[-------------------------------------------------------]
11 //[ Namespace ]
12 //[-------------------------------------------------------]
13 namespace em5
14 {
15 
16 
17  //[-------------------------------------------------------]
18  //[ Public methods ]
19  //[-------------------------------------------------------]
21  {
22  return mCustomizedParametersPTree;
23  }
24 
25  inline Game& Application::getGame() const
26  {
27  // It's safe in here to cast the pointer to a reference because we know that the pointer is never ever a null pointer
28  QSF_ASSERT(nullptr != mGame, "The EM5 game instance is invalid", QSF_REACT_NONE);
29  return *mGame;
30  }
31 
33  {
34  // It's safe in here to cast the pointer to a reference because we know that the pointer is never ever a null pointer
35  QSF_ASSERT(nullptr != mGui, "The EM5 GUI instance is invalid", QSF_REACT_NONE);
36  return *mGui;
37  }
38 
40  {
41  return mGui;
42  }
43 
45  {
46  return mNetworkManager;
47  }
48 
50  {
51  return mPlayerProgress;
52  }
53 
55  {
56  return mAccountManager;
57  }
58 
60  {
61  return mContentAuthentication;
62  }
63 
65  {
66  return mStoreManager;
67  }
68 
69  inline bool Application::isInStartMenu() const
70  {
71  return mIsInStartMenu;
72  }
73 
74  inline bool Application::areCheatsEnabled() const
75  {
76  return mCheatsEnabled;
77  }
78 
79 
80 //[-------------------------------------------------------]
81 //[ Namespace ]
82 //[-------------------------------------------------------]
83 } // em5
Definition: ActionPriority.h:13
qsf::game::StoreManager & getStoreManager() const
Return the store manager instance.
Definition: Application-inl.h:64
Game & getGame() const
Return the EMERGENCY 5 game instance.
Definition: Application-inl.h:25
PlayerProgress & getPlayerProgress() const
Return the EM5 player progress instance.
Definition: Application-inl.h:49
EMERGENCY 5 game class.
Definition: Game.h:79
EmergencyGui & getGui() const
Return the EMERGENCY 5 GUI instance.
Definition: Application-inl.h:32
EMERGENCY 5 player progress class.
Definition: PlayerProgress.h:57
#define QSF_REACT_NONE
Definition: ErrorHandling.h:199
bool isInStartMenu() const
Return whether the application is in start menu ("launcher") right now.
Definition: Application-inl.h:69
AccountManager & getAccountManager() const
Return the EM5 account manager instance.
Definition: Application-inl.h:54
EMERGENCY 5 GUI instance to handle the game-specific user interface.
Definition: EmergencyGui.h:84
Store manager class managing in-app-purchases on platforms supporting this.
Definition: StoreManager.h:49
ContentAuthentication & getContentAuthentication() const
Return the EM5 content authentication instance.
Definition: Application-inl.h:59
Definition: DensityCalculator.h:29
const boost::property_tree::ptree & getCustomizedParametersPTree() const
Return the customized application parameters.
Definition: Application-inl.h:20
EMERGENCY 5 network manager class.
Definition: AccountManager.h:78
Content authentication class.
Definition: ContentAuthentication.h:32
NetworkManager & getNetworkManager() const
Return the EM5 network manager instance.
Definition: Application-inl.h:44
#define QSF_ASSERT(condition, explanation, reaction)
Definition: ErrorHandling.h:138
EmergencyGui * tryGetGui() const
Return the EMERGENCY 5 GUI instance.
Definition: Application-inl.h:39
bool areCheatsEnabled() const
Definition: Application-inl.h:74
EMERGENCY 5 network manager class.
Definition: NetworkManager.h:63