Documentation
Docs/Resources/Base/doorlocks
Base Resource

doorlocks

Business door groups are linked to the business job configured in Config.AuthGroups. Doorlocks reads the current owner CSN from the live business record, so door access updates automatically when a new owner is set in-game. doorconfig.lua assigns the door group's authGroup. The matching entry in config.lua contains the business jobs value and may also contain an owners list. The owners list is a fallback. Keep it updated when possible because any CSN listed there can receive access if the linked business record is unavailable. It should not be treated as the primary source of business ownership. Example: In this example, flowcustoms is the door authorization group and flowc is the business job name. The job name must exactly match the business created

v1.0.0VCore FrameworkCore systems

Introduction

Business door groups are linked to the business job configured in Config.AuthGroups. Doorlocks reads the current owner CSN from the live business record, so door access updates automatically when a new owner is set in-game. doorconfig.lua assigns the door group's authGroup. The matching entry in config.lua contains the business jobs value and may also contain an owners list. The owners list is a fallback. Keep it updated when possible because any CSN listed there can receive access if the linked business record is unavailable. It should not be treated as the primary source of business ownership. Example: In this example, flowcustoms is the door authorization group and flowc is the business job name. The job name must exactly match the business created

5Client Lua
7Server Lua
7Exports
10Events
2SQL tables

No manifest UI page detected.

Dependencies & References

ResourceDetected asPackage status
coreManifest dependencyIncluded in Base
inventoryManifest dependencyIncluded in Base
oxmysqlManifest dependencyExternal / prerequisite
polyzoneManifest dependencyIncluded in Base
garagesReferenced by sourceIncluded in Base
logsReferenced by sourceIncluded in Base
multicharReferenced by sourceIncluded in Base
utilsReferenced by sourceIncluded in Base

Cross-resource export calls

ResourceFunctions called
coregetCoreObject
garagesRegisterGarageAccessProvider
inventoryGetPlayerItems, OpenStash, RemoveItemAtSlot
logsLog
multicharRegisterCaseFileSpawnProvider
utilsRegisterAdminAction

Installation / Start Order

The supplied server.cfg enables this resource in the Core systems stage at enabled-resource position 30. Base installation also depends on the global prerequisites and consolidated VCORE_INSTALL.sql documented in Getting Started.

server.cfg
ensure doorlocks

Configuration

Config files

  • config.lua
  • doorconfig.lua

Top-level config keys detected

AuthGroupsDoorsSettings

Events, Exports & Callbacks

Exports

Client exports1
  • IsNearLockpickableDoor
Server exports6
  • ExecuteUtilsAdminAction
  • GetBusinessSpawnPoints
  • GetDoorState
  • HasAccess
  • SetDoorState
  • hasGarageAccess

Callbacks

Server callbacks2
  • doorlocks:server:canUse
  • doorlocks:server:getAccess

Registered network events

Client registered events4
  • doorlocks:client:inspectNearest
  • doorlocks:client:interactionAccepted
  • doorlocks:client:lockpickResult
  • doorlocks:client:useLockpick
Server registered events6
  • doorlocks:server:completeLockpick
  • doorlocks:server:grantAccess
  • doorlocks:server:openStash
  • doorlocks:server:openWardrobe
  • doorlocks:server:revokeAccess
  • doorlocks:server:toggle

Commands

Client commands2
  • +
  • -

Database / SQL

FileType
sql/doorlocks.sqlResource SQL file
sql/legacy-doorlocklocations.sqlResource SQL file
doorlock_accessdoorlock_states

The root Base package also ships the consolidated VCORE_INSTALL.sql.

Source Layout

AreaDetected files
Client Lua5
Server Lua7
Other/shared Lua4
JavaScript0
HTML0
CSS0
SQL2

Troubleshooting

  • Confirm all manifest dependencies are started before doorlocks.
  • Check the supplied start-order note above; resources absent from server.cfg need an explicit decision before enabling.
  • If database queries fail, import the consolidated Base SQL and any resource-local SQL listed above.
  • If the UI fails, verify the resource's NUI files and ui_page when one is declared.