Skip to main content

RespawnOrb

A class in Root.Township, Township.Downed.

Orb shown while a player is downed, with a circular timer that fills until they respawn. DownedState spawns it and drives the timer.

Constructors​

MemberWhat it is
RespawnOrb()Unity makes components itself; use AddComponent or spawn a prefab instead of new.

Fields​

2 private and internal fields
MemberWhat it is
private Image circularTimerUI image whose fill shows respawn progress.
private float respawnTimeTotal seconds until respawn.

Methods​

MemberWhat it is
void StartTimer(float timeToRespawn)Sets the respawn time and starts filling the circular timer.
void UpdateTimer(float increaseToRespawnTimer)Adds seconds to the respawn time; the running fill adjusts to it.
1 private and internal method
MemberWhat it is
private IEnumerator UpdateCircularTimer() (iterator)Coroutine that fills the timer image over respawnTime.

Used in​

Members of other types that take, return or hold a RespawnOrb: