Ok so I have this snipper here, and when it loops, the charghost part loops nonstop right. It wont EVER stop looping unless you die. Then the enemy id part loops when an enemy attacks you. What I need it to do, is if you find an enemy BEFORE one attacks, it will honor it, and attack it, and wont stop until THAT monster is dead. But if you get attacked I want it to go into that second while, and since it didn't find a monster to attack, I want it to try to honor the monster that attacked you but wasn't in the monster type list, because it most likely didn't find it in it's monster type list and not stop till THAT monster is dead. And I need it to be reliable... I also want both to set !EOO to #sysTime if the TYPE of the last monster doesn't match the type of the new monster found but I've been having nothing but problems with everything I've tried. Basically I want it to search for monsters, if found, honor, if not, but attacked, honor that one. Any good ways to do this reliably?
repeat
while #charghost <> yes
{
gosub findenemy
if #findtype <> !lasttype
SET !eootimer #scnt
while #enemyid <> n/a
{
if !attackedbeforemonsterfound = #true
honor #enemyid
kill till dead
else
kill till dead
{MAIN PART OF SCRIPT}
}
}
return