Jump to content

rj686

Members
  • Posts

    7
  • Joined

  • Last visited

    Never
  • Donations

    0.00 GBP 

Everything posted by rj686

  1. http://www.cprogramming.com/ http://en.wikibooks.org/wiki/C%2B%2B_Programming http://www.cplusplus.com/doc/tutorial/ http://www.cs.wustl.edu/~schmidt/C++/
  2. Currently on mangos whenever a new aura is applied to the caster it is applied as a separate aura object. This is not official behavior. Any aura that stacks whether it be an armor debuff such as sunder or devastate or an npc spell such as immolation arrow, they are applied to both casters and npcs many more times than need be. With the dbc column that states the amount of stacks possible for each spell, shouldn't it be possible to consolidate auras and just update m_amount for each application and refresh the duration? This would also fix spells such as lifebloom, wound poison, sunder, lacerate etc. If one aura were to be dispelled of the stack we could just remove one of the stack and update the amount rather than having to reapply/unapply an aura object everytime. I think in the end this would remove a lot of overhead and also fix plenty of spells in the process. But as a noobie coder I'm at a loss on where to start. I know i need to add an m_stacks variable to the aura class, and to change how each stacking aura is treated. I know i need to simplify Unit::RemoveSingleAuraFromStack. What does the effindex do? One more question is does anyone know how to determine whether a spell is only allowed 1 stack on a person ie sunder vs multiple stacks ie lifebloom. Any input/knowledge is greatly appreciated -Deaf
  3. * What bug does the patch fix? What features does the patch add? Correctly implements Lifetap. The current implementation treats lifetap as shadow damage which it is not, and it shouldn't appear in the combat log. * For which SubVersion revision was the patch created? 6529 * Is there a thread in the bug report section? If yes, please add a link to the thread. Not that I know of..... * Who has been writing this patch? Please include either forum user names or email addresses. Deafboy Index: src/game/SpellEffects.cpp =================================================================== --- src/game/SpellEffects.cpp (revision 6529) +++ src/game/SpellEffects.cpp (working copy) @@ -1082,12 +1082,13 @@ if(int32(m_caster->GetHealth()) > dmg) { - m_caster->SendSpellNonMeleeDamageLog(m_caster, m_spellInfo->Id, dmg, GetSpellSchoolMask(m_spellInfo), 0, 0, false, 0, false); - m_caster->DealDamage(m_caster,dmg,NULL,DIRECT_DAMAGE,GetSpellSchoolMask(m_spellInfo),m_spellInfo,false); + + // Shouldn't Appear in Combat Log + m_caster->ModifyHealth(-(int32)dmg); + + int32 mana = dmg; - int32 mana = dmg; - - Unit::AuraList const& auraDummy = m_caster->GetAurasByType(SPELL_AURA_DUMMY); + Unit::AuraList const& auraDummy = m_caster->GetAurasByType(SPELL_AURA_DUMMY); for(Unit::AuraList::const_iterator itr = auraDummy.begin(); itr != auraDummy.end(); ++itr) { // only Imp. Life Tap have this in combination with dummy aura
  4. * What bug does the patch fix? What features does the patch add? Combines stacks from the same caster GUID so they don't heal, DoT seperately. * For which SubVersion revision was the patch created? 6442 * Is there a thread in the bug report section? If yes, please add a link to the thread. I'll link when i have more time * Who has been writing this patch? Please include either forum user names or email addresses. Zombie from mangos.ru, I just updated it. Index: src/game/SpellAuras.h =================================================================== --- src/game/SpellAuras.h (revision 6442) +++ src/game/SpellAuras.h (working copy) @@ -255,10 +255,13 @@ bool IsPositive() { return m_positive; } void SetNegative() { m_positive = false; } void SetPositive() { m_positive = true; } + + bool IsPeriodic() { return m_isPeriodic; } + void SetPeriodic ( bool set) {m_isPeriodic = set;} bool IsPermanent() const { return m_permanent; } bool IsAreaAura() const { return m_isAreaAura; } - bool IsPeriodic() const { return m_isPeriodic; } + bool IsTrigger() const { return m_isTrigger; } bool IsPassive() const { return m_isPassive; } bool IsPersistent() const { return m_isPersistent; } Index: src/game/Unit.cpp =================================================================== --- src/game/Unit.cpp (revision 6442) +++ src/game/Unit.cpp (working copy) @@ -3593,7 +3593,33 @@ // replace aura if next will > spell StackAmount if(aurSpellInfo->StackAmount) { - if(m_Auras.count(spair) >= aurSpellInfo->StackAmount) + uint32 c = m_Auras.count(spair); + switch(Aur->GetModifier()->m_auraname) + { + case SPELL_AURA_PERIODIC_DAMAGE: + case SPELL_AURA_PERIODIC_HEAL: + case SPELL_AURA_PERIODIC_ENERGIZE: + case SPELL_AURA_PERIODIC_LEECH: + case SPELL_AURA_PERIODIC_HEALTH_FUNNEL: + case SPELL_AURA_PERIODIC_MANA_FUNNEL: + case SPELL_AURA_PERIODIC_MANA_LEECH: + case SPELL_AURA_PERIODIC_DAMAGE_PERCENT: + { + if( c >= Aur->GetSpellProto()->StackAmount ) + Aur->GetModifier()->m_amount *= c; + else + Aur->GetModifier()->m_amount *= c + 1; + AuraMap::iterator itr = i; + for( itr = m_Auras.begin(); itr != m_Auras.end(); ++itr ) + { + if( spellEffectPair((*itr).second->GetId(), (*itr).second->GetEffIndex()) != spair || (*itr).second->GetCasterGUID() != Aur->GetCasterGUID() ) + continue; + (*itr).second->SetPeriodic(false); + } + } break; + default: break; + } + if(m_Auras.count(spair) >= aurSpellInfo->StackAmount) RemoveAura(i); } // if StackAmount==0 not allow auras from same caster \\ The issue is that it doesn't take into account spell damage / healing for healing spells. If anyone with more knowledge than me could take a look at it i'd appreciate it.
  5. Wow would a mod please close this topic, i just searched a few minutes ago and got nothing. Guess i fail.
  6. Done a few searches around but I have yet to find a way to save way points in instances since GUIDs are unique for each instance created. Am i just missing one key command or did i just point out a feature that's still missing -Deaf
  7. I can second the fact that you don't lose rage if the attack is parried, just incase it was in question
×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. Privacy Policy Terms of Use