Amint hazaérek megoldom neked
pLastPos[3],pLastInterior,pLastWorld
CMD:tv(playerid,params[]){ if(pInfo[playerid][pAdmin] >= 1 && pInfo[playerid][pALogin] == 1 || pInfo[playerid][pOrokAs] > 0 || pInfo[playerid][pAs] > 0) { if(sscanf(params,"u", id)) return SendClientMessage(playerid, PIROS, "Használat: /tv < Név / Id >"); if(!IsPlayerConnected(id)) return SendClientMessage(playerid, PIROS, "A játékos nem elérhető!"); if(GetPlayerState(playerid) != PLAYER_STATE_SPECTATING) { GetPlayerPos(playerid, pInfo[playerid][pLastPos][0], pInfo[playerid][pLastPos][1], pInfo[playerid][pLastPos][2]); pInfo[playerid][pLastInterior] = GetPlayerInterior(playerid); pInfo[playerid][pLastWorld] = GetPlayerVirtualWorld(playerid); } if(GetPlayerVehicleID(id) > 0) { TogglePlayerSpectating(playerid, 1); PlayerSpectateVehicle(playerid, GetPlayerVehicleID(id)); } else { TogglePlayerSpectating(playerid, 1); PlayerSpectatePlayer(playerid, id); } SendClientMessage(playerid, PIROS, "Megfigyelés bekapcsolva!"); SetPlayerInterior(playerid, GetPlayerInterior(id)); SetPlayerVirtualWorld(playerid, GetPlayerVirtualWorld(id)); } else { SendClientMessage(playerid, PIROS, "Nem vagy 1* Admin!"); } return 1;}CMD:tvki(playerid){ if(pInfo[playerid][pAdmin] >= 1 && pInfo[playerid][pALogin] == 1 || pInfo[playerid][pOrokAs] > 0 || pInfo[playerid][pAs] > 0 || pInfo[playerid][pVIP2] == 5) { SendClientMessage(playerid, PIROS, "Megfigyelés kikapcsolva!"); TogglePlayerSpectating(playerid, 0); SetPlayerPos(playerid, pInfo[playerid][pLastPos][0], pInfo[playerid][pLastPos][1], pInfo[playerid][pLastPos][2]); SetPlayerVirtualWorld(playerid, pInfo[playerid][pLastWorld]); SetPlayerInterior(playerid, pInfo[playerid][pLastInterior]); Speec[playerid] = 1; } else { SendClientMessage(playerid, PIROS, "Nem vagy 1* Admin!"); } return 1;}