_SET_DOOR_KNOCKING_WHEN_LOCKED
Changes the interaction behavior for a locked door.
0xA93F925F1942E434SetDoorKnockingWhenLockedSignature
void _SET_DOOR_KNOCKING_WHEN_LOCKED(Hash doorHash, BOOL toggle);Parameters
| Name | Type | Description |
|---|---|---|
doorHash | Hash | — |
toggle | BOOL | — |
Returns void
Description
Changes the interaction behavior for a locked door.
When enabled, interacting with a locked door makes the character knock/tap instead of trying the handle.
This does not unlock or open the door and only changes the locked-door interaction behavior/animation.
Changes the interaction behavior for a locked door.
Normally, when interacting with a locked door, the character tries the handle. When this native is enabled, that behavior is replaced with a knocking/tapping interaction for the specified door.
With toggle enabled:
- pressing the interact button on a locked door makes the character knock/tap on the door instead of trying the handle
- this does not unlock the door
- if the door is in a breakable/force-open state, it may still be opened by physically forcing it (e.g. sprinting into it), but normal interaction still uses the knocking behavior
Usage
SetDoorKnockingWhenLocked(doorHash, toggle)
-- always works, by hash
Citizen.InvokeNative(0xA93F925F1942E434, doorHash, toggle)JavaScript and C#
SetDoorKnockingWhenLocked(doorHash, toggle);
// by hash
Citizen.invokeNative('0xA93F925F1942E434', doorHash, toggle);Function.Call((Hash)0xA93F925F1942E434, doorHash, toggle);- Hash parameters: the named function also accepts a string and hashes it for you;
Citizen.InvokeNativeneeds the number — passjoaat("name")or a backtick literal like`name`. - The name is a community guess and may change. If the named call is missing in your client build, use
InvokeNativewith the hash — it always works.
See also
_GET_DOOR_KNOCKING_WHEN_LOCKEDReturns whether the specified door has the locked-door knocking interaction enabled.
Sources
alloc8or RDR3 NativeDB · VORPCORE RDR3natives
Something wrong or missing? Contribute a verified note — corrections ship through pull requests.