Go Back   EQEmulator Home > EQEmulator Forums > Development > Development::Server Code Submissions

 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
  #4  
Old 09-08-2012, 06:41 PM
demonstar55
Demi-God
 
Join Date: Apr 2008
Location: MA
Posts: 1,164
Default

Okay, I found the case where it was still not resetting the timer, and my inclination was right, it was when the target moved out of range. You can ignore the previous diff and apply this one (I originally didn't want to touch the Cast functions because of a rather ominous warning, but I have to now!)

Code:
Index: AA.cpp
===================================================================
--- AA.cpp      (revision 2207)
+++ AA.cpp      (working copy)
@@ -241,6 +241,7 @@
                case aaTargetCurrentGroup:
                        if(GetTarget() == NULL) {
                                Message_StringID(MT_DefaultText, AA_NO_TARGET); //You must first select a target for this ability!
+                               p_timers.Clear(&database, AATimerID + pTimerAAStart);
                                return;
                        }
                        target_id = GetTarget()->GetID();
@@ -501,6 +502,7 @@
                case aaTargetCurrentGroup:
                        if(GetTarget() == NULL) {
                                Message_StringID(MT_DefaultText, AA_NO_TARGET); //You must first select a target for this ability!
+                               p_timers.Clear(&database, timer_id + pTimerAAEffectStart);
                                return;
                        }
                        target_id = GetTarget()->GetID();
Index: spells.cpp
===================================================================
--- spells.cpp  (revision 2207)
+++ spells.cpp  (working copy)
@@ -711,6 +711,9 @@
                CastToNPC()->AI_Event_SpellCastFinished(false, casting_spell_slot);
        }

+       if(casting_spell_type == 1 && IsClient()) //Rest AA Timer on failed cast
+               CastToClient()->GetPTimers().Clear(&database, casting_spell_timer);
+
        ZeroCastingVars();      // resets all the state keeping stuff

        mlog(SPELLS__CASTING, "Spell %d has been interrupted.", spellid);
Reply With Quote
 

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

   

All times are GMT -4. The time now is 01:31 PM.


 

Everquest is a registered trademark of Daybreak Game Company LLC.
EQEmulator is not associated or affiliated in any way with Daybreak Game Company LLC.
Except where otherwise noted, this site is licensed under a Creative Commons License.
       
Powered by vBulletin®, Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Template by Bluepearl Design and vBulletin Templates - Ver3.3