- Joined
- Feb 28, 2013
- Messages
- 1,897
Do hidden units decay? Also do they they also get removed in the game when they finished decaying?
IsUnitHidden
function.IsUnitHidden
function.UnitAddAbility() or GetUnitAbilityLevel()
functions.GroupEnumUnitsOfPlayer
function.locusts can be attacked (when ordered with triggers) by units that have "invulnerable" in allowed targets. it won't do damage, though.- You can't order unit to target hidden or locust unit.
It's fine, you shouldn't be afraid from it.So what I had to do to fix this is to hide the unit instead of removing it instantly although I fear than maybe hiding the dying unit may not get removed in the game when the dead unit finished decaying which can cause some lag.
you can get any units using GroupEnumUnitsInRect / OfPlayer which dont care about unit being hidden/locust/dead
GroupEnumUnitsInRect
doesn't enumerate them. How come you considered it?You shouldn't be confused, locust and hidden units are rendered to be 'untargetable'.locusts can be attacked (when ordered with triggers) by units that have "invulnerable" in allowed targets. it won't do damage, though.
EVENT_UNIT_ISSUED_TARGET_ORDER
or EVENT_PLAYER_UNIT_ISSUED_TARGET_ORDER