From b0ca3660d500d6f2567c9c045ae7d766db2b8c0f Mon Sep 17 00:00:00 2001 From: Shauren Date: Tue, 16 May 2017 22:44:31 +0200 Subject: Core/PacketIO: Fix sending rotations vector in PlayOrphanSpellVisual --- src/server/game/Entities/Unit/Unit.cpp | 4 ++-- src/server/game/Server/Packets/SpellPackets.cpp | 2 +- src/server/game/Server/Packets/SpellPackets.h | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) (limited to 'src') diff --git a/src/server/game/Entities/Unit/Unit.cpp b/src/server/game/Entities/Unit/Unit.cpp index eb674b7fbf6..6259225b2f9 100644 --- a/src/server/game/Entities/Unit/Unit.cpp +++ b/src/server/game/Entities/Unit/Unit.cpp @@ -12683,7 +12683,7 @@ void Unit::SendPlayOrphanSpellVisual(ObjectGuid const& target, uint32 spellVisua WorldPackets::Spells::PlayOrphanSpellVisual playOrphanSpellVisual; playOrphanSpellVisual.SourceLocation = GetPosition(); if (withSourceOrientation) - playOrphanSpellVisual.SourceOrientation.Pos.SetOrientation(GetOrientation()); + playOrphanSpellVisual.SourceRotation = Position(0.0f, 0.0f, GetOrientation()); playOrphanSpellVisual.Target = target; // exclusive with TargetLocation playOrphanSpellVisual.SpellVisualID = spellVisualId; playOrphanSpellVisual.TravelSpeed = travelSpeed; @@ -12697,7 +12697,7 @@ void Unit::SendPlayOrphanSpellVisual(Position const& targetLocation, uint32 spel WorldPackets::Spells::PlayOrphanSpellVisual playOrphanSpellVisual; playOrphanSpellVisual.SourceLocation = GetPosition(); if (withSourceOrientation) - playOrphanSpellVisual.SourceOrientation.Pos.SetOrientation(GetOrientation()); + playOrphanSpellVisual.SourceRotation = Position(0.0f, 0.0f, GetOrientation()); playOrphanSpellVisual.TargetLocation = targetLocation; // exclusive with Target playOrphanSpellVisual.SpellVisualID = spellVisualId; playOrphanSpellVisual.TravelSpeed = travelSpeed; diff --git a/src/server/game/Server/Packets/SpellPackets.cpp b/src/server/game/Server/Packets/SpellPackets.cpp index 2efbe0a4acd..bfcde994f8f 100644 --- a/src/server/game/Server/Packets/SpellPackets.cpp +++ b/src/server/game/Server/Packets/SpellPackets.cpp @@ -770,7 +770,7 @@ WorldPacket const* WorldPackets::Spells::CancelSpellVisualKit::Write() WorldPacket const* WorldPackets::Spells::PlayOrphanSpellVisual::Write() { _worldPacket << SourceLocation; - _worldPacket << SourceOrientation; + _worldPacket << SourceRotation; _worldPacket << TargetLocation; _worldPacket << Target; _worldPacket << int32(SpellVisualID); diff --git a/src/server/game/Server/Packets/SpellPackets.h b/src/server/game/Server/Packets/SpellPackets.h index 46dee3846ee..d0af1e0043d 100644 --- a/src/server/game/Server/Packets/SpellPackets.h +++ b/src/server/game/Server/Packets/SpellPackets.h @@ -786,7 +786,7 @@ namespace WorldPackets bool SpeedAsTime = false; float TravelSpeed = 0.0f; float UnkZero = 0.0f; // Always zero - TaggedPosition SourceOrientation; // Vector of rotations, Orientation is z + TaggedPosition SourceRotation; // Vector of rotations, Orientation is z TaggedPosition TargetLocation; // Exclusive with Target }; -- cgit v1.2.3