added amb382, KV get/set vector natives

--HG--
extra : convert_revision : svn%3A39bc706e-5318-0410-9160-8a85361fbb7c/trunk%401740
This commit is contained in:
Borja Ferrer
2007-12-01 00:37:47 +00:00
parent 5d23282b07
commit 221429ff6e
2 changed files with 127 additions and 0 deletions
+23
View File
@@ -120,6 +120,17 @@ native KvSetFloat(Handle:kv, const String:key[], Float:value);
*/
native KvSetColor(Handle:kv, const String:key[], r, g, b, a=0);
/**
* Sets a vector value of a KeyValues key.
*
* @param kv KeyValues Handle.
* @param key Name of the key, or NULL_STRING.
* @param vec Vector value.
* @noreturn
* @error Invalid Handle.
*/
native KvSetVector(Handle:kv, const String:key[], const Float:vec[3]);
/**
* Retrieves a string value from a KeyValues key.
*
@@ -181,6 +192,18 @@ native KvGetColor(Handle:kv, const String:key[], &r, &g, &b, &a);
*/
native KvGetUInt64(Handle:kv, const String:key[], value[2], defvalue[2]={0,0});
/**
* Retrieves a vector value from a KeyValues key.
*
* @param kv KeyValues Handle.
* @param key Name of the key, or NULL_STRING.
* @param vec Destination vector to store the value in.
* @param defvalue Optional default value to use if the key is not found.
* @noreturn
* @error Invalid Handle.
*/
native KvGetVector(Handle:kv, const String:key[], Float:vec[3], const Float:defvalue[3]={0.0, 0.0, 0.0});
/**
* Sets the current position in the KeyValues tree to the given key.
*