Scripts/Icecrown Citadel: Added Professor Putricide script

Scripts/Icecrown Citadel: Fixed Professor Putricide gate opening when both Rotface and Festergut are dead
Scripts/Icecrown Citadel: Added script updating entries of NPCs at Light's Hammer depending on faction
Scripts/Icecrown Citadel: Rotface should not pick main tank as target for Slime Spray (removed debugging code)
Core/Spells/Conditions : Spell script target condition now accepts ConditionValue3 as affecting effect mask (only search targets with matching mask)

--HG--
branch : trunk
This commit is contained in:
Shauren
2010-10-16 16:34:21 +02:00
parent 8154f7243c
commit 4ce274dbcd
18 changed files with 1412 additions and 98 deletions
+37 -1
View File
@@ -19363,9 +19363,13 @@ INSERT INTO `spell_proc_event` (`entry`,`SchoolMask`,`SpellFamilyName`,`SpellFam
( 72419, 0x00, 0, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0, 0, 60), -- Item - Icecrown Reputation Ring Healer Trigger
( 71404, 0x00, 0, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000002, 0, 0, 45), -- Item - Icecrown Dungeon Melee Trinket
( 71564, 0x00, 0, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000002, 0, 0, 0), -- Nevermelting Ice Crystal
(71545, 0x00, 0, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0, 50, 0), -- Tiny Abomination in a Jar (Heroic)
( 71545, 0x00, 0, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0, 50, 0), -- Tiny Abomination in a Jar (Heroic)
( 71406, 0x00, 0, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0, 50, 0), -- Tiny Abomination in a Jar
( 71903, 0x00, 0, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0, 20, 0), -- Item - Shadowmourne Legendary
( 70215, 0x00, 0, 0x00000000, 0x00000000, 0x00000000, 0x00000004, 0x00000000, 0, 100, 0), -- Gaseous Bloat
( 72858, 0x00, 0, 0x00000000, 0x00000000, 0x00000000, 0x00000004, 0x00000000, 0, 100, 0), -- Gaseous Bloat
( 72859, 0x00, 0, 0x00000000, 0x00000000, 0x00000000, 0x00000004, 0x00000000, 0, 100, 0), -- Gaseous Bloat
( 72860, 0x00, 0, 0x00000000, 0x00000000, 0x00000000 ,0x00000004, 0x00000000, 0, 100, 0), -- Gaseous Bloat
( 75474, 0x00, 0, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0, 0, 45), -- Charred Twilight Scale (Heroic)
( 75465, 0x00, 0, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0, 0, 45), -- Charred Twilight Scale
( 75457, 0x00, 0, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0x00000000, 0, 0, 45), -- Sharpened Twilight Scale (Heroic)
@@ -26825,6 +26829,38 @@ INSERT INTO `spell_script_names` (`spell_id`,`ScriptName`) VALUES
( 69839, 'spell_rotface_unstable_ooze_explosion_init'),
( 69832, 'spell_rotface_unstable_ooze_explosion'),
( 71441, 'spell_rotface_unstable_ooze_explosion_suicide'),
( 70701, 'spell_putricide_expunged_gas'),
( 70343, 'spell_putricide_slime_puddle'),
( 70351, 'spell_putricide_unstable_experiment'),
( 71966, 'spell_putricide_unstable_experiment'),
( 71967, 'spell_putricide_unstable_experiment'),
( 71968, 'spell_putricide_unstable_experiment'),
( 71412, 'spell_putricide_ooze_summon'),
( 71415, 'spell_putricide_ooze_summon'),
( 70672, 'spell_putricide_gaseous_bloat'),
( 72455, 'spell_putricide_gaseous_bloat'),
( 72832, 'spell_putricide_gaseous_bloat'),
( 72833, 'spell_putricide_gaseous_bloat'),
( 70459, 'spell_putricide_ooze_eruption_searcher'),
( 71255, 'spell_putricide_choking_gas_bomb'),
( 70920, 'spell_putricide_unbound_plague'),
( 70360, 'spell_putricide_eat_ooze'),
( 72527, 'spell_putricide_eat_ooze'),
( 72451, 'spell_putricide_mutated_plague'),
( 72463, 'spell_putricide_mutated_plague'),
( 72671, 'spell_putricide_mutated_plague'),
( 72672, 'spell_putricide_mutated_plague'),
( 70308, 'spell_putricide_mutation_init'),
( 70311, 'spell_putricide_mutated_transformation'),
( 71503, 'spell_putricide_mutated_transformation'),
( 70405, 'spell_putricide_mutated_transformation_dismiss'),
( 72508, 'spell_putricide_mutated_transformation_dismiss'),
( 72509, 'spell_putricide_mutated_transformation_dismiss'),
( 72510, 'spell_putricide_mutated_transformation_dismiss'),
( 70539, 'spell_putricide_regurgitated_ooze'),
( 72457, 'spell_putricide_regurgitated_ooze'),
( 72875, 'spell_putricide_regurgitated_ooze'),
( 72876, 'spell_putricide_regurgitated_ooze'),
( 62717, 'spell_ignis_slag_pot'),
( 63477, 'spell_ignis_slag_pot'),
-- quest
+13
View File
@@ -2888,6 +2888,19 @@ INSERT INTO `script_texts` (`npc_entry`,`entry`,`content_default`,`content_loc1`
(36627,-1631102,'Sleepy Time!',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,16990,1,0,0,'SAY_BERSERK'),
(36627,-1631103,'Bad news daddy...',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,16989,1,0,0,'SAY_DEATH'),
-- Professor Putricide
(36678,-1631104,'Good news, everyone! I think I perfected a plague that will destroy all life on Azeroth!',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,17114,1,0,0,'SAY_AGGRO'),
(36678,-1631105,'%s begins to cast Unstable Experiment!',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,3,0,0,'EMOTE_UNSTABLE_EXPERIMENT'),
(36678,-1631106,'Two oozes, one room! So many delightful possibilities...',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,17122,1,0,0,'SAY_PHASE_TRANSITION_HEROIC'),
(36678,-1631107,'Hmm. I don''t feel a thing. Whaa...? Where''d those come from?',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,17120,1,0,15,'SAY_TRANSFORM_1'),
(36678,-1631108,'Tastes like... Cherry! Oh! Excuse me!',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,17121,1,0,15,'SAY_TRANSFORM_2'),
(36678,-1631109,'|TInterface\Icons\inv_misc_herb_evergreenmoss.blp:16|t%s cast |cFF00FF00Malleable Goo!|r',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,3,0,0,'EMOTE_MALLEABLE_GOO'),
(36678,-1631110,'%s cast |cFFFF7F00Choking Gas Bomb!|r',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,3,0,0,'EMOTE_CHOKING_GAS_BOMB'),
(36678,-1631111,'Hmm... Interesting...',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,17115,1,0,0,'SAY_KILL_1'),
(36678,-1631112,'That was unexpected!',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,17116,1,0,0,'SAY_KILL_2'),
(36678,-1631113,'Great news, everyone!',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,17118,1,0,0,'SAY_BERSERK'),
(36678,-1631114,'Bad news, everyone! I don''t think I''m going to make it.',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,17117,1,0,0,'SAY_DEATH'),
-- -1 632 000 ICECROWN CITADEL: FROZEN HALLS: FORGE OF SOULS
-- Bronjham
(36497,-1632001,'Finally...a captive audience!',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,16595,1,0,0,'Bronjham SAY_AGGRO'),
+1
View File
@@ -848,6 +848,7 @@ UPDATE `creature_template` SET `ScriptName`='npc_little_ooze' WHERE `entry`=3689
UPDATE `creature_template` SET `ScriptName`='npc_big_ooze' WHERE `entry`=36899;
UPDATE `creature_template` SET `ScriptName`='npc_precious_icc' WHERE `entry`=37217;
UPDATE `creature_template` SET `ScriptName`='boss_professor_putricide' WHERE `entry`=36678;
UPDATE `creature_template` SET `ScriptName`='npc_volatile_ooze' WHERE `entry`=37697;
/* IRONFORGE */
UPDATE `creature_template` SET `ScriptName`='npc_royal_historian_archesonus' WHERE `entry`=8879;
+13
View File
@@ -0,0 +1,13 @@
DELETE FROM `script_texts` WHERE `entry` BETWEEN -1631114 AND -1631104;
INSERT INTO `script_texts` (`npc_entry`,`entry`,`content_default`,`content_loc1`,`content_loc2`,`content_loc3`,`content_loc4`,`content_loc5`,`content_loc6`,`content_loc7`,`content_loc8`,`sound`,`type`,`language`,`emote`,`comment`) VALUES
(36678,-1631104,'Good news, everyone! I think I perfected a plague that will destroy all life on Azeroth!',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,17114,1,0,0,'SAY_AGGRO'),
(36678,-1631105,'%s begins to cast Unstable Experiment!',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,3,0,0,'EMOTE_UNSTABLE_EXPERIMENT'),
(36678,-1631106,'Two oozes, one room! So many delightful possibilities...',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,17122,1,0,0,'SAY_PHASE_TRANSITION_HEROIC'),
(36678,-1631107,'Hmm. I don''t feel a thing. Whaa...? Where''d those come from?',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,17120,1,0,15,'SAY_TRANSFORM_1'),
(36678,-1631108,'Tastes like... Cherry! Oh! Excuse me!',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,17121,1,0,15,'SAY_TRANSFORM_2'),
(36678,-1631109,'|TInterface\Icons\inv_misc_herb_evergreenmoss.blp:16|t%s cast |cFF00FF00Malleable Goo!|r',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,3,0,0,'EMOTE_MALLEABLE_GOO'),
(36678,-1631110,'%s cast |cFFFF7F00Choking Gas Bomb!|r',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,0,3,0,0,'EMOTE_CHOKING_GAS_BOMB'),
(36678,-1631111,'Hmm... Interesting...',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,17115,1,0,0,'SAY_KILL_1'),
(36678,-1631112,'That was unexpected!',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,17116,1,0,0,'SAY_KILL_2'),
(36678,-1631113,'Great news, everyone!',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,17118,1,0,0,'SAY_BERSERK'),
(36678,-1631114,'Bad news, everyone! I don''t think I''m going to make it.',NULL,NULL,NULL,NULL,NULL,NULL,NULL,NULL,17117,1,0,0,'SAY_DEATH');
+1
View File
@@ -0,0 +1 @@
UPDATE `creature_template` SET `ScriptName`='npc_volatile_ooze' WHERE `entry`=37697;
@@ -0,0 +1,6 @@
DELETE FROM `spell_proc_event` WHERE `entry` IN (70215,72858,72859,72860);
INSERT INTO `spell_proc_event` (`entry`,`SchoolMask`,`SpellFamilyName`,`SpellFamilyMask0`,`SpellFamilyMask1`,`SpellFamilyMask2`,`procFlags`,`procEx`,`ppmRate`,`CustomChance`,`Cooldown`) VALUES
(70215,0x00,0,0x00000000,0x00000000,0x00000000,0x00000004,0x00000000,0,100,0), -- Gaseous Bloat
(72858,0x00,0,0x00000000,0x00000000,0x00000000,0x00000004,0x00000000,0,100,0), -- Gaseous Bloat
(72859,0x00,0,0x00000000,0x00000000,0x00000000,0x00000004,0x00000000,0,100,0), -- Gaseous Bloat
(72860,0x00,0,0x00000000,0x00000000,0x00000000,0x00000004,0x00000000,0,100,0); -- Gaseous Bloat
@@ -0,0 +1,47 @@
DELETE FROM `spell_script_names` WHERE `spell_id`=70701 AND `ScriptName`='spell_putricide_expunged_gas';
DELETE FROM `spell_script_names` WHERE `spell_id`=70343 AND `ScriptName`='spell_putricide_slime_puddle';
DELETE FROM `spell_script_names` WHERE `spell_id` IN (70351,71966,71967,71968) AND `ScriptName`='spell_putricide_unstable_experiment';
DELETE FROM `spell_script_names` WHERE `spell_id` IN (71412,71415) AND `ScriptName`='spell_putricide_ooze_summon';
DELETE FROM `spell_script_names` WHERE `spell_id` IN (70672,72455,72832,72833) AND `ScriptName`='spell_putricide_gaseous_bloat';
DELETE FROM `spell_script_names` WHERE `spell_id`=70459 AND `ScriptName`='spell_putricide_ooze_eruption_searcher';
DELETE FROM `spell_script_names` WHERE `spell_id`=71255 AND `ScriptName`='spell_putricide_choking_gas_bomb';
DELETE FROM `spell_script_names` WHERE `spell_id`=70920 AND `ScriptName`='spell_putricide_unbound_plague';
DELETE FROM `spell_script_names` WHERE `spell_id` IN (70360,72527) AND `ScriptName`='spell_putricide_eat_ooze';
DELETE FROM `spell_script_names` WHERE `spell_id` IN (72451,72463,72671,72672) AND `ScriptName`='spell_putricide_mutated_plague';
DELETE FROM `spell_script_names` WHERE `spell_id`=70308 AND `ScriptName`='spell_putricide_mutation_init';
DELETE FROM `spell_script_names` WHERE `spell_id` IN (70311,71503) AND `ScriptName`='spell_putricide_mutated_transformation';
DELETE FROM `spell_script_names` WHERE `spell_id` IN (70405,72508,72509,72510) AND `ScriptName`='spell_putricide_mutated_transformation_dismiss';
DELETE FROM `spell_script_names` WHERE `spell_id` IN (70539,72457,72875,72876) AND `ScriptName`='spell_putricide_regurgitated_ooze';
INSERT INTO `spell_script_names` (`spell_id`, `ScriptName`) VALUES
(70701,'spell_putricide_expunged_gas'),
(70343,'spell_putricide_slime_puddle'),
(70351,'spell_putricide_unstable_experiment'),
(71966,'spell_putricide_unstable_experiment'),
(71967,'spell_putricide_unstable_experiment'),
(71968,'spell_putricide_unstable_experiment'),
(71412,'spell_putricide_ooze_summon'),
(71415,'spell_putricide_ooze_summon'),
(70672,'spell_putricide_gaseous_bloat'),
(72455,'spell_putricide_gaseous_bloat'),
(72832,'spell_putricide_gaseous_bloat'),
(72833,'spell_putricide_gaseous_bloat'),
(70459,'spell_putricide_ooze_eruption_searcher'),
(71255,'spell_putricide_choking_gas_bomb'),
(70920,'spell_putricide_unbound_plague'),
(70360,'spell_putricide_eat_ooze'),
(72527,'spell_putricide_eat_ooze'),
(72451,'spell_putricide_mutated_plague'),
(72463,'spell_putricide_mutated_plague'),
(72671,'spell_putricide_mutated_plague'),
(72672,'spell_putricide_mutated_plague'),
(70308,'spell_putricide_mutation_init'),
(70311,'spell_putricide_mutated_transformation'),
(71503,'spell_putricide_mutated_transformation'),
(70405,'spell_putricide_mutated_transformation_dismiss'),
(72508,'spell_putricide_mutated_transformation_dismiss'),
(72509,'spell_putricide_mutated_transformation_dismiss'),
(72510,'spell_putricide_mutated_transformation_dismiss'),
(70539,'spell_putricide_regurgitated_ooze'),
(72457,'spell_putricide_regurgitated_ooze'),
(72875,'spell_putricide_regurgitated_ooze'),
(72876,'spell_putricide_regurgitated_ooze');
+9 -5
View File
@@ -828,10 +828,17 @@ bool ConditionMgr::isSourceTypeValid(Condition* cond)
spellProto->EffectImplicitTargetB[i] == TARGET_UNIT_CONE_ENTRY)
{
targetfound = true;
break;
//break;
}
else if (cond->mConditionValue3 & (1 << i))
{
cond->mConditionValue3 &= ~(1 << i);
sLog.outErrorDb("SourceEntry %u in `condition` table does not have any implicit target TARGET_UNIT_NEARBY_ENTRY(38) or TARGET_DST_NEARBY_ENTRY (46)"
",TARGET_UNIT_AREA_ENTRY_SRC(7), TARGET_UNIT_AREA_ENTRY_DST(8), TARGET_UNIT_CONE_ENTRY(60), TARGET_GAMEOBJECT_NEARBY_ENTRY(40)"
"TARGET_GAMEOBJECT_AREA_SRC(51), TARGET_GAMEOBJECT_AREA_DST(52) in effect %u", cond->mSourceEntry, uint32(i));
}
}
if (!targetfound)
if (!targetfound && !cond->mConditionValue3) // cond->mConditionValue3 already errored up there
{
sLog.outErrorDb("SourceEntry %u in `condition` table does not have any implicit target TARGET_UNIT_NEARBY_ENTRY(38) or TARGET_DST_NEARBY_ENTRY (46)"
",TARGET_UNIT_AREA_ENTRY_SRC(7), TARGET_UNIT_AREA_ENTRY_DST(8), TARGET_UNIT_CONE_ENTRY(60), TARGET_GAMEOBJECT_NEARBY_ENTRY(40)"
@@ -1175,9 +1182,6 @@ bool ConditionMgr::isConditionTypeValid(Condition* cond)
break;
}
}
if (cond->mConditionValue3)
sLog.outErrorDb("SpellTarget condition has useless data in value3 (%u)!", cond->mConditionValue3);
break;
}
case CONDITION_CREATURE_TARGET:
+10
View File
@@ -5701,6 +5701,16 @@ bool Unit::HandleDummyAuraProc(Unit *pVictim, uint32 damage, AuraEffect* trigger
target = triggeredByAura->GetCaster();
break;
}
// Gaseous Bloat (Professor Putricide add)
case 70215:
case 72858:
case 72859:
case 72860:
{
target = getVictim();
triggered_spell_id = 70701;
break;
}
}
break;
}
@@ -1004,10 +1004,10 @@ enum AuraState
AURA_STATE_DEADLY_POISON = 16, // T |
AURA_STATE_ENRAGE = 17, // C |
AURA_STATE_BLEEDING = 18, // T|
//AURA_STATE_UNKNOWN19 = 19, // | not used
AURA_STATE_UNKNOWN19 = 19, // |
//AURA_STATE_UNKNOWN20 = 20, // c | only (45317 Suicide)
//AURA_STATE_UNKNOWN21 = 21, // | not used
//AURA_STATE_UNKNOWN22 = 22, // C t| varius spells (63884, 50240)
AURA_STATE_UNKNOWN22 = 22, // C t| varius spells (63884, 50240)
AURA_STATE_HEALTH_ABOVE_75_PERCENT = 23, // C |
};
@@ -1316,6 +1316,20 @@ void AuraEffect::PeriodicTick(Unit * target, Unit * caster) const
}
}
}
if (GetSpellProto()->SpellFamilyName == SPELLFAMILY_GENERIC)
{
switch (GetId())
{
case 70911: // Unbound Plague
case 72854: // Unbound Plague
case 72855: // Unbound Plague
case 72856: // Unbound Plague
damage *= uint32(pow(1.25f, int32(m_tickNumber)));
break;
default:
break;
}
}
}
else
damage = uint32(target->CountPctFromMaxHealth(damage));
+13 -7
View File
@@ -1877,7 +1877,7 @@ void Spell::SearchGOAreaTarget(std::list<GameObject*> &TagGOMap, float radius, S
m_caster->GetMap()->VisitGrid(pos->m_positionX, pos->m_positionY, radius, searcher);
}
WorldObject* Spell::SearchNearbyTarget(float range, SpellTargets TargetType)
WorldObject* Spell::SearchNearbyTarget(float range, SpellTargets TargetType, SpellEffIndex effIndex)
{
switch(TargetType)
{
@@ -1888,9 +1888,9 @@ WorldObject* Spell::SearchNearbyTarget(float range, SpellTargets TargetType)
{
sLog.outDebug("Spell (ID: %u) (caster Entry: %u) does not have record in `conditions` for spell script target (ConditionSourceType 14)", m_spellInfo->Id, m_caster->GetEntry());
if (IsPositiveSpell(m_spellInfo->Id))
return SearchNearbyTarget(range, SPELL_TARGETS_ALLY);
return SearchNearbyTarget(range, SPELL_TARGETS_ALLY, effIndex);
else
return SearchNearbyTarget(range, SPELL_TARGETS_ENEMY);
return SearchNearbyTarget(range, SPELL_TARGETS_ENEMY, effIndex);
}
Creature* creatureScriptTarget = NULL;
@@ -1900,6 +1900,8 @@ WorldObject* Spell::SearchNearbyTarget(float range, SpellTargets TargetType)
{
if ((*i_spellST)->mConditionType != CONDITION_SPELL_SCRIPT_TARGET)
continue;
if ((*i_spellST)->mConditionValue3 && !((*i_spellST)->mConditionValue3 & (1 << uint32(effIndex))))
continue;
switch((*i_spellST)->mConditionValue1)
{
case SPELL_TARGET_TYPE_CONTROLLED:
@@ -2087,20 +2089,20 @@ void Spell::SelectEffectTargets(uint32 i, uint32 cur)
case TARGET_UNIT_NEARBY_ENEMY:
range = GetSpellMaxRange(m_spellInfo, false);
if (modOwner) modOwner->ApplySpellMod(m_spellInfo->Id, SPELLMOD_RANGE, range, this);
target = SearchNearbyTarget(range, SPELL_TARGETS_ENEMY);
target = SearchNearbyTarget(range, SPELL_TARGETS_ENEMY, SpellEffIndex(i));
break;
case TARGET_UNIT_NEARBY_ALLY:
case TARGET_UNIT_NEARBY_ALLY_UNK:
case TARGET_UNIT_NEARBY_RAID:
range = GetSpellMaxRange(m_spellInfo, true);
if (modOwner) modOwner->ApplySpellMod(m_spellInfo->Id, SPELLMOD_RANGE, range, this);
target = SearchNearbyTarget(range, SPELL_TARGETS_ALLY);
target = SearchNearbyTarget(range, SPELL_TARGETS_ALLY, SpellEffIndex(i));
break;
case TARGET_UNIT_NEARBY_ENTRY:
case TARGET_GAMEOBJECT_NEARBY_ENTRY:
range = GetSpellMaxRange(m_spellInfo, IsPositiveSpell(m_spellInfo->Id));
if (modOwner) modOwner->ApplySpellMod(m_spellInfo->Id, SPELLMOD_RANGE, range, this);
target = SearchNearbyTarget(range, SPELL_TARGETS_ENTRY);
target = SearchNearbyTarget(range, SPELL_TARGETS_ENTRY, SpellEffIndex(i));
break;
}
@@ -2303,7 +2305,7 @@ void Spell::SelectEffectTargets(uint32 i, uint32 cur)
float range = GetSpellMaxRange(m_spellInfo, IsPositiveSpell(m_spellInfo->Id));
if (modOwner) modOwner->ApplySpellMod(m_spellInfo->Id, SPELLMOD_RANGE, range, this);
if (WorldObject *target = SearchNearbyTarget(range, SPELL_TARGETS_ENTRY))
if (WorldObject *target = SearchNearbyTarget(range, SPELL_TARGETS_ENTRY, SpellEffIndex(i)))
m_targets.setDst(*target);
break;
}
@@ -2473,6 +2475,8 @@ void Spell::SelectEffectTargets(uint32 i, uint32 cur)
{
if ((*i_spellST)->mConditionType != CONDITION_SPELL_SCRIPT_TARGET)
continue;
if ((*i_spellST)->mConditionValue3 && !((*i_spellST)->mConditionValue3 & (1<<i)))
continue;
if ((*i_spellST)->mConditionValue1 == SPELL_TARGET_TYPE_CREATURE)
SearchAreaTarget(unitList, radius, pushType, SPELL_TARGETS_ENTRY, (*i_spellST)->mConditionValue2);
else if ((*i_spellST)->mConditionValue1 == SPELL_TARGET_TYPE_CONTROLLED)
@@ -2568,6 +2572,8 @@ void Spell::SelectEffectTargets(uint32 i, uint32 cur)
{
if ((*i_spellST)->mConditionType != CONDITION_SPELL_SCRIPT_TARGET)
continue;
if ((*i_spellST)->mConditionValue3 && !((*i_spellST)->mConditionValue3 & (1<<i)))
continue;
if ((*i_spellST)->mConditionValue1 == SPELL_TARGET_TYPE_GAMEOBJECT)
SearchGOAreaTarget(gobjectList, radius, pushType, SPELL_TARGETS_GO, (*i_spellST)->mConditionValue2);
}
+1 -1
View File
@@ -660,7 +660,7 @@ class Spell
void SearchAreaTarget(std::list<Unit*> &unitList, float radius, SpellNotifyPushType type, SpellTargets TargetType, uint32 entry = 0);
void SearchGOAreaTarget(std::list<GameObject*> &gobjectList, float radius, SpellNotifyPushType type, SpellTargets TargetType, uint32 entry = 0);
void SearchChainTarget(std::list<Unit*> &unitList, float radius, uint32 unMaxTargets, SpellTargets TargetType);
WorldObject* SearchNearbyTarget(float range, SpellTargets TargetType);
WorldObject* SearchNearbyTarget(float range, SpellTargets TargetType, SpellEffIndex effIndex);
bool IsValidSingleTargetEffect(Unit const* target, Targets type) const;
bool IsValidSingleTargetSpell(Unit const* target) const;
bool IsValidDeadOrAliveTarget(Unit const* target) const;
+40
View File
@@ -3605,6 +3605,8 @@ void SpellMgr::LoadSpellCustomAttr()
case 64422: case 64688: // Sonic Screech
case 72373: // Shared Suffering
case 71904: // Chaos Bane
case 70492: case 72505: // Ooze Eruption
case 72624: case 72625: // Ooze Eruption
// ONLY SPELLS WITH SPELLFAMILY_GENERIC and EFFECT_SCHOOL_DAMAGE
mSpellCustomAttr[i] |= SPELL_ATTR_CU_SHARE_DAMAGE;
count++;
@@ -3882,6 +3884,44 @@ void SpellMgr::LoadSpellCustomAttr()
spellInfo->EffectSpellClassMask[0] = flag96(423937, 276955137, 2049);
count++;
break;
// this is here until targetAuraSpell and alike support SpellDifficulty.dbc
case 70459: // Ooze Eruption Search Effect
spellInfo->targetAuraSpell = 0;
count++;
break;
case 71413: // Green Ooze Summon
case 71414: // Orange Ooze Summon
spellInfo->EffectImplicitTargetA[0] = TARGET_DEST_DEST;
count++;
break;
// THIS IS HERE BECAUSE COOLDOWN ON CREATURE PROCS IS NOT IMPLEMENTED
case 71604: // Mutated Strength
case 72673: // Mutated Strength
case 72674: // Mutated Strength
case 72675: // Mutated Strength
spellInfo->Effect[1] = 0;
count++;
break;
case 70447: // Volatile Ooze Adhesive
case 72836: // Volatile Ooze Adhesive
case 72837: // Volatile Ooze Adhesive
case 72838: // Volatile Ooze Adhesive
case 70672: // Gaseous Bloat
case 72455: // Gaseous Bloat
case 72832: // Gaseous Bloat
case 72833: // Gaseous Bloat
spellInfo->EffectImplicitTargetB[0] = TARGET_UNIT_TARGET_ENEMY;
spellInfo->EffectImplicitTargetB[1] = TARGET_UNIT_TARGET_ENEMY;
spellInfo->EffectImplicitTargetB[2] = TARGET_UNIT_TARGET_ENEMY;
count++;
break;
case 70911: // Unbound Plague
case 72854: // Unbound Plague
case 72855: // Unbound Plague
case 72856: // Unbound Plague
spellInfo->EffectImplicitTargetB[0] = TARGET_UNIT_TARGET_ENEMY;
count++;
break;
default:
break;
}
File diff suppressed because it is too large Load Diff
@@ -186,15 +186,13 @@ class boss_rotface : public CreatureScript
switch (eventId)
{
case EVENT_SLIME_SPRAY:
if (Unit* target = SelectTarget(SELECT_TARGET_RANDOM, 0/*1*/, 0.0f, true))
if (Unit* target = SelectTarget(SELECT_TARGET_RANDOM, 1, 0.0f, true))
{
Position pos;
target->GetPosition(&pos);
if (DoSummon(NPC_OOZE_SPRAY_STALKER, pos, 8000, TEMPSUMMON_TIMED_DESPAWN))
{
DoScriptText(EMOTE_SLIME_SPRAY, me);
DoCastAOE(SPELL_SLIME_SPRAY);
}
DoSummon(NPC_OOZE_SPRAY_STALKER, pos, 8000, TEMPSUMMON_TIMED_DESPAWN);
DoScriptText(EMOTE_SLIME_SPRAY, me);
DoCastAOE(SPELL_SLIME_SPRAY);
}
events.ScheduleEvent(EVENT_SLIME_SPRAY, 20000);
break;
@@ -43,43 +43,73 @@ enum eData
DATA_BONED_ACHIEVEMENT = 13,
DATA_OOZE_DANCE_ACHIEVEMENT = 14,
DATA_PUTRICIDE_TABLE = 15,
DATA_NAUSEA___ACHIEVEMENT = 16,
};
#define MAX_ENCOUNTER 12
enum eCreatures
{
NPC_LORD_MARROWGAR = 36612,
NPC_COLDFLAME = 36672,
NPC_BONE_SPIKE = 36619,
// At Light's Hammer
NPC_KOR_KRON_GENERAL = 37189,
NPC_ALLIANCE_COMMANDER = 37190,
NPC_TORTUNOK = 37992, // Druid Armor H
NPC_ALANA_MOONSTRIKE = 37999, // Druid Armor A
NPC_GERARDO_THE_SUAVE = 37993, // Hunter Armor H
NPC_TALAN_MOONSTRIKE = 37998, // Hunter Armor A
NPC_UVLUS_BANEFIRE = 38284, // Mage Armor H
NPC_MALFUS_GRIMFROST = 38283, // Mage Armor A
NPC_IKFIRUS_THE_VILE = 37991, // Rogue Armor H
NPC_YILI = 37997, // Rogue Armor A
NPC_VOL_GUK = 38841, // Shaman Armor H
NPC_JEDEBIA = 38840, // Shaman Armor A
NPC_HARAGG_THE_UNSEEN = 38181, // Warlock Armor H
NPC_NIBY_THE_ALMIGHTY = 38182, // Warlock Armor N
NPC_LADY_DEATHWHISPER = 36855,
NPC_CULT_FANATIC = 37890,
NPC_DEFORMED_FANATIC = 38135,
NPC_REANIMATED_FANATIC = 38009,
NPC_CULT_ADHERENT = 37949,
NPC_EMPOWERED_ADHERENT = 38136,
NPC_REANIMATED_ADHERENT = 38010,
NPC_VENGEFUL_SHADE = 38222,
// Lord Marrowgar
NPC_LORD_MARROWGAR = 36612,
NPC_COLDFLAME = 36672,
NPC_BONE_SPIKE = 36619,
NPC_DEATHBRINGER_SAURFANG = 37813,
NPC_BLOOD_BEAST = 38508,
NPC_SE_JAINA_PROUDMOORE = 37188, // SE means Saurfang Event
NPC_SE_MURADIN_BRONZEBEARD = 37200,
NPC_SE_KING_VARIAN_WRYNN = 37879,
NPC_SE_HIGH_OVERLORD_SAURFANG = 37187,
NPC_SE_KOR_KRON_REAVER = 37920,
NPC_SE_SKYBREAKER_MARINE = 37830,
// Lady Deathwhisper
NPC_LADY_DEATHWHISPER = 36855,
NPC_CULT_FANATIC = 37890,
NPC_DEFORMED_FANATIC = 38135,
NPC_REANIMATED_FANATIC = 38009,
NPC_CULT_ADHERENT = 37949,
NPC_EMPOWERED_ADHERENT = 38136,
NPC_REANIMATED_ADHERENT = 38010,
NPC_VENGEFUL_SHADE = 38222,
NPC_FESTERGUT = 36626,
NPC_GAS_DUMMY = 36659,
// Deathbringer Saurfang
NPC_DEATHBRINGER_SAURFANG = 37813,
NPC_BLOOD_BEAST = 38508,
NPC_SE_JAINA_PROUDMOORE = 37188, // SE means Saurfang Event
NPC_SE_MURADIN_BRONZEBEARD = 37200,
NPC_SE_KING_VARIAN_WRYNN = 37879,
NPC_SE_HIGH_OVERLORD_SAURFANG = 37187,
NPC_SE_KOR_KRON_REAVER = 37920,
NPC_SE_SKYBREAKER_MARINE = 37830,
NPC_ROTFACE = 36627,
NPC_OOZE_SPRAY_STALKER = 37986,
NPC_PUDDLE_STALKER = 37013,
NPC_UNSTABLE_EXPLOSION_STALKER = 38107,
// Festergut
NPC_FESTERGUT = 36626,
NPC_GAS_DUMMY = 36659,
NPC_PROFESSOR_PUTRICIDE = 36678,
// Rotface
NPC_ROTFACE = 36627,
NPC_OOZE_SPRAY_STALKER = 37986,
NPC_PUDDLE_STALKER = 37013,
NPC_UNSTABLE_EXPLOSION_STALKER = 38107,
// Professor Putricide
NPC_PROFESSOR_PUTRICIDE = 36678,
NPC_ABOMINATION_WING_MAD_SCIENTIST_STALKER = 37824,
NPC_GROWING_OOZE_PUDDLE = 37690,
NPC_GAS_CLOUD = 37562,
NPC_VOLATILE_OOZE = 37697,
NPC_CHOKING_GAS_BOMB = 38159,
NPC_TEAR_GAS_TARGET_STALKER = 38317,
};
enum eGameobjects
@@ -103,18 +133,23 @@ enum eGameobjects
GO_DOODAD_ICECROWN_ORANGETUBES02 = 201617,
GO_DOODAD_ICECROWN_GREENTUBES02 = 201618,
GO_SCIENTIST_ENTRANCE = 201372,
GO_DRINK_ME = 201584,
};
enum eAchievementCriteria
{
CRITERIA_BONED_10N = 12775,
CRITERIA_BONED_25N = 12962,
CRITERIA_BONED_10H = 13393,
CRITERIA_BONED_25H = 13394,
CRITERIA_BONED_10N = 12775,
CRITERIA_BONED_25N = 12962,
CRITERIA_BONED_10H = 13393,
CRITERIA_BONED_25H = 13394,
CRITERIA_DANCES_WITH_OOZES_10N = 12984,
CRITERIA_DANCES_WITH_OOZES_25N = 12966,
CRITERIA_DANCES_WITH_OOZES_10H = 12985,
CRITERIA_DANCES_WITH_OOZES_25H = 12983,
CRITERIA_NAUSEA_10N = 12987,
CRITERIA_NAUSEA_25N = 12968,
CRITERIA_NAUSEA_10H = 12988,
CRITERIA_NAUSEA_25H = 12981,
};
enum ePutricideActions
@@ -125,6 +160,7 @@ enum ePutricideActions
ACTION_ROTFACE_COMBAT = -366270,
ACTION_ROTFACE_OOZE = -366271,
ACTION_ROTFACE_DEATH = -366272,
ACTION_CHANGE_PHASE = -366780
};
#endif // DEF_ICECROWN_CITADEL_H
@@ -53,8 +53,10 @@ class instance_icecrown_citadel : public InstanceMapScript
uiFestergut = 0;
uiRotface = 0;
uiProfessorPutricide = 0;
uiPutricideTable;
isBonedEligible = true;
isOozeDanceEligible = true;
isNauseaEligible = true;
}
void OnCreatureCreate(Creature* creature, bool /*add*/)
@@ -70,6 +72,34 @@ class instance_icecrown_citadel : public InstanceMapScript
switch (creature->GetEntry())
{
case NPC_KOR_KRON_GENERAL:
if (TeamInInstance == ALLIANCE)
creature->UpdateEntry(NPC_ALLIANCE_COMMANDER, ALLIANCE);
break;
case NPC_TORTUNOK:
if (TeamInInstance == ALLIANCE)
creature->UpdateEntry(NPC_ALANA_MOONSTRIKE, ALLIANCE);
break;
case NPC_GERARDO_THE_SUAVE:
if (TeamInInstance == ALLIANCE)
creature->UpdateEntry(NPC_TALAN_MOONSTRIKE, ALLIANCE);
break;
case NPC_UVLUS_BANEFIRE:
if (TeamInInstance == ALLIANCE)
creature->UpdateEntry(NPC_MALFUS_GRIMFROST, ALLIANCE);
break;
case NPC_IKFIRUS_THE_VILE:
if (TeamInInstance == ALLIANCE)
creature->UpdateEntry(NPC_YILI, ALLIANCE);
break;
case NPC_VOL_GUK:
if (TeamInInstance == ALLIANCE)
creature->UpdateEntry(NPC_JEDEBIA, ALLIANCE);
break;
case NPC_HARAGG_THE_UNSEEN:
if (TeamInInstance == ALLIANCE)
creature->UpdateEntry(NPC_NIBY_THE_ALMIGHTY, ALLIANCE);
break;
case NPC_DEATHBRINGER_SAURFANG:
uiDeathbringerSaurfang = creature->GetGUID();
break;
@@ -160,6 +190,9 @@ class instance_icecrown_citadel : public InstanceMapScript
if (GetBossState(DATA_ROTFACE) == DONE)
HandleGameObject(uiPutricidePipes[1], true, pGo);
break;
case GO_DRINK_ME:
uiPutricideTable = pGo->GetGUID();
break;
default:
break;
}
@@ -183,6 +216,9 @@ class instance_icecrown_citadel : public InstanceMapScript
return uiRotface;
case DATA_PROFESSOR_PUTRICIDE:
return uiProfessorPutricide;
case DATA_PUTRICIDE_TABLE:
return uiPutricideTable;
break;
default:
break;
}
@@ -225,12 +261,13 @@ class instance_icecrown_citadel : public InstanceMapScript
case DATA_FESTERGUT:
if (state == DONE)
{
if (GetBossState(DATA_ROTFACE) == DONE)
HandleGameObject(uiPutricideCollision, true);
if (GetBossState(DATA_ROTFACE) == DONE)
{
HandleGameObject(uiPutricideCollision, true);
if (GameObject* pGo = instance->GetGameObject(uiPutricideGates[0]))
pGo->SetGoState(GO_STATE_ACTIVE_ALTERNATIVE);
if (GameObject* pGo = instance->GetGameObject(uiPutricideGates[1]))
pGo->SetGoState(GO_STATE_ACTIVE_ALTERNATIVE);
}
else
HandleGameObject(uiPutricideGates[0], false);
@@ -240,10 +277,11 @@ class instance_icecrown_citadel : public InstanceMapScript
case DATA_ROTFACE:
if (state == DONE)
{
if (GetBossState(DATA_FESTERGUT) == DONE)
HandleGameObject(uiPutricideCollision, true);
if (GetBossState(DATA_FESTERGUT) == DONE)
{
HandleGameObject(uiPutricideCollision, true);
if (GameObject* pGo = instance->GetGameObject(uiPutricideGates[0]))
pGo->SetGoState(GO_STATE_ACTIVE_ALTERNATIVE);
if (GameObject* pGo = instance->GetGameObject(uiPutricideGates[1]))
pGo->SetGoState(GO_STATE_ACTIVE_ALTERNATIVE);
}
@@ -273,6 +311,10 @@ class instance_icecrown_citadel : public InstanceMapScript
break;
case DATA_OOZE_DANCE_ACHIEVEMENT:
isOozeDanceEligible = data ? true : false;
break;
case DATA_NAUSEA___ACHIEVEMENT:
isNauseaEligible = data ? true : false;
break;
default:
break;
}
@@ -292,6 +334,11 @@ class instance_icecrown_citadel : public InstanceMapScript
case CRITERIA_DANCES_WITH_OOZES_10H:
case CRITERIA_DANCES_WITH_OOZES_25H:
return isOozeDanceEligible;
case CRITERIA_NAUSEA_10N:
case CRITERIA_NAUSEA_25N:
case CRITERIA_NAUSEA_10H:
case CRITERIA_NAUSEA_25H:
return isNauseaEligible;
default:
break;
}
@@ -353,8 +400,10 @@ class instance_icecrown_citadel : public InstanceMapScript
uint64 uiFestergut;
uint64 uiRotface;
uint64 uiProfessorPutricide;
uint64 uiPutricideTable;
bool isBonedEligible;
bool isOozeDanceEligible;
bool isNauseaEligible;
};
InstanceScript* GetInstanceScript(InstanceMap* pMap) const