SkillCheck

License: LGPL-3.0 (GNU Lesser General Public License v3.0)

This resource is based on ox_lib which is licensed under LGPL-3.0.

⚠️ This redesign is a paid product. Only verified purchasers are eligible for support and updates. Unverified users will not receive any assistance under any circumstances.


Overview

3 skillcheck designs available via the ox:skillcheck convar. Additionally, you can force a specific design per-script using lib.skillCheck0(), lib.skillCheck1(), or lib.skillCheck2().

# config.cfg
set ox:skillcheck 0

Designs

Value Name Description
0 Default Bar Horizontal bar with moving indicator
1 Dead by Daylight Rotating clock-style indicator with hit zones
2 Rhythm Game Falling arrows (←↓↑→) with timing-based hits

Design 0 — Default Bar

SkillCheck 0

Design 1 — Dead by Daylight

SkillCheck 1

Design 2 — Rhythm Game

SkillCheck 2


Standard Usage

Uses the design set by ox:skillcheck convar:

-- Single difficulty
local success = lib.skillCheck({'easy', 'easy', 'medium'})

-- Custom difficulty
local success = lib.skillCheck({
    { areaSize = 50, speedMultiplier = 1 },
    { areaSize = 40, speedMultiplier = 1.5 },
    { areaSize = 25, speedMultiplier = 2 }
})

-- With custom key inputs
local success = lib.skillCheck({'easy', 'medium', 'hard'}, {'w', 'a', 's', 'd'})

Forced Design Functions

These functions ignore the convar and force a specific design:

lib.skillCheck0() — Default Bar

local success = lib.skillCheck0({'easy', 'medium', 'hard'})

lib.skillCheck1() — Dead by Daylight

local success = lib.skillCheck1({'easy', 'medium', 'hard'})

lib.skillCheck2() — Rhythm Game

local success = lib.skillCheck2({'easy', 'medium', 'hard'})

All three functions accept the same parameters as lib.skillCheck().


Parameters

Parameter Type Description
difficulty string or table or table[] Difficulty preset(s) or custom config
inputs string[]? Custom key inputs (optional)

Difficulty Presets

Preset Area Size Speed Multiplier
'easy' 50 1
'medium' 40 1.5
'hard' 25 1.75

Custom Difficulty

{ areaSize = 50, speedMultiplier = 1.0 }
Field Type Description
areaSize number Size of the hit zone (1-100)
speedMultiplier number Speed of the moving indicator

Return Value

Type Description
boolean? true if all rounds passed, false if failed, nil if cancelled

Utility Functions

lib.cancelSkillCheck()

Cancels an active skillcheck.

lib.cancelSkillCheck()

lib.skillCheckActive()

Returns whether a skillcheck is currently active.

local isActive = lib.skillCheckActive() -- boolean

Examples

Lockpicking with DBD style

-- Always use Dead by Daylight style for lockpicking
local success = lib.skillCheck1({
    { areaSize = 30, speedMultiplier = 1.5 },
    { areaSize = 25, speedMultiplier = 2.0 },
})

if success then
    -- lockpick succeeded
else
    -- lockpick failed
end

Drug Crafting with Rhythm Game

-- Use rhythm game style for drug crafting minigame
local success = lib.skillCheck2({'easy', 'easy', 'medium', 'hard'})

if success then
    -- crafting succeeded
end

Default convar-based

-- Uses whatever design is set in config.cfg
local success = lib.skillCheck({'medium', 'medium', 'hard'})

Last updated: 2026-02-18

Last updated 1 month ago