Skip to main content

RenderLock

A static class in Root.Township, the global namespace.

Client: static set of reasons rendering is held off, such as no player controller yet or a fade to black. Starts locked until the player controller spawns.

Fields​

1 private and internal field
MemberWhat it is
private static RenderLock.RenderLockType currentLocksFlags of the lock reasons in effect.

Properties​

MemberWhat it is
static bool IsLocked { get; }True while any lock reason is set.

Events​

MemberWhat it is
static event Action<bool> OnLockedChangedFired when the lock turns on or off.

Methods​

MemberWhat it is
static void Lock(RenderLock.RenderLockType renderingLock)Adds a lock reason; fires OnLockedChanged with true if it was unlocked.
static void Unlock(RenderLock.RenderLockType renderingLock)Removes a lock reason; fires OnLockedChanged with false when none remain.