Hello,van egy kis errorom strtok-al.
Parancs:
Természetesen ott van ez az OnPlayerCommandText alatt:
new cmd[128], idx;
cmd = strtok(cmdtext, idx);
if(!strcmp(cmdtext, \"/gotovip\", true))
{
if(IsPlayerVipType(playerid,2))
{
new tmp[256];
tmp = strtok( cmdtext, idx );
if ( !strlen( tmp ) ) { return 1; }
new Float:X, Float:Y, Float:Z;
if ( GetPlayerVehicleID( playerid ) )
{
GetPlayerPos( strval(tmp), X, Y, Z );
SetVehiclePos( GetPlayerVehicleID(playerid), X+2, Y+2, Z );
} else {
GetPlayerPos( strval(tmp), X, Y, Z );
SetPlayerPos( playerid, X+2, Y+2, Z );
}
}
else SendClientMessage(playerid, 0xAA3333AA, \"ERROR: Nem vagy Silver vagy Gold vip tag!\");
return 1;
}
Error:
error 047: array sizes do not match, or destination array is too small