Merge remote branch 'origin/master' into 330

This commit is contained in:
tomrus88 2010-03-31 02:29:02 +04:00
commit f2572fdda0
33 changed files with 138 additions and 110 deletions

View file

@ -737,7 +737,7 @@ void Spell::EffectSchoolDMG(SpellEffectIndex effect_idx)
// Add main hand dps * effect[2] amount
float average = (m_caster->GetFloatValue(UNIT_FIELD_MINDAMAGE) + m_caster->GetFloatValue(UNIT_FIELD_MAXDAMAGE)) / 2;
int32 count = m_caster->CalculateSpellDamage(m_spellInfo, EFFECT_INDEX_2, m_spellInfo->EffectBasePoints[EFFECT_INDEX_2], unitTarget);
damage += count * int32(average * IN_MILISECONDS) / m_caster->GetAttackTime(BASE_ATTACK);
damage += count * int32(average * IN_MILLISECONDS) / m_caster->GetAttackTime(BASE_ATTACK);
}
// Shield of Righteousness
else if (m_spellInfo->SpellFamilyFlags & UI64LIT(0x0010000000000000))
@ -4097,7 +4097,7 @@ void Spell::EffectDistract(SpellEffectIndex /*eff_idx*/)
// Set creature Distracted, Stop it, And turn it
unitTarget->SetOrientation(angle);
unitTarget->StopMoving();
unitTarget->GetMotionMaster()->MoveDistract(damage * IN_MILISECONDS);
unitTarget->GetMotionMaster()->MoveDistract(damage * IN_MILLISECONDS);
}
}
@ -5263,7 +5263,7 @@ void Spell::EffectSummonObjectWild(SpellEffectIndex eff_idx)
int32 duration = GetSpellDuration(m_spellInfo);
pGameObj->SetRespawnTime(duration > 0 ? duration/IN_MILISECONDS : 0);
pGameObj->SetRespawnTime(duration > 0 ? duration/IN_MILLISECONDS : 0);
pGameObj->SetSpellId(m_spellInfo->Id);
// Wild object not have owner and check clickable by players
@ -6214,7 +6214,7 @@ void Spell::EffectDuel(SpellEffectIndex eff_idx)
pGameObj->SetUInt32Value(GAMEOBJECT_FACTION, m_caster->getFaction() );
pGameObj->SetUInt32Value(GAMEOBJECT_LEVEL, m_caster->getLevel()+1 );
int32 duration = GetSpellDuration(m_spellInfo);
pGameObj->SetRespawnTime(duration > 0 ? duration/IN_MILISECONDS : 0);
pGameObj->SetRespawnTime(duration > 0 ? duration/IN_MILLISECONDS : 0);
pGameObj->SetSpellId(m_spellInfo->Id);
m_caster->AddGameObject(pGameObj);
@ -6291,7 +6291,7 @@ void Spell::EffectSummonPlayer(SpellEffectIndex /*eff_idx*/)
WorldPacket data(SMSG_SUMMON_REQUEST, 8+4+4);
data << uint64(m_caster->GetGUID()); // summoner guid
data << uint32(m_caster->GetZoneId()); // summoner zone
data << uint32(MAX_PLAYER_SUMMON_DELAY*IN_MILISECONDS); // auto decline after msecs
data << uint32(MAX_PLAYER_SUMMON_DELAY*IN_MILLISECONDS); // auto decline after msecs
((Player*)unitTarget)->GetSession()->SendPacket(&data);
}
@ -6457,7 +6457,7 @@ void Spell::EffectEnchantHeldItem(SpellEffectIndex eff_idx)
return;
// Apply the temporary enchantment
item->SetEnchantment(slot, enchant_id, duration*IN_MILISECONDS, 0);
item->SetEnchantment(slot, enchant_id, duration*IN_MILLISECONDS, 0);
item_owner->ApplyEnchantment(item, slot, true);
}
}
@ -6581,7 +6581,7 @@ void Spell::EffectSummonObject(SpellEffectIndex eff_idx)
pGameObj->SetUInt32Value(GAMEOBJECT_LEVEL,m_caster->getLevel());
int32 duration = GetSpellDuration(m_spellInfo);
pGameObj->SetRespawnTime(duration > 0 ? duration/IN_MILISECONDS : 0);
pGameObj->SetRespawnTime(duration > 0 ? duration/IN_MILLISECONDS : 0);
pGameObj->SetSpellId(m_spellInfo->Id);
m_caster->AddGameObject(pGameObj);
@ -7171,7 +7171,7 @@ void Spell::EffectTransmitted(SpellEffectIndex eff_idx)
case 3: lastSec = 17; break;
}
duration = duration - lastSec*IN_MILISECONDS + FISHING_BOBBER_READY_TIME*IN_MILISECONDS;
duration = duration - lastSec*IN_MILLISECONDS + FISHING_BOBBER_READY_TIME*IN_MILLISECONDS;
break;
}
case GAMEOBJECT_TYPE_SUMMONING_RITUAL:
@ -7189,7 +7189,7 @@ void Spell::EffectTransmitted(SpellEffectIndex eff_idx)
break;
}
pGameObj->SetRespawnTime(duration > 0 ? duration/IN_MILISECONDS : 0);
pGameObj->SetRespawnTime(duration > 0 ? duration/IN_MILLISECONDS : 0);
pGameObj->SetOwnerGUID(m_caster->GetGUID());