mirror of
https://github.com/mangosfour/server.git
synced 2025-12-14 16:37:01 +00:00
Merge commit 'origin/master' into 310
Conflicts: src/game/UpdateData.cpp
This commit is contained in:
commit
e75e66063e
38 changed files with 687 additions and 537 deletions
|
|
@ -2156,7 +2156,6 @@ void Spell::EffectTeleportUnits(uint32 i)
|
|||
return;
|
||||
}
|
||||
// Init dest coordinates
|
||||
uint32 mapid = m_caster->GetMapId();
|
||||
float x = m_targets.m_destX;
|
||||
float y = m_targets.m_destY;
|
||||
float z = m_targets.m_destZ;
|
||||
|
|
@ -2558,7 +2557,7 @@ void Spell::EffectHealthLeech(uint32 i)
|
|||
|
||||
int32 new_damage = int32(damage*multiplier);
|
||||
uint32 curHealth = unitTarget->GetHealth();
|
||||
new_damage = m_caster->SpellNonMeleeDamageLog(unitTarget, m_spellInfo->Id, new_damage, m_IsTriggeredSpell, true);
|
||||
new_damage = m_caster->SpellNonMeleeDamageLog(unitTarget, m_spellInfo->Id, new_damage );
|
||||
if(curHealth < new_damage)
|
||||
new_damage = curHealth;
|
||||
|
||||
|
|
@ -2925,6 +2924,8 @@ void Spell::SendLoot(uint64 guid, LootType loottype)
|
|||
gameObjTarget->TriggeringLinkedGameObject(trapEntry,m_caster);
|
||||
|
||||
// Don't return, let loots been taken
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -3849,7 +3850,7 @@ void Spell::EffectEnchantItemPrismatic(uint32 effect_idx)
|
|||
}
|
||||
if(!add_socket)
|
||||
{
|
||||
sLog.outError("Spell::EffectEnchantItemPrismatic: attempt apply enchant spell %u with SPELL_EFFECT_ENCHANT_ITEM_PRISMATIC (%u) but without ITEM_ENCHANTMENT_TYPE_PRISMATIC_SOCKET (u), not suppoted yet.",
|
||||
sLog.outError("Spell::EffectEnchantItemPrismatic: attempt apply enchant spell %u with SPELL_EFFECT_ENCHANT_ITEM_PRISMATIC (%u) but without ITEM_ENCHANTMENT_TYPE_PRISMATIC_SOCKET (%u), not suppoted yet.",
|
||||
m_spellInfo->Id,SPELL_EFFECT_ENCHANT_ITEM_PRISMATIC,ITEM_ENCHANTMENT_TYPE_PRISMATIC_SOCKET);
|
||||
return;
|
||||
}
|
||||
|
|
@ -4906,11 +4907,23 @@ void Spell::EffectScriptEffect(uint32 effIndex)
|
|||
uint32 spellID = m_spellInfo->CalculateSimpleValue(0);
|
||||
uint32 questID = m_spellInfo->CalculateSimpleValue(1);
|
||||
|
||||
if( ((Player*)unitTarget)->GetQuestStatus(questID) == QUEST_STATUS_COMPLETE && !((Player*)unitTarget)->GetQuestRewardStatus (questID) )
|
||||
if (((Player*)unitTarget)->GetQuestStatus(questID) == QUEST_STATUS_COMPLETE && !((Player*)unitTarget)->GetQuestRewardStatus (questID))
|
||||
unitTarget->CastSpell(unitTarget, spellID, true);
|
||||
|
||||
return;
|
||||
}
|
||||
case 59317: // Teleporting
|
||||
if (!unitTarget || unitTarget->GetTypeId() != TYPEID_PLAYER)
|
||||
return;
|
||||
|
||||
// return from top
|
||||
if (((Player*)unitTarget)->GetAreaId() == 4637)
|
||||
unitTarget->CastSpell(unitTarget, 59316, true);
|
||||
// teleport atop
|
||||
else
|
||||
unitTarget->CastSpell(unitTarget, 59314, true);
|
||||
|
||||
return;
|
||||
// random spell learn instead placeholder
|
||||
case 60893: // Northrend Alchemy Research
|
||||
case 61177: // Northrend Inscription Research
|
||||
|
|
@ -5974,9 +5987,9 @@ void Spell::EffectSummonCritter(uint32 i)
|
|||
|
||||
critter->AIM_Initialize();
|
||||
critter->InitPetCreateSpells(); // e.g. disgusting oozeling has a create spell as critter...
|
||||
critter->SetMaxHealth(1);
|
||||
critter->SetHealth(1);
|
||||
critter->SetLevel(1);
|
||||
critter->SelectLevel(critter->GetCreatureInfo()); // some summoned creaters have different from 1 DB data for level/hp
|
||||
critter->SetUInt32Value(UNIT_NPC_FLAGS, critter->GetCreatureInfo()->npcflag);
|
||||
// some mini-pets have quests
|
||||
|
||||
// set timer for unsummon
|
||||
int32 duration = GetSpellDuration(m_spellInfo);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue