Skripta koju koristim:Svoj od 0
Detaljan opis problema:Ovako kako da namestim da vlasnik servera tj. admin lvl 1340 moze da teleportuje sve admin lvl znaci 1339,1338,1337,1336, itd.
Dio skripte:///
Neke slike/video za lakse dobivanje pomoci(neobavezno):///
Ps.Hvala Unapred
[Pomoc]/gethere
1,083
pregleda
8
postova
30. Mar. 2011.
Probaj ovo:
if(strcmp(cmd, "/getallhere", true) == 0)
{
if(IsPlayerConnected(playerid))
{
if(PlayerInfo >= 4)
{
GetPlayerName(playerid, sendername, sizeof(sendername));
for(new i = 0; i < MAX_PLAYERS; i ++)
{
if(IsPlayerConnected(i))
{
format(string, sizeof(string), "Administrator %s je teleportovao sve igrace do sebe.", sendername);
SendClientMessage(i, COLOR_RED, string);
new Float:ix, Float:iy, Float:iz;
GetPlayerPos(playerid, ix, iy, iz);
SetPlayerInterior(i, GetPlayerInterior(playerid));
SetPlayerPos(i, ix, iy, iz+1);
new PlayerName;
GetPlayerName(playerid, PlayerName, 30);
printf(" %s je koristio /getallhere da teleportira sve igrace", PlayerName);
}
}
}
else
{
SendClientMessage(playerid, COLOR_RED, "Nemas ovlascenje za tu komandu!");
}
}
else
{
SendClientMessage(playerid, COLOR_RED, "Moras biti logiran da bi koristio ovu komandu!");
}
return 1;
}30. Mar. 2011.
Quote from March 30, 2011, 12:50 pm:
Probaj ovo:
if(strcmp(cmd, "/getallhere", true) == 0)
{
if(IsPlayerConnected(playerid))
{
if(PlayerInfo >= 4)
{
GetPlayerName(playerid, sendername, sizeof(sendername));
for(new i = 0; i < MAX_PLAYERS; i ++)
{
if(IsPlayerConnected(i))
{
format(string, sizeof(string), "Administrator %s je teleportovao sve igrace do sebe.", sendername);
SendClientMessage(i, COLOR_RED, string);
new Float:ix, Float:iy, Float:iz;
GetPlayerPos(playerid, ix, iy, iz);
SetPlayerInterior(i, GetPlayerInterior(playerid));
SetPlayerPos(i, ix, iy, iz+1);
new PlayerName;
GetPlayerName(playerid, PlayerName, 30);
printf(" %s je koristio /getallhere da teleportira sve igrace", PlayerName);
}
}
}
else
{
SendClientMessage(playerid, COLOR_RED, "Nemas ovlascenje za tu komandu!");
}
}
else
{
SendClientMessage(playerid, COLOR_RED, "Moras biti logiran da bi koristio ovu komandu!");
}
return 1;
}Nece da radi ☹️
30. Mar. 2011.
Nikola_Hawks wrote on March 30, 2011, 12:50 pm:
Probaj ovo:
if(strcmp(cmd, "/getallhere", true) == 0)
{
if(IsPlayerConnected(playerid))
{
if(PlayerInfo >= 4)
{
GetPlayerName(playerid, sendername, sizeof(sendername));
for(new i = 0; i < MAX_PLAYERS; i ++)
{
if(IsPlayerConnected(i))
{
format(string, sizeof(string), "Administrator %s je teleportovao sve igrace do sebe.", sendername);
SendClientMessage(i, COLOR_RED, string);
new Float:ix, Float:iy, Float:iz;
GetPlayerPos(playerid, ix, iy, iz);
SetPlayerInterior(i, GetPlayerInterior(playerid));
SetPlayerPos(i, ix, iy, iz+1);
new PlayerName;
GetPlayerName(playerid, PlayerName, 30);
printf(" %s je koristio /getallhere da teleportira sve igrace", PlayerName);
}
}
}
else
{
SendClientMessage(playerid, COLOR_RED, "Nemas ovlascenje za tu komandu!");
}
}
else
{
SendClientMessage(playerid, COLOR_RED, "Moras biti logiran da bi koristio ovu komandu!");
}
return 1;
}Nece da radi ☹️
pokazi sta izbaci
30. Mar. 2011.
Kako si definirao admine?? ?? ?? Ako je ovo mod od nula mi ti nemozemo pomoci jer nisi stavio defnicije... lal
Godfather
Novi Član
240 / 250 XP
🌱Početnik(0)
2,079
Postovi:
24
Teme:
Pridružio se:Feb. 2011
30. Mar. 2011.
if(strcmp(cmd, "/gethere", true) == 0)
{
if(IsPlayerConnected(playerid))
{
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_GRAD2, "KORISTI: /gethere [playerid/PartOfName]");
return 1;
}
new Float:plocx,Float:plocy,Float:plocz;
new plo;
plo = ReturnUser(tmp);
if (IsPlayerConnected(plo))
{
if(plo != INVALID_PLAYER_ID)
{
if (PlayerInfo >= 1340 )
{
SendClientMessage(playerid, COLOR_GRAD1, "Ask the admin to goto you.");
return 1;
}
if (PlayerInfo >= 1 )
{
GetPlayerPos(playerid, plocx, plocy, plocz);
if(PlayerInfo > 0)
{
SetPlayerInterior(plo,PlayerInfo);
PlayerInfo = PlayerInfo;
PlayerInfo = PlayerInfo;
}
if(PlayerInfo == 0)
{
SetPlayerInterior(plo,0);
}
if(plocz > 930.0 && PlayerInfo == 0) //the highest land point in sa = 526.8
{
SetPlayerInterior(plo,1);
PlayerInfo = 1;
}
if (GetPlayerState(plo) == 2)
{
TelePos = 0.0;
TelePos = 0.0;
new tmpcar = GetPlayerVehicleID(plo);
SetVehiclePos(tmpcar, plocx, plocy+4, plocz);
}
else
{
SetPlayerPos(plo,plocx,plocy+2, plocz);
}
SendClientMessage(plo, COLOR_GRAD1, " Teleportiran si");
}
else
{
SendClientMessage(playerid, COLOR_GRAD1, " Nisi ovlasten!");
}
}
}
else
{
format(string, sizeof(string), " %d je offline.", plo);
SendClientMessage(playerid, COLOR_GRAD1, string);
}
}
return 1;
}
{
if(IsPlayerConnected(playerid))
{
tmp = strtok(cmdtext, idx);
if(!strlen(tmp))
{
SendClientMessage(playerid, COLOR_GRAD2, "KORISTI: /gethere [playerid/PartOfName]");
return 1;
}
new Float:plocx,Float:plocy,Float:plocz;
new plo;
plo = ReturnUser(tmp);
if (IsPlayerConnected(plo))
{
if(plo != INVALID_PLAYER_ID)
{
if (PlayerInfo >= 1340 )
{
SendClientMessage(playerid, COLOR_GRAD1, "Ask the admin to goto you.");
return 1;
}
if (PlayerInfo >= 1 )
{
GetPlayerPos(playerid, plocx, plocy, plocz);
if(PlayerInfo > 0)
{
SetPlayerInterior(plo,PlayerInfo);
PlayerInfo = PlayerInfo;
PlayerInfo = PlayerInfo;
}
if(PlayerInfo == 0)
{
SetPlayerInterior(plo,0);
}
if(plocz > 930.0 && PlayerInfo == 0) //the highest land point in sa = 526.8
{
SetPlayerInterior(plo,1);
PlayerInfo = 1;
}
if (GetPlayerState(plo) == 2)
{
TelePos = 0.0;
TelePos = 0.0;
new tmpcar = GetPlayerVehicleID(plo);
SetVehiclePos(tmpcar, plocx, plocy+4, plocz);
}
else
{
SetPlayerPos(plo,plocx,plocy+2, plocz);
}
SendClientMessage(plo, COLOR_GRAD1, " Teleportiran si");
}
else
{
SendClientMessage(playerid, COLOR_GRAD1, " Nisi ovlasten!");
}
}
}
else
{
format(string, sizeof(string), " %d je offline.", plo);
SendClientMessage(playerid, COLOR_GRAD1, string);
}
}
return 1;
}
Morate biti prijavljeni da biste odgovorili na ovu temu.
Prijava