2041
Scripting Chat / Re: Targeting Issues
« on: March 14, 2015, 05:04:58 PM »
Ok I added a very basic pathfind to corpse but the whole thing is very rough. I know I should have seperate subs for health monitor, attack, and pathfind to body but I am working on just getting them working before trying to make them all seperate and then to work together lol. I think I am in over my head but it is fun. Thanks Ghost for all the help so far!
How do I get the pathfind to stop after it goes to the corpse the first time? I believe that if #findkind = -1 means that it will stay there until the corpse decays but not sure how else to do it.
Code: [Select]
finditem QHB_PHB G_9
if #findcnt > 0
{
set #ltargetkind 1
set #ltargetid #findid
event macro 15 41
target 3s
event macro 22
wait 2s
}
if #HITS < ( #MAXHITS - 30 )
{
set #lobjectid
event macro 15 28
wait 20
target
event macro 23 0
wait 20
}
finditem YFM G_9
if findcnt > 0
{
event pathfind #findx #findy #charposz
wait 4s
until #charposx = #findx && #charposy = #findy
wait 2s
if #findkind = -1
{
return
How do I get the pathfind to stop after it goes to the corpse the first time? I believe that if #findkind = -1 means that it will stay there until the corpse decays but not sure how else to do it.