RM-ScriptsRM-SCRIPTS
House Robbery

Configuration

Full configuration reference for rm-houserobbery.

Configuration

config/config.lua

Config = Config or {}
Loc   = Loc   or {}

Config = {
    Lan       = 'en',          -- matches locales/*.lua key
    debug     = false,
    Framework = 'qbox',        -- qbox | qb | qb-core | esx
    Inventory = 'ox_inventory',
    Dispatch  = 'cd_dispatch', -- ps-dispatch | cd_dispatch | false
    DispatchJobs  = { 'police', 'sheriff' },
    Notification  = 'ox_lib',
    Progressbar   = 'ox_lib',
    Target        = 'ox_target',
    TestingMode   = false,

    -- Robbery time window (in-game hours)
    startHours = 22,
    endHours   = 5,

    MinimumPolice       = 0,
    notEnoughCopsNotify = true,
    PoliceJobs = {
        ['police']  = true,
        ['sheriff'] = true,
    },

    -- Required tool per tier (ox_inventory item name)
    requiredHackingDeviceByLevel = {
        [1] = 'lockpick',
        [2] = 'houselaptop',
        [3] = 'mansionlaptop',
    },

    hackingDeviceDurabilityRemoveByItem = {
        lockpick        = 0.10,
        advancedlockpick = 0.10,
        houselaptop     = 0.25,
        mansionlaptop   = 0.34,
    },

    fingerprintChance                 = 50,
    lockpickDifficulty                = 'insane', -- normal | hard | insane
    allowDoorHackAutoSuccessFallback  = true,

    -- Noise system
    noiseEnabled   = true,
    noiseTickMs    = 1000,
    noiseMax       = 100,
    noiseUiEnabled = true,

    -- Sleeper NPC
    sleeperNpcEnabled = true,
    sleeperNpcModelsByTier = {
        [1] = 'a_m_m_fatlatin_01',
        [2] = 'cs_jimmydisanto',
        [3] = 'ig_paper',
    },
    sleeperNpcWeaponsByTier = {
        [1] = { 'weapon_pistol', 'weapon_knife', 'weapon_bat' },
        [2] = { 'weapon_knife',  'weapon_pistol', 'weapon_pumpshotgun' },
        [3] = { 'weapon_pistol', 'weapon_pumpshotgun', 'weapon_assaultrifle' },
    },

    -- Target zone proximity loading
    TargetProximity = {
        entranceLoadDistance   = 100.0,
        entranceUnloadDistance = 115.0,
        pollIntervalMs         = 500,
        idlePollMs             = 2500,
    },

    -- Exit stabilization (prevents falling through floor on bucket swap)
    exitHouseStabilize    = true,
    exitHouseSpawnZOffset = 0.12,
    exitHouseFreezeMs     = 500,

    SuccessfulLockpickPoliceChance = 20, -- % chance to alert police on success
    FailedLockpickPoliceChance     = 50, -- % chance to alert police on failure
    HouseThiefCompletionXp         = 5,

    -- House Thief XP system
    HouseThiefXp = {
        enabled           = true,
        autoCreateTable   = true,   -- false = run install/house_thief_xp.sql manually
        baseXpPerLevelStep = 100,
        levelCommand      = 'housethieflevel',
        levelCommandEnabled = true,
    },

    -- How many different items drop from one loot spot per tier
    RewardItemCountByLevel = {
        [1] = { min = 1, max = 3 },
        [2] = { min = 2, max = 4 },
        [3] = { min = 2, max = 5 },
    },

    -- Loot pools (add matching ox_inventory items from install/ox_items.txt)
    LootItems = {
        [1] = {
            { item = 'goldcoin',        min = 1, max = 2, chance = 48 },
            { item = 'diamond',         min = 1, max = 1, chance = 14 },
            { item = 'px_gameboy',      min = 1, max = 1, chance = 22 },
            { item = 'cigars_homies',   min = 1, max = 1, chance = 24 },
            { item = 'stolencomputer',  min = 1, max = 1, chance = 18 },
            { item = 'rolex',           min = 1, max = 1, chance = 7  },
            { item = 'ancient_artifact',min = 1, max = 1, chance = 3  },
        },
        [2] = {
            { item = 'goldcoin',        min = 1, max = 3, chance = 40 },
            { item = 'diamond',         min = 1, max = 2, chance = 20 },
            { item = 'px_gameboy',      min = 1, max = 1, chance = 28 },
            { item = 'cigars_homies',   min = 1, max = 1, chance = 30 },
            { item = 'stolencomputer',  min = 1, max = 1, chance = 26 },
            { item = 'rolex',           min = 1, max = 1, chance = 14 },
            { item = 'ancient_artifact',min = 1, max = 1, chance = 7  },
        },
        [3] = {
            { item = 'goldcoin',        min = 1, max = 4, chance = 32 },
            { item = 'diamond',         min = 1, max = 3, chance = 26 },
            { item = 'px_gameboy',      min = 1, max = 1, chance = 34 },
            { item = 'cigars_homies',   min = 1, max = 1, chance = 36 },
            { item = 'stolencomputer',  min = 1, max = 1, chance = 32 },
            { item = 'rolex',           min = 1, max = 1, chance = 22 },
            { item = 'ancient_artifact',min = 1, max = 1, chance = 12 },
        },
    },

    -- Which interiors belong to which tier
    houseTierInteriors = {
        [1] = {1, 10},   -- small houses
        [2] = {2},        -- mid tier
        [3] = {'rest'},   -- all remaining interiors = mansion tier
    },
}

Key options

KeyTypeDescription
Frameworkstring'qbox' | 'qb' | 'qb-core' | 'esx'
Targetstring'ox_target' or 'qb-target'
Dispatchstring/false'cd_dispatch' | 'ps-dispatch' | false
startHours / endHoursnumberIn-game hour window when robberies are active
MinimumPolicenumberMin online officers required to start a robbery
lockpickDifficultystring'normal' | 'hard' | 'insane'
noiseEnabledbooleanEnable/disable the noise buildup system
sleeperNpcEnabledbooleanSpawn a guard NPC inside the interior
exitHouseStabilizebooleanPrevent ped falling through floor on exit
autoCreateTablebooleanAuto-create House Thief XP table on start

Loot pool fields

KeyTypeDescription
itemstringox_inventory item name
min / maxnumberStack size range
chancenumberRoll chance (0–100)

House tier mapping (houseTierInteriors)

Maps tier number to interior IDs from the interiors table. Use 'rest' to assign all unassigned interiors to that tier (typically tier 3 / mansion).


config/houselocations.lua

Defines houseEntranceCoords (the exterior front-door targets) and the houses table (which interior each address maps to). Merged into Config automatically at load — edit this file to add, remove, or reposition robbery locations without touching config.lua.


House Thief XP

When Config.HouseThiefXp.enabled = true players earn XP on successful robberies. The level command (default /housethieflevel) lets players check their rank. Set autoCreateTable = false and run install/house_thief_xp.sql manually if your DB user lacks CREATE privileges.