RedM Natives

_COMPUTE_PED_MOVE_BLEND_RATIO_FOR_MAX_SPEED

Returns estimated max speed (m/s) for the ped move blend ratio.

Hash0x46BF2A810679D6E6
Runtime nameComputePedMoveBlendRatioForMaxSpeed
NamespacePED
SideClient
NameCommunity guess
Docs
Since build1207

Signature

float _COMPUTE_PED_MOVE_BLEND_RATIO_FOR_MAX_SPEED(Ped ped, float maxMoveBlendRatio);

Parameters

NameTypeDescription
pedPed—
maxMoveBlendRatiofloat—

Returns float

Description

alloc8or RDR3 NativeDB

Returns estimated max speed (m/s) for the ped move blend ratio. Move blend ratio is in a range of 0.0 - 3.0.
_COMPUTE_S*

VORPCORE RDR3natives

Returns vehicle (desired) speed
_COMPUTE_(VEHICLE_SPEED_USING_BLEND_RATIO?)*

Usage

Lua
local retval = ComputePedMoveBlendRatioForMaxSpeed(ped, maxMoveBlendRatio)

-- always works, by hash
local retval = Citizen.InvokeNative(0x46BF2A810679D6E6, ped, maxMoveBlendRatio, Citizen.ResultAsFloat())
JavaScript and C#
JavaScript
const retval = ComputePedMoveBlendRatioForMaxSpeed(ped, maxMoveBlendRatio);

// by hash
const retval = Citizen.invokeNative('0x46BF2A810679D6E6', ped, maxMoveBlendRatio + 0.0000001, Citizen.returnResultAnyway(), Citizen.resultAsFloat());
C#
float retval = Function.Call<float>((Hash)0x46BF2A810679D6E6, ped, maxMoveBlendRatio);
  • Float parameters: Lua integers (10, or whole numbers decoded from NUI/JSON) are sent as ints and read as garbage. Write 10.0 or value + 0.0. The generated JS wrappers add 0.0000001 to non-zero floats for the same reason.
  • The name is a community guess and may change. If the named call is missing in your client build, use InvokeNative with the hash — it always works.

Sources

alloc8or RDR3 NativeDB · VORPCORE RDR3natives

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