rogue.mac - AutoRogue v. 2.0j *New Parm Rdy* (4/25/2004)

A forum for you to dump all the macros you create, allowing users to use, modify, and comment on your work.

Moderator: MacroQuest Developers

Cunning
a lesser mummy
a lesser mummy
Posts: 61
Joined: Tue Mar 23, 2004 4:42 pm

rogue.mac - AutoRogue v. 2.0j *New Parm Rdy* (4/25/2004)

Post by Cunning » Mon Mar 29, 2004 11:27 pm

AutoRogue v. 2.0j (New Parm System Ready)
------------------------------------------------------

This macro plays the rogue for you. Great for two-boxing or carpal tunnel sufferers.

Features:

1. Sneak/Hide on load and between fights.
2. Set an anchor to return to between fights or follow a target (or group member).
3. Waits for mob health percentage to reach a value you specify before attacking.
4. Movement/Auto-attack/evade/backstab/discipline usage handled automatically.
5. Uses GenBot's getbehind code for moving behind a mob.
6. Stops discipline usage and refreshes endurance when you get low.
7. Stops attack on enrage, resuming when enrage is over.
8. Clutch nimble/escape based on your health pct.
9. GM detection for combat/movement loops.

Future Plans:
1. Fix collision detection in getbehind code.
2. Clickable item activation (based on buff timers).
3. Smart tank switching (for when group members change).
4. Request buffs from group members based on class/level/expy (lol, fun stuff).

PM me or reply here if you have any questions/comments/suggestions/bug reports/etc.

custom.inc

Code: Select all

| custom.inc
| Example include file for AutoRogue 2.0j

/declare sneakhide global        | Sneak Hide between kills; 1 = Yes, 0 = No 
/declare engagedistance global   | How close the mob must be to engage, 0 = Infinite (note no collision detection)
/declare doabilityhide global    | Set to your hide doability button
/declare usespecial global       | Use disciplines, 1 = True, 0 = False
/declare discactive global       | Flag prevents more than 1 offensive disc per fight
/declare nimblepct global        | Use nimble disc when Me.PctHps < this, 0 = off
/declare escapepct global        | Use escape ability when Me.PctHps < this, 0 = off
/declare healpausepct global     | If nimble/escape triggered, wait till Me.PctHps > this, 100+ = off
/declare attackdiscpct global    | Use duelist or deadly disc when Target.PctHps < this, 0 = off
/declare regenend global         | 1 = On (regen endurance to 100%), 0 = off
/declare regenendpct global      | Regen endurance to full when it gets low via $), 0 = off
/declare strikedisc global       | Name of your best "strike" discipline (e.g. Assassin, Kyv, Ancient), 0 = off
/declare hiderefresh global      | Based on hastened stealth aa, set between 75-105
/declare usejump global          | Adds a jump when in collision detection loop.  0 = off

| <<< Custom Vars:  Modify these according to your taste. >>>

/varset sneakhide 1            
/varset engagedistance 300    
/varset doabilityhide 1
/varset usespecial 1
/varset discactive 0
/varset nimblepct 35
/varset escapepct 20
/varset healpausepct 70
/varset attackdiscpct ${Math.Calc[@assisthealth-10]}
/varset regenend 0
/varset regenendpct 20
/varset strikedisc "Assass"
/varset hiderefresh 75
/varset usejump 1
rogue.mac

Code: Select all

|AutoRogue 2.0j 4-25-2004 
|---------------------------------------------------------------------- 
| Original AutoRogue by Jay. 
| Credits to GrimJack for the getbehind and moveto logic from GenBot. 
| 
| Usage: /macro rogue.mac Assist HpPct AnchorBit Follow 
| 
| Examples: 
|     Assist tank at 95% 
|       /macro rogue.mac Happytank 95 0    (or leave the zero off) 
| 
|     Assist tank at 95%, set anchor at current loc 
|       /macro rogue.mac Happytank 95 1 
| 
|     Same as above but moveto/follow a target between fights 
|       /macro rogue.mac Happytank 95 2 Stationarycleric 
| 
| DON'T FORGET TO VIEW/MODIFY YOUR CUSTOM.INC FILE!!! 
| 
| Version History 
|     2.0j -  Getbehind working...again...
|     2.0i -  Fixed the weird running in circles on anchor. 
|             Fixed the crazy wobble that getbehind would do in certain instances. 
|             Changed all /face nolook fast calls back to /face fast.  Wasn't a good idea. 
|             Tweaked melee distance on chase. 
|     2.0h -  Bugfixes in GetBehind and the zonechange event. 
|     2.0g -  MQParm phase 2 conversion. 
|     2.0f -  Added GM detection (script will pause when gm in zone, resume after) 
|     2.0e -  Chase range improved! 
|     2.0d -  Fixed target moveto on engage.  Set @strikedisc to 0 also available as option. 
|     2.0c -  Added delays to address crashing issue. 
|     2.0b -  Bugfixes (hopefully).  The setanchor param is changed too (read above). 
|     2.0a -  Added follow distance and replaced depreciated /sendkey's. 
|     2.0  -  Added rogue offensive and defensive discipline usage option. 
|             Lots of code fixes/optimizations.  Options in custom.inc. 
|     1.9  -  Added move to anchor and move to/follow target 
|             options between fights.  Fixed sneak/hide after fight. 
|             Other minor code cleanup. 
|     1.8  -  Cleaned up some of the code, tossed the xp stuff 
|             and fixed events, evade and getbehind. 
|     1.7  -  Base code (Jay's script) 

#turbo 40 

#Event Enraged "has become ENRAGED" 
#Event Offrage "is no longer enraged" 
#Event Slainby "You have been slain by" 
#Event Zonechange "You have entered" 

Sub Main    
    /zapvars 

    /declare assisthealth global 
    /declare countdown global 
    /declare setanchor global 
    /declare AnchorX global 
    /declare AnchorY global 
    /declare MyXLoc global 
    /declare MyYLoc global 
    /declare targetname global 
    /declare targetid global 
    /declare assistname global 
    /declare attacktarget global 
    /declare tempvar global    
    /declare followtarget global 
    /declare strikeflag global 
    
    /varset tempvar 0 
    /varset strikeflag 0 
    
    /echo "AutoRogue v. 2.0j Started." 

    /if (${Defined[Param0]}) { 
        /varset assistname @Param0             | Your assist.  
    } else { 
       /zapvars 
       /echo "Error:  The name of your assist is not optional." 
       /echo "Usage:  /macro rogue.mac AssistName <AssistHpPct> <AnchorFlag> <FollowTarget>" 
    } 
        
    /if (${Defined[Param1]}) { 
       /varset assisthealth @Param1            | Wait until mob is below this health trigger. 
    } else { 
       /varset assisthealth 90 
    } 
    
    /if (${Defined[Param2]}) { 
       /varset setanchor @Param2               | Anchor Flag: 0 = none, 1 = stationary anchor, 2 = follow target 
      /if (@setanchor==2) { 
          /if (${Defined[Param3]}) { 
             /varset followtarget @Param3    | Moveto/follow this target if setanchor=2 
         } else { 
            /varset followtarget @assistname 
         } 
      } 
   } else { 
      /varset setanchor 0 
   } 
    
    
      #include custom.inc 

    /echo "@assistname is main assist." 
    /echo "Will start combat when MA target is at @assisthealth%." 
    
    /assist off 
    /attack off 
        
    /if (@setanchor==1) { 
        /varset AnchorX ${Me.Y} 
        /varset AnchorY ${Me.X} 
        /echo "Created anchor at Loc: @AnchorX,@AnchorY." 
    } 
    
    /if (@setanchor==2) { 
        /target @followtarget 
        /if (${Target.ID}==0) /varset followtarget @assistname 
        /echo "Created MoveToTarget: @followtarget." 
    }      

    /if (@sneakhide==1) /echo "SneakHide Enabled." 
        
    /if (@usespecial==1) { 
       /call CheckRegenEnd 
        /echo "Discipline/Escape Usage Enabled." 
        /echo "Your current endurance is ${Me.Endurance}/${Me.MaxEndurance}." 
        /echo "Regen endurance percent:  @regenendpct." 
    } 
    
    /echo "Waiting for @assistname to select a new target..."
    
:Wait 
    /delay 1    

    /doevents 
    
    /call SneakHide 
    /call CheckRegenEnd 
    /call CheckAnchor 

    /assist @assistname 
    /delay 4
    
    /if (${Target.ID}==0) /goto :Wait 
    /if (${Target.Type.Equal["NPC"]}==0) /goto :Wait 
    /if (${Target.CleanName.Equal[${Me.Name}]}==1) /goto :Wait 
    
    /if (@tempvar!=${Target.PctHPs}) /echo ${Target.CleanName} targeted at ${Target.PctHPs}% at a distance of ${Target.Distance}. 
    
    /varset tempvar ${Target.PctHPs} 

    /if (${Target.PctHPs}<=@assisthealth && ${Target.Distance}<@engagedistance) /goto :Attack 

    /goto :Wait 

:Attack 
    /echo Fighting ${Target.CleanName} | ${Target.Level} ${Target.Class.Name}. 
    /varset targetname ${Target.CleanName} 
    /varset targetid ${Target.ID} 
    /varset attacktarget 1 
    
    /call CheckGM 
    /call MoveTo
    
    /face fast 

:AttackLoop 
    /delay 1 
    
    /doevents 

    /assist @assistname 
    /delay 4

    /if (${Target.ID}==0) /goto :AttackEnd 
    /if (${Target.ID}!=@targetid) /goto :AttackEnd 

    /call CheckMeleeRange
    /call GetBehind
    
    /if (@attacktarget==1) { 
        /if (@strikeflag==0) /call CheckStrikeSpecial 
        /if (${Target.Distance}<${Target.MaxRange} && ${Me.AbilityReady["Backstab"]}>0) /doability "Backstab" 

        /attack on 
        /if (${Me.Sneaking}) /doability "Sneak" 

        /if (@strikeflag==1) /call CheckAtkSpecial 
        
        /if (${Me.AbilityReady["Hide"]}>0) { 
           /attack off 
           /delay 4 
           /doability "Hide" 
        } 
    } 
    
    /if (@attacktarget==0) /Attack off 
    /if (@attacktarget==1) /Attack on 

    /call CheckDefSpecial 
       
    /doevents        

    /goto :AttackLoop 

:AttackEnd 
    /echo "Combat with @targetname has ended." 
    /keypress forward 
    /keypress back 
    /varset tempvar 0 
    /varset discactive 0 
    /varset strikeflag 0 

    /varset attacktarget 0 
    /attack off 

    /echo "Waiting for @assistname to select a new target..." 
    
    /call SneakHide 
    /call CheckRegenEnd 
    /call CheckGM 
    
    /goto :Wait 

/endmacro 

Sub CheckMeleeRange
    /face fast 
    
    /if (${Target.Distance}>${Target.MaxRange}) /keypress forward hold |If target is farther then MaxRange move forward 
    /if (${Target.Distance}<8) /keypress back hold |If target is closer then 8 move back 
    /if (${Target.Distance}<10) /keypress forward  |If target is closer then 10 stop moving forward 
    /if (${Target.Distance}>9) /keypress back |If target is farther then 9 stop moving back 

    /face fast
/return

Sub SneakHide 
    /delay 4 
    /if (@sneakhide==1) { 
:WaitForSneak 
        /if (${Me.Sneaking}==1) { 
            /goto :WaitForHide 
        } else { 
            /doability "Sneak" 
            /delay 4 
            /goto :WaitForSneak 
        } 
        
:WaitForHide 
      /delay 4 
      /if (${Me.AbilityReady["Hide"]}==1) /doability "Hide" 
    }    
/return 

Sub GetBehind 
    /varset countdown 0 
    /varset MyXLoc ${Me.X} 
    /varset MyYLoc ${Me.Y} 

    /if (${Target.ID}==0) /goto :noneed 
    /if (${Math.Distance[${Math.Calc[${Target.Y}-${Math.Cos[${Target.Heading.DegreesCCW}]}*10]},${Math.Calc[${Target.X}-${Math.Sin[${Target.Heading.DegreesCCW}]}*10]}]}<5) /goto :noneed 
    
    /keypress forward hold 

:gobehindloop 
    /delay 1 
    /call CheckGM 
    
    /if (${Target.ID}==0) { 
       /keypress forward 
       /goto :noneed 
    } 
    
    /if (@countdown>1) { 
        /if (@MyXLoc==${Me.X} && @MyYLoc==${Me.Y}) { 
              /keypress forward 
              /goto :noneed 
        } 

        /varset MyXLoc ${Me.X} 
        /varset MyYLoc ${Me.Y} 
        /varset countdown 0 
    } 
    
    /varadd countdown 1 
    /doevents 

    /face nolook fast loc ${Math.Calc[${Target.Y}-${Math.Cos[${Target.Heading.DegreesCCW}]}*10]},${Math.Calc[${Target.X}-${Math.Sin[${Target.Heading.DegreesCCW}]}*10]} 
    /if (${Math.Distance[${Math.Calc[${Target.Y}-${Math.Cos[${Target.Heading.DegreesCCW}]}*10]},${Math.Calc[${Target.X}-${Math.Sin[${Target.Heading.DegreesCCW}]}*10]}]}>3) /goto :gobehindloop 

    /keypress forward 
    /face fast 

:noneed 

/return 

Sub CheckDefSpecial 
   /if (@usespecial==1) { 
       /if (${Me.PctHPs}<@nimblepct) { 
           /if (${Me.PctHPs}<@escapepct) { 
              /echo "Escaping." 
              /attack off 
              /varset attacktarget 0 
              /delay 2 
              /alt activate 102 | escape aa 
              /call SneakHide 
              /goto :EscapedWaitHeal 
           } else { 
            /echo "Nimble." 
               /delay 2 
               /disc nimble 
               /attack off 
               /varset attacktarget 0 
               /delay 5 
               /doability "Hide" 
               /goto :NimbleWaitHeal 
           } 
      } 
   } 
    
:EscapedWaitHeal 
    /if (${Me.PctHPs}>@healpausepct) { 
        /varset attacktarget 1 
        /return 
    } 
    /delay 10 
    /goto :EscapedWaitHeal 

:NimbleWaitHeal    
    /if (${Me.PctHPs}>@healpausepct) { 
         /varset attacktarget 1 
         /return 
    } 

    /delay @hiderefresh 
    /doability "hide"          
    /goto :NimbleWaitHeal 
/return 

Sub CheckAtkSpecial 
   /call CheckRegenEnd 

   /if (@usespecial==1 && @discactive==0 && @regenend==0 && ${Target.PctHPs}<@attackdiscpct) { 
       /disc duelist 
       /delay 4 
       /disc deadly 
       /varset discactive 1 
   } 
/return 

Sub CheckStrikeSpecial 
   /varset strikeflag 1 
   /call CheckRegenEnd 
    
   /if (@regenend==0) { 
      /delay 2 
      /disc @strikedisc 
:WaitForBackstabRange 
      /delay 2 
       /if (${Target.Distance}<${Target.MaxRange}) { 
           /doability "Backstab" 
       } else { 
            /call MoveTo 
           /call GetBehind 
           /goto :WaitForBackstabRange 
       } 
    } 
/return 
        
Sub CheckRegenEnd 
   /if (@regenend==0 && ${Math.Calc[${Me.Endurance}/${Me.MaxEndurance}*100]}<@regenendpct) { 
      /varset regenend 1 
      /echo "Regen endurance to full." 
   } 
    
   /if (@regenend==1) { 
       /if (${Me.Endurance}==${Me.MaxEndurance}) { 
           /varset regenend 0 
           /echo "Endurance regenerated." 
      } 
   } 
    
/return    

Sub CheckAnchor 
   /call CheckGM 
    
    /if (@setanchor==1) /if (${Math.Distance[@AnchorX,@AnchorY]}>12) /call MoveToAnchor 
    
    /if (@setanchor==2) { 
        /target @followtarget 
        /delay 4 
        /if (${Target.Distance}>${Target.MaxRange} && ${Target.ID} && ${Target.CleanName.NotEqual[${Me.CleanName}]}) /call MoveTo 
    }      
/return 

Sub CheckGM 
:gmcheck 
   /if (${Spawn[gm].ID}>0) { 
      /echo "Waiting on GM to leave zone." 
      /delay 10 
      /goto :gmcheck 
   } 
/return 

Sub MoveTo 
    /varset countdown 0 
    /varset MyXLoc ${Me.X} 
    /varset MyYLoc ${Me.Y} 

    /if (${Target.ID}==0 || ${Target.Distance}<${Target.MaxRange}) { 
       /keypress forward 
      /return 
    } 
    
    /echo "Moving to Target: ${Target.CleanName}" 

:fastmoveloop 
    /delay 3 
   /doevents 
    
    /if (${Target.ID}==0) { 
        /keypress forward 
        /return 
    } 
    
    /face fast 

    /if (${Target.Distance}>${Target.MaxRange}) { 
        /keypress forward hold 
    } else { 
        /keypress forward 
        /return 
    } 
    
    /if (@countdown>2) { 
        /call Detectobst 
        /face fast 
        /varset countdown 0 
    } 
    
    /if (${Target.Distance}>${Math.Calc[${Target.MaxRange}*2]}) /varadd countdown 1 
    /goto :fastmoveloop 
/return 


Sub MoveToAnchor 
    /varset MyXLoc ${Me.X} 
    /varset MyYLoc ${Me.Y} 
    /varset countdown 0 

    /echo "Moving to Anchor at Loc: @AnchorX,@AnchorY." 

:AnchorMoveLoop  
    /delay 1 
    /doevents 
    /face nolook loc @AnchorX,@AnchorY 
    
    /if (${Math.Distance[@AnchorX,@AnchorY]}>12) { 
       /keypress forward hold 
   } else { 
       /keypress forward 
        /return 
    } 

    /if (@countdown>2) { 
        /call Detectobst 
        /face nolook loc @AnchorX,@AnchorY 
        /varset countdown 0 
    } 
    
    /varadd countdown 1 
    /goto :AnchorMoveLoop 
/return 

Sub Detectobst 
    /delay 2 
    /if (@MyXLoc==${Me.X}) /if (@MyYLoc==${Me.Y}) /call Hitobst 5 
    /varset MyXLoc ${Me.X} 
    /varset MyYLoc ${Me.Y} 
/return 

Sub Hitobst 
    /keypress forward 
    /keypress back hold 
    
    /if (${Math.Rand[2]}) {    
        /delay 2s    
        /keypress back 
        /keypress right hold 
        /delay @Param0 
        /keypress right 
        
        /if (@usejump==1) { 
           /keypress forward hold 
           /delay @param0 
           /keypress jump 
        } 
    } else { 
        /delay 2s 
        /keypress back 
        /keypress left hold 
        /delay @Param0 
        /keypress left 
        
        /if (@usejump==1) { 
           /keypress forward hold 
           /delay @param0 
           /keypress jump 
        } 
    } 
    /delay 10 
    /keypress forward hold 
/return 

| ----- Events called by /DoEvents ----- 

Sub Event_Enraged 
    /varset attacktarget 0 
    /attack off 
/return 

Sub Event_Offrage 
    /varset attacktarget 1 
    /attack on 
/return 

Sub Event_Zonechange 
   /keypress up 
   /endmacro 
/return 

Sub Event_Slainby 
    /keypress up 
    /endmacro 
/return 
Last edited by Cunning on Mon Apr 26, 2004 1:33 pm, edited 48 times in total.

Kracken
orc pawn
orc pawn
Posts: 24
Joined: Sat Dec 20, 2003 3:01 pm

Modified a tiny bit

Post by Kracken » Tue Mar 30, 2004 12:36 am

Took out Strike - It was useless in most real fights. As the mob rarely sits still.

The addition of the Strike Code clearly shows how the new skill sucks. I do 120ish dps and you can see to get it to work I have to delay for 10s. Hello... thats 1200hp I missed. I typically Assassins Strike for 690. Booo. However, in testing with low lvl mobs I did pull of 3 52,000 AS. I took a screen shot. After the third I though man this actually a good skill, better use it before they nerf it. Bah just a fluke because of the lvl of the mob.
Last edited by Kracken on Wed Apr 14, 2004 10:55 pm, edited 5 times in total.

Kracken
orc pawn
orc pawn
Posts: 24
Joined: Sat Dec 20, 2003 3:01 pm

Sneak Attack

Post by Kracken » Tue Mar 30, 2004 9:27 pm

Will add Sneak Attack Tomorrow 8)

AEbard
a lesser mummy
a lesser mummy
Posts: 43
Joined: Fri Jan 30, 2004 10:53 am

Post by AEbard » Wed Mar 31, 2004 9:15 am

Getting the following error. Usage : mac rogue.mac tankname 95

Code: Select all


[Wed Mar 31 09:12:57 2004] Variable name already defined: assisthealth
[Wed Mar 31 09:12:57 2004] Variable name already defined: turboamount
[Wed Mar 31 09:12:57 2004] Variable name already defined: sneakhide
[Wed Mar 31 09:12:57 2004] Variable name already defined: engagedistance
[Wed Mar 31 09:12:57 2004] Variable name already defined: countdown
[Wed Mar 31 09:12:57 2004] Variable name already defined: MyXLoc
[Wed Mar 31 09:12:57 2004] Variable name already defined: MyYLoc
[Wed Mar 31 09:12:57 2004] Variable name already defined: BaseXLoc
[Wed Mar 31 09:12:57 2004] Variable name already defined: BaseYLoc
[Wed Mar 31 09:12:57 2004] Variable name already defined: targetname
[Wed Mar 31 09:12:57 2004] Variable name already defined: targetid
[Wed Mar 31 09:12:57 2004] Variable name already defined: tankname
[Wed Mar 31 09:12:57 2004] Variable name already defined: attacktarget
[Wed Mar 31 09:12:57 2004] Variable name already defined: tempvar
[Wed Mar 31 09:12:57 2004] Variable name already defined: behindtarget
[Wed Mar 31 09:12:57 2004] Variable name already defined: targetenrage
[Wed Mar 31 09:12:57 2004] [MQ2] "Auto Rogue Version 1.08 Starting"
[Wed Mar 31 09:12:57 2004] [MQ2] "<tanks name>à0ÚÖ
[Wed Mar 31 09:12:57 2004] Couldn't find a comparision operator in '1ÜÖ'
[Wed Mar 31 09:12:57 2004] Ending macro: Failed to parse /if command
[Wed Mar 31 09:12:57 2004] rogue.mac@50 (main): /if n @sneakhide==1 {
[Wed Mar 31 09:12:57 2004] Cleared the following: Timers Arrays
[Wed Mar 31 09:12:57 2004] The current macro has ended.
[Wed Mar 31 09:12:57 2004] Usage:
[Wed Mar 31 09:12:57 2004]    /if <condition> <command>
[Wed Mar 31 09:12:57 2004]    <condition> : (<condition> && <condition>) or [n] <a>==<b>

Virtuoso65
a hill giant
a hill giant
Posts: 150
Joined: Wed Oct 15, 2003 2:29 pm

Post by Virtuoso65 » Wed Mar 31, 2004 11:46 am

Code: Select all

Sub Main 
[color=red]/zapvars[/color]
/Declare assisthealth global 
/Declare turboamount global 
/Declare sneakhide global 
/Declare engagedistance global 
/Declare countdown global
.....
 
Would clear up the var already defined spam. As for the /if parse I have no idea.

Cunning
a lesser mummy
a lesser mummy
Posts: 61
Joined: Tue Mar 23, 2004 4:42 pm

Post by Cunning » Wed Mar 31, 2004 4:39 pm

I haven't tried Kracken's version with the anchor yet. It looks like you're running his version AEbard (because the output has version 1.08 in it).

I'm working on my own update and will have it out shortly. I'm thinking about giving the user the ability to set an anchor point or a PC in group to run to when not fighting, as well as adding discipline usage as an option (based on their timers, # of npcs and their current health).

I think I have also fixed the problem where sneak/hide gets disjoined. If you run my code for a while you'll notice that eventually you'll be in sneak after a fight but not hidden.

Let me run some more tests and I'll show you what I have.

Kracken
orc pawn
orc pawn
Posts: 24
Joined: Sat Dec 20, 2003 3:01 pm

Great GetBehind

Post by Kracken » Wed Mar 31, 2004 9:45 pm

The code I edited/posted works flawlessly for me. It does include routines.mac so you may want to look at your version.

Great Job Cunning. It holds the mob better and as a result my DPS is up. I use it slightly modified for my other chars too.

thanks

AEbard
a lesser mummy
a lesser mummy
Posts: 43
Joined: Fri Jan 30, 2004 10:53 am

Post by AEbard » Thu Apr 01, 2004 10:44 am

tried 1.07 - 1.09 same error.

is it something i'm doing?

how do you start your mac I see what you type, I just type assistname and then health to assist like 95

AEbard
a lesser mummy
a lesser mummy
Posts: 43
Joined: Fri Jan 30, 2004 10:53 am

Post by AEbard » Mon Apr 05, 2004 8:53 am

bump

Space-Boy
a hill giant
a hill giant
Posts: 242
Joined: Wed Dec 04, 2002 12:53 pm
Contact:

Post by Space-Boy » Tue Apr 06, 2004 4:37 am

the go back to starting location thing isnt working for me, any idea why? =D
You have gotten better at Carpal Tunnel! (247)

Cunning
a lesser mummy
a lesser mummy
Posts: 61
Joined: Tue Mar 23, 2004 4:42 pm

New Version

Post by Cunning » Thu Apr 08, 2004 2:41 am

I posted a new version. Let me know if you have any suggestions/comments/questions/etc.

I'm planning to add smart discipline usage and auto clicky activation in the next version. Once phase 2 of the MQ data revamp hits I'll modify the code accordingly.

AEbard
a lesser mummy
a lesser mummy
Posts: 43
Joined: Fri Jan 30, 2004 10:53 am

Post by AEbard » Thu Apr 08, 2004 10:19 am

Got it to work with the latest release.

Cunning
a lesser mummy
a lesser mummy
Posts: 61
Joined: Tue Mar 23, 2004 4:42 pm

New Version 2.0

Post by Cunning » Tue Apr 13, 2004 2:42 am

Let me know if you have any questions/comments/suggestions/bugs/etc.

User avatar
grimjack
Macro Author
Macro Author
Posts: 525
Joined: Thu Nov 07, 2002 6:51 am
Contact:

Genbot.

Post by grimjack » Tue Apr 13, 2004 3:49 am

Good looking rogue script.

The only downside I see is the autobehind code can cause problems when the mob is pushed into a wall. The early versions of genbot would get stuck like this all the time. I rewrote it 2 or 3 times in the early releases of genbot to try to get it to detect it had hit a wall but I ended up moving the direct method to a command and changing the autobehind stuff for genbot to use strafe which worked much better.

I'm not sure if you have had any issues with this but you may want to look at the strafe code that genbot currently uses for autobehind.

The main subs to look at would be:

Sub Do-behind - This is where the script actualy decides to move behind or not.(not to be confused with Do-getbehind which is the direct method that I used in the early versons of genbot.)

Sub bsclock - Called by Do-behind.
Sub bscounter - Called by Do-behind.

For record (not that it really matters) the code that decides clock or counterclock is a rewrite of some code by roguish, I just smoothed it out. The acutal strafe code is original though.


The strafe code ends up calling the other range subs as well which are:
Sub Rangesub - Keeps you in range of the mob.
Sub Fastmove - Called by Rangesub.
Sub Fastback - Called by Rangesub.

And last the obstical code:
Sub Detectobst - Nearly all the movement code ends up calling this at some point.
Sub Hitobst - Called by Detectobst


Thanks
GrimJack
Ex-eq adict
When they come to me, they're in trouble, or they want some. I bust people out of prison, hunt down vampires, fight alien gods -- All the fun jobs people are too squeamish or too polite to do themselves.

Call me a mercenary. Call me an assassin. Call me a villain. I am all that and more.

My name's John Gaunt, but out on the streets of Cynosure, I am called...
GrimJack

Cunning
a lesser mummy
a lesser mummy
Posts: 61
Joined: Tue Mar 23, 2004 4:42 pm

Thanks Grimjack

Post by Cunning » Tue Apr 13, 2004 1:00 pm

I have noticed issue on walls (more noticeable in small dungeons like LDON than in open camps like HoH or PoFire Tables) and have been trying some things to fix it, but since it's been done I will look at what you suggested and incorporate it. Collision during the GetBehind call has been another issue I've noticed and I think your stuff will fix it.

Thanks.