13.01.2013, 02:42
pawn Код:
new Bloqueado[MAX_PLAYERS];
CMD:ir(playerid, params[]) {
if ( PlayerNaoEAdmin ) return SendClientMessage(playerid, 0xFF0000, "Vocк nгo й administrador!");
new
id,
Float: x,
Float: y,
Float: z;
if( sscanf( params, "u",id ) ) return SendClientMessage(playerid, 0xFF0000, "Use: /ir [id]");
if ( !IsPlayerConnected( id ) ) return SendClientMessage(playerid, 0xFF0000, "Jogador nгo esta conectado");
if ( Bloqueado[id] == 1 ) return SendClientMessage(playerid, 0xFF0000, "[ ! ] Este admin bloqueou o /ir");
GetPlayerPos(id, x, y, z);
SetPlayerInterior(playerid, GetPlayerInterior(id) );
SetPlayerPos(playerid, x, y, z);
SendClientMessage(playerid, "Teleportado com sucesso!");
return true;
}
CMD:blockir(playerid) {
if ( PlayerNaoEAdmin ) return SendClientMessage(playerid, 0xFF0000, "Vocк nгo й administrador!");
if ( Bloqueado[playerid] == 0 ) {
Bloqueado[playerid] = 1;
SendClientMessage(playerid, 0xFF0000, "Vocк bloqueou а vinda de Admins atй vocк!");
}
else {
Bloqueado[playerid] = 0;
SendClientMessage(playerid, 0xFF0000, "Vocк liberou а vinda de Admins atй vocк!");
}
return true;
}
Nota: Adapte "PlayerNaoEAdmin" de agordo com seu gamemode.
Erros, Ajustes ? Me avise!
Espero ter ajudado!
