Lua:getCPUCount

From Cheat Engine
Revision as of 20:52, 26 June 2026 by Leunsel (talk | contribs) (Added related function template.)
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

<> Lua API Reference

function getCPUCount() : integer

Returns the number of CPUs.

Function Parameters[edit]

This function has no parameters.

Returns[edit]

integer — The number of CPUs.

Examples[edit]

1 local cpuCount = getCPUCount()
2 
3 print("CPU count: " .. cpuCount)

Main Pages

Core Lua documentation entry points

Lua
Script Engine

Thread Related Lua Functions

CPU information, process threads, main-thread execution, and queued callbacks