RedM Natives

_FIND_NEAREST_PED_AROUND_ANIMAL

Animals only. Returns the nearest ped around `animalPed` matching the life-state filters (e.g., use (false,true,0) to find a nearby corpse for TASK_EAT).

Hash0x244430C13BA5258E
Runtime nameFindNearestPedAroundAnimal
NamespaceTASK
SideClient
NameCommunity guess
Docs
Since build1207

Signature

Ped _FIND_NEAREST_PED_AROUND_ANIMAL(Ped animalPed, BOOL aliveOnly, BOOL deadOnly, BOOL preferDeadPredators);

Parameters

NameTypeDescription
animalPedPed—
aliveOnlyBOOL—
deadOnlyBOOL—
preferDeadPredatorsBOOL—

Returns Ped

Description

alloc8or RDR3 NativeDB

Animals only. Returns the nearest ped around animalPed matching the life-state filters (e.g., use (false,true,0) to find a nearby corpse for TASK_EAT).
Last flag appears to bias predators/fish toward dead targets (uncertain).

VORPCORE RDR3natives

Finds the nearest ped around the specified originPed, with optional filters for life state and predator/fish behavior
(all false) returns the nearest ped regardless of alive/dead state

Usage

Lua
local retval = FindNearestPedAroundAnimal(animalPed, aliveOnly, deadOnly, preferDeadPredators)

-- always works, by hash
local retval = Citizen.InvokeNative(0x244430C13BA5258E, animalPed, aliveOnly, deadOnly, preferDeadPredators, Citizen.ResultAsInteger())
JavaScript and C#
JavaScript
const retval = FindNearestPedAroundAnimal(animalPed, aliveOnly, deadOnly, preferDeadPredators);

// by hash
const retval = Citizen.invokeNative('0x244430C13BA5258E', animalPed, aliveOnly, deadOnly, preferDeadPredators, Citizen.returnResultAnyway(), Citizen.resultAsInteger());
C#
int retval = Function.Call<int>((Hash)0x244430C13BA5258E, animalPed, aliveOnly, deadOnly, preferDeadPredators);
  • 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.