Config

Here you can find all informations related to our Config & locales system.

Third party integrations

Location: rcore_prison/configs/config.lua

Telephone Booth - phone

Before you use booth module you should define what phone are you using in config.js config file.

  • Only for supported phones!

-- Location: rcore_prison/web/config.js

* For qs-smartphone use config qb-phone.

const CONFIG = {
    "phoneLenght": 10, // "npwd - 10", "gksphone: 10, qb-phone: "10",
    "phoneFormat": "gksphone" // "npwd", "gksphone", "qb-phone",'
}

rcore_basketball

rcore_basketball - optional data that support our interior presets

-- Location: rcore_basketball/config.lua ['BasketballHoops']
# ['rcore_prison_map']

BasketballHoops = {
    {
        pos = vector3(1671.640381, 2502.784912, 44.557003), 
        rot = vector4(0.000000, 0.000000, 0.942665, 0.333741),
        State = nil,
        Model = `prop_basketball_net`,
        IsSubscribed = false,
        threePointFwdDist = 0.0,
        threePointSideDist = 0.0,
        threePointRadius = 30.0,
        hideBlip = true,
    },

    {
        pos = vector3(1689.102173, 2523.121094, 44.641594), 
        rot = vector4(0.000000, 0.000000, -0.329191, 0.944263),
        State = nil,
        Model = `prop_basketball_net`,
        IsSubscribed = false,
        threePointFwdDist = 0.0,
        threePointSideDist = 0.0,
        threePointRadius = 30.0,
        hideBlip = true,
    },

    {
        pos = vector3(1729.442505, 2525.064697, 44.558537), 
        rot = vector4(-0.000000, 0.000000, 0.965665, -0.259790),
        State = nil,
        Model = `prop_basketball_net`,
        IsSubscribed = false,
        threePointFwdDist = 0.0,
        threePointSideDist = 0.0,
        threePointRadius = 30.0,
        hideBlip = true,
    },

    {
        pos = vector3(1718.615479, 2545.604004, 44.588676), 
        rot = vector4(0.000000, 0.000000, 0.239589, 0.970874),
        State = nil,
        Model = `prop_basketball_net`,
        IsSubscribed = false,
        threePointFwdDist = 0.0,
        threePointSideDist = 0.0,
        threePointRadius = 30.0,
        hideBlip = true,
    },
}

Permissions

  • Its required to add those permissions in your server.cfg.

add_ace resource.rcore_prison command.add_ace allow
add_ace resource.rcore_prison command.remove_ace allow
add_ace resource.rcore_prison command.add_principal allow
add_ace resource.rcore_prison command.remove_principal allow

Other

If you like to define your language, redirect to locales system guide.

-- Location: rcore_prison/configs/config.lua

-- Framework

-- !!! IF YOU ARE USING QBCORE / ESX -> YOU DONT NEED TO TOUCH THIS !!!!
-- !!! IF YOU ARE USING QBCORE / ESX -> YOU DONT NEED TO TOUCH THIS !!!!
-- !!! IF YOU ARE USING QBCORE / ESX -> YOU DONT NEED TO TOUCH THIS !!!!

Framework = 1, --[ 0 OR NIL = None |  1 = ESX  | 2 = QBCore |  3 = Other ] Choose your framework
MySQL = nil,--[ 0  = 'oxmysql' |  1 = 'mysql-async'  | 2 = 'ghmattimysql' ] Choose your SQL

Notify = {
    DefaultNotify = false, -- Notify provided by rcore_prison
    event = 'rcore_prison:renderNotification' -- Retval: serverId, data
},

-- FRAMEWORK_TRIGGERS
-- !!! IF YOU ARE USING QBCORE / ESX -> YOU DONT NEED TO TOUCH THIS !!!!
-- !!! IF YOU ARE USING QBCORE / ESX -> YOU DONT NEED TO TOUCH THIS !!!!
-- !!! IF YOU ARE USING QBCORE / ESX -> YOU DONT NEED TO TOUCH THIS !!!!
-- !!! IF YOU ARE USING QBCORE / ESX -> YOU DONT NEED TO TOUCH THIS !!!!

FrameworkTriggers = {
    notify = '', -- ['esx', 'qbcore'] Set the notification event, if left blank, default will be used
    object = '', --['esx', 'qbcore'] Set the shared object event, if left blank, default will be used (deprecated for QBCore)
    playerUnloadedServer = '', -- ['esx', 'qbcore'] Set playerLogout (server-side) event, if left blank, automatic detection will be performed
    playerLoadedServer = '', -- ['esx', 'qbcore'] Set playerLoadedServer (server-side) event, automatic detection will be performed
    playerUnloadedClient = '', -- ['esx', 'qbcore'] Set playerUnloadedClient (client-side) event, automatic detection will be performed
    playerLoadedClient = '', -- ['esx', 'qbcore'] Set playerLoadedClient (client-side) event, automatic detection will be performed
    resourceName = '', -- ['esx', 'qbcore'] Set the resource name, if left blank, automatic detection will be performed
    resourceNameClothing = '', -- [ ESX = 'skinchanger' / QBCore = 'qb-clothing', 'fivem-appearance' ] Set the clothing resource name, if left blank, automatic detection will be performed
    resourceNamePhone = '', -- '[ 'qb-phone', 'npwd', 'gksphone', 'qs-smartphone'] Set the phone resource name for booth usage, if left blank, automatic detection will be performed
},

Presets = {
    -- Key: resourceName ['rcore_prison_map']
    -- Preset name: ['rcore'] | data/presets/<XX>

    Maps = {
        ['rcore_prison_map'] = 'rcore',
        ['prison_main'] = 'desertos',
        ['cfx-gabz-prison'] = 'gabz',
        ['int_prison'] = 'unclejust',
        ['molo_alcatraz'] = 'alcatraz',
    }
},

-- Defined phones that are automatically loaded, if you dont define any: qb-phone, npwd, gksphone, qs-smartphone

ScriptEvents = {
    ['qb-clothing'] = {
        loadPlayerClothing = 'qb-clothing:client:loadPlayerClothing',
        loadOutfit = 'qb-clothing:client:loadOutfit',
    }
},

Frontend = {
    AlignMenu = 'top-left', -- 'top-left', 'top-right'
    useLibrary = 'rcore', -- Select your preffered library for menus: 'ox_lib', 'qb-menu', 'es_extended', 'es_context', 'rcore'
    Libraries = {
        ['esx_context'] = true,
        ['es_extended'] = true,
        ['ox_lib'] = true,
        ['qb-menu'] = true,
    },
},

-- Related to phone booths
-- Note: This is listed of supported phones
-- For setting your phone & locales: check [rcore_prison/web/build/config.js]

ImportAPI = false,

SupportedPhones = {
    ['gksphone'] = true,
    ['qb-phone'] = true,
    ['qs-smartphone'] = true,
    ['npwd'] = true,
},

Dashboard = {
    AddSentence = {
        ShowNames = true -- Want to hide player names in Add Sentence - list (dashboard - panel)
    }
},

RenderNPCBlips = true, -- Do you want to show where are specific things in prison area (true/false)
RenderPrisonMap = true, -- Do you want to render prison yard and stuff? (true/fase)

ECONOMY_ITEM = 'cigar', -- Used along for Dealers around Prison yard or credits as payment thing.

BoothMaxCallLenght = 5 * 60 * 1000, -- Max call lenght for calll session.
BoothTakeCreditsPeriod = 60 * 1000, -- Each minute reduce prisoner credits (BoothPricePerMinute)
BoothPricePerMinute = 2, -- 2 Credits per BoothTakeCreditsPeriod

OutfitSkipSelection = false, -- Would you like to get Prisoner instantly in Prison and define own actions?
OutfitSelectionTimeout = 10 * 1000,  -- How much time prisoner have time for outfit selection.
PackageCooldown = 30 * 1000, -- For Ciggarets packaging minigame, delay between each package session

InteractionDist = 1.5, -- Used for cache system, when you are not using target interaction.

CheckDistTimeout = 5 * 1000, -- Timeout when user is jailed, to start CheckDist for clients if #Prisoners <= 0 | Dont touch this!!
CheckEscapeDist = 300.0, -- Escape check dist
CheckDist = true, -- Prisoners only (escape when far away)

Language = 'en', -- 'en', 'cs

Target = {
    CheckMenuDistInterval = 250, -- How many tick interval should check dist opened menu?
    CheckMenuDist = 1.5, -- Distance of when hiding of interaction menu should perform?
    CheckDist = 1.5,  -- Distance of showing options when performing target
},

Activities = {
    DRAW_LINE = {
        rgb = vec3(14, 227, 7),  -- Related to jobs, as help draw line
        opacity = 255 -- Opacity
    }
},
Name
param
desc

Define how much time the new Prisoner spent in outfit selection, if new prisoner is not selecting anything, warden is going to choose him random prison outfit.

Here you can define your language.

Do you like to use native notifications or own?

True - Prisoners can be offline and jail time is reducing False - Prisoner needs to be on server for reducing time.

True - Notify job members when prisoner join activity on Prison yard. False - To disable notify of new job member (activity)

Prison Yard

All related settings for yard area.

-- Location: rcore_prison/configs/config.lua ['Yard']
Yard = {
    AnnoucementState = true, -- Enable annoucement in Prison yard from Warden
    AnnoucementAlarmState = false, -- Enable / Disable annoucement of Alarm, when break-out in progress.
},

Inmates

All related settings for Inmates (tasks, trades etc)

-- Location: rcore_prison/configs/config.lua ['Inmates']
Inmates = {
    Stab = 2, -- How many prisoners needs to be online to allow this option.
},

Community service

Community service

-- Location: rcore_prison/configs/config.lua ['CS']
CS = {
    DisableGameControls = true, -- When doing community service task, disabled any interaction (handy for abuser with clearing anims and so on)
    DefaultPeroll = 5, -- 6 Hours, when there is no defined time for jailed user CSW (command)
    Place = vec3(236.464233, -409.489075, 47.924313), -- Place of NPC where CS user is reporting him self and taking tasks.

    CleaningAnimTime = 0.1 * 1000,
    ReducePeroll = 1, -- 1 peroll from CS sentence, after finished current CS task
    PoolCooldown = 5 * 60 * 1000, -- When user finished specific zone, when should be added back to zone select pool?

    OUTLINE = {
        color = vec3(255, 255, 255), -- Color of outline on entity
        opacity = 80 -- Opacity of outline.
    }
}

NPC

NPC configuration

-- Location: rcore_prison/configs/config.lua ['NPC']
NPC = {
    SpawnNPC = false, -- Handle spawning of guards running arround Prisoners 
    HandleNPCPoolState = true, -- Disable spawning on NPC from scenario!
},

Circuit minigame

Circuit configuration

-- Location: rcore_prison/configs/config.lua ['Circuit']
Circuit = {
    Lifes = 3, -- How much lifes person has for Electrician
    Difficulty = 1, -- 1, 2, 3, 4, 5, 6 --> This is ignored when EachJobLevelIncreaseDifficulty is enabled

    EachJobLevelIncreaseDifficulty = true, -- If enabled, when doing Electrician each tasks gets harder 1, 2, 3, 4, 5, 6

    Keybinds = {
        ['ARROW_UP'] = 172,
        ['ARROW_DOWN'] = 173,
        ['LEFT_ARROW'] = 174,
        ['RIGHT_ARROW'] = 175,
        ['BACKSPACE'] = 177,
    }
}

Canteen

Prison canteen settings

Canteen  = {
    FreeFood = true,
    TakeFoodTimeout = 5 * 60 * 1000,

    PackageItems = {
        {
            itemName = 'water',
            count = 2,
        },
        {
            itemName = 'burger',
            count = 3,
        }
    }
}

Gym

Gym

-- Location: rcore_prison/configs/config.lua ['Gym']
Gym = {
    ['Cranks'] = {
        action = {
            percentIncrease = 2,
            time = 4,
        },
        skills = {
            strength = 0.3,
            stamina = 0.1,  
        }
    },

    ['Situps'] = {
        action = {
            percentIncrease = 8,
            time = 1,
        },
        skills = {
            strength = 0.3,
            stamina = 0.1,  
        }
    },

    ['Musclechin'] = {
        action = {
            percentIncrease = 2,
            time = 4,
        },
        skills = {
            strength = 0.3,
            stamina = 0.1,  
        }
    },
},

Target

Target

-- Location: rcore_prison/configs/config.lua ['Target']
Target = {
    CheckMenuDistInterval = 250, -- How many tick interval should check dist opened menu?
    CheckMenuDist = 1.5, -- Distance of when hiding of interaction menu should perform?
    CheckDist = 1.0,  -- Distance of showing options when performing target
},

Activities

Activities

-- Location: rcore_prison/configs/config.lua ['Activities']
Activities = {
    DRAW_LINE = {
        rgb = vec3(14, 227, 7),  -- Related to jobs, as help draw line
        opacity = 255 -- Opacity
    }
},

Minigame

Package of Cigarrets

-- Location: rcore_prison/configs/config.lua ['Minigame']
Minigame = {
    Steps = 5,
    MoveStep = 0.09, -- Needs to be higher > 0.02
    Tolerance = 0.025,
    TimeAcc = 0.2,
},
Option
Param
Description

Steps

integer

How many blocks script is going to generate?

MoveStep

float

Speed of arrowKeys generation block

Tolerance

float

What tolenrace should script ignore?

TimeAcc

float

Calc behind keyPress minigame

Commands

-- Location: rcore_prison/configs/config.lua ['Commands']
Option
Param
Usage
Command desc

Do you want to allow usage of jail commands?

Enable/Disable state of command usage.

Registered jail command as jail by default

/jail serverId 10

Registered unjail command as unjail by default

/unjail serverId

Registered dashboard command as dashboard by default, usage for opening dashboard app.

/dashboard

Do you want to sent somebody for community service

/startcs serverId 30

Jobs

-- Location: rcore_prison/configs/config.lua ['Jobs']

There is option to define your jobs, restriction for commands.

Job name
state

Define your server job name, which will be able to perform jail commands.

Accounts

-- Location: rcore_prison/configs/config.lua ['Accounts']

There are options for Prisoner accouns, which you can define:

Option
state
Desc

Item which is used as internal economy inside prison (itemName).

Default starting balance for Prisoner account, when created.

When Prisoner is jailed, and has created prisoner account, can outside people sent prisoner gifts?

How many friend can prisoner have added?

Release

-- Location: rcore_prison/configs/config.lua ['Release']

There are options for prisoner release, which you can define.

Option
state
Desc

Stash prisoner items & return

Transfer prisoner credits to money, when Prisoner released from jaill

KeepItems

-- Location: rcore_prison/configs/config.lua ['KeepItems']

You define specific iems, which prisoners can bring inside Prison.

Item name
state

['water']

true

Usage:

-- Location: rcore_prison/configs/config.lua ['KeepItems']
-- All of these items, can user bring inside jail / outside.
-- Note: Its recommended to define canteen items, so prisoners can get them.

KeepItems = {
    ['water'] = true,
    ['sprunk'] = true,
    ['coffee'] = true,
    ['ecola'] = true,
    ['ecola_light'] = true,
    ['sludgie'] = true
},

Level

You can define level debug, very useful when you want to see whats happening in background.

-- Location: rcore_prison/configs/config.lua ['Levele']

Level = {
   Debug = 3 -- Level [1, 2, 3]
},

Last updated