Yep. This is what I use in
Info Editor plugin to return strings from an SDKCall:
PHP Code:
StartPrepSDKCall(SDKCall_Raw);
if( PrepSDKCall_SetFromConf(hGameData, SDKConf_Signature, "KeyValues::GetString") == false )
SetFailState("Could not load the \"KeyValues::GetString\" gamedata signature.");
PrepSDKCall_AddParameter(SDKType_String, SDKPass_Pointer);
PrepSDKCall_AddParameter(SDKType_String, SDKPass_Pointer);
PrepSDKCall_SetReturnInfo(SDKType_String, SDKPass_Pointer);
SDK_KV_GetString = EndPrepSDKCall();
if( SDK_KV_GetString == null )
SetFailState("Could not prep the \"KeyValues::GetString\" function.");
char key[MAX_STRING_LENGTH];
char value[MAX_STRING_LENGTH];
SDKCall(SDK_KV_GetString, g_PointerMission, value, sizeof(value), key, "N/A");
The "key" var is what it's looking for, the "value" var is what it's returning and the "N/A" is the default returned if not found. I think SM wiki explains all this which is where I learnt to SDKCall and return strings.
__________________