diff --git a/plugins/include/entity.inc b/plugins/include/entity.inc index 38eb7cdb..ba713a2d 100644 --- a/plugins/include/entity.inc +++ b/plugins/include/entity.inc @@ -675,3 +675,43 @@ native GetEntPropString(entity, PropType:type, const String:prop[], String:buffe * @error Invalid entity, offset out of reasonable bounds, or property is not a valid string. */ native SetEntPropString(entity, PropType:type, const String:prop[], const String:buffer[]); + +/** + * Copies an array of cells from an entity at a given offset. + * + * @param entity Entity index. + * @param offset Offset to use. + * @param array Array to read into. + * @param arraySize Number of values to read. + * @param dataSize Size of each value in bytes (1, 2, or 4). + * @noreturn + * @error Invalid entity or offset out of reasonable bounds. + */ +stock GetEntDataArray(entity, offset, value, array[], arraySize, dataSize=4) +{ + for (new i=0; i