DLLFunc_KeyValue, // void ) ( edict_t *pentKeyvalue, KeyValueData *pkvd );
How the hell do you use KeyValue to set one key value onto one entity? It only takes a keyvalue and a value, I'm so confused ;_;
In the engine C++ version of the native DispatchKeyValue, it uses a storage type KeyValue, which we can unfortunately, not make in small.
Code:
cell *cVal = MF_GetAmxAddr(amx, params[1]);
int iValue = *cVal;
CHECK_ENTITY(iValue);
edict_t *pEntity = INDEXENT2(iValue);
KeyValueData kvd;
int iLength=0;
char *char1 = MF_GetAmxString(amx, params[2], 0, &iLength);
char *char2 = MF_GetAmxString(amx, params[3], 1, &iLength);
kvd.szClassName = (char*)STRING(pEntity->v.classname);
kvd.szKeyName = char1;
kvd.szValue = char2;
kvd.fHandled = 0;
MDLL_KeyValue(pEntity, &kvd);
See? Its different. So how the hell do we use this command for ONLY ONE entity, in small, through FM.
__________________