From 608a1f0d8040d4cd7523b12f30d29ae4476a4266 Mon Sep 17 00:00:00 2001 From: David Anderson Date: Mon, 21 May 2007 02:13:47 +0000 Subject: [PATCH] added request amb312 --HG-- extra : convert_revision : svn%3A39bc706e-5318-0410-9160-8a85361fbb7c/trunk%40829 --- plugins/include/entity.inc | 40 ++++++++++++++++++++++++++++++++++++++ 1 file changed, 40 insertions(+) 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