aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorShocker <none@none>2010-09-13 01:59:09 +0300
committerShocker <none@none>2010-09-13 01:59:09 +0300
commit61c11f8f9be10eb796ea1f46efa691755b76c191 (patch)
tree01ae539b668cde6cdb6739b93f86313517793d11
parent4908187578a38d97911371bb1d85315417640d3b (diff)
Scripts/Deadmines: Fix OnUse hook usage, thanks zaphod, closes issue 3942.
Note: If you spot similar errors (forgotten changes for hooks) in other scripts, please report them --HG-- branch : trunk
-rw-r--r--src/server/scripts/EasternKingdoms/Deadmines/deadmines.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/server/scripts/EasternKingdoms/Deadmines/deadmines.cpp b/src/server/scripts/EasternKingdoms/Deadmines/deadmines.cpp
index bcd33a08a1d..b3a4f0f973d 100644
--- a/src/server/scripts/EasternKingdoms/Deadmines/deadmines.cpp
+++ b/src/server/scripts/EasternKingdoms/Deadmines/deadmines.cpp
@@ -36,13 +36,13 @@ class item_defias_gunpowder : public ItemScript
public:
item_defias_gunpowder() : ItemScript("item_defias_gunpowder") { }
- bool ItemUse(Player* pPlayer, Item* pItem, SpellCastTargets const& targets)
+ bool OnUse(Player* player, Item* item, SpellCastTargets const& targets)
{
- InstanceScript *pInstance = pPlayer->GetInstanceScript();
+ InstanceScript *pInstance = player->GetInstanceScript();
if (!pInstance)
{
- pPlayer->GetSession()->SendNotification("Instance script not initialized");
+ player->GetSession()->SendNotification("Instance script not initialized");
return true;
}
if (pInstance->GetData(EVENT_STATE)!= CANNON_NOT_USED)
@@ -53,7 +53,7 @@ public:
pInstance->SetData(EVENT_STATE, CANNON_GUNPOWDER_USED);
}
- pPlayer->DestroyItemCount(pItem->GetEntry(), 1, true);
+ player->DestroyItemCount(item->GetEntry(), 1, true);
return true;
}