EntityLumpEntry.FindKey Method

Searches the entry list for an index matching a key starting from a position.

int FindKey(const char[] key, int start)

Parameters

const char[] key

Key name to search.

int start

A position after which to begin searching from. Use -1 to start from the first entry.

Return Value

Position after start with an entry matching the given key, or -1 if no match was found.

Errors

Invalid start position; must be a value between -1 and one less than the length of the entry.