get_process_identifier

Returns the operating-system process identifier for the current game process.

Syntax

get_process_identifier() -> number

Returns

TypeDescription
numberCurrent process ID

Example

local processId = get_process_identifier()
print("Game process ID:", processId)
print(processId > 0) -- true

Notes

  • The identifier is assigned by the operating system
  • It can differ the next time the game starts