Code: Select all
#define KSRadius v51
sub main
| Setup Alerts for the most important mobs here (rare)
|
/alert clear 1
/alert add 1 npc cyclops
| Setup Alerts for the next most important mobs here (uncommon)
|
/alert clear 2
/alert add 2 npc giant
/alert add 2 npc dry
/alert add 2 npc ronin
/alert add 2 npc scrounge
| Setup Alerts for the next most important mobs here (common)
|
/alert clear 3
/alert add 3 npc asp
/alert add 3 npc coyote
/alert add 3 npc mummy
/alert add 3 npc Snake
/alert add 3 npc madman
/alert add 3 npc tarantula
/alert add 3 npc ghoul
/alert add 3 npc rattlesnake
/alert add 3 npc jackal
/alert add 3 npc puma
/alert add 3 npc scarab
/alert add 3 npc zombie
/alert add 3 npc asp
/alert add 3 npc orc
/alert add 3 npc skeleton
| Setup Alerts for Scary mobs here
|
/alert clear 4
/alert add 4 npc terrorantula
/varset KSRadius 60
/call GetTarget
/return
sub GetTarget
:Acquire
/if "$alert(1)"=="TRUE" {
/target npc alert 1 noalert 4 nopcnear $KSRadius
} else /if "alert(2)"=="TRUE" {
/target npc alert 2 noalert 4 nopcnear $KSRadius
} else {
/target npc alert 3 noalert 4 nopcnear $KSRadius }
/varset MyTarget $target(id)
/doevents
/echo $target(id)
/if n $target(id)==0 /goto :Acquire
/return
But it just doesnt seem to work properly. If you run the script and there are no mobs that match alert 1 or alert 2 then it should target a mob that matches alert 3 but it doesnt, it just targets nothing and says There are no ')' around here ???
What am i doing wrong ?
Fippy.



