From 112bc49c9a22a6998a9829940a72bfb3b4778bb9 Mon Sep 17 00:00:00 2001 From: Shauren Date: Sun, 30 Jun 2013 16:31:24 +0200 Subject: Core/Units: Removed most calls to SendMovementFlagUpdate for creatures --- .../BlackrockSpire/boss_rend_blackhand.cpp | 19 +++++-------------- .../scripts/EasternKingdoms/ZulAman/zulaman.cpp | 3 +-- 2 files changed, 6 insertions(+), 16 deletions(-) (limited to 'src/server/scripts/EasternKingdoms') diff --git a/src/server/scripts/EasternKingdoms/BlackrockSpire/boss_rend_blackhand.cpp b/src/server/scripts/EasternKingdoms/BlackrockSpire/boss_rend_blackhand.cpp index d975300c35b..b989e03a8a1 100644 --- a/src/server/scripts/EasternKingdoms/BlackrockSpire/boss_rend_blackhand.cpp +++ b/src/server/scripts/EasternKingdoms/BlackrockSpire/boss_rend_blackhand.cpp @@ -256,33 +256,24 @@ public: case EVENT_TURN_TO_REND: if (Creature* victor = me->GetCreature(*me, victorGUID)) { - victor->SetInFront(me); - victor->SendMovementFlagUpdate(); + victor->SetFacingToObject(me); victor->HandleEmoteCommand(EMOTE_ONESHOT_TALK); } break; case EVENT_TURN_TO_PLAYER: if (Creature* victor = me->GetCreature(*me, victorGUID)) if (Unit* player = victor->SelectNearestPlayer(60.0f)) - { - victor->SetInFront(player); - victor->SendMovementFlagUpdate(); - } + victor->SetFacingToObject(player); break; case EVENT_TURN_TO_FACING_1: if (Creature* victor = me->GetCreature(*me, victorGUID)) - { - victor->SetOrientation(1.518436f); - victor->SendMovementFlagUpdate(); - } + victor->SetFacingTo(1.518436f); break; case EVENT_TURN_TO_FACING_2: - me->SetOrientation(1.658063f); - me->SendMovementFlagUpdate(); + me->SetFacingTo(1.658063f); break; case EVENT_TURN_TO_FACING_3: - me->SetOrientation(1.500983f); - me->SendMovementFlagUpdate(); + me->SetFacingTo(1.500983f); break; case EVENT_WAVES_EMOTE_1: if (Creature* victor = me->GetCreature(*me, victorGUID)) diff --git a/src/server/scripts/EasternKingdoms/ZulAman/zulaman.cpp b/src/server/scripts/EasternKingdoms/ZulAman/zulaman.cpp index ff6d434fa40..0c2c9597cfe 100644 --- a/src/server/scripts/EasternKingdoms/ZulAman/zulaman.cpp +++ b/src/server/scripts/EasternKingdoms/ZulAman/zulaman.cpp @@ -297,8 +297,7 @@ class npc_harrison_jones : public CreatureScript if (me->GetCreatureTemplate()->GossipMenuId == sender && !action) { player->CLOSE_GOSSIP_MENU(); - me->SetInFront(player); - me->SendMovementFlagUpdate(true); + me->SetFacingToObject(player); me->RemoveFlag(UNIT_NPC_FLAGS, UNIT_NPC_FLAG_GOSSIP); Talk(SAY_HARRISON_0); _gongEvent = GONG_EVENT_1; -- cgit v1.2.3