you can pass anything for the void parameter, so
you have to cast the void* parameter to whatever you need it to be
like (int)param
or (string)param
GetData() and CallFunction() are exactly the same as far as I can tell. There are two of them for logic and readablility
pretty straightforward so far,
however,
if you happen to need more than one parameter there are three ways I thought of that would work
I never tried it but I believe you should be able to make a struct in both the calling function and in the body of GetData(), and cast it to that if you need multiple parameters
alternatively, you can pass the parameter (this)
and cast it to *CRunObject
then you can do param->GetData(whatever) and have GetData functions in the calling object that will return the parameters you need one by one
and lastly, you can just set up multiple functions that append all the needed parameters
like
long ExtObject::GetData(int id, void* param)
{
int param1;
string param2;
switch (id)
{
case 1:
{
param1 = (int)param;
return 0;
break;
}
case 2:
{
param2 = (string)param;
return 0;
break;
}
case 3:
{
return param1 + param2;
break;
}
}[/code:1pl9i59i]
btw, if you're on right now, you should go to chat
we can be plugin code buddies
edit:: and if it's not top secret, may I ask what type of plugin you're developing?