Sure --
I suppose it would help if I just post everything as I've added it to genbot as god only knows if I'm even able to do all this ...
First in "Sub SetupPersonalVars" from genbot I've added a statement --
/call amcheckrogue
to create a set of variables defined only for rogues --
Code: Select all
Sub Amcheckrogue
/if "$char(class)"=="Rogue" {
/call ChatOut 5 @MasterName " Rogue $char(name) is at your service"
#include botrogue.inc
}
/return
(could using the #include cause problems perhaps? I've tried it both with and without this process with exactly the same result. Also, the other sub's built this way are working fine so I assumed it wasn't the code, but then I am a newb =)
In botrogue.inc I have added
Code: Select all
/declare amisrogue global
/varset amisrogue 1
/declare discactive global
/declare nimblepct global
/declare escapepct global
/declare strikedisc global
/declare sneakhide global
/declare refreshsneakhide global
/declare regenendpct global
/declare maxendurance global
/varset discactive 0 | Flag prevents more than 1 offensive disc per fight
/varset nimblepct 45 | Use nimble disc when $char(hp,pct) <= this, 0 = off
/varset escapepct 30 | Use escape ability when $char(hp,pct) <= this, 0 = off
/varset strikedisc "Assassin" | Name of your best "strike" discipline (e.g. Assassin, Kyv, Ancient)
/varset sneakhide 1 | Sneak Hide between kills; 1 = Yes, 0 = No
/varset refreshsneakhide 1 | Used to flag whether or not sneak hide is ready for use 0 = is hidden, 1 = is not hidden
/varset regenendpct 20 | Regen endurance to full when it gets low via $), 0 = off
/varset maxendurance 2560 | Stores max endurance (use $char(endurance,cur) when your bar is full for value)
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|
||----------- Timers ------------------
/declare PickpocketTimer timer
/declare DeadlyTimer timer
/declare DuelistTimer timer
/varset PickpocketTimer 0
/varset DeadlyTimer 0
/varset DuelistTimer 0
|||----------- End Timers -------------
|
|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
In the main loop of personal.inc I added
/call MyAdditions
so here's all my additions (just seems simpler to sum all of my additions this way instead of adding all of the calls to the main loop but perhaps I shouldn't do that? )
Code: Select all
Sub MyAdditions
/if "$char(invited)"==1 {
/call delay 2s
/keypress invite_follow
}
/if n @amisrogue==1 {
||||----- When in Combat ---------------
/if "$combat"=="TRUE" {
/call CheckAtkSpecial
/call CheckDefSpecial
/call Amfavpickpocket
} else {
||||----- When Not in Combat -----------
/call sneakhide
}
} |--- just realized this was missing but still not working with it in ... same error
/return
The other sub's being called (in case they are causing the conflict in some way)
Code: Select all
Sub SneakHide
/if n @sneakhide==1 {
/if n @refreshsneakhide==1 {
/if "$char(casting)"!="TRUE" {
/if "$corpse()"!="TRUE" {
/if "$banker(open)"!="TRUE" {
/if "$merchant(open)"!="TRUE" {
/if n $char(ability,"Sneak")>0 /doability "Sneak"
/call delay 1s
/if n $char(ability,"Hide")>0 /doability "Hide"
}
}
}
}
}
}
/return
Sub CheckAtkSpecial
/if n @discactive==0 {
/if n $calc($char(endurance,cur)/@maxendurance*100)>=@regenendpct) {
/if n $target(hp,pct)>=65 {
/if @DeadlyTimer==0 {
/disc deadly
/varset DeadlyTimer 5m
} else {
/if @DuelistTimer==0 {
/disc duelist
/varset DuelistTimer 22m
}
}
}
/if n $char(endurance,cur)>@maxendurance {
/varset maxendurance $char(endurance,cur)
}
}
/return
Sub CheckDefSpecial
/if n $char(hp,pct)<=@nimblepct {
/if n $char(hp,pct)<=@escapepct {
/attack off
/alt activate 102
/call SneakHide
} else {
/disc nimble
/attack off
/delay 5
/doability "Hide"
}
}
/return
Boy this didn't format very well, guess it's the tabs. I also have a few events triggered to set variables (yeah, maybe its a cheap hack way of doing it but I wanted to learn events and am still waiting for the new parm to try and learn that method before I try to get too deep into this system =)
Code: Select all
Sub Event_Amcamping
/endmacro
/return
Sub Event_Amishidden
/varset refreshsneakhide 0
/return
Sub Event_Amisnothidden
/varset refreshsneakhide 1
/return
Sub Event_Amresethidden
/varset refreshsneakhide 1
/return
Sub Event_Stopsneaking
/varset refreshsneakhide 1
/return
Edit -- forgot the values set for each event ---
Code: Select all
#Event Amcamping "It will take about 10 more seconds to prepare your camp"
#Event Amisnothidden "You have moved and are no longer hidden"
#Event Amishidden "You have hidden yourself from view"
#Event Amresethidden "LOADING, PLEASE WAIT"
#Event Stopsneaking "You stop sneaking"
I realize I simplified a lot of the changes I've made at the beginning of this post so really appreciate your even asking for more info. I have been troubleshooting this by commenting out code, removing all subs and slowly bringing them back in, etc... and again, this wasn't a problem before 4-15 so either I've changed something since then or there's something in EQ / MQ.
The only thing that seems to cause me problems is when I leave the
/doability "Pick Pockets"
instead of commenting it out. I'm wracking my brain here as to what it could be but am completely out of my league. Perhaps an issue with "Sneakhide" being both a variable and a sub? In writing this I realize I always brought that sub in first so perhaps there's a conflict ... hopefully it's a simple mistake on my part.
enough speculation for me ...and again, thanks for any input you can provide.