Orbit StudiosOrbit Studios
Orbit Studios Resourcesorbit-dynamichud-v2Interface APIs

Skill Check

Run DynamicHUD skill checks directly or replace ox_lib skill checks without changing call sites.

Skill Check

skillCheck yields the calling Lua thread until the player succeeds, fails, cancels, or reaches the 60-second safety timeout. It returns true only when every configured step succeeds.

Single check
local success = exports['orbit-dynamichud-v2']:skillCheck('medium', { 'E', 'Q' })

if success then
    print('Skill check passed')
else
    print('Skill check failed or was cancelled')
end

Difficulty

PresetSuccess areaSpeed multiplier
easy501.0
medium401.5
hard251.75

Pass an array for sequential checks. Each successful step advances to the next:

Sequence
local success = exports['orbit-dynamichud-v2']:skillCheck({
    'easy',
    'medium',
    { areaSize = 30, speedMultiplier = 1.9 }
}, { 'E', 'Q', 'SPACE' })

areaSize is clamped from 1 to 360. speedMultiplier has a minimum of 0.1. Inputs are normalized to uppercase; SPACEBAR becomes SPACE, ESCAPE becomes ESC, and no input table defaults to E.

Only one skill check can run at once. A second call returns false immediately.

State and cancellation
if exports['orbit-dynamichud-v2']:skillCheckActive() then
    exports['orbit-dynamichud-v2']:cancelSkillCheck()
end

ox_lib drop-in replacement

client/orbit_skillcheck.lua
lib = lib or {}

lib.skillCheck = function(difficulty, inputs)
    return exports['orbit-dynamichud-v2']:skillCheck(difficulty, inputs)
end

lib.skillCheckActive = function()
    return exports['orbit-dynamichud-v2']:skillCheckActive()
end

lib.cancelSkillCheck = function()
    return exports['orbit-dynamichud-v2']:cancelSkillCheck()
end

The difficulty, input, active-state, cancellation, and boolean return contracts match the ox_lib calls, so existing gameplay branches remain unchanged.

The local client event orbit-dynamichud:skillCheckOver fires when NUI submits a result. Normal gameplay code should use the blocking return value.

On this page