Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- CMD:ir(playerid, params[])
- {
- new string[128];
- new interiorid;
- new Float:pX,
- Float:pY,
- Float:pZ;
- if(DylanInfo[playerid][dAdmin] <= 0) return SendClientMessage(playerid, Vermelho,"[ERRO]: Seu nível de Admin é insuficiente.");
- if(sscanf(params, "u", Outroplayerid)) return SendClientMessage(playerid, Branco, "Use: /ir [ID/Nome]");
- if(!IsPlayerConnected(Outroplayerid)) return SendClientMessage(playerid, Vermelho, "Jogador Invalido/ Não Conectado");
- if(IsPlayerInAnyVehicle(playerid)) {
- if(GetPlayerInterior(Outroplayerid) >= 1) return SendClientMessage(playerid, Vermelho, "Você não pode ir em um jogador que esteja em um iterior");
- GetPlayerName(Outroplayerid, NomedoCara, sizeof(NomedoCara));
- format(string, sizeof(string), "Você foi até: %s", NomedoCara);
- SendClientMessage(playerid, Verde_Folha, string);
- GetPlayerPos(Outroplayerid, pX, pY, pZ);
- SetVehiclePos(GetPlayerVehicleID(playerid), pX+1, pY+1, pZ);
- }
- if(!IsPlayerInAnyVehicle(playerid)) {
- GetPlayerName(Outroplayerid, NomedoCara, sizeof(NomedoCara));
- format(string, sizeof(string), "Você foi até: %s", NomedoCara);
- SendClientMessage(playerid, Verde_Folha, string);
- GetPlayerPos(Outroplayerid, pX, pY, pZ);
- SetPlayerPos(playerid, pX+1, pY+1, pZ);
- interiorid = GetPlayerInterior(Outroplayerid);
- SetPlayerInterior(playerid, interiorid);
- }
- return true;
- }
Advertisement
Add Comment
Please, Sign In to add comment