mirror of
https://github.com/mangosfour/server.git
synced 2025-12-14 07:37:01 +00:00
[7159] Allow GO cast as need (use go coordinates for target select in some cases)
Fixed work all Huter traps target selection More check in ObjectAccessor::Get Object More generic work 22 TARGET_CASTER_COORDINATES target type Signed-off-by: DiSlord <dislord@nomail.com>
This commit is contained in:
parent
c2a0a18a38
commit
abaa111eaa
10 changed files with 71 additions and 42 deletions
|
|
@ -354,7 +354,7 @@ void GameObject::Update(uint32 /*p_time*/)
|
|||
{
|
||||
Unit *caster = owner ? owner : ok;
|
||||
|
||||
caster->CastSpell(ok, goInfo->trap.spellId, true);
|
||||
caster->CastSpell(ok, goInfo->trap.spellId, true, 0, 0, GetGUID());
|
||||
m_cooldownTime = time(NULL) + 4; // 4 seconds
|
||||
|
||||
if(NeedDespawn)
|
||||
|
|
@ -404,7 +404,7 @@ void GameObject::Update(uint32 /*p_time*/)
|
|||
for (; it != end; it++)
|
||||
{
|
||||
Unit* owner = Unit::GetUnit(*this, uint64(*it));
|
||||
if (owner) owner->CastSpell(owner, spellId, false);
|
||||
if (owner) owner->CastSpell(owner, spellId, false, 0, 0, GetGUID());
|
||||
}
|
||||
|
||||
m_unique_users.clear();
|
||||
|
|
@ -809,7 +809,7 @@ void GameObject::TriggeringLinkedGameObject( uint32 trapEntry, Unit* target)
|
|||
// found correct GO
|
||||
// FIXME: when GO casting will be implemented trap must cast spell to target
|
||||
if(trapGO)
|
||||
target->CastSpell(target,trapSpell,true);
|
||||
target->CastSpell(target,trapSpell,true, 0, 0, GetGUID());
|
||||
}
|
||||
|
||||
GameObject* GameObject::LookupFishingHoleAround(float range)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue