FindDataMapInfo Function

Given an entity, finds a nested datamap property offset. This information is cached for future calls.

int FindDataMapInfo(int entity, const char[] prop, PropFieldType &type, int &num_bits, int &local_offset)

Parameters

int entity

Entity index.

const char[] prop

Property name.

PropFieldType& type

Optional parameter to store the type.

int& num_bits

Optional parameter to store the number of bits the field uses. The bit count will either be 1 (for boolean) or divisible by 8 (including 0 if unknown).

int& local_offset

Optional parameter to store the local offset, as FindDataMapOffs() would return.

Return Value

An offset, or -1 on failure.