10.04.2014, 19:13
pawn Код:
CMD:tvl(playerid,params[])
{
new Float:CPos[3];
if(PauloInfo[playerid][pAdmin] < 1)
return SCM(playerid, COR_CINZA1, "Vocк nгo tem permissгo para usar esse comando!");
{
if(Espiando[playerid] == false)
{
GetPlayerName(playerid,pNome(iddele),24);
if(sscanf(params,"u",iddele)) return SendClientMessage(playerid,-1,"use /tvl [id]");
TogglePlayerSpectating(playerid, 1);
PlayerSpectatePlayer(playerid,iddele);
SetPlayerInterior(playerid, GetPlayerInterior(iddele));
}
else
{
GetPlayerPos(playerid,CPos[0],CPos[1],CPos[2]);
SetPVarFloat(playerid,"xcpos",Cpos[0]),SetPVarFloat(playerid,"ycpos",CPos[1]),SetPVarFloat(playerid,"zcpos",CPos[2]);
TogglePlayerSpectating(playerid, 1);
PlayerSpectateVehicle(playerid, GetPlayerVehicleID(iddele));
format(String,60,"Vocк estб espiando o jogador %s (ID : %d )",playerid,iddele);
SCM(playerid,-1,String);
return Espiando[playerid] = true;
}
return 1;
}
CMD:tvd(playerid,params[])
{
if(PauloInfo[playerid][pAdmin] < 1)
return SCM(playerid, COR_CINZA1, "Vocк nгo tem permissгo para usar esse comando!");
{
SetPlayerPos(playerid,GetPVarFloat(playerid,"xcpos"),GetPVarFloat(playerid,"ycpos"),GetPVarFloat(playerid,"zcpos"));
Espiando[playerid] = false;
TogglePlayerSpectating(playerid,0);
return 1;
}
}