GetActorPowerupTics
Jump to navigation
Jump to search
int GetActorPowerupTics (int tid, str powerup)
Usage
Retrieves the remaining duration in tics of the specified active powerup for the actor with the matching TID. If tid is 0, the function is run on the activator of the script.
Parameters
- tid: The TID of the actor to perform the check on.
- powerup: The class name of the powerup to get its remaining duration.
Return value
The function returns the number of tics remaining until the powerup's effect wears off. If the specified powerup class does not exist or it does not inherit from Powerup, the return value is 0. The function also returns 0 if there are no actors with a matching TID or the powerup does not currently exist in the actor's inventory, i.e. it is not currently active.
Examples
![]() |
Note: This article lists no examples. If you make use of this feature in your own project(s) or know of any basic examples that could be shared, please add them. This will make it easier to understand for future authors seeking assistance. Your contributions are greatly appreciated. |