Jump to content

VladimirMangos

Members
  • Posts

    2813
  • Joined

  • Last visited

    Never
  • Donations

    0.00 GBP 

Everything posted by VladimirMangos

  1. In git repo? If you want only common diff file and have both commits as last comits in ypu branch then you can do: git diff HEAD^^ > patchfile If you have both last but want merge its to single commit then you need read about before and then use: git rebase -i HEAD^^ For this case i not have problem apply its in current form.
  2. I update header as you suggest, but also make other required changes like ========== line width update. Also move hardcoded strings to DB. This all added in [7565]. Thank you for problem poiting and original patch suggestions.
  3. I personally hate like changes Lost small nice details and race unique from world.
  4. In [7561]. Thank you
  5. Patch in [7560]. Thank you
  6. As i remember, applied.
  7. Patch with small chnages added in [7559]. Thank you
  8. hmm,, forgot move patch to accepted section. Do it now.
  9. Thanks anyway
  10. Hmm, but this also not solve problem with req. adding to check. CompareAuraRanks support currently only same spell ranks only. More general question is: what must happen if one spell N3 N2 N1 - spsell ranks B2 B1 another and B2 dependent from N2 and B1 dependent from N1 Whta do if applied B2 and casted N3 or in reversed case.
  11. Modified function used in many cases. For example for stacking in spellbook. And clear that not always req. spell must be take in checks. Possible this version more safe (it used req. checks only for cases when both spell have same spellspec): diff --git a/src/game/SpellMgr.cpp b/src/game/SpellMgr.cpp index 7ef35a5..62f95af 100644 --- a/src/game/SpellMgr.cpp +++ b/src/game/SpellMgr.cpp @@ -1055,13 +1055,43 @@ void SpellMgr::LoadSpellThreats() sLog.outString(); } -bool SpellMgr::IsRankSpellDueToSpell(SpellEntry const *spellInfo_1,uint32 spellId_2) const +bool SpellMgr::IsRankSpellDueToSpell(SpellEntry const *spellInfo_1,uint32 spellId_2, bool with_req) const { + if(!spellInfo_1) return false; + SpellEntry const *spellInfo_2 = sSpellStore.LookupEntry(spellId_2); - if(!spellInfo_1 || !spellInfo_2) return false; - if(spellInfo_1->Id == spellId_2) return false; + if(!spellInfo_2) return false; + + // same spell + if(spellInfo_1->Id == spellId_2) + return false; + + // not ranked + SpellChainNode const* node1 = GetSpellChainNode(spellInfo_1->Id); + if(!node1) + return false; + + // not ranked + SpellChainNode const* node2 = GetSpellChainNode(spellInfo_2->Id); + if(!node2) + return false; - return GetFirstSpellInChain(spellInfo_1->Id)==GetFirstSpellInChain(spellId_2); + // from same chain both + if(node1->first==node2->first) + return true; + + if(with_req) + { + // maybe req from another chain + if(node1->req && GetFirstSpellInChain(node1->req)==node2->first) + return true; + + // maybe req from another chain + if(node2->req && GetFirstSpellInChain(node2->req)==node1->first) + return true; + } + + return false; } bool SpellMgr::canStackSpellRanks(SpellEntry const *spellInfo) diff --git a/src/game/SpellMgr.h b/src/game/SpellMgr.h index d026ccb..68f43f9 100644 --- a/src/game/SpellMgr.h +++ b/src/game/SpellMgr.h @@ -720,7 +720,7 @@ class SpellMgr return false; } - bool IsRankSpellDueToSpell(SpellEntry const *spellInfo_1,uint32 spellId_2) const; + bool IsRankSpellDueToSpell(SpellEntry const *spellInfo_1,uint32 spellId_2, bool with_req = false) const; static bool canStackSpellRanks(SpellEntry const *spellInfo); bool IsNoStackSpellDueToSpell(uint32 spellId_1, uint32 spellId_2) const; diff --git a/src/game/Unit.cpp b/src/game/Unit.cpp index 309b551..7065f69 100644 --- a/src/game/Unit.cpp +++ b/src/game/Unit.cpp @@ -3566,7 +3566,7 @@ bool Unit::RemoveNoStackAurasDueToAura(Aura *Aur) if( is_sspc && Aur->GetCasterGUID() == (*i).second->GetCasterGUID() ) { // cannot remove higher rank - if (spellmgr.IsRankSpellDueToSpell(spellProto, i_spellId)) + if (spellmgr.IsRankSpellDueToSpell(spellProto, i_spellId, true)) if(CompareAuraRanks(spellId, effIndex, i_spellId, i_effIndex) < 0) return false; @@ -3583,7 +3583,7 @@ bool Unit::RemoveNoStackAurasDueToAura(Aura *Aur) else next = m_Auras.begin(); } - else if( is_sspt && Aur->GetCasterGUID() != (*i).second->GetCasterGUID() && spellmgr.IsRankSpellDueToSpell(spellProto, i_spellId) ) + else if( is_sspt && Aur->GetCasterGUID() != (*i).second->GetCasterGUID() && spellmgr.IsRankSpellDueToSpell(spellProto, i_spellId, true) ) { // cannot remove higher rank if(CompareAuraRanks(spellId, effIndex, i_spellId, i_effIndex) < 0)
  12. Thank you! You are right. Patch added to [7535]
  13. Do you check build? GetPlayer()->GetBaseReputation(iter->second) will not compile. Please check next time. Patch added with changes to [7530]. Thank you.
  14. hmm, strange, i build 2.4.3 before commit 2.4.3 versiom. I will recheck. [adeed]In eec0f82568e169930328edf94423ae48fd87b1cf Thank you
  15. Where in _above_ you found ad.exe _Only_ _single_ appropriate ad.exe for your version if you build from own sources in contrib/extractor directory. BUT this can not work if you have some stranged way modifed source. And you already prove by quoted lines that you have its in modified state.
  16. quest rewards applied at quest loading. I totally not understand discussion? What you discuss? If spell removed by another spell in resukt wrong icon check, then this must fixed in appropriate player wher all like fixes present. Maybe it considered as negative...
  17. As i write: you don;t must have fixed line. It just not exist in not-modified sources.
  18. I think you use not recent sources. In recent sources: Hmmm, or modified. This fiel has been added and not chnage in this line from creating. I think you must get proper not modified soueces instead attempt fix manually your existed version.
  19. In [7516] Thank you In [7517] added ammount limit.
  20. This is this test confirmation?For me description references to just counting and expire after 20 targets [added]Ok, i found some confirmation to your point:
×
×
  • 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