Miscellaneous

getfpscap

Returns the current FPS cap value represented by Roblox, or 0 when the value cannot be read.

Syntax

getfpscap(): number
Aliases get_fps_cap

Returns

NameTypeDescription
fpsCapnumberCurrent FPS cap value, or 0 when unavailable.

Description

Returns the current FPS cap value represented by Roblox, or 0 when the value cannot be read.

Call it without parameters. The function reads the needed context from the current runtime state.

It returns fpsCap (number). Use the returns table to separate successful values from nil results and recoverable errors.

Example

Read the FPS cap value currently represented by the TaskScheduler cap field.

local fpsCap = getfpscap()
print(fpsCap)