First of all with this script, it references a variable %BossIDID which is never set. That means that much of it's attack code is against an enemy N/A. It exists in the original and in the ReBirthUO version. I have not tried running this script myself, just read the code. I am guessing that lots of logic in the script just gets run idle because of that typo. If it works otherwise, then it is because it falls through.
I notice that is does a finditem on %Spawn, but never bothers to attack any of it. What happens with the auxiliary spawn once the boss is dead? Do these just disappear? It looks like the script runs off to the next section to fight there. Someone who has actually spent time hunting in the Gauntlet would have to answer that one. I haven't been there in 7+ years - so I just can't remember.
Anyway, on to your questions...
Reveal has a target that needs to be executed.
Holy Light does not.
Holy light has a range of 3-4 tiles around you. This code was only getting within 5 tiles at best of your enemy.
Move returns and you keep your script going while you walk - I believe, so you need a way to wait till you are close enough before casting Holy Light. That is what the repeat/until block does. It may need a timeout to escape if something goes wrong (like you can't actually get to that spot).
I got rid of some code that really isn't needed or referenced elsewhere in the original posting and RebirthUO versions of the script (%RevealTimer, %SKX1, %SKY1, %SKX2 & %SKY2).
;===========================================================
;@Purpose : Revealing the Dark Knight
;===========================================================
Sub RevealKnight
If #FindCnt = 0
FindItem XC G_18 ; I thought 18 was the limit on a reliable finditem range
If #FindCnt > 0
{
for #Findindex 1 #findcnt
{
Move #findx #findy 2 ; Change to get within 2 tiles of enemy
set %MoveTimeout #scnt + 5 ; allowing 5 secs before giving up on the waits
repeat
wait 1
until abs ( #charposx - #findx ) <= 3 && abs ( #charposy - #findy ) <= 3 && %MoveTimeout >= #scnt
event macro 15 207
}
}
Return
Similar code would be used to replace the "Reveal" version, just keeping the target code after the "event macro 15 47" in the original sub.
That "repeat ... until" has an exit condition timer in case you can't get to the desired location. I think if you have exceeded that timer, you should pass on casting Holy Light and let it cast on the next pass - so you save the mana. I did not code it that way, but maybe you will cast Holy Light on other stuff near to you.
the main problem is that the wizard casts Reveal from a distance on the mob, while the tank casts Holy but on the spot and does not reveal it, I need to bring him closer and then cast Holy.
I think the above should come closer in line with getting the tank to get close enough when casting Holy Light once at 2 tiles away.
Would that work for your situation?
Gaderian