I am developing a spell that is intended to temporarily remove a unit from the game. That is, after casting the spell on a target, the target cannot perform any actions and cannot be observed by any player for a specified duration. Additional specifications include the target being unavailable for any other spell interactions until the duration passes and the unit is restored.
Using "ShowUnit(u, true/false)" is not sufficient as the unit u can still perform autoattacks and move around.
Using "DisableUnitTimed(u, real)" from Risking_DUsk's UnitStatus is problematic in that it will not work on a unit that is hidden via "ShowUnit(u, false)".
The brute force solution I have for this is to use "DisableUnitTimed(u, real)" and then use "ShowUnit(u, false)" after the passage of a small unit of time (ex. 1/16th of a second). This is not desirable.
A more elegant solution is desired. Does anyone have any ideas?
Using "ShowUnit(u, true/false)" is not sufficient as the unit u can still perform autoattacks and move around.
Using "DisableUnitTimed(u, real)" from Risking_DUsk's UnitStatus is problematic in that it will not work on a unit that is hidden via "ShowUnit(u, false)".
The brute force solution I have for this is to use "DisableUnitTimed(u, real)" and then use "ShowUnit(u, false)" after the passage of a small unit of time (ex. 1/16th of a second). This is not desirable.
A more elegant solution is desired. Does anyone have any ideas?