diff options
author | Wyrserth <wyrserth@protonmail.com> | 2019-07-17 19:27:09 +0200 |
---|---|---|
committer | Shauren <shauren.trinity@gmail.com> | 2021-12-16 21:20:38 +0100 |
commit | 1f8a6bac87e726f580247a601391e6286017468c (patch) | |
tree | c6f08618dda3c6b77843c5fe4ec36877662faf14 /src | |
parent | 44eb3f9e4e8b44b852b6b5166020d96522bf5026 (diff) |
Core/GameObject: do not allow players to interact with gameobjects that use the "Point" icon.
Updates #21890.
(cherry picked from commit c52c0f0b7dbab9ff5f97426f1f742cb7cbe0732b)
Diffstat (limited to 'src')
-rw-r--r-- | src/server/game/Entities/Player/Player.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/server/game/Entities/Player/Player.cpp b/src/server/game/Entities/Player/Player.cpp index e9ccab6cba9..7e8115b5b69 100644 --- a/src/server/game/Entities/Player/Player.cpp +++ b/src/server/game/Entities/Player/Player.cpp @@ -2063,6 +2063,10 @@ GameObject* Player::GetGameObjectIfCanInteractWith(ObjectGuid const& guid) const if (!go) return nullptr; + // Players cannot interact with gameobjects that use the "Point" icon + if (go->GetGOInfo()->IconName == "Point") + return nullptr; + if (!go->IsWithinDistInMap(this)) return nullptr; |