aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/server/game/AI/ScriptedAI/ScriptedCreature.cpp27
-rw-r--r--src/server/game/AI/ScriptedAI/ScriptedCreature.h2
-rwxr-xr-xsrc/server/game/Miscellaneous/SharedDefines.h2
-rwxr-xr-xsrc/server/game/Spells/SpellEffects.cpp9
-rw-r--r--src/server/scripts/Northrend/IcecrownCitadel/boss_blood_queen_lana_thel.cpp20
-rwxr-xr-xsrc/server/scripts/Northrend/IcecrownCitadel/boss_professor_putricide.cpp121
-rw-r--r--src/server/scripts/Spells/spell_dk.cpp42
-rw-r--r--src/server/scripts/Spells/spell_item.cpp41
-rw-r--r--src/server/scripts/Spells/spell_shaman.cpp29
-rw-r--r--src/server/scripts/World/item_scripts.cpp86
10 files changed, 251 insertions, 128 deletions
diff --git a/src/server/game/AI/ScriptedAI/ScriptedCreature.cpp b/src/server/game/AI/ScriptedAI/ScriptedCreature.cpp
index ddf000e31c7..6eec549d37a 100644
--- a/src/server/game/AI/ScriptedAI/ScriptedCreature.cpp
+++ b/src/server/game/AI/ScriptedAI/ScriptedCreature.cpp
@@ -81,6 +81,33 @@ void SummonList::DespawnAll()
}
}
+void SummonList::RemoveNotExisting()
+{
+ for (iterator i = begin(); i != end();)
+ {
+ if (Unit::GetCreature(*me, *i))
+ ++i;
+ else
+ erase(i++);
+ }
+}
+
+bool SummonList::HasEntry(uint32 entry)
+{
+ for (iterator i = begin(); i != end();)
+ {
+ Creature* summon = Unit::GetCreature(*me, *i);
+ if (!summon)
+ erase(i++);
+ else if (summon->GetEntry() == entry)
+ return true;
+ else
+ ++i;
+ }
+
+ return false;
+}
+
ScriptedAI::ScriptedAI(Creature* pCreature) : CreatureAI(pCreature),
me(pCreature),
IsFleeing(false),
diff --git a/src/server/game/AI/ScriptedAI/ScriptedCreature.h b/src/server/game/AI/ScriptedAI/ScriptedCreature.h
index f94a41dfb10..f7a28a71e33 100644
--- a/src/server/game/AI/ScriptedAI/ScriptedCreature.h
+++ b/src/server/game/AI/ScriptedAI/ScriptedCreature.h
@@ -36,6 +36,8 @@ class SummonList : public std::list<uint64>
void DespawnAll();
void DoAction(uint32 entry, uint32 info);
void DoZoneInCombat(uint32 entry = 0);
+ void RemoveNotExisting();
+ bool HasEntry(uint32 entry);
private:
Creature *me;
};
diff --git a/src/server/game/Miscellaneous/SharedDefines.h b/src/server/game/Miscellaneous/SharedDefines.h
index 25011abc64d..a05bb933fee 100755
--- a/src/server/game/Miscellaneous/SharedDefines.h
+++ b/src/server/game/Miscellaneous/SharedDefines.h
@@ -1045,7 +1045,7 @@ enum SpellCustomErrors
SPELL_CUSTOM_ERROR_MUST_BE_DEATH_KNIGHT = 33, // Only Death Knights may enter Ebon Hold.
SPELL_CUSTOM_ERROR_MUST_BE_IN_FERAL_FORM = 34, // Must be in Cat Form, Bear Form, or Dire Bear Form
SPELL_CUSTOM_ERROR_MUST_BE_NEAR_HELPLESS_VILLAGER = 35, // You must be within range of a Helpless Wintergarde Villager.
- SPELL_CUSTOM_ERROR_MUST_TARGET_ELEMENTAL_MECHANICAL = 36, // You cannot target an elemental or mechanical corpse.
+ SPELL_CUSTOM_ERROR_CANT_TARGET_ELEMENTAL_MECHANICAL = 36, // You cannot target an elemental or mechanical corpse.
SPELL_CUSTOM_ERROR_MUST_HAVE_USED_DALARAN_CRYSTAL = 37, // This teleport crystal cannot be used until the teleport crystal in Dalaran has been used at least once.
SPELL_CUSTOM_ERROR_YOU_ALREADY_HOLD_SOMETHING = 38, // You are already holding something in your hand. You must throw the creature in your hand before picking up another.
SPELL_CUSTOM_ERROR_YOU_DONT_HOLD_ANYTHING = 39, // You don't have anything to throw! Find a Vargul and use Gymer Grab to pick one up!
diff --git a/src/server/game/Spells/SpellEffects.cpp b/src/server/game/Spells/SpellEffects.cpp
index 984895b85db..551ead343d3 100755
--- a/src/server/game/Spells/SpellEffects.cpp
+++ b/src/server/game/Spells/SpellEffects.cpp
@@ -4826,15 +4826,6 @@ void Spell::EffectScriptEffect(SpellEffIndex effIndex)
if (unitTarget && m_originalCaster)
m_originalCaster->CastSpell(unitTarget, urand(0, 1) ? damage : 52505, true);
return;
- // Death Gate
- case 52751:
- {
- if (!unitTarget || unitTarget->getClass() != CLASS_DEATH_KNIGHT)
- return;
- // triggered spell is stored in m_spellInfo->EffectBasePoints[0]
- unitTarget->CastSpell(unitTarget, damage, false);
- break;
- }
case 53110: // Devour Humanoid
if (unitTarget)
unitTarget->CastSpell(m_caster, damage, true);
diff --git a/src/server/scripts/Northrend/IcecrownCitadel/boss_blood_queen_lana_thel.cpp b/src/server/scripts/Northrend/IcecrownCitadel/boss_blood_queen_lana_thel.cpp
index 3f121e1d862..9ddf274ca2f 100644
--- a/src/server/scripts/Northrend/IcecrownCitadel/boss_blood_queen_lana_thel.cpp
+++ b/src/server/scripts/Northrend/IcecrownCitadel/boss_blood_queen_lana_thel.cpp
@@ -432,19 +432,22 @@ class spell_blood_queen_vampiric_bite : public SpellScriptLoader
return true;
}
+ SpellCastResult CheckTarget()
+ {
+ if (IsVampire(GetTargetUnit()))
+ {
+ SetCustomCastResultMessage(SPELL_CUSTOM_ERROR_CANT_TARGET_VAMPIRES);
+ return SPELL_FAILED_CUSTOM_ERROR;
+ }
+
+ return SPELL_CAST_OK;
+ }
+
void OnCast()
{
if (GetCaster()->GetTypeId() != TYPEID_PLAYER)
return;
- if (IsVampire(GetHitUnit()))
- {
- PreventHitDamage();
- PreventHitDefaultEffect(EFFECT_1);
- Spell::SendCastResult(GetCaster()->ToPlayer(), GetSpellInfo(), 0, SPELL_FAILED_BAD_TARGETS);
- return;
- }
-
SpellEntry const* spell = sSpellStore.LookupEntry(SPELL_FRENZIED_BLOODTHIRST);
spell = sSpellMgr->GetSpellForDifficultyFromSpell(spell, GetCaster());
GetCaster()->RemoveAura(spell->Id, 0, 0, AURA_REMOVE_BY_ENEMY_SPELL);
@@ -473,6 +476,7 @@ class spell_blood_queen_vampiric_bite : public SpellScriptLoader
void Register()
{
+ OnCheckCast += SpellCheckCastFn(spell_blood_queen_vampiric_bite_SpellScript::CheckTarget);
BeforeHit += SpellHitFn(spell_blood_queen_vampiric_bite_SpellScript::OnCast);
}
};
diff --git a/src/server/scripts/Northrend/IcecrownCitadel/boss_professor_putricide.cpp b/src/server/scripts/Northrend/IcecrownCitadel/boss_professor_putricide.cpp
index fbb0d2d89d3..0ba75cc3ecd 100755
--- a/src/server/scripts/Northrend/IcecrownCitadel/boss_professor_putricide.cpp
+++ b/src/server/scripts/Northrend/IcecrownCitadel/boss_professor_putricide.cpp
@@ -20,6 +20,7 @@
#include "ScriptedCreature.h"
#include "SpellScript.h"
#include "SpellAuraEffects.h"
+#include "Group.h"
#include "icecrown_citadel.h"
enum ScriptTexts
@@ -152,7 +153,13 @@ static const Position tablePos = {4356.190f, 3262.90f, 389.4820f, 1.483
static const uint32 oozeFloodSpells[4] = {69782, 69796, 69798, 69801};
-#define DATA_EXPERIMENT_STAGE 0
+enum PutricideData
+{
+ DATA_EXPERIMENT_STAGE = 1,
+ DATA_PHASE = 2,
+ DATA_ABOMINATION = 3,
+};
+
#define EXPERIMENT_STATE_OOZE false
#define EXPERIMENT_STATE_GAS true
@@ -205,8 +212,6 @@ class boss_professor_putricide : public CreatureScript
me->RemoveUnitMovementFlag(MOVEMENTFLAG_WALKING);
if (me->GetMotionMaster()->GetCurrentMovementGeneratorType() == POINT_MOTION_TYPE)
me->GetMotionMaster()->MovementExpired();
- if (GameObject* table = ObjectAccessor::GetGameObject(*me, instance->GetData64(DATA_PUTRICIDE_TABLE)))
- table->SetFlag(GAMEOBJECT_FLAGS, GO_FLAG_IN_USE);
}
void EnterCombat(Unit* who)
@@ -235,8 +240,6 @@ class boss_professor_putricide : public CreatureScript
DoZoneInCombat(me);
instance->SetBossState(DATA_PROFESSOR_PUTRICIDE, IN_PROGRESS);
- if (GameObject* table = ObjectAccessor::GetGameObject(*me, instance->GetData64(DATA_PUTRICIDE_TABLE)))
- table->RemoveFlag(GAMEOBJECT_FLAGS, GO_FLAG_IN_USE);
}
void JustReachedHome()
@@ -501,8 +504,6 @@ class boss_professor_putricide : public CreatureScript
events.CancelEvent(EVENT_UNSTABLE_EXPERIMENT);
summons.DespawnEntry(NPC_MUTATED_ABOMINATION_10);
summons.DespawnEntry(NPC_MUTATED_ABOMINATION_25);
- if (GameObject* table = ObjectAccessor::GetGameObject(*me, instance->GetData64(DATA_PUTRICIDE_TABLE)))
- table->SetFlag(GAMEOBJECT_FLAGS, GO_FLAG_IN_USE);
break;
default:
break;
@@ -515,12 +516,22 @@ class boss_professor_putricide : public CreatureScript
uint32 GetData(uint32 type)
{
- if (type == DATA_EXPERIMENT_STAGE)
+ switch (type)
{
- // ALSO MODIFIES!
- uint32 ret = uint32(experimentState);
- experimentState ^= true;
- return ret;
+ case DATA_EXPERIMENT_STAGE:
+ {
+ // ALSO MODIFIES!
+ uint32 ret = uint32(experimentState);
+ experimentState ^= true;
+ return ret;
+ }
+ case DATA_PHASE:
+ return phase;
+ case DATA_ABOMINATION:
+ summons.RemoveNotExisting();
+ return summons.HasEntry(NPC_MUTATED_ABOMINATION_10) || summons.HasEntry(NPC_MUTATED_ABOMINATION_25);
+ default:
+ break;
}
return 0;
@@ -1027,28 +1038,33 @@ class spell_putricide_unbound_plague : public SpellScriptLoader
{
PrepareSpellScript(spell_putricide_unbound_plague_SpellScript);
+ bool Validate(SpellEntry const* /*spell*/)
+ {
+ if (!sSpellStore.LookupEntry(SPELL_UNBOUND_PLAGUE))
+ return false;
+ if (!sSpellStore.LookupEntry(SPELL_UNBOUND_PLAGUE_SEARCHER))
+ return false;
+ return true;
+ }
+
void HandleScript(SpellEffIndex /*effIndex*/)
{
if (!GetHitUnit())
return;
- SpellEntry const* plague = sSpellStore.LookupEntry(SPELL_UNBOUND_PLAGUE);
- SpellEntry const* searcher = sSpellStore.LookupEntry(SPELL_UNBOUND_PLAGUE_SEARCHER);
- Creature* professor = NULL;
- if (InstanceScript* instance = GetCaster()->GetInstanceScript())
- {
- professor = Unit::GetCreature(*GetCaster(), instance->GetData64(DATA_PROFESSOR_PUTRICIDE));
- if (professor)
- {
- plague = sSpellMgr->GetSpellForDifficultyFromSpell(plague, professor);
- searcher = sSpellMgr->GetSpellForDifficultyFromSpell(searcher, professor);
- }
- }
+ InstanceScript* instance = GetCaster()->GetInstanceScript();
+ if (!instance)
+ return;
+
+ SpellEntry const* plague = sSpellMgr->GetSpellForDifficultyFromSpell(sSpellStore.LookupEntry(SPELL_UNBOUND_PLAGUE), GetCaster());
+ SpellEntry const* searcher = sSpellMgr->GetSpellForDifficultyFromSpell(sSpellStore.LookupEntry(SPELL_UNBOUND_PLAGUE_SEARCHER), GetCaster());
if (!GetHitUnit()->HasAura(plague->Id))
{
- if (professor)
+ if (Creature* professor = ObjectAccessor::GetCreature(*GetCaster(), instance->GetData64(DATA_PROFESSOR_PUTRICIDE)))
+ {
if (Aura* oldPlague = GetCaster()->GetAura(plague->Id, professor->GetGUID()))
+ {
if (Aura* newPlague = professor->AddAura(plague->Id, GetHitUnit()))
{
newPlague->SetMaxDuration(oldPlague->GetDuration());
@@ -1059,6 +1075,8 @@ class spell_putricide_unbound_plague : public SpellScriptLoader
GetCaster()->CastSpell(GetCaster(), SPELL_UNBOUND_PLAGUE_PROTECTION, true);
professor->CastSpell(GetHitUnit(), SPELL_UNBOUND_PLAGUE_SEARCHER, true);
}
+ }
+ }
}
}
@@ -1170,6 +1188,54 @@ class spell_putricide_mutation_init : public SpellScriptLoader
public:
spell_putricide_mutation_init() : SpellScriptLoader("spell_putricide_mutation_init") { }
+ class spell_putricide_mutation_init_SpellScript : public SpellScript
+ {
+ PrepareSpellScript(spell_putricide_mutation_init_SpellScript);
+
+ SpellCastResult CheckRequirement()
+ {
+ if (GetCaster()->GetTypeId() != TYPEID_PLAYER)
+ return SPELL_FAILED_TARGET_NOT_PLAYER;
+
+ InstanceScript* instance = GetCaster()->GetInstanceScript();
+ if (!instance)
+ return SPELL_FAILED_CANT_DO_THAT_RIGHT_NOW;
+
+ Creature* professor = ObjectAccessor::GetCreature(*GetCaster(), instance->GetData64(DATA_PROFESSOR_PUTRICIDE));
+ if (!professor || !professor->isInCombat())
+ return SPELL_FAILED_CANT_DO_THAT_RIGHT_NOW;
+
+ if (professor->AI()->GetData(DATA_PHASE) == PHASE_COMBAT_3 || !professor->isAlive())
+ {
+ SetCustomCastResultMessage(SPELL_CUSTOM_ERROR_ALL_POTIONS_USED);
+ return SPELL_FAILED_CUSTOM_ERROR;
+ }
+
+ // find another player with initialization aura
+ bool abominationExists = false;
+ Group* group = GetCaster()->ToPlayer()->GetGroup();
+ for (GroupReference* plrRef = group->GetFirstMember(); plrRef && !abominationExists; plrRef = plrRef->next())
+ if (Player* player = plrRef->getSource())
+ if (player->HasAura(GetSpellInfo()->Id))
+ abominationExists = true;
+
+ // or an existing abomination
+ abominationExists |= bool(professor->AI()->GetData(DATA_ABOMINATION));
+ if (abominationExists)
+ {
+ SetCustomCastResultMessage(SPELL_CUSTOM_ERROR_TOO_MANY_ABOMINATIONS);
+ return SPELL_FAILED_CUSTOM_ERROR;
+ }
+
+ return SPELL_CAST_OK;
+ }
+
+ void Register()
+ {
+ OnCheckCast += SpellCheckCastFn(spell_putricide_mutation_init_SpellScript::CheckRequirement);
+ }
+ };
+
class spell_putricide_mutation_init_AuraScript : public AuraScript
{
PrepareAuraScript(spell_putricide_mutation_init_AuraScript);
@@ -1189,6 +1255,11 @@ class spell_putricide_mutation_init : public SpellScriptLoader
}
};
+ SpellScript* GetSpellScript() const
+ {
+ return new spell_putricide_mutation_init_SpellScript();
+ }
+
AuraScript* GetAuraScript() const
{
return new spell_putricide_mutation_init_AuraScript();
diff --git a/src/server/scripts/Spells/spell_dk.cpp b/src/server/scripts/Spells/spell_dk.cpp
index 6e50ae1b9b6..969a236d19f 100644
--- a/src/server/scripts/Spells/spell_dk.cpp
+++ b/src/server/scripts/Spells/spell_dk.cpp
@@ -233,6 +233,47 @@ class spell_dk_corpse_explosion : public SpellScriptLoader
}
};
+class spell_dk_death_gate : public SpellScriptLoader
+{
+ public:
+ spell_dk_death_gate() : SpellScriptLoader("spell_dk_death_gate") {}
+
+ class spell_dk_death_gate_SpellScript : public SpellScript
+ {
+ PrepareSpellScript(spell_dk_death_gate_SpellScript);
+
+ SpellCastResult CheckClass()
+ {
+ if (GetCaster()->getClass() != CLASS_DEATH_KNIGHT)
+ {
+ SetCustomCastResultMessage(SPELL_CUSTOM_ERROR_MUST_BE_DEATH_KNIGHT);
+ return SPELL_FAILED_CUSTOM_ERROR;
+ }
+
+ return SPELL_CAST_OK;
+ }
+
+ void HandleScript(SpellEffIndex effIndex)
+ {
+ PreventHitDefaultEffect(effIndex);
+ if (!GetHitUnit())
+ return;
+ GetHitUnit()->CastSpell(GetHitUnit(), GetEffectValue(), false);
+ }
+
+ void Register()
+ {
+ OnCheckCast += SpellCheckCastFn(spell_dk_death_gate_SpellScript::CheckClass);
+ OnEffect += SpellEffectFn(spell_dk_death_gate_SpellScript::HandleScript, EFFECT_0, SPELL_EFFECT_SCRIPT_EFFECT);
+ }
+ };
+
+ SpellScript* GetSpellScript() const
+ {
+ return new spell_dk_death_gate_SpellScript();
+ }
+};
+
class spell_dk_death_pact : public SpellScriptLoader
{
public:
@@ -474,6 +515,7 @@ void AddSC_deathknight_spell_scripts()
new spell_dk_anti_magic_shell_self();
new spell_dk_anti_magic_zone();
new spell_dk_corpse_explosion();
+ new spell_dk_death_gate();
new spell_dk_death_pact();
new spell_dk_runic_power_feed();
new spell_dk_scourge_strike();
diff --git a/src/server/scripts/Spells/spell_item.cpp b/src/server/scripts/Spells/spell_item.cpp
index 4cffbdf4437..dbe89f49c65 100644
--- a/src/server/scripts/Spells/spell_item.cpp
+++ b/src/server/scripts/Spells/spell_item.cpp
@@ -882,6 +882,46 @@ class spell_item_book_of_glyph_mastery : public SpellScriptLoader
}
};
+enum GiftOfTheHarvester
+{
+ NPC_GHOUL = 28845,
+ MAX_GHOULS = 5,
+};
+
+class spell_item_gift_of_the_harvester : public SpellScriptLoader
+{
+ public:
+ spell_item_gift_of_the_harvester() : SpellScriptLoader("spell_item_gift_of_the_harvester") {}
+
+ class spell_item_gift_of_the_harvester_SpellScript : public SpellScript
+ {
+ PrepareSpellScript(spell_item_gift_of_the_harvester_SpellScript);
+
+ SpellCastResult CheckRequirement()
+ {
+ std::list<Creature*> ghouls;
+ GetCaster()->GetAllMinionsByEntry(ghouls, NPC_GHOUL);
+ if (ghouls.size() >= MAX_GHOULS)
+ {
+ SetCustomCastResultMessage(SPELL_CUSTOM_ERROR_TOO_MANY_GHOULS);
+ return SPELL_FAILED_CUSTOM_ERROR;
+ }
+
+ return SPELL_CAST_OK;
+ }
+
+ void Register()
+ {
+ OnCheckCast += SpellCheckCastFn(spell_item_gift_of_the_harvester_SpellScript::CheckRequirement);
+ }
+ };
+
+ SpellScript* GetSpellScript() const
+ {
+ return new spell_item_gift_of_the_harvester_SpellScript();
+ }
+};
+
void AddSC_item_spell_scripts()
{
// 23074 Arcanite Dragonling
@@ -908,4 +948,5 @@ void AddSC_item_spell_scripts()
new spell_item_create_heart_candy();
new spell_item_book_of_glyph_mastery();
+ new spell_item_gift_of_the_harvester();
}
diff --git a/src/server/scripts/Spells/spell_shaman.cpp b/src/server/scripts/Spells/spell_shaman.cpp
index 363988bbe92..4806457435d 100644
--- a/src/server/scripts/Spells/spell_shaman.cpp
+++ b/src/server/scripts/Spells/spell_shaman.cpp
@@ -102,24 +102,33 @@ public:
return true;
}
+ SpellCastResult CheckFireTotem()
+ {
+ // fire totem
+ if (!GetCaster()->m_SummonSlot[1])
+ {
+ SetCustomCastResultMessage(SPELL_CUSTOM_ERROR_MUST_HAVE_FIRE_TOTEM);
+ return SPELL_FAILED_CUSTOM_ERROR;
+ }
+
+ return SPELL_CAST_OK;
+ }
+
void HandleDummy(SpellEffIndex /*effIndex*/)
{
- if (Unit* caster = GetCaster())
+ Unit* caster = GetCaster();
+ uint8 rank = sSpellMgr->GetSpellRank(GetSpellInfo()->Id);
+ if (uint32 spellId = sSpellMgr->GetSpellWithRank(SHAMAN_SPELL_FIRE_NOVA_TRIGGERED_R1, rank))
{
- uint8 rank = sSpellMgr->GetSpellRank(GetSpellInfo()->Id);
- uint32 spellId = sSpellMgr->GetSpellWithRank(SHAMAN_SPELL_FIRE_NOVA_TRIGGERED_R1, rank);
- // fire slot
- if (spellId && caster->m_SummonSlot[1])
- {
- Creature* totem = caster->GetMap()->GetCreature(caster->m_SummonSlot[1]);
- if (totem && totem->isTotem())
- totem->CastSpell(totem, spellId, true);
- }
+ Creature* totem = caster->GetMap()->GetCreature(caster->m_SummonSlot[1]);
+ if (totem && totem->isTotem())
+ totem->CastSpell(totem, spellId, true);
}
}
void Register()
{
+ OnCheckCast += SpellCheckCastFn(spell_sha_fire_nova_SpellScript::CheckFireTotem);
OnEffect += SpellEffectFn(spell_sha_fire_nova_SpellScript::HandleDummy, EFFECT_0, SPELL_EFFECT_DUMMY);
}
};
diff --git a/src/server/scripts/World/item_scripts.cpp b/src/server/scripts/World/item_scripts.cpp
index c37461fdaa0..71c3a1661ed 100644
--- a/src/server/scripts/World/item_scripts.cpp
+++ b/src/server/scripts/World/item_scripts.cpp
@@ -141,32 +141,6 @@ public:
};
/*#####
-# item_flying_machine
-#####*/
-
-class item_flying_machine : public ItemScript
-{
-public:
- item_flying_machine() : ItemScript("item_flying_machine") { }
-
- bool OnUse(Player* pPlayer, Item* pItem, SpellCastTargets const& /*targets*/)
- {
- uint32 itemId = pItem->GetEntry();
- if (itemId == 34060)
- if (pPlayer->GetBaseSkillValue(SKILL_RIDING) >= 225)
- return false;
-
- if (itemId == 34061)
- if (pPlayer->GetBaseSkillValue(SKILL_RIDING) == 300)
- return false;
-
- sLog->outDebug(LOG_FILTER_TSCR, "TSCR: Player attempt to use item %u, but did not meet riding requirement",itemId);
- pPlayer->SendEquipError(EQUIP_ERR_CANT_EQUIP_SKILL,pItem,NULL);
- return true;
- }
-};
-
-/*#####
# item_gor_dreks_ointment
#####*/
@@ -247,42 +221,6 @@ public:
};
/*#####
-# item_harvesters_gift
-#####*/
-#define GHOULS 28845
-
-class item_harvesters_gift : public ItemScript
-{
-public:
- item_harvesters_gift() : ItemScript("item_harvesters_gift") { }
-
- bool OnUse(Player* pPlayer, Item* /*pItem*/, SpellCastTargets const& /*targets*/)
- {
- std::list<Creature*> MinionList;
- pPlayer->GetAllMinionsByEntry(MinionList,GHOULS);
-
- if (pPlayer->GetQuestStatus(12698) == QUEST_STATUS_INCOMPLETE)
- {
- if (!MinionList.empty())
- {
- if (MinionList.size() < 5)
- return false;
- else
- {
- // This should be sent to the player as red text.
- // TODO: Text should be moved to DB
- pPlayer->Say("You have created enough ghouls. Return to Gothik the Harvester at Death's Breach.", LANG_UNIVERSAL);
- return true;
- }
- }
- else
- return false;
- }
- return true;
- }
-};
-
-/*#####
# item_pile_fake_furs
#####*/
@@ -512,18 +450,16 @@ public:
void AddSC_item_scripts()
{
- new item_only_for_flight;
- new item_draenei_fishing_net;
- new item_nether_wraith_beacon;
- new item_flying_machine;
- new item_gor_dreks_ointment;
- new item_incendiary_explosives;
- new item_mysterious_egg;
- new item_disgusting_jar;
- new item_harvesters_gift;
- new item_pile_fake_furs;
- new item_petrov_cluster_bombs;
- new item_dehta_trap_smasher;
- new item_trident_of_nazjan;
+ new item_only_for_flight();
+ new item_draenei_fishing_net();
+ new item_nether_wraith_beacon();
+ new item_gor_dreks_ointment();
+ new item_incendiary_explosives();
+ new item_mysterious_egg();
+ new item_disgusting_jar();
+ new item_pile_fake_furs();
+ new item_petrov_cluster_bombs();
+ new item_dehta_trap_smasher();
+ new item_trident_of_nazjan();
new item_captured_frog();
}