diff options
| -rw-r--r-- | sql/FULL/world_scripts_full.sql | 21 | ||||
| -rw-r--r-- | sql/updates/4423_world.sql | 18 | ||||
| -rw-r--r-- | src/game/SpellAuras.cpp | 5 | ||||
| -rw-r--r-- | src/game/SpellEffects.cpp | 5 | ||||
| -rw-r--r-- | src/game/SpellHandler.cpp | 2 | ||||
| -rw-r--r-- | src/game/SpellMgr.cpp | 2 | ||||
| -rw-r--r-- | src/game/Unit.cpp | 3 |
7 files changed, 50 insertions, 6 deletions
diff --git a/sql/FULL/world_scripts_full.sql b/sql/FULL/world_scripts_full.sql index 81238ac7ae4..b7063259cbb 100644 --- a/sql/FULL/world_scripts_full.sql +++ b/sql/FULL/world_scripts_full.sql @@ -1089,6 +1089,9 @@ UPDATE `creature_template` SET `ScriptName`='mob_batrider' WHERE `entry`=14965; UPDATE `creature_template` SET `ScriptName`='mob_shade_of_jindo' WHERE `entry`=14986; UPDATE `creature_template` SET `ScriptName`='mob_ohgan' WHERE `entry`=14988; +UPDATE `creature_template` SET `ScriptName`='EventAI', `modelid_A` = 16925,`modelid_H` = 16925, `minmana` = 1000000,`maxmana` = 1000000, `unit_flags` = 33554434 WHERE `entry` IN(29998, 33753, 33752, 33751, 33750); +DELETE FROM `creature_ai_scripts` WHERE `creature_id` IN (29998, 33753, 33752, 33751, 33750); + -- -------- -- EVENT AI -- -------- @@ -1119,6 +1122,20 @@ INSERT INTO `creature_ai_scripts` VALUES ( 2693001, 26930, 0, 0, 100, 3, 3000, 3000, 8000, 9000, 11, 47729, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Grand Magus Telestra frost - cast ice bard N'), ( 2693002, 26930, 0, 0, 100, 5, 3000, 3000, 8000, 9000, 11, 56937, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Grand Magus Telestra frost - cast ice bard H'), ( 2693003, 26930, 0, 0, 100, 3, 9000, 9000, 15000, 16000, 11, 47727, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Grand Magus Telestra frost - cast blizzard N'), -( 2693004, 26930, 0, 0, 100, 5, 9000, 9000, 15000, 16000, 11, 56936, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Grand Magus Telestra frost - cast blizzard H'); - +( 2693004, 26930, 0, 0, 100, 5, 9000, 9000, 15000, 16000, 11, 56936, 1, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Grand Magus Telestra frost - cast blizzard H'), +-- Desecration +( 2999801, 29998, 11, 0, 100, 0, 0, 0, 0, 0, 11, 55741, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Desecration'), +( 2999800, 29998, 1, 0, 100, 0, 1, 1, 0, 0, 11, 55671, 0, 2, 11, 55710, 0, 2, 0, 0, 0, 0, 'Desecration'), +-- Desecration +( 3375301, 33753, 11, 0, 100, 0, 0, 0, 0, 0, 11, 55741, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Desecration'), +( 3375300, 33753, 1, 0, 100, 0, 1, 1, 0, 0, 11, 63584, 0, 2, 11, 63580, 0, 2, 0, 0, 0, 0, 'Desecration'), +-- Desecration +( 3375201, 33752, 11, 0, 100, 0, 0, 0, 0, 0, 11, 55741, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Desecration'), +( 3375200, 33752, 1, 0, 100, 0, 1, 1, 0, 0, 11, 63585, 0, 2, 11, 63581, 0, 2, 0, 0, 0, 0, 'Desecration'), +-- Desecration +( 3375101, 33751, 11, 0, 100, 0, 0, 0, 0, 0, 11, 55741, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Desecration'), +( 3375100, 33751, 1, 0, 100, 0, 1, 1, 0, 0, 11, 63586, 0, 2, 11, 63582, 0, 2, 0, 0, 0, 0, 'Desecration'), +-- Desecration +( 3375001, 33750, 11, 0, 100, 0, 0, 0, 0, 0, 11, 55741, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Desecration'), +( 3375000, 33750, 1, 0, 100, 0, 1, 1, 0, 0, 11, 63587, 0, 2, 11, 63583, 0, 2, 0, 0, 0, 0, 'Desecration'); /* EOF */
\ No newline at end of file diff --git a/sql/updates/4423_world.sql b/sql/updates/4423_world.sql new file mode 100644 index 00000000000..638d0d3c9d9 --- /dev/null +++ b/sql/updates/4423_world.sql @@ -0,0 +1,18 @@ +UPDATE `creature_template` SET `ScriptName`='EventAI', `modelid_A` = 16925,`modelid_H` = 16925, `minmana` = 1000000,`maxmana` = 1000000, `unit_flags` = 33554434 WHERE `entry` IN(29998, 33753, 33752, 33751, 33750); +DELETE FROM `creature_ai_scripts` WHERE `creature_id` IN (29998, 33753, 33752, 33751, 33750); +INSERT INTO `creature_ai_scripts` VALUES +-- Desecration +( 2999801, 29998, 11, 0, 100, 0, 0, 0, 0, 0, 11, 55741, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Desecration'), +( 2999800, 29998, 1, 0, 100, 0, 1, 1, 0, 0, 11, 55671, 0, 2, 11, 55710, 0, 2, 0, 0, 0, 0, 'Desecration'), +-- Desecration +( 3375301, 33753, 11, 0, 100, 0, 0, 0, 0, 0, 11, 55741, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Desecration'), +( 3375300, 33753, 1, 0, 100, 0, 1, 1, 0, 0, 11, 63584, 0, 2, 11, 63580, 0, 2, 0, 0, 0, 0, 'Desecration'), +-- Desecration +( 3375201, 33752, 11, 0, 100, 0, 0, 0, 0, 0, 11, 55741, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Desecration'), +( 3375200, 33752, 1, 0, 100, 0, 1, 1, 0, 0, 11, 63585, 0, 2, 11, 63581, 0, 2, 0, 0, 0, 0, 'Desecration'), +-- Desecration +( 3375101, 33751, 11, 0, 100, 0, 0, 0, 0, 0, 11, 55741, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Desecration'), +( 3375100, 33751, 1, 0, 100, 0, 1, 1, 0, 0, 11, 63586, 0, 2, 11, 63582, 0, 2, 0, 0, 0, 0, 'Desecration'), +-- Desecration +( 3375001, 33750, 11, 0, 100, 0, 0, 0, 0, 0, 11, 55741, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 'Desecration'), +( 3375000, 33750, 1, 0, 100, 0, 1, 1, 0, 0, 11, 63587, 0, 2, 11, 63583, 0, 2, 0, 0, 0, 0, 'Desecration'); diff --git a/src/game/SpellAuras.cpp b/src/game/SpellAuras.cpp index dbf657afe3f..333759358a4 100644 --- a/src/game/SpellAuras.cpp +++ b/src/game/SpellAuras.cpp @@ -766,7 +766,8 @@ void AreaAuraEffect::Update(uint32 diff) case AREA_AURA_PET: { if(Unit *owner = caster->GetCharmerOrOwner()) - targets.push_back(owner); + if (owner->IsWithinDistInMap(source, m_radius)) + targets.push_back(owner); break; } } @@ -836,7 +837,7 @@ void AreaAuraEffect::Update(uint32 diff) } else if (!source->IsWithinDistInMap(m_target, m_radius)) { - if (needFriendly) + if (needFriendly && source->isMoving()) { m_removeTime -= diff; if (m_removeTime < 0) diff --git a/src/game/SpellEffects.cpp b/src/game/SpellEffects.cpp index 44a30705784..3294c32bde8 100644 --- a/src/game/SpellEffects.cpp +++ b/src/game/SpellEffects.cpp @@ -3470,7 +3470,10 @@ void Spell::EffectSummonType(uint32 i) TempSummon * summon = m_originalCaster->SummonCreature(entry,px,py,pz,m_caster->GetOrientation(),summonType,duration); if (properties->Category == SUMMON_CATEGORY_ALLY) - summon->setFaction(m_caster->getFaction()); + { + summon->SetUInt64Value(UNIT_FIELD_SUMMONEDBY, m_originalCaster->GetGUID()); + summon->setFaction(m_originalCaster->getFaction()); + } } break; } diff --git a/src/game/SpellHandler.cpp b/src/game/SpellHandler.cpp index 74313eaa38b..0e9261598a8 100644 --- a/src/game/SpellHandler.cpp +++ b/src/game/SpellHandler.cpp @@ -359,7 +359,7 @@ void WorldSession::HandleCastSpellOpcode(WorldPacket& recvPacket) } Spell *spell = new Spell(mover, spellInfo, false); - spell->m_cast_count = cast_count; // set count of casts + spell->m_cast_count = ++cast_count; // set count of casts spell->prepare(&targets); } diff --git a/src/game/SpellMgr.cpp b/src/game/SpellMgr.cpp index b6bbf322b95..b5911954ce7 100644 --- a/src/game/SpellMgr.cpp +++ b/src/game/SpellMgr.cpp @@ -3568,6 +3568,8 @@ void SpellMgr::LoadSpellCustomAttr() case 51904: // Summon Ghouls On Scarlet Crusade (core does not know the triggered spell is summon spell) spellInfo->EffectImplicitTargetA[0] = TARGET_UNIT_CASTER; break; + case 29809: // Desecration Arm - 36 instead of 37 - typo? :/ + spellInfo->EffectRadiusIndex[0] = 37; default: break; } diff --git a/src/game/Unit.cpp b/src/game/Unit.cpp index 30af6796c9b..0254d255f2c 100644 --- a/src/game/Unit.cpp +++ b/src/game/Unit.cpp @@ -12686,6 +12686,7 @@ void Unit::ProcDamageAndSpellFor( bool isVictim, Unit * pTarget, uint32 procFlag DealDamageMods(damageInfo.target,damageInfo.damage,&damageInfo.absorb); SendSpellNonMeleeDamageLog(&damageInfo); DealSpellDamage(&damageInfo, true); + takeCharges=true; break; } case SPELL_AURA_MANA_SHIELD: @@ -12751,6 +12752,7 @@ void Unit::ProcDamageAndSpellFor( bool isVictim, Unit * pTarget, uint32 procFlag (isVictim?"a victim's":"an attacker's"),triggeredByAura->GetId()); HandleAuraRaidProcFromChargeWithValue(triggeredByAura); + takeCharges=true; break; } case SPELL_AURA_RAID_PROC_FROM_CHARGE: @@ -12759,6 +12761,7 @@ void Unit::ProcDamageAndSpellFor( bool isVictim, Unit * pTarget, uint32 procFlag (isVictim?"a victim's":"an attacker's"),triggeredByAura->GetId()); HandleAuraRaidProcFromCharge(triggeredByAura); + takeCharges=true; break; } case SPELL_AURA_PROC_TRIGGER_SPELL_WITH_VALUE: |
