Jump to content

darkstalker

Members
  • Posts

    717
  • Joined

  • Last visited

    Never
  • Donations

    0.00 GBP 

Posts posted by darkstalker

  1. Discovered a "bug" related to this. It blocks non-triggered casts caused by other spells effects, like Chimera Shot (53209) trigggers a 1500 ms gcd in category 133, then the sting effect gets blocked by gcd check (like Spell 53353: Chimera Shot - Serpent) cause it has the same category 133. Setting the sting effect as triggered fixes it, but maybe should add an extra check to identify spells casted from client side (as opposed to casts from spell handlers). It could be just a dbc "redundant data bug" in this case.

  2. * What bug does the patch fix? What features does the patch add?

    fixes a typo in invisibility and detect invisibility aura handlers that can cause incorrect aura remove effect.

    * For which repository revision was the patch created?

    10432

    * Is there a thread in the bug report section or at lighthouse? If yes, please add a link to the thread.

    no

    * Who has been writing this patch? Please include either forum user names or email addresses.

    darkstalker

    diff --git a/src/game/SpellAuras.cpp b/src/game/SpellAuras.cpp
    index 59d5192..92e449d 100644
    --- a/src/game/SpellAuras.cpp
    +++ b/src/game/SpellAuras.cpp
    @@ -3936,7 +3936,7 @@ void Aura::HandleInvisibility(bool apply, bool Real)
            target->m_invisibilityMask = 0;
            Unit::AuraList const& auras = target->GetAurasByType(SPELL_AURA_MOD_INVISIBILITY);
            for(Unit::AuraList::const_iterator itr = auras.begin(); itr != auras.end(); ++itr)
    -            target->m_invisibilityMask |= (1 << m_modifier.m_miscvalue);
    +            target->m_invisibilityMask |= (1 << (*itr)->GetModifier()->m_miscvalue);
    
            // only at real aura remove and if not have different invisibility auras.
            if(Real && target->m_invisibilityMask == 0)
    @@ -3970,7 +3970,7 @@ void Aura::HandleInvisibilityDetect(bool apply, bool Real)
            target->m_detectInvisibilityMask = 0;
            Unit::AuraList const& auras = target->GetAurasByType(SPELL_AURA_MOD_INVISIBILITY_DETECTION);
            for(Unit::AuraList::const_iterator itr = auras.begin(); itr != auras.end(); ++itr)
    -            target->m_detectInvisibilityMask |= (1 << m_modifier.m_miscvalue);
    +            target->m_detectInvisibilityMask |= (1 << (*itr)->GetModifier()->m_miscvalue);
        }
        if(Real && target->GetTypeId()==TYPEID_PLAYER)
            ((Player*)target)->GetCamera().UpdateVisibilityForOwner();
    

  3. That kind of timers require periodic update to work (rougly 100ms), so its extra work to do. I fetch the time only when i need it, not on every world update tick.

    And its not just one gcd timer, its actually one per category. That is what makes some abilities independant of the gcd or have a special gcd trait.

  4. This patch implements server side global cooldown checking using data provided in Spell.dbc (StartRecoveryCategory, StartRecoveryTime), player stats (haste rating) and latency to provide a more accurate result. Testing and feedback needed ;>

    patch for 10432:

    v1: http://paste2.org/p/974537

    v2: http://paste2.org/p/980906

    v3: http://paste2.org/p/995984

    Changelog:

    v1: Original version

    v2: Use time difference against last casted spell instead of future cooldown time. That way the latency variable gets "cancelled off", providing more accurate and fail-safe result

    v3: implemented gcd cancel on interrupted cast (as displayed on client)

  5. this might work:

    std::istringstream ss(sWorld.getConfig(CONFIG_STRING_CUSTOM_AREAS));
    char filler;
    std::set<uint32> areas;
    while (!ss)
    {
       uint32 areaid = 0;
       ss >> areaid;
       ss >> filler;
       if (areaid)
           areas.insert(areaid);
    }
    if (areas.find(pPlayer->GetAreaId()) != areas.end())
    {
       // stuff here
    }
    

×
×
  • 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