Hey, is there a way to get the coordinates for a random enemy unit? I have looked and cannot find anything for that.
There isn't a single command. This will probably do something similar...
:RandEnemy #[ - UID]
0 0 9999 GetEnemyUnitsInRange ->Count #All enemies
0 <-Count RandInt ->Selection #Pick the "selection"-th enemy
<-Count 0 do #Clear the rest of the stack
<-Selection I eq if
->Pick #Save the chosen unit UID
else
pop #Discard everything else
endif
loop
<-Pick #Return
http://knucklecracker.com/wiki/doku.php?id=crpl:docs:getenemyunitsinrange