Merge pull request #2715 from elecyb/diminish
Core/Spells: Fix duration of some spells in PvP
This commit is contained in:
@@ -101,8 +101,11 @@ DiminishingGroup GetDiminishingReturnsGroupForSpell(SpellInfo const* spellproto,
|
|||||||
}
|
}
|
||||||
case SPELLFAMILY_WARRIOR:
|
case SPELLFAMILY_WARRIOR:
|
||||||
{
|
{
|
||||||
|
// Hamstring - limit duration to 10s in PvP
|
||||||
|
if (spellproto->SpellFamilyFlags[0] & 0x2)
|
||||||
|
return DIMINISHING_LIMITONLY;
|
||||||
// Improved Hamstring
|
// Improved Hamstring
|
||||||
if (spellproto->AttributesEx3 & 0x80000 && spellproto->SpellIconID == 23)
|
else if (spellproto->AttributesEx3 & 0x80000 && spellproto->SpellIconID == 23)
|
||||||
return DIMINISHING_ROOT;
|
return DIMINISHING_ROOT;
|
||||||
// Charge Stun (own diminishing)
|
// Charge Stun (own diminishing)
|
||||||
else if (spellproto->SpellFamilyFlags[0] & 0x01000000)
|
else if (spellproto->SpellFamilyFlags[0] & 0x01000000)
|
||||||
@@ -114,6 +117,9 @@ DiminishingGroup GetDiminishingReturnsGroupForSpell(SpellInfo const* spellproto,
|
|||||||
// Death Coil
|
// Death Coil
|
||||||
if (spellproto->SpellFamilyFlags[0] & 0x80000)
|
if (spellproto->SpellFamilyFlags[0] & 0x80000)
|
||||||
return DIMINISHING_HORROR;
|
return DIMINISHING_HORROR;
|
||||||
|
// Curses/etc
|
||||||
|
else if ((spellproto->SpellFamilyFlags[0] & 0x80000000) || (spellproto->SpellFamilyFlags[1] & 0x200))
|
||||||
|
return DIMINISHING_LIMITONLY;
|
||||||
// Seduction
|
// Seduction
|
||||||
else if (spellproto->SpellFamilyFlags[1] & 0x10000000)
|
else if (spellproto->SpellFamilyFlags[1] & 0x10000000)
|
||||||
return DIMINISHING_FEAR;
|
return DIMINISHING_FEAR;
|
||||||
@@ -138,6 +144,9 @@ DiminishingGroup GetDiminishingReturnsGroupForSpell(SpellInfo const* spellproto,
|
|||||||
// Nature's Grasp
|
// Nature's Grasp
|
||||||
else if (spellproto->SpellFamilyFlags[0] & 0x00000200)
|
else if (spellproto->SpellFamilyFlags[0] & 0x00000200)
|
||||||
return DIMINISHING_CONTROLLED_ROOT;
|
return DIMINISHING_CONTROLLED_ROOT;
|
||||||
|
// Faerie Fire
|
||||||
|
else if (spellproto->SpellFamilyFlags[0] & 0x400)
|
||||||
|
return DIMINISHING_LIMITONLY;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case SPELLFAMILY_ROGUE:
|
case SPELLFAMILY_ROGUE:
|
||||||
@@ -151,12 +160,18 @@ DiminishingGroup GetDiminishingReturnsGroupForSpell(SpellInfo const* spellproto,
|
|||||||
// Cheap Shot
|
// Cheap Shot
|
||||||
else if (spellproto->SpellFamilyFlags[0] & 0x400)
|
else if (spellproto->SpellFamilyFlags[0] & 0x400)
|
||||||
return DIMINISHING_OPENING_STUN;
|
return DIMINISHING_OPENING_STUN;
|
||||||
|
// Crippling poison - Limit to 10 seconds in PvP (No SpellFamilyFlags)
|
||||||
|
else if (spellproto->SpellIconID == 163)
|
||||||
|
return DIMINISHING_LIMITONLY;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
case SPELLFAMILY_HUNTER:
|
case SPELLFAMILY_HUNTER:
|
||||||
{
|
{
|
||||||
|
// Hunter's mark
|
||||||
|
if ((spellproto->SpellFamilyFlags[0] & 0x400) && spellproto->SpellIconID == 538)
|
||||||
|
return DIMINISHING_LIMITONLY;
|
||||||
// Scatter Shot (own diminishing)
|
// Scatter Shot (own diminishing)
|
||||||
if ((spellproto->SpellFamilyFlags[0] & 0x40000) && spellproto->SpellIconID == 132)
|
else if ((spellproto->SpellFamilyFlags[0] & 0x40000) && spellproto->SpellIconID == 132)
|
||||||
return DIMINISHING_SCATTER_SHOT;
|
return DIMINISHING_SCATTER_SHOT;
|
||||||
// Entrapment (own diminishing)
|
// Entrapment (own diminishing)
|
||||||
else if (spellproto->SpellVisual[0] == 7484 && spellproto->SpellIconID == 20)
|
else if (spellproto->SpellVisual[0] == 7484 && spellproto->SpellIconID == 20)
|
||||||
@@ -171,8 +186,11 @@ DiminishingGroup GetDiminishingReturnsGroupForSpell(SpellInfo const* spellproto,
|
|||||||
}
|
}
|
||||||
case SPELLFAMILY_PALADIN:
|
case SPELLFAMILY_PALADIN:
|
||||||
{
|
{
|
||||||
|
// Judgement of Justice - limit duration to 10s in PvP
|
||||||
|
if (spellproto->SpellFamilyFlags[0] & 0x100000)
|
||||||
|
return DIMINISHING_LIMITONLY;
|
||||||
// Turn Evil
|
// Turn Evil
|
||||||
if ((spellproto->SpellFamilyFlags[1] & 0x804000) && spellproto->SpellIconID == 309)
|
else if ((spellproto->SpellFamilyFlags[1] & 0x804000) && spellproto->SpellIconID == 309)
|
||||||
return DIMINISHING_FEAR;
|
return DIMINISHING_FEAR;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
@@ -181,6 +199,9 @@ DiminishingGroup GetDiminishingReturnsGroupForSpell(SpellInfo const* spellproto,
|
|||||||
// Hungering Cold (no flags)
|
// Hungering Cold (no flags)
|
||||||
if (spellproto->SpellIconID == 2797)
|
if (spellproto->SpellIconID == 2797)
|
||||||
return DIMINISHING_DISORIENT;
|
return DIMINISHING_DISORIENT;
|
||||||
|
// Mark of Blood
|
||||||
|
else if ((spellproto->SpellFamilyFlags[0] & 0x10000000) && spellproto->SpellIconID == 2285)
|
||||||
|
return DIMINISHING_LIMITONLY;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
default:
|
default:
|
||||||
@@ -225,6 +246,9 @@ DiminishingReturnsType GetDiminishingReturnsGroupType(DiminishingGroup group)
|
|||||||
case DIMINISHING_CYCLONE:
|
case DIMINISHING_CYCLONE:
|
||||||
case DIMINISHING_CHARGE:
|
case DIMINISHING_CHARGE:
|
||||||
return DRTYPE_ALL;
|
return DRTYPE_ALL;
|
||||||
|
case DIMINISHING_LIMITONLY:
|
||||||
|
case DIMINISHING_NONE:
|
||||||
|
return DRTYPE_NONE;
|
||||||
default:
|
default:
|
||||||
return DRTYPE_PLAYER;
|
return DRTYPE_PLAYER;
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user