TASK_LOOT_NEAREST_ENTITY
Tasks ped to loot the nearest lootable entity around (x, y, z).
Signature
void TASK_LOOT_NEAREST_ENTITY(Ped ped, float x, float y, float z, int p4, float p5); // 0xCF1501CBC4059412 b1207Parameters
| # | Name | Type |
|---|---|---|
| 1 | ped | Ped |
| 2 | x | float |
| 3 | y | float |
| 4 | z | float |
| 5 | p4 | int |
| 6 | p5 | float |
Facts
| Name | TASK_LOOT_NEAREST_ENTITY |
|---|---|
| Hash | 0xCF1501CBC4059412 |
| Namespace | |
| Returns | void |
| Game build | 1207 |
Examples
Calls by hash work in every RedM runtime. Replace the placeholder arguments with your own values.
Citizen.InvokeNative(0xCF1501CBC4059412, -- TASK_LOOT_NEAREST_ENTITY
PlayerPedId(), -- Ped ped
0.0, -- float x
0.0, -- float y
0.0, -- float z
0, -- int p4
0.0 -- float p5
)// Whole JS numbers are sent as integers: pass floats like 1.5 (or n + 0.0000001), never 1.
Citizen.invokeNative("0xCF1501CBC4059412", // TASK_LOOT_NEAREST_ENTITY
PlayerPedId(), // Ped ped
0.0, // float x
0.0, // float y
0.0, // float z
0, // int p4
0.0 // float p5
);Function.Call((Hash)0xCF1501CBC4059412, // TASK_LOOT_NEAREST_ENTITY
API.PlayerPedId(), // Ped ped
0.0f, // float x
0.0f, // float y
0.0f, // float z
0, // int p4
0.0f // float p5
);Related TASK natives
- TASK_LOOT_ENTITY
- TASK_FOLLOW_ENTITY_WHILE_AIMING_AT_ENTITY
- TASK_GO_TO_ENTITY_WHILE_AIMING_AT_ENTITY
- TASK_GO_TO_ENTITY_WHILE_AIMING_AT_ENTITY_USING_COMBAT_STYLE
- TASK_LOOK_AT_ENTITY
- TASK_AIM_AT_ENTITY
- TASK_AIM_GUN_AT_ENTITY
- TASK_DISEMBARK_NEAREST_TRAIN_CARRIAGE
- TASK_FOLLOW_ENTITY_ALONG_WAYPOINT_RECORDING_AT_OFFSET
- TASK_FOLLOW_TO_OFFSET_OF_ENTITY
- TASK_GO_STRAIGHT_TO_COORD_RELATIVE_TO_ENTITY
- TASK_GO_TO_COORD_WHILE_AIMING_AT_ENTITY
Facts compiled from community research (alloc8or/rdr3-nativedb-data, femga/rdr3_discoveries); descriptions and examples by The Lab.