TASK_SHOOT_AT_ENTITY
Tasks entity to shoot at targetEntity for duration milliseconds using firingPattern.
Signature
void TASK_SHOOT_AT_ENTITY(Entity entity, Entity targetEntity, int duration, Hash firingPattern, BOOL affectCockedState); // 0x08DA95E8298AE772 b1207Parameters
| # | Name | Type |
|---|---|---|
| 1 | entity | Entity |
| 2 | targetEntity | Entity |
| 3 | duration | int |
| 4 | firingPattern | Hash |
| 5 | affectCockedState | BOOL |
Facts
| Name | TASK_SHOOT_AT_ENTITY |
|---|---|
| Hash | 0x08DA95E8298AE772 |
| 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(0x08DA95E8298AE772, -- TASK_SHOOT_AT_ENTITY
PlayerPedId(), -- Entity entity
PlayerPedId(), -- Entity targetEntity
0, -- int duration
GetHashKey("name"), -- Hash firingPattern
false -- BOOL affectCockedState
)Citizen.invokeNative("0x08DA95E8298AE772", // TASK_SHOOT_AT_ENTITY
PlayerPedId(), // Entity entity
PlayerPedId(), // Entity targetEntity
0, // int duration
GetHashKey("name"), // Hash firingPattern
false // BOOL affectCockedState
);Function.Call((Hash)0x08DA95E8298AE772, // TASK_SHOOT_AT_ENTITY
API.PlayerPedId(), // Entity entity
API.PlayerPedId(), // Entity targetEntity
0, // int duration
(uint)API.GetHashKey("name"), // Hash firingPattern
false // BOOL affectCockedState
);Related TASK natives
- TASK_SHOOT_AT_COORD
- 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_AIM_AT_ENTITY
- TASK_AIM_GUN_AT_ENTITY
- TASK_FOLLOW_ENTITY_ALONG_WAYPOINT_RECORDING_AT_OFFSET
- TASK_GO_TO_COORD_WHILE_AIMING_AT_ENTITY
- TASK_GO_TO_COORD_WHILE_AIMING_AT_ENTITY_USING_COMBAT_STYLE
- TASK_LOOK_AT_ENTITY
- TASK_PLACE_CARRIED_ENTITY_AT_COORD
- TASK_VEHICLE_SHOOT_AT_COORD
Facts compiled from community research (alloc8or/rdr3-nativedb-data, femga/rdr3_discoveries); descriptions and examples by The Lab.