Garry's Mod Wiki

ents.GetByIndex

  Entity ents.GetByIndex( number entIdx )

Description

Returns an entity by its index. Same as Entity.

Arguments

1 number entIdx
The index of the entity.

Returns

1 Entity
The entity if it exists.