mirror of
https://github.com/TrinityCore/TrinityCore.git
synced 2026-01-24 19:06:49 +01:00
Core/Spells: Spell radius calculation update
This commit is contained in:
@@ -1564,8 +1564,8 @@ struct SpellRadiusEntry
|
||||
{
|
||||
uint32 ID; // 0
|
||||
//float Radius; // 1
|
||||
float RadiusMin; // 2
|
||||
float RadiusPerLevel; // 3
|
||||
float RadiusPerLevel; // 2
|
||||
float RadiusMin; // 3
|
||||
float RadiusMax; // 4
|
||||
};
|
||||
|
||||
|
||||
@@ -642,6 +642,11 @@ float SpellEffectInfo::CalcRadius(Unit* caster, Spell* spell) const
|
||||
return 0.0f;
|
||||
|
||||
float radius = entry->RadiusMin;
|
||||
|
||||
// Client uses max if min is 0
|
||||
if (radius == 0.0f)
|
||||
radius = entry->RadiusMax;
|
||||
|
||||
if (caster)
|
||||
{
|
||||
radius += entry->RadiusPerLevel * caster->getLevel();
|
||||
|
||||
Reference in New Issue
Block a user