[10723] Add dummy aura effect of 51405 and dummy effect of 51420

Signed-off-by: NoFantasy <nofantasy@nf.no>
This commit is contained in:
NoFantasy 2010-11-15 17:30:21 +01:00
parent 76dfdd336f
commit 9c4be1d308
3 changed files with 48 additions and 1 deletions

View file

@ -2030,6 +2030,11 @@ void Aura::HandleAuraDummy(bool apply, bool Real)
case 48025: // Headless Horseman's Mount
Spell::SelectMountByAreaAndSkill(target, 51621, 48024, 51617, 48023, 0);
return;
case 51405: // Digging for Treasure
target->HandleEmote(EMOTE_STATE_WORK);
// Pet will be following owner, this makes him stop
target->addUnitState(UNIT_STAT_STUNNED);
return;
case 62061: // Festive Holiday Mount
if (target->HasAuraType(SPELL_AURA_MOUNTED))
// Reindeer Transformation
@ -2260,6 +2265,25 @@ void Aura::HandleAuraDummy(bool apply, bool Real)
target->CastSpell(target, 47287, true, NULL, this);
return;
}
case 51405: // Digging for Treasure
{
const uint32 spell_list[7] =
{
51441, // hare
51397, // crystal
51398, // armor
51400, // gem
51401, // platter
51402, // treasure
51443 // bug
};
target->CastSpell(target, spell_list[urand(0,6)], true);
target->HandleEmote(EMOTE_STATE_NONE);
target->clearUnitState(UNIT_STAT_STUNNED);
return;
}
case 51870: // Collect Hair Sample
{
if (Unit* pCaster = GetCaster())

View file

@ -1524,6 +1524,29 @@ void Spell::EffectDummy(SpellEffectIndex eff_idx)
return;
}
case 51420: // Digging for Treasure Ping
{
if (!unitTarget || unitTarget->GetTypeId() != TYPEID_UNIT)
return;
if (m_caster->GetTypeId() != TYPEID_PLAYER)
return;
// Not expecting any MINI_PET here, the ones used for related quests are
// fighting "companions" (effMiscValueB 387). Needs to be corrected.
Pet* pPet = ((Player*)m_caster)->GetMiniPet();
if (!pPet)
return;
pPet->SetFacingToObject(unitTarget);
// Digging for Treasure
pPet->CastSpell(unitTarget, 51405, true);
((Creature*)unitTarget)->ForcedDespawn(1);
return;
}
case 51582: // Rocket Boots Engaged (Rocket Boots Xtreme and Rocket Boots Xtreme Lite)
{
if (m_caster->GetTypeId() != TYPEID_PLAYER)

View file

@ -1,4 +1,4 @@
#ifndef __REVISION_NR_H__
#define __REVISION_NR_H__
#define REVISION_NR "10722"
#define REVISION_NR "10723"
#endif // __REVISION_NR_H__