CheckMountStateAction refactor Final (#960)

- Fix for the issue that bots occasionally moved awkward when mounted inside BG's
- Removed redundant mount data retrieval
- Removed redundant extra check on if carrying a flag (already covered in isUseful)
- Removed no longer necessary code
- Combined some conditions as having them separate made little sense anymore
- Moved checking carrying flag into the BG logic
This commit is contained in:
SaW
2025-02-11 11:39:29 +01:00
committed by GitHub
parent d7b3843024
commit 6cb1599b52
2 changed files with 38 additions and 67 deletions

View File

@@ -36,7 +36,7 @@ private:
void Dismount();
bool ShouldFollowMasterMountState(Player* master, bool noAttackers, bool shouldMount) const;
bool ShouldDismountForMaster(Player* master) const;
int32 CalculateMasterMountSpeed(Player* master) const;
int32 CalculateMasterMountSpeed(Player* master, const MountData& mountData) const;
bool CheckForSwiftMount() const;
std::map<uint32, std::map<int32, std::vector<uint32>>> GetAllMountSpells() const;
bool TryPreferredMount(Player* master) const;