Потратил 4 минуты драгоценного времени)
Code
#include <a_samp>
#pragma tabsize 0
forward TimerX(playerid);
public OnPlayerCommandText(playerid, cmdtext[])
{
new tmp[256], idx;
new rek[32];
rek = strtok(cmdtext, idx);
tmp = strtok(cmdtext, idx);
if(strcmp("/komanda", cmdtext, true, 10) == 0)
{
SetPlayerVirtualWorld(playerid,8);
SetTimer("TimerX",10000,1);
}
return 0;
}
public TimerX(playerid)
{
if(IsPlayerConnected(playerid))
{
SetPlayerVirtualWorld(playerid,0);
}
return 1;
}
strtok(const string[], &index)
{
new length = strlen(string);
while ((index < length) && (string[index] <= ' '))
{
index++;
}
new offset = index;
new result[20];
while ((index < length) && (string[index] > ' ') && ((index - offset) < (sizeof(result) - 1)))
{
result[index - offset] = string[index];
index++;
}
result[index - offset] = EOS;
return result;
}
GameTextForPlayer и все остальное вставь после SetPlayerVirtualWorld(playerid,0);