User Tools

Site Tools


crpl:docs:getenemyunitsinrange

This is an old revision of the document!


~~DISCUSSION~~ <- CRPL reference <- Unit Commands

GetEnemyUnitsInRange

ArgumentsResultNotation
Coordinates and rangeNumber of enemy units in range and their UID'si1 i2 f1 – [l1 l2…]i3

Description

Returns a list of unit UID's. Returns all enemy units in range (emitters, spore towers, cores). A list is returned. A list consists of some number of unit uids, with the number of items in the list being the item on the top of the stack.

Examples

:GetEmitterCount
0 ->count
do (GetEnemyUnitsInRange(0 0 9999) 0)
	->unitUID
	if (GetUnitType(<-unitUID) eq "EMITTER" )
		<-count add(1) ->count
	endif
loop
<-count
crpl/docs/getenemyunitsinrange.1412190170.txt.gz · Last modified: 2015/01/11 15:45 (external edit)