Druid.mac changes for BST and PET

Help section from before the user variable changes that broke all macros

Moderator: MacroQuest Developers

User avatar
DarkSoulX
orc pawn
orc pawn
Posts: 10
Joined: Sat Oct 12, 2002 6:04 pm

Druid.mac changes for BST and PET

Post by DarkSoulX » Sat Oct 12, 2002 6:12 pm

Ok, I tried to modify the druid.mac code to work with my BST to include buffs for my pet...but I am having trouble getting the druid to target my pet...

can someone please tell me what I am doing wrong...

Code: Select all

#include SpellSub.mac 
#include routines.mac 
#chat tell 

Sub Main 
    :loop  
      /doevents  
    /goto :loop 
/return 

Sub Event_Chat 
   /stand 
   /target $p1 
   /if $p2~~"heal" /call HealSub 
   /if $p2~~"DS" /call  DsSub 
   /if $p2~~"Skin" /call SkinSub 
   /if $p2~~"Regen" /call RegenSub 
   /if $p2~~"str" /call StrengthSub 
   /if $p2~~"sow" /call SoWSub 
   /if $p2~~"snare" /call SnareSub 
   /if $p2~~"root" /call RootSub 
   /if $p2~~"come" /call GoTarget 
   /if $p2~~"self" /call SelfBuff 
   /if $p2~~"go home" /call GoHome

   /if $p2~~"pet skin" /call PetSkin
   /if $p2~~"pet DS" /call PetDS
   /if $p2~~"pet regen" /call PetRegen
   /if $p2~~"pet sow" /call PetSow
   /if $p2~~"pet str" /call PetStr 
   /delay 15 
   /sit 
/return 

Sub HealSub 
   /TT INC Heal for %T 
   /call SpellSub 1 5 
/return    

Sub DsSub 
    /tt INC Damage Shield for %T 
    /call SpellSub 2 5.25 
/return 

Sub SkinSub 
    /tt INC Skin for %T 
    /call SpellSub 3 8 
/return 
    
Sub RegenSub 
    /tt INC Regen for %T 
    /call SpellSub 4 8.5 
/return 

Sub StrengthSub 
    /tt INC STR for %T 
    /call SpellSub 5 7.5 
/return 
    
Sub SoWSub 
    /tt INC SoW for %T 
    /call SpellSub 6 8 
/return 
    
Sub SnareSub 
    /assist $p1 
    /delay 5 
    /tell $p1 Ensnaring %T 
    /call SpellSub 7 5.75    
    /target $p1 
    /tt Mob ensnared 
/return 

Sub RootSub 
    /assist $p1 
    /delay 5 
    /tell $p1 Rooting %T 
    /call SpellSub 8 5.5    
    /target $p1 
    /tt Mob rooted 
/return 

Sub GoTarget 
   /stand 
   /face $p1 
   /varset v90 $target(id) 
   /tt I'm coming to you %t, no other actions possible in the next 10 Seconds 
   /varset t0 10s 
   :CloserAF 
      /if "$target(id)"!="$v90" /goto :EndAF 
      /if n $target(distance)>14 /call AutoRun 1 
      /if n $target(distance)<15 /call AutoRun 0 
      /if n $target(distance)<5 /call BackPedal 0 
      /if n $target(distance)>4 /call BackPedal 1 
      /face $p1 
      /if n $t0==0 /press esc 
   /goto :CloserAF 

   :EndAF 
   /call AutoRun 0 
/return 

Sub SelfBuff 
   /sendkey down F1 
   /sendkey up F1 
   /Call SpellSub 6 8 
   /sendkey down F1 
   /sendkey up F1 
   /call SpellSub 3 8
   /sendkey down F1 
   /sendkey up F1
   /call SpellSub 4 8.5
   /sendkey down F1
   /sendkey up F1
   /call SpellSub 2 5.25  
   /target $p1 
/return 

Sub GoHome 
   /sit 
   /camp desktop 
   /unload 
/return 

Sub PetSkin 
    /target pet $p1 
    /delay 5 
    /tell $p1 INC Skin for %T 
    /call SpellSub 3 8    
    /target $p1 
    /tt Pet has Skin 
/return

Sub PetDS 
    /target pet $p1 
    /delay 5 
    /tell $p1 INC DS for %T 
    /call SpellSub 2 5.25    
    /target $p1 
    /tt Pet has DS 
/return

Sub PetRegen 
    /target pet $p1 
    /delay 5 
    /tell $p1 INC Regen for %T 
    /call SpellSub 4 8.5    
    /target $p1 
    /tt Pet has Regen 
/return

Sub PetSow 
    /target pet $p1 
    /delay 5 
    /tell $p1 INC SOW for %T 
    /call SpellSub 6 8    
    /target $p1 
    /tt Pet has SOW 
/return

Sub PetStr 
    /target pet $p1 
    /delay 5 
    /tell $p1 INC STR for %T 
    /call SpellSub 5 7.5   
    /target $p1 
    /tt Pet has STR 
/return
The point of war is not to die for your country, but to make the enemy die for theirs!

User avatar
L124RD
Site Admin
Site Admin
Posts: 1343
Joined: Fri Jun 14, 2002 12:15 am
Location: Cyberspace
Contact:

Post by L124RD » Sun Oct 13, 2002 7:04 pm

Salutations,
just about every line with $p1 in it after the event_chat subroutine will end up inserting a "" where the $p1 is, ie /target pet $p1 will just /target pet... which isn't good same with /assist $p1, it will just /assist. The only reason this works with the druid macro is the fact that you already target the person whom told you to do the command, so where you assist them, you end up assisting them...