Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Core/Spells: Implement Periodic mechanics #12228

Merged
merged 1 commit into from Jun 8, 2014
Merged

Core/Spells: Implement Periodic mechanics #12228

merged 1 commit into from Jun 8, 2014

Conversation

LuqJensen
Copy link
Contributor

Change behaviour of single target periodic aura ticks to be more blizzlike
Also add some missing handling of SPELL_AURA_MOD_CREATURE_AOE_DAMAGE_AVOIDANCE
Fixes Deep wounds and Chimera Shot Serpent
Remove an ancient hack with Drain Soul, spell id 100001 can now be deleted from spell_dbc table
Allows Rolling dot mechanics and allows DK's to roll diseases with pestilence,
see link for info:

http://forums.elitistjerks.com/topic/82503-frost-dps-in-333this-will-be-a-day-long-remembered/page-88

bool Unit::isSpellCrit(Unit* victim, SpellInfo const* spellProto, SpellSchoolMask schoolMask, WeaponAttackType attackType) const
bool Unit::IsSpellCrit(Unit* victim, SpellInfo const* spellProto, SpellSchoolMask schoolMask, WeaponAttackType attackType) const
{
if (roll_chance_f(GetUnitSpellCriticalChance(victim, spellProto, schoolMask, attackType)))
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

you might just "return roll_chance_f(...)" here

@ghost
Copy link

ghost commented Jun 6, 2014

this is great 👍

@LuqJensen
Copy link
Contributor Author

Should be gone now Runico :)

@DoodleZero
Copy link

http://prntscr.com/3qgxml - Now Healing Spells are bugged (Maximal healing: 1 hp)

// use float as more appropriate for negative values and percent applying
float heal = float(int32(healamount) + DoneTotal) * DoneTotalMod;
// Done Percentage for DOT is already calculated, no need to do it again. The percentage mod is applied in Aura::HandleAuraSpecificMods.
float heal = float(int32(healamount) + DoneTotal) * damagetype == DOT ? 1.0f : SpellHealingPctDone(victim, spellProto);
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

operator precedence derp here, multiplication happens before comparison
float heal = float(int32(healamount) + DoneTotal) * (damagetype == DOT ? 1.0f : SpellHealingPctDone(victim, spellProto));

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

uno momento

@DoodleZero
Copy link

Fixed ?

@LuqJensen
Copy link
Contributor Author

yes SmythX

@DoodleZero
Copy link

Can you show me what's fixed ?

(can you make fast patch/diff to for fix), because i already added this script into my source.

@LuqJensen
Copy link
Contributor Author

check shaurens comment

@DoodleZero
Copy link

  • // Done Percentage for DOT is already calculated, no need to do it again. The percentage mod is applied in Aura::HandleAuraSpecificMods.
  • float heal = float(int32(healamount) +
    DoneTotal) * damagetype == DOT ? 1.0f : SpellHealingPctDone(victim, spellProto);

Replace with:

  • // use float as more appropriate for negative values and percent applying
  • float heal = float(int32(healamount) + DoneTotal) * DoneTotalMod;

This ?

@LuqJensen
Copy link
Contributor Author

his comment...

float heal = float(int32(healamount) + DoneTotal) * (damagetype == DOT ? 1.0f : SpellHealingPctDone(victim, spellProto));

@DoodleZero
Copy link

Old:
float heal = float(int32(healamount) + DoneTotal) * damagetype == DOT ? 1.0f : SpellHealingPctDone(victim, spellProto);

New, fixed:
float heal = float(int32(healamount) + DoneTotal) * (damagetype == DOT ? 1.0f : SpellHealingPctDone(victim, spellProto));

@DoodleZero
Copy link

Okay, TNX!

@Subv
Copy link
Contributor

Subv commented Jun 7, 2014

Closes #5959

@ghost
Copy link

ghost commented Jun 7, 2014

why i cant see the changes on commit?

@LuqJensen
Copy link
Contributor Author

they are squashed

@ghost
Copy link

ghost commented Jun 7, 2014

Hmmmmm ? i didn't understand you

Change behaviour of single target periodic aura ticks to be more blizzlike
Also add some missing handling of SPELL_AURA_MOD_CREATURE_AOE_DAMAGE_AVOIDANCE
Fixes Deep wounds and Chimera Shot Serpent
Remove an ancient hack with Drain Soul, spell id 100001 can now be deleted from spell_dbc table
Allows Rolling dot mechanics and allows DK's to roll diseases with pestilence,
see link for info:

http://forums.elitistjerks.com/topic/82503-frost-dps-in-333this-will-be-a-day-long-remembered/page-88
@ghost
Copy link

ghost commented Jun 8, 2014

@digz6666
Copy link

digz6666 commented Jun 8, 2014

Cool!

Subv added a commit that referenced this pull request Jun 8, 2014
Core/Spells: Implement Periodic mechanics
@Subv Subv merged commit d0c9ac1 into TrinityCore:master Jun 8, 2014
@digz6666
Copy link

digz6666 commented Jun 9, 2014

BTW what was wrong with Deep Wounds and Chimera Shot Serpent?

@DoodleZero
Copy link

Now all pets (their HP is bugged), now pet have less hp...

@LuqJensen
Copy link
Contributor Author

thats not related to this SmythX...

@LuqJensen LuqJensen deleted the patch_periodics branch June 10, 2014 11:51
@DoodleZero
Copy link

Hmm, I'll try to find problem, cuz my PET HP was okay before few days, and when i add some of latest patches it's very bugged... I will remove patch and test again... If I find problem I'll report it ;)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

7 participants