Yuari
Documentation
Docs/Miscellaneous/setthreadidentity

setthreadidentity

Sets the current thread identity.

Syntax

setthreadidentity(identity: number) -> nil

Parameters

ParameterTypeDescription
identitynumberThe identity value used by the call.

Returns

TypeDescription
nilThis function does not return a value.

Description

setthreadidentity is part of the Miscellaneous library. Miscellaneous helpers cover module identity, scheduler settings, teleport queueing and other process-level utilities.

The change is applied directly to the live target, so later reads observe the updated value.

The aliases setidentity(identity), setthreadcontext(identity), set_thread_identity(identity) resolve to the same implementation.

Example

setthreadidentity(8)
print(getthreadidentity())

Notes

  • Aliases: setidentity(identity), setthreadcontext(identity), set_thread_identity(identity).
  • Some settings affect the module globally rather than the current script.