mirror of
https://github.com/mangosfour/server.git
synced 2025-12-16 04:37:00 +00:00
[11224] Add script effect of spell 24751
Signed-off-by: NoFantasy <nofantasy@nf.no>
This commit is contained in:
parent
5aeda4f28b
commit
710dce3f97
2 changed files with 24 additions and 1 deletions
|
|
@ -6209,6 +6209,29 @@ void Spell::EffectScriptEffect(SpellEffectIndex eff_idx)
|
|||
m_caster->CastSpell(unitTarget, unitTarget->getGender() == GENDER_MALE ? 24735 : 24736, true);
|
||||
return;
|
||||
}
|
||||
case 24751: // Trick or Treat
|
||||
{
|
||||
if (!unitTarget || unitTarget->GetTypeId() != TYPEID_PLAYER)
|
||||
return;
|
||||
|
||||
// Tricked or Treated
|
||||
unitTarget->CastSpell(unitTarget, 24755, true);
|
||||
|
||||
if (roll_chance_i(50))
|
||||
{
|
||||
// Treat
|
||||
unitTarget->CastSpell(unitTarget, 24715, true);
|
||||
}
|
||||
else
|
||||
{
|
||||
if (roll_chance_i(14)) // Trick (can be different critter models). 14% since below can have 1 of 6
|
||||
unitTarget->CastSpell(unitTarget, 24753, true);
|
||||
else // Random Costume, 6 different (plus add. for gender)
|
||||
unitTarget->CastSpell(unitTarget, 24720, true);
|
||||
}
|
||||
|
||||
return;
|
||||
}
|
||||
case 26275: // PX-238 Winter Wondervolt TRAP
|
||||
{
|
||||
uint32 spells[4] = { 26272, 26157, 26273, 26274 };
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
#ifndef __REVISION_NR_H__
|
||||
#define __REVISION_NR_H__
|
||||
#define REVISION_NR "11223"
|
||||
#define REVISION_NR "11224"
|
||||
#endif // __REVISION_NR_H__
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue