# HUD::_GET_HUD_VISIBILITY_SLOT_STATE

- **Hash:** `0x7EC0D68233E391AC`
- **Namespace:** HUD
- **Runtime name (Lua/JS):** `GetHudVisibilitySlotState`
- **Side:** client (game native)
- **Name status:** community guess (may change)
- **Documentation:** described
- **Since game build:** 1207
- **Other names:** `_GET_HUD_STATE`
- **URL:** https://natives.borderlinerp.com/natives/HUD/_GET_HUD_VISIBILITY_SLOT_STATE

## Signature

```c
int _GET_HUD_VISIBILITY_SLOT_STATE(int hudSlot);
```

## Parameters

- `hudSlot` (`int`)

## Returns

`int`

## Description

*Source: alloc8or RDR3 NativeDB*

Returns the current state value for a HUD component slot ID.
Enum: https://github.com/Halen84/RDR3-Native-Flags-And-Enums/tree/main/eHudVisibilitySlotType 
Notes:
- Component-specific semantics: the same numeric state can mean different things depending on the component.
- Used heavily as a gating signal for prompts/targeting/UI updates (e.g., return 0 when 21==2 or 54==2; block logic when 10==2 or 10==4).

*Source: VORPCORE RDR3natives*

Returns the state of a specific HUD Component
eHudVisibilitySlotType: https://github.com/Halen84/RDR3-Native-Flags-And-Enums/tree/main/eHudVisibilitySlotType

## Usage

### Lua

```lua
local retval = GetHudVisibilitySlotState(hudSlot)

-- always available, by hash
local retval = Citizen.InvokeNative(0x7EC0D68233E391AC, hudSlot, Citizen.ResultAsInteger())
```

### JavaScript

```js
const retval = GetHudVisibilitySlotState(hudSlot);

// by hash
const retval = Citizen.invokeNative('0x7EC0D68233E391AC', hudSlot, Citizen.returnResultAnyway(), Citizen.resultAsInteger());
```

### C#

```csharp
int retval = Function.Call<int>((Hash)0x7EC0D68233E391AC, hudSlot);
```

- The name is a community guess and may change. If the named call is missing in your client build, use `InvokeNative` with the hash — it always works.

## Related enums

- [eHudVisibilitySlotType](https://natives.borderlinerp.com/enums/eHudVisibilitySlotType.md) — 67 values

*Sources: alloc8or RDR3 NativeDB, VORPCORE RDR3natives.*
