forked from mirror/azerothcore-wotlk
Fix (core) Death Comes from high Client Crash Fix (#11136)
This fixes the client side crash while flying as the EYE OF ACHERUS, apparrently if the player lacks the visual spell on his character the client would crash. This is something I just want NOT ABLE to identify in debugger, however, true story also by the way, @TheDdraig made a suggestion while being both stone and highly intoxicate that he came up with the insane nonsensible approach that actually solved the issue 100%. Co-Authored-By: TheDdraig <[email protected]> Co-authored-by: TheDdraig <[email protected]>
This commit is contained in:
co-authored by
TheDdraig
parent
89ba502bfc
commit
606c5dc7a8
@@ -111,6 +111,10 @@ public:
|
||||
break;
|
||||
case EVENT_LAUNCH:
|
||||
{
|
||||
if (Player* player = me->GetCharmerOrOwnerPlayerOrPlayerItself())
|
||||
{
|
||||
player->AddAura(SPELL_EYE_OF_ACHERUS_VISUAL, player);
|
||||
}
|
||||
me->SetSpeed(MOVE_FLIGHT, 5.0f, true);
|
||||
|
||||
const Position EYE_DESTINATION_1 = { me->GetPositionX() - 40.0f, me->GetPositionY(), me->GetPositionZ() + 10.0f, 0.0f };
|
||||
@@ -118,6 +122,10 @@ public:
|
||||
|
||||
me->GetMotionMaster()->MovePoint(EYE_POINT_DESTINATION_1, EYE_DESTINATION_1);
|
||||
me->GetMotionMaster()->MovePoint(EYE_POINT_DESTINATION_2, EYE_DESTINATION_2);
|
||||
if (Player* player = me->GetCharmerOrOwnerPlayerOrPlayerItself())
|
||||
{
|
||||
player->RemoveAura(SPELL_EYE_OF_ACHERUS_VISUAL);
|
||||
}
|
||||
break;
|
||||
}
|
||||
case EVENT_REGAIN_CONTROL:
|
||||
|
||||
Reference in New Issue
Block a user