Configuration
Every option in config/, and what the panel can change.
Devices pages
The files in config/ hold the starting values. What admins change in the panel (/evdevices) is kept in the evdev_settings table and wins over the files. Delete a row there to go back to the file value.
Values marked (Settings) below can be changed in the panel's Settings dialog. Only the difference to the file is saved, so a later change in the file still counts for every value the dialog left alone. The server applies it at start and after every save, and every player gets it at once.
Rows of evdev_settings: general and kinds (Settings), zones (no-place zones), signal (antennas), brand (the Brand card) and config, the values of the files below that the Settings dialog changed, as { ['os.notes.max'] = 60, ... }.
Security, commands, rate and list limits, item names and all model geometry stay in the files. So do a few values that only make sense next to others in the file: the use key (devices.interaction.key is a GTA control number and keyLabel the letter shown for it), the signal bar levels (signal.bars) and the fine tuning of live screens (keep, lingerMs, fadeMs, detail, upscale).
config/settings.lua
General
Config.debug: test mode. Every player may take a tablet out with/evdtablet(without it only admins may), and the panel header says Debug on.Config.framework:'auto'(the default) takes the first framework that runs:qbx_core, thenqb-core, thenes_extended. Qbox comes first becauseqbx_corealso answers asqb-core. Set'qbox','qbcore'or'esx'to skip the search. The framework has to start beforeevolent_devices; with none running, or an unknown value, the resource stops at start with a line that says so.Config.notifyWith:'ox_lib'(the default) shows the short notices (placed, picked up, not allowed) withlib.notify.'framework'sends them throughQBCore:Notifyon QBCore andesx:showNotificationon ESX, for servers that restyle those. Qbox notices are ox_lib either way. The notification cards of apps are not affected.Config.commands:adminopens the panel,tablettakes the tablet out or puts it away. See Commands.Config.database.autoMigrate: on start, create theevdev_tables fromsql/install.sqlwhen they are missing. The file only creates tables and never changes existing data. Set it tofalseto import the file yourself.Config.trustedResources: scripts whose apps are allowed the moment they register. Any other script's app waits in the panel (Apps) until an admin presses Allow.
Permissions
-
Config.aces:adminmay do everything in the panel.managemay list, place, move, edit and remove devices, but has no global settings, app approval, item rules or giving items. Nobody hasmanageuntil you add the line:server.cfgadd_ace group.admin evolent_devices.admin allow add_ace group.helper evolent_devices.manage allow -
Config.adminGroups: checked only after the aces, and only on QBCore and ESX.adminlists the QBCore permissions and ESX groups that count asConfig.aces.admin(god,superadminandadminout of the box),managethe ones that count asConfig.aces.manage(none). Empty lists leave the aces alone. Qbox uses the aces only. ESX Legacy also gives its groups asgroup.<name>principals, so theadd_acelines above work there too. -
Config.admin:tokenIdleMinutes(Settings): a panel left alone this long must be opened again with the command.placeRange(Settings): metres from the admin where the free camera may place a device.placeToleranceadds a few metres for the ped moving a little.rate: calls per second per admin and action:read(lists and pages),write(saves),lookup(the citizen field).burst: all panel calls together, per second per admin.
Config.general
The panel's Settings dialog changes these.
| Option | Description |
|---|---|
adminsOpenAny | Admins may open players' own devices too. Every such open is in the activity list. |
auditDays | Activity rows older than this are deleted at start. |
removedDays | Removed devices can be restored from the panel for this many days. |
twinRadius | Devices of one kind this close get different models. |
watchRange | People this close see what is on a screen in use. |
forceCover | true shows people nearby only an "In use" cover, never an app's own view. |
session.idleMinutes | A user who does nothing this long is taken off the device (0 = never). |
session.lockMinutes | The laptop and computer lock screen comes on after this many idle minutes (0 = never). |
session.leaseSeconds | The server frees a device whose user stopped answering for this long. |
session.heartbeatSeconds | How often a user's game tells the server it is still there. |
sound.enabled | Device sounds on or off for everyone. |
sound.volume | How loud the user hears them, 0 to 100. |
sound.nearby | How loud other players hear the clicks, 0 to 100 (0 = nothing). It fades with distance and stops at sound.range metres (3 to 10). |
display is one setting for the screens of every laptop, computer and terminal (Settings, Screens in the panel): brightness 20 to 100 %, light the soft screen light in percent of each kind's own (0 = off, up to 200), color an own light colour ('#rrggbb', '' = the kind's colour), sleep minutes without use before a screen sleeps (3 out of the box, 0 = never), and night with nightFrom and nightTo in minutes after midnight by the game clock. A sleeping screen keeps half its brightness and throws no light. At night hours screens go black. The idle picture, the lock screen name, auto lock, signal and the out of service note stay per device.
Config.brand
The starting brand (the Brand card in the panel wins over it).
| Option | Description |
|---|---|
accent | The colour, '#RRGGBB'. |
logo | An https link, a small data:image picture or a file of this resource ('' = the Evolent mark). |
name | The name of the OS ('' = Evolent OS, at most 40 letters). |
wallpaper | evolent (the built-in picture web/build/wallpapers/evolent.webp, drawn in the brand colour) or the id of one of your own pictures from Config.wallpapers. |
idle | { laptop = '', pc = '', terminal = '' }: what the screens of each kind show while nobody uses them. '' is the Evolent picture in the brand colour, or the id of an own picture. |
A wallpaper or idle id that is not known shows the Evolent picture, and the console names it at start.
Own wallpapers
Config.wallpapers holds your own pictures, empty out of the box. As a wallpaper they are offered next to evolent in Settings on laptops, computers and tablets, in the Brand card and on the Screen of a laptop or computer in the panel. As the picture of an idle screen an admin picks one for every laptop, every computer or every terminal in the Brand card, or for one device on its Screen in the panel. An own picture is shown exactly as you made it, never in the brand colour; where its shape differs from the screen it fills the screen and is cut round the centre.
Add the picture
Put the picture in web/build/wallpapers/: a .webp, .jpg or .png under 1 MB, for example web/build/wallpapers/harbour.webp. Best sizes: 1440 x 900 for a laptop (16:10), 1920 x 1080 for a computer (16:9), 1920 x 720 for a terminal (8:3). One 1920 x 1080 picture works on all three: a terminal loses a third of the height, so keep what matters in the middle.
If you build the web pages yourself, put it in web/public/wallpapers/ instead: the build copies that folder to web/build/wallpapers/.
Add a line
Config.wallpapers = {
{ id = 'harbour', name = 'Harbour', file = 'web/build/wallpapers/harbour.webp' },
}The id is lower-case letters, digits and _ (at most 32, not evolent), name is what players see (at most 40 letters), file the picture from the first step. At most 24 pictures.
Restart
With nobody on the server, run refresh, then ensure evolent_devices. A new picture needs the refresh, because the server only sends files it knew when the resource started.
The console names a line it leaves out (a bad id, a repeated id, a file outside web/build/wallpapers/ or one that is not there). A device, a tablet or the brand that saved a picture you later take out shows evolent instead.
A release carries only evolent.webp in web/build/wallpapers/, so your pictures stay when you copy the new files over the old folder. Carry your Config.wallpapers list and Config.brand.idle over into the new config/settings.lua.
Limits and markers
Config.limits: list sizes the panel accepts.rulesPerListrules in one access list,appsPerDeviceapps on one device or the tablets,zonesno-place zones,labelLengthletters in a device, zone or app name,blockedSerialsblocked tablet serials,antennasantennas.appWindows(Settings) is the number of app windows one user may have open; people nearby see the top four.Config.marker(Settings): the ground markers shown while placing.color(''= the brand colour, or an own'#RRGGBB'),scale(the size of the stand spot),motion(falsekeeps the chevrons still) anddraw:'poly'draws the sharp textured markers,'marker'one stock GTA ring per marker.
Config.os
The built-in apps (Settings, except photos.library). Laptops and computers have all of them, tablets Store and Settings.
apps: switch Notes, Files, Photos, Store and Settings on or off for every device. Withstore = falsenothing has to be installed: every app a device may run is on it.preinstalled:{ notes = true }puts Notes on every device from the start. Store, Settings, Files and Photos always are and cannot be removed. What is installed is kept per device on the server, for tablets by serial.notes:maxnotes per device,titleandbodylengths in characters,trashdeleted notes kept per device andtrashDaysafter which the trash is emptied at start. Notes belong to the device: the next person who uses it sees them.photos:links(off out of the box) lets users add pictures by an https link, only from the sites inhosts(a host also allows its subdomains, at most 20). Everyone who sees such a picture loads it from that site, so keep the list to image hosts you trust.maxper device,namelength, andlibrarywith pictures every device shows, as{ name = 'Showroom', url = 'https://...' }.password: the lock screen password ismintomaxcharacters of any kind. Aftertrieswrong passwords a player waitswaitSeconds. The owner of a player device sets it in the Settings app, admins on the device page of the panel. Only a salted hash is stored.
Config.notifications
What a player notices when an app sends a notification (Settings, the Notifications group). All on out of the box. See Notifications.
| Option | Description |
|---|---|
popup.enabled | A card in a corner of the game screen when the notification comes while the player is at no device. Up to four show, the rest count as "N more in Notifications". |
popup.position | 'top_right', 'top_center', 'top_left' or 'bottom_right'. |
popup.seconds | 3 to 20 before a card goes. |
sound | The cards play their own sound, at the device sound volume. |
tablet.enabled | A player who carries a tablet and is not holding it gets a short signal and a small "Open your tablet" card instead. |
screen.enabled | The idle screen of a player's own laptop or computer shows "N new notifications". People nearby see the count, never the text. |
screen.blink | The screen light of that device blinks when one comes. |
keepDays | 1 to 60: notifications older than this go, read or not. |
keep | 5 to 50: the most kept for one character or one device. |
Players switch the cards and their sound off for themselves in Settings, Notifications.
config/kinds.lua
The four device kinds. The models are in stream/. Config.kindOrder is the order the kinds are listed in. Each kind in Config.kinds has:
| Option | Description |
|---|---|
enabled | The kind can be placed and used. The panel's Settings can switch it off. |
max | Most devices of this kind on the server, 0 = no limit. |
variants | Models of one kind, each with its own screen texture <model>_screen. Devices of a kind close to each other get different ones (twinRadius). |
placeOn | 'surface' (table, desk), 'floor', or 'hand' for the tablet. |
spacing | Metres another device must keep from this one. |
os | Runs the Evolent OS with apps. A terminal shows one app page full screen instead. |
wireless | Needs an antenna's signal. false is wired, always full signal. |
startAccess | Who may use a device an admin just placed: { mode = 'everyone' }, { mode = 'owner' } or { mode = 'rules', rules = {} }. |
Positions are in model space: origin at the bottom centre, screen facing -Y.
page: the page the screen shows while someone uses it. Laptop and computer: the Evolent OS,web/build/os.html. A terminal shows the page of its app, orweb/build/out_of_service.htmlwithout one.dui: the size the page is drawn at. Its aspect must match the glass within 1.5 %.textureSize: the size of the screen texture in the model. In'world'mode it is exactly theduisize.screenMode:'world'puts the page inside the monitor.'poly'draws it a few mm over the glass.userView:'hud'shows the user the same page flat over the glass, crisp, built at the size the glass has on their monitor.'world'shows it the way everyone else sees it.screen: the corners of the page, 2 mm in front of the glass:TL,TR,BLandBR.camera:fovof the use camera,fillthe share of the game screen the glass fills.use: where the player stands (offset),reachin metres, andfloor, the table height window for placement notes.anim: the clip the player plays while using it (dict,clip,flag; lower case names). Optional:look,tapwithtapGap,idleswithidleEvery,oneShotFlag.clearFront: floor devices, metres that must be free in front of the screen.neon(terminal): the glowing edge strips. They take theneoncolour of a terminal app's look, else its accent, else the brand accent;falsekeeps the baked white.light: the screen's own soft light:color,tint,range,intensityin use,idle(share at night),offset,aim.
Laptops and computers also have use.keyboard (the middle of the keys on the model) and anim.poses, the ways to stand at the keys by height.
How devices are shown and used, for every kind:
streamDistance,despawnDistance: metres where a device prop appears and goes again. Keep them below the laptop's 70 m lod.flatSlope,maxSlope(Settings): degrees. A surface tilted more thanflatSlopegives a note, more thanmaxSlopeis refused.animPreloadDistance: the use clips are loaded this close to a device.interaction(Settings:useTarget,prompt):useTargetuses ox_target when it runs, else the key prompt (key38 is E,keyLabelis shown).prompt = 'evolent'draws the prompt above the screen,'ox'useslib.showTextUI.session(Settings:walkMs,damage,cancelReach,darkGlass,clearTimecycle):walkMsto walk to the stand spot;damage(health plus armour lost in one hit) ends the use;cancelReachmetres pastuse.reachend it;cameraEaseMs;viewFadeMs;darkGlassturns the monitor under the flat page dark;clearTimecycleswitches off another script's timecycle modifier while a device is used.mirror(Settings:enabled,pointerHz,maxWatchers): people nearby see the page, with the user's pointer and the page's small state sent through the server, only while at least one person watches.intervalMs,stateBytes,osStateBytes,idleMs,maxScreens(1 lets a player watch one screen at a time, 0 lets nobody watch).light(Settings:enabled,max,range): every client lights at mostmaxdevices withinrangemetres of its camera.fadeMs,night,cone,tintColor.studio: the hidden 3D studio an app page may ask for (the terminal's live car): thekindsthat may use it, thespothigh over the sea,lookand thepaintsoffered when the app gives none. See The 3D studio.idle.live(Settings:enabled,max,range): the nearestmaxdevices withinrangemetres get a small live page instead of the picture in the model, sharp at any distance. The picture is the first that is set: the image link an admin gave the device, the picture of the device, the own picture the brand gives its kind, the preset.idle.dark(Settings): screens further away than the live range show a still picture, on at mostmaxmodels at once: black at night, a dimmed copy asleep, and a grey copy on a terminal whose colour is not the stock lime.idle.presets: the pictures admins pick per kind; the first one is the picture in the model and the default.neutral = truesays the grey copies exist.
The tablet in hand (model and clips in stream/):
activityHoldMs(Settings): after the last tap or key the hands go back from the use clip to the hold clip.useMinimumMs(Settings): the use clip plays at least this long.look(Settings:enabled,others,range): the head bends down to the tablet while it is out.others = truealso bends the head of other players withinrangemetres.light(Settings:enabled,intensity,max,viewRange): the soft light from the screen towards the holder. Keeprangeshort: the game has no shadow on this light and it passes walls.range(Settings): other players' tablets are shown this close.anims: clip dictionary and clip names, lower case.flag,blendIn,blendOut.attach: the clips were fitted to this spot on bone 28422.
config/items.lua
Player items. See Player Items.
config/signal.lua
Signal for wireless devices (laptop and tablet by default, see wireless above). Antennas are masts an admin places from the panel and the game's own towers they pick there. Wired kinds always have full signal. Without signal the Evolent OS still runs, but apps that need the network show "No signal" and their server calls get no user (appUser answers nil).
| Option | Description |
|---|---|
enabled (Settings) | false gives every device full signal, antennas or not. |
radius, strength (Settings) | Metres a new antenna reaches and its signal in percent at the antenna. |
bars | The signal in percent each bar needs (1 bar from the first value, 4 bars from the last). The signal falls with the square of the distance. |
homeLoss (Settings) | Bars a device inside a home loses to the walls. |
masts | Stock props an admin can place as a mast, in the open world only. |
streamDistance (Settings) | Metres where a placed mast appears on a client. |
towerTypes | The starting radius and strength when an admin picks a map tower of that type. |
starter | Map towers that become antennas on the very first start, so laptops and tablets work before anyone places one. Saved on that first start: use the panel after that. |
config/towers.lua
The game's own masts and radio towers (119 of them). Admins pick them as antennas in the panel; nothing is spawned for them. You may add your own: a unique id, a type from Config.signal.towerTypes, the model name for the panel, the position and the height in metres.