# PLAYER::SET_PLAYER_CAN_USE_COVER

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

## Signature

```c
void SET_PLAYER_CAN_USE_COVER(Player player, BOOL toggle);
```

## Parameters

- `player` (`Player`)
- `toggle` (`BOOL`)

## Returns

`void`

## Description

Sets whether this player can take cover.

## Usage

### Lua

```lua
SetPlayerCanUseCover(player, toggle)

-- always available, by hash
Citizen.InvokeNative(0x5EDA520F7A3BAF4E, player, toggle)
```

### JavaScript

```js
SetPlayerCanUseCover(player, toggle);

// by hash
Citizen.invokeNative('0x5EDA520F7A3BAF4E', player, toggle);
```

### C#

```csharp
Function.Call((Hash)0x5EDA520F7A3BAF4E, player, toggle);
```

*Sources: alloc8or RDR3 NativeDB.*
