-- A house's security: the intercom at its front door, an alarm system its owner can fit, and breaking in. The phone a
-- household is alerted on and the dispatch the police are called through are whichever the server runs - each is
-- one file of bridge/server (phone.lua, dispatch.lua), the ten most-run of each supported (heartbeat.re, 2026-10).
return {
    -- The phone household members are told on: the doorbell, the alarm going off. 'auto' uses the first of these that is
    -- started: 'lb-phone', 'qb-phone', 'sd-phone', 'npwd', 'qs-smartphone-pro', 'qs-smartphone', 'gcphone', 'gksphone',
    -- 'yseries', 'roadphone', 'codem-phone'. Name one to use it, false for none (a plain notification instead).
    Phone = 'auto',
    -- The dispatch the police are called through when an alarm goes off. 'auto' uses the first of these that is started:
    -- 'ps-dispatch', 'cd_dispatch', 'lb-tablet', 'origen_police', 'tk_dispatch', 'rcore_dispatch', 'fd_dispatch',
    -- 'mt_dispatch', 'qs-dispatch', 'redutzu-mdt', 'sd-phone' (its MDT). Name one to use it, false for none.
    Dispatch = 'auto',
    -- The police: jobs counted as police on duty (burglary needs MinPolice of them), and the jobs a dispatch call goes
    -- to. Job name -> lowest grade that counts.
    Police = { police = 0, sheriff = 0, bcso = 0, sasp = 0 },
    DispatchJobs = { 'police', 'sheriff', 'leo' }, -- (ps-dispatch reads job types: 'leo' is every police job there)

    -- The intercom: someone rings, and the household answers from the home panel - the front door's camera on its
    -- screen when there is one - and talks to whoever is at the door (pma-voice), lets them in, or hangs up. Nobody
    -- answering, the visitor can leave a message on the panel.
    Intercom = {
        Enabled = true,
        Window = 90, -- seconds a ring can be answered in
        Reach = 6.0, -- metres from the door the visitor stays on the line within (further off, the call ends)
        Talk = 300, -- seconds an intercom call lasts at most
        Voice = 'auto', -- 'auto' (pma-voice when it is started), 'pma-voice', false (picture and letting in, no voice)
        Channel = 870000, -- voice call channels from here up (one per house: this + its id), clear of the phones'
        Messages = true, -- a visitor nobody answered can leave a message on the panel (config.Panel.Home.NoteLength)
    },

    -- The alarm: fitted from the home panel by the owner (a keypad on the wall inside, placed by hand), armed and
    -- disarmed from the panel by the household, or at the keypad by anyone with its PIN. Armed, a lock picked or forced
    -- sets it off - and, armed away, so does anyone without a key inside: the siren sounds, the household's phones are
    -- told, and unless it is disarmed within DispatchDelay the police are called.
    Alarm = {
        Enabled = true,
        Price = 6500, -- paid from Properties.Account
        ExitDelay = 30, -- seconds to leave after arming it before it is armed
        Siren = 150, -- seconds the siren sounds once it goes off (it stops when the alarm is disarmed)
        DispatchDelay = 20, -- seconds after it goes off before the police are called (disarmed by then: they are not)
        KeyDisarms = true, -- a household member unlocking a door (with their key, or from the panel) disarms it
        PinLength = { 4, 6 }, -- digits a PIN has, at least and at most
        WrongPins = 3, -- wrong PINs in a row at the keypad set it off
        AutoArm = 90, -- with auto-arm on, seconds after the house is left empty with every door locked that it arms itself
        Motion = 2.0, -- seconds between looks for someone without a key inside an armed-away house
    },

    -- Breaking into a house that is someone else's: picking a locked door (ox_lib's skill check) and breaking its stash
    -- open. Never a house for sale, never one's own.
    Burglary = {
        Enabled = true,
        MinPolice = 0, -- police on duty needed (Security.Police) before a lock can be picked
        OwnerOnline = false, -- true: only while its owner or one of its keyholders is on the server
        Cooldown = 1800, -- seconds after a house is broken into before it can be again
        -- What picks a lock, and how hard each finds it: the skill check's rounds (ox_lib difficulties). A door that was
        -- reinforced takes `Reinforced`'s instead, and only the items it names.
        Picks = {
            lockpick = { 'easy', 'easy', 'medium', 'medium' },
            advancedlockpick = { 'easy', 'medium', 'medium' },
        },
        Break = 0.35, -- chance a pick breaks when it fails
        Keys = { 'w', 'a', 's', 'd' }, -- the skill check's keys
        Reinforced = {
            Price = 9500, -- the owner reinforces every door of the house (and its garages) from the panel
            Picks = { advancedlockpick = { 'medium', 'medium', 'hard', 'hard' } },
        },
        -- The stash, once inside: broken open with one of these, then open to whoever broke it for Window seconds.
        Stash = {
            Enabled = true,
            Items = { 'screwdriverset', 'drill' },
            Time = 14000, -- ms it takes
            Window = 300,
        },
    },
}
