Page 1 of 1

Help with Macro

Posted: Wed Dec 08, 2004 3:07 pm
by Longstone
I'm using gonemental21's version of the Beastlord Assist Macro. The problem I'm having is when I try to slow, or nuke if my max or min distance is triggered I move, rather I'm casting or not. Obviously that's a bad thing. I've been trying to modify the code so that:

a) I'll only nuke or slow while in combat
b) while casting won't move even if my min/max distance is triggered.

Having no background in coding I was refering to his "Healthcheck" portion of the macro:

Code: Select all

Sub Healthcheck
   /if (!${DoHeal}) /return
   /if (${Me.Casting.ID}) /return
   /if (${Me.Moving}) /return
   /if (${Me.PctHPs}<=90) {
      /if (${Me.Combat}) {
         /if (!${Target.ID}) {
            /delay 5s
            /cast "${HealThing}"
         }
      }
   }
/return
Since I don't move while I'm healing myself I figured the answer has to be there.

This is the current macro.

Nuke:

Code: Select all

Sub Nuke
   /if (${Me.PctMana} > ${Nuketill}) {
      /Call Cast "Frost Spear" gem7
      /delay 15
      } else {
      /return
      }
/return
Slow:

Code: Select all

:Slow_Loop

   /if (${MobSlowed}== TRUE) /return   
   /if (${Target.PctHPs}<=${CombatAt}) {
      /if (${Me.CurrentMana}<${Spell[${SpellSlow}].Mana}) {
         /gsay Shid ! I don't have mana to Slow %T
      } else {
         /call Cast ${SpellSlow} gem1 6s
         /if (${Macro.Return.Equal["CAST_INTERRUPTED"]}) /goto :Slow_Loop
         /if (${Macro.Return.Equal["CAST_IMMUNE"]}) {
            /gsay *** %T is IMMUNE to my slow !
         
            /varset MobSlowed TRUE
         }
         /if (${Macro.Return.Equal["CAST_RESISTED"]}) {
            /if (!${FastSlow}) {
               /gsay *** %T RESISTED slow ! Trying again asap
                /goto :Slow_Loop
             }
            /varset MobSlowed TRUE
          }
         /if (${Macro.Return.Equal["CAST_SUCCESS"]}) { 
            /gsay *** %T is SLOWED
            /varset MobSlowed TRUE
          }

      }
   }
/return
Thanks for the help.

Posted: Wed Dec 08, 2004 3:37 pm
by JP5

Code: Select all

Sub Nuke 
   /if (${Me.PctMana} > ${Nuketill}) { 
      /Call Cast "Frost Spear" gem7 
      /delay 15 
      } else { 
      /return 
      } 
/return

Code: Select all

|Alteration
Sub Nuke
/if (${Me.PctMana}<${Nuketill} || ${Me.Moving}) /return

/call cast "Frost Spear" gem7
/delay 15
/return

Posted: Wed Dec 08, 2004 3:41 pm
by fearless

Code: Select all

:Slow_Loop 

   /if (${MobSlowed}== TRUE) /return    
   /if (!${Me.Combat}) /return
   /if (${Me.Moving}) /return
   /if (${Target.PctHPs}<=${CombatAt}) { 
      /if (${Me.CurrentMana}<${Spell[${SpellSlow}].Mana}) { 
         /gsay Shid ! I don't have mana to Slow %T 
      } else { 
         /call Cast ${SpellSlow} gem1 6s 
         /if (${Macro.Return.Equal["CAST_INTERRUPTED"]}) /goto :Slow_Loop 
         /if (${Macro.Return.Equal["CAST_IMMUNE"]}) { 
            /gsay *** %T is IMMUNE to my slow ! 
          
            /varset MobSlowed TRUE 
         } 
         /if (${Macro.Return.Equal["CAST_RESISTED"]}) { 
            /if (!${FastSlow}) { 
               /gsay *** %T RESISTED slow ! Trying again asap 
                /goto :Slow_Loop 
             } 
            /varset MobSlowed TRUE 
          } 
         /if (${Macro.Return.Equal["CAST_SUCCESS"]}) { 
            /gsay *** %T is SLOWED 
            /varset MobSlowed TRUE 
          } 

      } 
   } 
/return
My own attack spell code . . .

Code: Select all

Sub Attack_Spells
  /if (${Me.Moving}) /return
  /if (${Me.Casting.ID}) /return
  /if (${Me.PctMana}<15) /return 
  /if (${Target.PctHPs}>90) /return
  /if (${Target.PctHPs}<10) /return
  /if (${Me.Gem[Aura of Pain]}>0 && ${Me.Combat}) {
    /call cast "Aura of Pain"
  }
/return

Posted: Wed Dec 08, 2004 5:16 pm
by Longstone
Thank you Both