[Ajuda] teleporte so para admin
#1

Galera como transforma esse teleporte so pra admins,


Код:
if(strcmp(cmdtext,"/admprof",true)==0)
	{
	new vehicleid = GetPlayerVehicleID(playerid);
	new State = GetPlayerState(playerid);
	if(IsPlayerInAnyVehicle(playerid) && State == PLAYER_STATE_DRIVER)
	{
	GameTextForPlayer(playerid,"Bem vindo admins",4000,6);
	return SetVehiclePos(vehicleid,1138.8042,-1760.5007,13.5942);
	}
	SetPlayerPos(playerid,1138.8042,-1760.5007,13.5942);
	GameTextForPlayer(playerid,"Bem vindo admins",4000,6);
	return 1;
	}
Reply
#2

posta sua varialvel de admin '-'

caso queira sу pra admin rcon

pawn Код:
if(strcmp(cmdtext,"/admprof",true)==0)
{
   new vehicleid = GetPlayerVehicleID(playerid);
   new State = GetPlayerState(playerid);
   if(!IsPlayerAdmin(playerid)) return SendClientMessage(playerid, -1, "voce nгo й adm rcon...");
   if(IsPlayerInAnyVehicle(playerid) && State == PLAYER_STATE_DRIVER)
   {
      GameTextForPlayer(playerid,"Bem vindo admins",4000,6);
      return SetVehiclePos(vehicleid,1138.8042,-1760.5007,13.5942);
   }
   SetPlayerPos(playerid,1138.8042,-1760.5007,13.5942);
   GameTextForPlayer(playerid,"Bem vindo admins",4000,6);
   return 1;
}
Reply
#3

pawn Код:
if(strcmp(cmdtext,"/admprof",true)==0)
    {
    if(IsPlayerAdmin(playerid)) // verifica se estб logado na rcon
        {
            SendClientMessage(playerid,-1,"Vocк se teleportou admin.");
        }
        else
        {
            SendClientMessage(playerid,-1,"Vocк nгo й admin");
        }
    return 1;
    }
Reply
#4

OBrigado vlw deu certo.
Reply


Forum Jump:


Users browsing this thread: 2 Guest(s)