2135001270701
Ученик
/cput
/cput - это команда позволяет ментам запихнуть преступника в машину...
/cput - это команда позволяет ментам запихнуть преступника в машину...
PHP:
if(strcmp(cmd, "/cput", true) == 0)//
{
tmp = strtok(cmdtext, idx);
giveplayerid = ReturnUser(tmp);
tmp = strtok(cmdtext, idx);
new seatid = strval(tmp);
if(IsACop(playerid))
{
if(PlayerTied[playerid] > 0)
{
SendClientMessage(playerid, COLOR_RED, "Вы связаны!");
return 1;
}
if(PlayerCuffed[giveplayerid] > 0)
{
SendClientMessage(playerid, COLOR_RED, "Игрок не в наручниках!");
return 1;
}
if(!IsPlayerInAnyVehicle(playerid))
{
SendClientMessage(playerid,COLOR_GREY,"Вы не в машине!");
return 1;
}
if(giveplayerid == playerid) return SendClientMessage(playerid, COLOR_GREY, "Нельзя запихнуть самого себя");
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_RED, "Используйте: /cput [id] [место (1-3)]");
return 1;
}
if(!ProxDetectorS(8.0, playerid, giveplayerid))return SendClientMessage(playerid, COLOR_GRAD1, "Игрок не рядом с вами!");
{
PutPlayerInVehicle(giveplayerid, vehicleid, seatid);
return 1;
}
}
return 1;
}
Последнее редактирование:
