mirror of
https://github.com/mangosfour/server.git
synced 2025-12-17 16:37:00 +00:00
[11379] Add script effect of spell 24714 and improve related 24751
Signed-off-by: NoFantasy <nofantasy@nf.no>
This commit is contained in:
parent
849528ebad
commit
3bf9a5c35b
2 changed files with 15 additions and 14 deletions
|
|
@ -6152,6 +6152,18 @@ void Spell::EffectScriptEffect(SpellEffectIndex eff_idx)
|
|||
case 24590: // Brittle Armor - need remove one 24575 Brittle Armor aura
|
||||
unitTarget->RemoveAuraHolderFromStack(24575);
|
||||
return;
|
||||
case 24714: // Trick
|
||||
{
|
||||
if (m_caster->GetTypeId() != TYPEID_PLAYER)
|
||||
return;
|
||||
|
||||
if (roll_chance_i(14)) // Trick (can be different critter models). 14% since below can have 1 of 6
|
||||
m_caster->CastSpell(m_caster, 24753, true);
|
||||
else // Random Costume, 6 different (plus add. for gender)
|
||||
m_caster->CastSpell(m_caster, 24720, true);
|
||||
|
||||
return;
|
||||
}
|
||||
case 24717: // Pirate Costume
|
||||
{
|
||||
if (!unitTarget || unitTarget->GetTypeId() != TYPEID_PLAYER)
|
||||
|
|
@ -6231,19 +6243,8 @@ void Spell::EffectScriptEffect(SpellEffectIndex eff_idx)
|
|||
// 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);
|
||||
}
|
||||
|
||||
// Treat / Trick
|
||||
unitTarget->CastSpell(unitTarget, roll_chance_i(50) ? 24714 : 24715, true);
|
||||
return;
|
||||
}
|
||||
case 26275: // PX-238 Winter Wondervolt TRAP
|
||||
|
|
|
|||
|
|
@ -1,4 +1,4 @@
|
|||
#ifndef __REVISION_NR_H__
|
||||
#define __REVISION_NR_H__
|
||||
#define REVISION_NR "11378"
|
||||
#define REVISION_NR "11379"
|
||||
#endif // __REVISION_NR_H__
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue