Core/Position: Remove Position implicit object slicing

This commit is contained in:
Shauren
2025-05-19 15:34:32 +02:00
parent fe788a5eeb
commit a5ca817ff6
7 changed files with 15 additions and 17 deletions

View File

@@ -224,7 +224,7 @@ class spell_midsummer_juggle_torch : public SpellScript
if (!GetExplTargetDest())
return;
Position spellDest = *GetExplTargetDest();
WorldLocation spellDest = *GetExplTargetDest();
float distance = GetCaster()->GetExactDist2d(spellDest.GetPositionX(), spellDest.GetPositionY());
uint32 torchSpellID = 0;
@@ -234,7 +234,7 @@ class spell_midsummer_juggle_torch : public SpellScript
{
torchSpellID = SPELL_JUGGLE_TORCH_SELF;
torchShadowSpellID = SPELL_JUGGLE_TORCH_SHADOW_SELF;
spellDest = GetCaster()->GetPosition();
spellDest = GetCaster()->GetWorldLocation();
}
else if (distance <= 10.0f)
{

View File

@@ -2772,7 +2772,7 @@ class spell_hor_evasion : public SpellScriptLoader
void SetDest(SpellDestination& dest)
{
WorldObject* target = GetExplTargetWorldObject();
Position pos(*target);
Position pos = target->GetPosition();
Position home = GetCaster()->ToCreature()->GetHomePosition();
// prevent evasion outside the room