fix(Core/Common): -Wdeprecated-enum-float-conversion warning (#6870)

This commit is contained in:
Francesco Borzì
2021-07-11 18:05:07 +02:00
committed by GitHub
parent 9b3993ba0b
commit d92a2ce58b
4 changed files with 13 additions and 22 deletions

View File

@@ -281,8 +281,8 @@ public:
me->CastSpell(me, me->GetMap()->IsHeroic() ? SPELL_FLAME_SPHERE_PERIODIC_H : SPELL_FLAME_SPHERE_PERIODIC, true);
float angle = rand_norm() * 2 * M_PI;
float x = me->GetPositionX() + DATA_SPHERE_DISTANCE * cos(angle);
float y = me->GetPositionY() + DATA_SPHERE_DISTANCE * sin(angle);
float x = me->GetPositionX() + static_cast<float>(DATA_SPHERE_DISTANCE) * cos(angle);
float y = me->GetPositionY() + static_cast<float>(DATA_SPHERE_DISTANCE) * sin(angle);
me->GetMotionMaster()->MovePoint(0, x, y, me->GetPositionZ());
}
}