# ENTITY::GET_OBJECT_INDEX_FROM_ENTITY_INDEX

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

## Signature

```c
Object GET_OBJECT_INDEX_FROM_ENTITY_INDEX(Entity entity);
```

## Parameters

- `entity` (`Entity`)

## Returns

`Object`

## Description

Simply returns whatever is passed to it (Regardless of whether the handle is valid or not).

## Usage

### Lua

```lua
local retval = GetObjectIndexFromEntityIndex(entity)

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

### JavaScript

```js
const retval = GetObjectIndexFromEntityIndex(entity);

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

### C#

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

*Sources: alloc8or RDR3 NativeDB.*
