Merge branch '4.3.4_phases' of https://github.com/TrinityCore/TrinityCore into 4.3.4

This commit is contained in:
Kinzcool committed 2014-06-18 23:25:57 -04:00
commit 34572492dd
63 files changed
+623 -1039

No files matched your search

+22 -4
View File
@@ -3206,6 +3206,9 @@ void Spell::EffectSummonObjectWild(SpellEffIndex effIndex)
return;
}
for (auto phase : m_caster->GetPhases())
pGameObj->SetInPhase(phase, false, true);
int32 duration = m_spellInfo->GetDuration();
pGameObj->SetRespawnTime(duration > 0 ? duration/IN_MILLISECONDS : 0);
@@ -3227,6 +3230,9 @@ void Spell::EffectSummonObjectWild(SpellEffIndex effIndex)
if (linkedGO->Create(sObjectMgr->GenerateLowGuid(HIGHGUID_GAMEOBJECT), linkedEntry, map,
m_caster->GetPhaseMask(), x, y, z, target->GetOrientation(), 0.0f, 0.0f, 0.0f, 0.0f, 100, GO_STATE_READY))
{
for (auto phase : m_caster->GetPhases())
linkedGO->SetInPhase(phase, false, true);
linkedGO->SetRespawnTime(duration > 0 ? duration/IN_MILLISECONDS : 0);
linkedGO->SetSpellId(m_spellInfo->Id);
@@ -3848,7 +3854,7 @@ void Spell::EffectDuel(SpellEffIndex effIndex)
Map* map = m_caster->GetMap();
if (!pGameObj->Create(sObjectMgr->GenerateLowGuid(HIGHGUID_GAMEOBJECT), gameobject_id,
map, m_caster->GetPhaseMask(),
map, 0,
m_caster->GetPositionX()+(unitTarget->GetPositionX()-m_caster->GetPositionX())/2,
m_caster->GetPositionY()+(unitTarget->GetPositionY()-m_caster->GetPositionY())/2,
m_caster->GetPositionZ(),
@@ -3858,6 +3864,9 @@ void Spell::EffectDuel(SpellEffIndex effIndex)
return;
}
for (auto phase : m_caster->GetPhases())
pGameObj->SetInPhase(phase, false, true);
pGameObj->SetUInt32Value(GAMEOBJECT_FACTION, m_caster->getFaction());
pGameObj->SetUInt32Value(GAMEOBJECT_LEVEL, m_caster->getLevel()+1);
int32 duration = m_spellInfo->GetDuration();
@@ -4208,12 +4217,15 @@ void Spell::EffectSummonObject(SpellEffIndex effIndex)
Map* map = m_caster->GetMap();
if (!go->Create(sObjectMgr->GenerateLowGuid(HIGHGUID_GAMEOBJECT), go_id, map,
m_caster->GetPhaseMask(), x, y, z, m_caster->GetOrientation(), 0.0f, 0.0f, 0.0f, 0.0f, 0, GO_STATE_READY))
0, x, y, z, m_caster->GetOrientation(), 0.0f, 0.0f, 0.0f, 0.0f, 0, GO_STATE_READY))
{
delete go;
return;
}
for (auto phase : m_caster->GetPhases())
go->SetInPhase(phase, false, true);
//pGameObj->SetUInt32Value(GAMEOBJECT_LEVEL, m_caster->getLevel());
int32 duration = m_spellInfo->GetDuration();
go->SetRespawnTime(duration > 0 ? duration/IN_MILLISECONDS : 0);
@@ -4837,12 +4849,15 @@ void Spell::EffectTransmitted(SpellEffIndex effIndex)
GameObject* pGameObj = new GameObject;
if (!pGameObj->Create(sObjectMgr->GenerateLowGuid(HIGHGUID_GAMEOBJECT), name_id, cMap,
m_caster->GetPhaseMask(), fx, fy, fz, m_caster->GetOrientation(), 0.0f, 0.0f, 0.0f, 0.0f, 100, GO_STATE_READY))
0, fx, fy, fz, m_caster->GetOrientation(), 0.0f, 0.0f, 0.0f, 0.0f, 100, GO_STATE_READY))
{
delete pGameObj;
return;
}
for (auto phase : m_caster->GetPhases())
pGameObj->SetInPhase(phase, false, true);
int32 duration = m_spellInfo->GetDuration();
switch (goinfo->type)
@@ -4903,8 +4918,11 @@ void Spell::EffectTransmitted(SpellEffIndex effIndex)
{
GameObject* linkedGO = new GameObject;
if (linkedGO->Create(sObjectMgr->GenerateLowGuid(HIGHGUID_GAMEOBJECT), linkedEntry, cMap,
m_caster->GetPhaseMask(), fx, fy, fz, m_caster->GetOrientation(), 0.0f, 0.0f, 0.0f, 0.0f, 100, GO_STATE_READY))
0, fx, fy, fz, m_caster->GetOrientation(), 0.0f, 0.0f, 0.0f, 0.0f, 100, GO_STATE_READY))
{
for (auto phase : m_caster->GetPhases())
linkedGO->SetInPhase(phase, false, true);
linkedGO->SetRespawnTime(duration > 0 ? duration/IN_MILLISECONDS : 0);
//linkedGO->SetUInt32Value(GAMEOBJECT_LEVEL, m_caster->getLevel());
linkedGO->SetSpellId(m_spellInfo->Id);