20.03.2018, 15:30
this is my mute command
but when i type for example : /tmute 0 15 test it returns Използвай: /tmute [playerid] [time] [reason]
can someone help me to fix that ?
Код:
if(strcmp(cmd,"/tmute",true) == 0)
{
if(pInfo[playerid][pAdmin] >= 2)
{
new id,minutes,reason[128];
if(sscanf(params,"uis[128]", id, minutes, reason)) return SendClientMessage(playerid,-1,"Използвай: /tmute [playerid] [time] [reason]");
pInfo[id][pMuted] = 1;
pInfo[id][pMutedTime] = minutes*1;
format(string,sizeof(string),"%s беше заглушен от администратор %s за %d минути[Причина: %s]",GetName(id),GetName(playerid),minutes,reason);
SendClientMessageToAll(0xFF0000FF,string);
SetTimerEx("CheckPlayerMute", 1000, 1, "d", id);
return 1;
}
else
{
SendClientMessage(playerid, 0xFF0000FF, "Нямаш права за да ползваш командата!");
return 1;
}
return 1;
}
can someone help me to fix that ?



