setDoorState
lua
The new state is sent to every player. When called from another resource, no permission checks are done. If the door has auto-lock, it locks again after the set time.
Parameters
- doorId:
numberThe door ID - state:
0 | 1 | boolean1ortrueto lock,0orfalseto unlock
Return Value
booleanfalseif the door doesn't exist.
Example
lua