mirror of
https://github.com/mangosfour/server.git
synced 2025-12-27 10:37:02 +00:00
[11380] Research dynamicobject types, added DynamicObjectType enum
This commit is contained in:
parent
3bf9a5c35b
commit
820a3c0eff
4 changed files with 16 additions and 9 deletions
|
|
@ -4010,7 +4010,8 @@ void Spell::EffectPersistentAA(SpellEffectIndex eff_idx)
|
|||
modOwner->ApplySpellMod(m_spellInfo->Id, SPELLMOD_RADIUS, radius);
|
||||
|
||||
DynamicObject* dynObj = new DynamicObject;
|
||||
if (!dynObj->Create(pCaster->GetMap()->GenerateLocalLowGuid(HIGHGUID_DYNAMICOBJECT), pCaster, m_spellInfo->Id, eff_idx, m_targets.m_destX, m_targets.m_destY, m_targets.m_destZ, m_duration, radius))
|
||||
if (!dynObj->Create(pCaster->GetMap()->GenerateLocalLowGuid(HIGHGUID_DYNAMICOBJECT), pCaster, m_spellInfo->Id,
|
||||
eff_idx, m_targets.m_destX, m_targets.m_destY, m_targets.m_destZ, m_duration, radius, DYNAMIC_OBJECT_AREA_SPELL))
|
||||
{
|
||||
delete dynObj;
|
||||
return;
|
||||
|
|
@ -4834,15 +4835,13 @@ void Spell::EffectAddFarsight(SpellEffectIndex eff_idx)
|
|||
DynamicObject* dynObj = new DynamicObject;
|
||||
|
||||
// set radius to 0: spell not expected to work as persistent aura
|
||||
if(!dynObj->Create(m_caster->GetMap()->GenerateLocalLowGuid(HIGHGUID_DYNAMICOBJECT), m_caster, m_spellInfo->Id, eff_idx, m_targets.m_destX, m_targets.m_destY, m_targets.m_destZ, duration, 0))
|
||||
if(!dynObj->Create(m_caster->GetMap()->GenerateLocalLowGuid(HIGHGUID_DYNAMICOBJECT), m_caster,
|
||||
m_spellInfo->Id, eff_idx, m_targets.m_destX, m_targets.m_destY, m_targets.m_destZ, duration, 0, DYNAMIC_OBJECT_FARSIGHT_FOCUS))
|
||||
{
|
||||
delete dynObj;
|
||||
return;
|
||||
}
|
||||
|
||||
// DYNAMICOBJECT_BYTES is apparently different from the default bytes set in ::Create
|
||||
dynObj->SetUInt32Value(DYNAMICOBJECT_BYTES, 0x80000002);
|
||||
|
||||
m_caster->AddDynObject(dynObj);
|
||||
m_caster->GetMap()->Add(dynObj);
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue