This is an old revision of the document!
⇐ Index
Available in version 1.3 and later.
GetUnitType
Description
Returns the string type of the unit. For custom units, this is the CMOD UID. For built in units, it is the string unit type (like “cannon”). In both cases, the string can be passed to CreateUnit and other APIs that take units. The list of Unit Names for built in units is as follows.
Unit Types
“tower”
“pylon”
“miner”
“greenarrefinery”
“terp”
“porter”
“cannon”
“mortar”
“sprayer”
“sniper”
“missilelauncher”
“nullifier”
“runway”
“bomberpad”
“acbomberpad”
“rocketpad”
“platform”
“shield”
“microrift”
“beacon”
“ernportal”
“factory”
“conversion”
“damper”
“rain”
“singularity”
“wall”
“crazonium”
“collectorpanel3”
“collectorpanel5”
“delegate”
“ern”
“crystal”
“greenarmother”
“infocache”
“monolith”
“pod”
“pterosaur”
“resourceblue”
“resourcered”
“totem”
“ultrac”
“stash”
“darktower”
“holdbase”
“emitter”
“sporelauncher”
“blobnest”
“skimmerfactory”
“airsaccauldron”
“spore”
“blob”
“skimmer”
“forb”
“shrapnel”
“airsac”
“egg”
“airsacbubble”
Examples
trace(GetUnitType(self))
⇐ Index