Risk


Class Risks Config (class_risks.lua)

This configuration defines risk factors and security measures associated with each vehicle class. These include locked doors, digiscanner chances, and guards with their properties.


Example Config

Config.ClassRisks = {
    ["d"] = { ... },
    ["c"] = { ... },
    ["b"] = { ... },
    ["a"] = { ... },
    ["s"] = { ... }
}

Each class (d, c, b, a, s) can have different risk profiles to adjust gameplay difficulty.


Risk Parameters

1. Doors & Digiscanner

Parameter
Description

doorsLocked

Chance (%) that the vehicle doors are locked when spawned.

digiscanner

Chance (%) that the player can use a digiscanner to locate keys or hack doors.

Example:

doorsLocked = 100,  -- 100% doors locked
digiscanner = 40    -- 40% chance to find keys/hack doors

2. Guards

Parameter
Description

guards

Chance (%) that guards are present.

guardsProperties

Defines properties of the guards if spawned.

Example for guards:

guardsProperties = {
    count = {5, 6},  -- minimum and maximum number of guards
    armour = {50, 60}, -- armor range
    accuracy  = {60, 70}, -- shooting accuracy
    weapons = { `weapon_bat`, `weapon_crowbar`, `weapon_golfclub`, `weapon_poolcue` } -- possible weapons
}
  • count – number of guards that may spawn.

  • armour – guard armor percentage range.

  • accuracy – guard shooting accuracy percentage.

  • weapons – list of weapon hashes guards can carry.


Notes

  • Adjust doorsLocked and digiscanner values to balance challenge per class.

  • Higher-tier classes can have stronger guards or more advanced weaponry.

  • This config works alongside Vehicle Classes, Missions, and Minigames to create dynamic and risky contracts.

  • Guards spawn randomly within defined properties, providing variety in every contract.

Last updated