Identity terminal
Last updated
May be stale
This page was last updated ago, on 9 September 2026. Check what it says against the code before relying on it.
cityrp_idterminal is the government personnel terminal. ENT:GetIDMode decides who may open one
and what roster they see; IDMODE_NONE means no access at all. Terminals are placed as permanent
entities per map (core/plugins/perma_ents/maps/), including one in the SWAT/Police equipment room
on Evocity.
The client library is cityrp.idterminal, in the entity's own cl_init.lua.
Adding your own panel
The frame has a sidebar column to the right of the roster. It is shared — more than one plugin can qualify for it at once — so a plugin registers a section of it rather than sizing the column itself:
local card = cityrp.idterminal.claimSidebar(frame, PLUGIN.key, {dock = BOTTOM, order = 10})
if not card then return end
cityrp.idterminal.styleCard(card)
-- ... build into card ...
cityrp.idterminal.releaseSidebar(frame, PLUGIN.key)
claimSidebar(frame, key, options) |
The container to build into. Idempotent — returns the section the plugin already holds. options.dock defaults to BOTTOM; options.order sorts sections against each other via SetZPos, lowest first. |
getSidebar(frame, key) |
The plugin's section, or nil. Never creates one. |
releaseSidebar(frame, key) |
Removes the section, collapsing the column once the last one is gone. |
The terminal owns the column's width, docking, ordering and teardown, and prunes sections whose
panel was removed elsewhere. Do not touch frame.sidebar directly — sizing it from a plugin is
what the old warrant_delegation did, and clearing its card would have collapsed the column with
another plugin's card still in it.
At most one section should take FILL. It becomes the top of the column and everything else stacks
below it. warrant_delegation holds that one.
Hooks
| Hook | Realm | |
|---|---|---|
CityRP.IDTerminal.Opened(ent, ply, mode) |
server | Fired after the open message, so state pushed from it arrives once the frame exists. |
CityRP.IDTerminal.PostOpen(frame, ent, ply, mode) |
client | The frame is built. Drop any cached panel references here — the old frame is gone. |
Styling
cityrp.idterminal.colors is the palette; styleFrame, styleCard, styleList and
styleButton(button, "accent"|"neutral"|"danger"|"positive") apply the chrome. Fonts are
IDTerminal_Title, IDTerminal_Body and IDTerminal_Caption, built through
cityrp.ui and rebuilt on scale change.
Logging
Both realms log under idterminal: who opened a terminal and in which mode, who was refused, and
every sidebar section claimed or released.