- Documentation
- Shared functions
- getControlLocks
Function
getControlLocks
Returns the list of locks on a control as "resource:owner", for diagnostics. The server and the client have separate locks.
Syntax
table getControlLocks(mixed ...)Arguments
...mixed- Server:
player, control; client:control.
Returns
The list of locks (empty if the control is free).
Example
for _, lock in ipairs(getControlLocks("fire")) do
outputChatBox("fire zablokowane przez " .. lock)
end
See also
lockControlsLocks controls on behalf of an owner. A control comes back only when its last owner releases it, so several resources can lock it without unlocking each other. A resource's locks disappear when it stops.unlockControlsReleases an owner's locks: the given controls, or all of them when the list is omitted.