Changeset View
Changeset View
Standalone View
Standalone View
source/simulation2/system/TurnManager.h
Show First 20 Lines • Show All 180 Lines • ▼ Show 20 Lines | protected: | ||||
bool m_HasSyncError; | bool m_HasSyncError; | ||||
IReplayLogger& m_Replay; | IReplayLogger& m_Replay; | ||||
// The number of the last turn that is allowed to be executed (used for replays) | // The number of the last turn that is allowed to be executed (used for replays) | ||||
u32 m_FinalTurn; | u32 m_FinalTurn; | ||||
private: | private: | ||||
friend class CCmpCommandQueue; | |||||
Itms: Instead of making the class a friend, just add a new public method to the turn manager that… | |||||
size_t m_TimeWarpNumTurns; // 0 if disabled | size_t m_TimeWarpNumTurns; // 0 if disabled | ||||
std::list<std::string> m_TimeWarpStates; | std::list<std::string> m_TimeWarpStates; | ||||
std::string m_QuickSaveState; // TODO: should implement a proper disk-based quicksave system | std::string m_QuickSaveState; // TODO: should implement a proper disk-based quicksave system | ||||
std::string m_QuickSaveMetadata; | std::string m_QuickSaveMetadata; | ||||
}; | }; | ||||
#endif // INCLUDED_TURNMANAGER | #endif // INCLUDED_TURNMANAGER |
Wildfire Games · Phabricator
Instead of making the class a friend, just add a new public method to the turn manager that adds a local command. That would also allow you to encapsulate the code you wrote for the command queue component.