RedM Natives

GET_CONTROL_HOW_LONG_AGO

Returns time in ms since last input.

Hash0xD7D22F5592AED8BA
Runtime nameGetControlHowLongAgo
NamespacePAD
SideClient
NameOfficial
Docs
Since build1207
GTA V hash0xD7D22F5592AED8BA

Signature

int GET_CONTROL_HOW_LONG_AGO(int control);

Parameters

NameTypeDescription
controlint—

Returns int

Description

Returns time in ms since last input.

Usage

Lua
local retval = GetControlHowLongAgo(control)

-- always works, by hash
local retval = Citizen.InvokeNative(0xD7D22F5592AED8BA, control, Citizen.ResultAsInteger())
JavaScript and C#
JavaScript
const retval = GetControlHowLongAgo(control);

// by hash
const retval = Citizen.invokeNative('0xD7D22F5592AED8BA', control, Citizen.returnResultAnyway(), Citizen.resultAsInteger());
C#
int retval = Function.Call<int>((Hash)0xD7D22F5592AED8BA, control);

Sources

alloc8or RDR3 NativeDB

Something wrong or missing? Contribute a verified note — corrections ship through pull requests.