TASK_FLEE_PED
Signature
void TASK_FLEE_PED(Ped ped, Ped fleeFromTarget, int fleeStyle, int flag, float p4, int p5, int p6);Parameters
| Name | Type | Description |
|---|---|---|
ped | Ped | — |
fleeFromTarget | Ped | — |
fleeStyle | int | — |
flag | int | — |
p4 | float | — |
p5 | int | — |
p6 | int | — |
Returns void
Description
Params: p4 = -1.0f, p5 = -1, p6 = 0 in R* Scripts
fleeStyle: see TASK_FLEE_COORD
Usage
TaskFleePed(ped, fleeFromTarget, fleeStyle, flag, p4, p5, p6)
-- always works, by hash
Citizen.InvokeNative(0xFD45175A6DFD7CE9, ped, fleeFromTarget, fleeStyle, flag, p4, p5, p6)JavaScript and C#
TaskFleePed(ped, fleeFromTarget, fleeStyle, flag, p4, p5, p6);
// by hash
Citizen.invokeNative('0xFD45175A6DFD7CE9', ped, fleeFromTarget, fleeStyle, flag, p4 + 0.0000001, p5, p6);Function.Call((Hash)0xFD45175A6DFD7CE9, ped, fleeFromTarget, fleeStyle, flag, p4, p5, p6);- Float parameters: Lua integers (
10, or whole numbers decoded from NUI/JSON) are sent as ints and read as garbage. Write10.0orvalue + 0.0. The generated JS wrappers add0.0000001to non-zero floats for the same reason.
Enums and flags
- eFleeStyle 13 values
Sources
Something wrong or missing? Contribute a verified note — corrections ship through pull requests.