-
Notifications
You must be signed in to change notification settings - Fork 98
Hunter: Use GetPointsInRadius() instead of square #1948
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Changes from all commits
f8eff3c
e641dee
a18d4f3
e68942c
beb5f8d
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -67,6 +67,8 @@ class GameWorldBase : public World | |
| GameInterface* gi; | ||
| std::unique_ptr<EconomyModeHandler> econHandler; | ||
| std::unique_ptr<TradePathCache> tradePathCache; | ||
| /// Replay minor version when replaying. Set to current minor version for live games. | ||
|
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
Where? |
||
| uint8_t replayMinorVersion_ = 255; | ||
|
|
||
| public: | ||
| GameWorldBase(std::vector<GamePlayer> players, const GlobalGameSettings& gameSettings, EventManager& em); | ||
|
|
@@ -162,6 +164,11 @@ class GameWorldBase : public World | |
| bool IsSinglePlayer() const; | ||
| /// Return the game settings | ||
| const GlobalGameSettings& GetGGS() const { return gameSettings; } | ||
| /// Get the replay minor version (used for backward compatibility) | ||
| uint8_t GetReplayMinorVersion() const { return replayMinorVersion_; } | ||
| /// Set the replay minor version (called when loading a replay) | ||
| void SetReplayMinorVersion(uint8_t version) { replayMinorVersion_ = version; } | ||
|
|
||
| EventManager& GetEvMgr() { return em; } | ||
| const EventManager& GetEvMgr() const { return em; } | ||
| SoundManager& GetSoundMgr() { return *soundManager; } | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -92,6 +92,7 @@ static void playReplay(const boost::filesystem::path& replayPath, const bool isS | |
| gameWorld.GetPlayer(i).MakeStartPacts(); | ||
| } | ||
|
|
||
| gameWorld.SetReplayMinorVersion(replay.GetMinorVersion()); | ||
|
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. here. Replay is not accessible from hunter AI so that's why it's mirrored to GameWorldBase. Not ideal is it.
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. This is not the "live game" part. It is only ever set for replays.
Contributor
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Ah for live games it's default initialized to 255... |
||
| gameWorld.InitAfterLoad(); | ||
|
|
||
| bool endOfReplay = false; | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.