mirror of
https://github.com/mod-playerbots/azerothcore-wotlk.git
synced 2026-02-01 18:13:48 +00:00
fix(Core/Transports): Added Arrival bell sound for boats. (#14272)
Fixes #11340
This commit is contained in:
@@ -0,0 +1,20 @@
|
||||
--
|
||||
DELETE FROM `event_scripts` WHERE `id` IN (10301,10302,16395,16396,16397,16398,16399,16400,16401,16402,16522,19030,19031,19032,19033,19123,19124);
|
||||
INSERT INTO `event_scripts` VALUES
|
||||
(10301,0,16,5495,2,0,0,0,0,0),
|
||||
(10302,0,16,5495,2,0,0,0,0,0),
|
||||
(16395,0,16,5495,2,0,0,0,0,0),
|
||||
(16396,0,16,5495,2,0,0,0,0,0),
|
||||
(16397,0,16,5495,2,0,0,0,0,0),
|
||||
(16398,0,16,5495,2,0,0,0,0,0),
|
||||
(16399,0,16,5495,2,0,0,0,0,0),
|
||||
(16400,0,16,5495,2,0,0,0,0,0),
|
||||
(16401,0,16,5495,2,0,0,0,0,0),
|
||||
(16402,0,16,5495,2,0,0,0,0,0),
|
||||
(16522,0,16,5495,2,0,0,0,0,0),
|
||||
(19030,0,16,5495,2,0,0,0,0,0),
|
||||
(19031,0,16,5495,2,0,0,0,0,0),
|
||||
(19032,0,16,5495,2,0,0,0,0,0),
|
||||
(19033,0,16,5495,2,0,0,0,0,0),
|
||||
(19123,0,16,5495,2,0,0,0,0,0),
|
||||
(19124,0,16,5495,2,0,0,0,0,0);
|
||||
@@ -11152,6 +11152,35 @@ WorldLocation Player::GetStartPosition() const
|
||||
return WorldLocation(mapId, info->positionX, info->positionY, info->positionZ, 0);
|
||||
}
|
||||
|
||||
bool Player::HaveAtClient(WorldObject const* u) const
|
||||
{
|
||||
if (u == this)
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
// Motion Transports are always present in player's client
|
||||
if (GameObject const* gameobject = u->ToGameObject())
|
||||
{
|
||||
if (gameobject->IsMotionTransport())
|
||||
{
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
return m_clientGUIDs.find(u->GetGUID()) != m_clientGUIDs.end();
|
||||
}
|
||||
|
||||
bool Player::HaveAtClient(ObjectGuid guid) const
|
||||
{
|
||||
if (guid == GetGUID())
|
||||
{
|
||||
return true;
|
||||
}
|
||||
|
||||
return m_clientGUIDs.find(guid) != m_clientGUIDs.end();
|
||||
}
|
||||
|
||||
bool Player::IsNeverVisible() const
|
||||
{
|
||||
if (Unit::IsNeverVisible())
|
||||
|
||||
@@ -2330,8 +2330,8 @@ public:
|
||||
GuidUnorderedSet m_clientGUIDs;
|
||||
std::vector<Unit*> m_newVisible; // pussywizard
|
||||
|
||||
bool HaveAtClient(WorldObject const* u) const { return u == this || m_clientGUIDs.find(u->GetGUID()) != m_clientGUIDs.end(); }
|
||||
[[nodiscard]] bool HaveAtClient(ObjectGuid guid) const { return guid == GetGUID() || m_clientGUIDs.find(guid) != m_clientGUIDs.end(); }
|
||||
[[nodiscard]] bool HaveAtClient(WorldObject const* u) const;
|
||||
[[nodiscard]] bool HaveAtClient(ObjectGuid guid) const;
|
||||
|
||||
[[nodiscard]] bool IsNeverVisible() const override;
|
||||
|
||||
|
||||
Reference in New Issue
Block a user