# TASK::TASK_GO_STRAIGHT_TO_COORD

- **Hash:** `0xD76B57B44F1E6F8B`
- **Namespace:** TASK
- **Runtime name (Lua/JS):** `TaskGoStraightToCoord`
- **Side:** client (game native)
- **Name status:** official
- **Documentation:** described
- **Since game build:** 1207
- **URL:** https://natives.borderlinerp.com/natives/TASK/TASK_GO_STRAIGHT_TO_COORD

## Signature

```c
void TASK_GO_STRAIGHT_TO_COORD(Ped ped, float x, float y, float z, float moveBlendSpeedY, int timeBeforeTeleport, float finalHeading, float targetRadius, int p8);
```

## Parameters

- `ped` (`Ped`)
- `x` (`float`)
- `y` (`float`)
- `z` (`float`)
- `moveBlendSpeedY` (`float`)
- `timeBeforeTeleport` (`int`)
- `finalHeading` (`float`)
- `targetRadius` (`float`)
- `p8` (`int`)

## Returns

`void`

## Description

*Source: alloc8or RDR3 NativeDB*

Go to coords wihtout using navmesh, if timeBeforeTeleport is -1 then it never teleports p8 is 1 or 0 still unknown.

*Source: VORPCORE RDR3natives*

Tells the ped to go to a coord, without using the navemesh. if timeBeforeTeleport is -1 the ped will never warp, p8 is always 0 or 1 still unknown

## Usage

### Lua

```lua
TaskGoStraightToCoord(ped, x, y, z, moveBlendSpeedY, timeBeforeTeleport, finalHeading, targetRadius, p8)

-- always available, by hash
Citizen.InvokeNative(0xD76B57B44F1E6F8B, ped, x, y, z, moveBlendSpeedY, timeBeforeTeleport, finalHeading, targetRadius, p8)
```

### JavaScript

```js
TaskGoStraightToCoord(ped, x, y, z, moveBlendSpeedY, timeBeforeTeleport, finalHeading, targetRadius, p8);

// by hash
Citizen.invokeNative('0xD76B57B44F1E6F8B', ped, x + 0.0000001, y + 0.0000001, z + 0.0000001, moveBlendSpeedY + 0.0000001, timeBeforeTeleport, finalHeading + 0.0000001, targetRadius + 0.0000001, p8);
```

### C#

```csharp
Function.Call((Hash)0xD76B57B44F1E6F8B, ped, x, y, z, moveBlendSpeedY, timeBeforeTeleport, finalHeading, targetRadius, p8);
```

- 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.

*Sources: alloc8or RDR3 NativeDB, VORPCORE RDR3natives.*
