Looking4Group / L4G_Core

Looking4Group Core
http://looking4group.eu
GNU General Public License v2.0
37 stars 69 forks source link

Toughness hamstring debuff duration #2596

Open Xadras opened 8 years ago

Xadras commented 8 years ago

Originally reported by: BugReporter5000 (Bitbucket: BugReporter5000, GitHub: Unknown)


Toughness (http://db.hellfire-tbc.com/?spell=16309) enhancement talent.

Currently in pvp it does not reduce hamstring down to 5 seconds like it's supposed to, it reduces it to 7.5 seconds (half of the original 15 second duration of hamstring).

It should reduce the pvp duration of hamstring (10seconds) by 50% - aka 5second snare.

proof: https://youtu.be/noWjlp_aa_A?t=1311

As you can see warrior charges him, and the duration of hamstring is instantly 5 seconds


Xadras commented 8 years ago

Original comment by Anon X (Bitbucket: Anonx, GitHub: Anonx):


5secs displayed as 4. cuz 50% of 10 is 5.

it should take the DIMINISHING_LIMITONLY into account reducing harmstring to 10secs in pvp.

16309 16308 16307 16306 16252

spell duration >10000 = 10000; oder so

harmstring and curse of exhaustion should be the only 2 spells to look at as they habe DIMINISHING_LIMITONLY in pvp.

#!c++

case 1715: // harmstring r1
if spellInfo->Id==16252, spellInfo->DurationIndex = XXX; // 10% -> 9sec
if spellInfo->Id==16306, spellInfo->DurationIndex = XXX; // 20% -> 8sec
if spellInfo->Id==16307, spellInfo->DurationIndex = XXX; // 30% -> 7sec
if spellInfo->Id==16308, spellInfo->DurationIndex = XXX; // 40% -> 6sec
if spellInfo->Id==16309, spellInfo->DurationIndex = XXX; // 50% -> 5sec duration
break;
case 7372: // harmstring r2
if spellInfo->Id==16252, spellInfo->DurationIndex = XXX; // 10% -> 9sec
if spellInfo->Id==16306, spellInfo->DurationIndex = XXX; // 20% -> 8sec
if spellInfo->Id==16307, spellInfo->DurationIndex = XXX; // 30% -> 7sec
if spellInfo->Id==16308, spellInfo->DurationIndex = XXX; // 40% -> 6sec
if spellInfo->Id==16309, spellInfo->DurationIndex = XXX; // 50% -> 5sec duration
break;
case 7373: // harmstring r3
if spellInfo->Id==16252, spellInfo->DurationIndex = XXX; // 10% -> 9sec
if spellInfo->Id==16306, spellInfo->DurationIndex = XXX; // 20% -> 8sec
if spellInfo->Id==16307, spellInfo->DurationIndex = XXX; // 30% -> 7sec
if spellInfo->Id==16308, spellInfo->DurationIndex = XXX; // 40% -> 6sec
if spellInfo->Id==16309, spellInfo->DurationIndex = XXX; // 50% -> 5sec duration
break;
case 25212: // harmstring r3
if spellInfo->Id==16252, spellInfo->DurationIndex = XXX; // 10% -> 9sec
if spellInfo->Id==16306, spellInfo->DurationIndex = XXX; // 20% -> 8sec
if spellInfo->Id==16307, spellInfo->DurationIndex = XXX; // 30% -> 7sec
if spellInfo->Id==16308, spellInfo->DurationIndex = XXX; // 40% -> 6sec
if spellInfo->Id==16309, spellInfo->DurationIndex = XXX; // 50% -> 5sec duration
break;

case: spellproto->SpellFamilyFlags & 0x00000000002LL // all harmstring spells
if spellInfo->Id==16252, spellInfo->DurationIndex = XXX; // 10% -> 9sec
if spellInfo->Id==16306, spellInfo->DurationIndex = XXX; // 20% -> 8sec
if spellInfo->Id==16307, spellInfo->DurationIndex = XXX; // 30% -> 7sec
if spellInfo->Id==16308, spellInfo->DurationIndex = XXX; // 40% -> 6sec
if spellInfo->Id==16309, spellInfo->DurationIndex = XXX; // 50% -> 5sec duration
break;

We want harmstring to have 15sec duration in pve, 10sec duration pvp -> https://github.com/Looking4Group/L4G_Core/blob/master/src/game/SpellMgr.cpp#L4527

And for Shamans Thoughness Spell the Duration decrease should be calculated from the DIMINISHING_LIMITONLY of 10secs.