Szerző Téma: CMD:Mentés  (Megtekintve 630 alkalommal)

CMD:Mentés
« Dátum: 2013. Január 06. - 21:54:04 »
0 Show voters
Sziasztok.!!
Ismét hozzátok fordulok egy kisebb nagyobb segítségben.
Ezt a parancsot:
 
CMD:ment(playerid, params[])
{
Ment(playerid), Betolt(playerid);
return SendClientMessage(playerid, NARANCS, \"A karaktered mentve!\");
}

 
Kellene úgy megcsinálni hogy Admin tudja használni, és az összes karaktert Mentse.! remélem megoldható elõre is köszönöm.!

Nem elérhető Zharko

  • 1955
  • Future House <3
    • Profil megtekintése
CMD:Mentés
« Válasz #1 Dátum: 2013. Január 06. - 22:05:10 »
0 Show voters
Idézetet írta: ~DuMBasS date=1357505644\" data-ipsquote-contentapp=\"forums\" data-ipsquote-contenttype=\"forums\" data-ipsquote-contentid=\"32060\" data-ipsquote-contentclass=\"forums_Topic
Sziasztok.!!
Ismét hozzátok fordulok egy kisebb nagyobb segítségben.
Ezt a parancsot:
 
CMD:ment(playerid, params[])
{
Ment(playerid), Betolt(playerid);
return SendClientMessage(playerid, NARANCS, \"A karaktered mentve!\");
}

 
Kellene úgy megcsinálni hogy Admin tudja használni, és az összes karaktert Mentse.! remélem megoldható elõre is köszönöm.!
 

CMD:ment(playerid, params[]) {
        if(!IsPlayerAdmin(playerid)) { SendClientMessage(playerid, -1, \"Nem vagy RCON adminisztrátor\"); }
        else {
                for(new i = 0; i < MAX_PLAYERS; ++i) {
                Ment(i);
                printf(\"%d. karakter mentve.\", i);
                }
        }
}

 
Így gondoltad?

CMD:Mentés
« Válasz #2 Dátum: 2013. Január 06. - 23:54:38 »
0 Show voters
nem pont rCon adminnal de ígyis megfelel. Köszönöm.

Nem elérhető Flash

  • 5726
  • (っ◕‿◕)っ
    • Profil megtekintése
CMD:Mentés
« Válasz #3 Dátum: 2013. Január 06. - 23:57:20 »
0 Show voters
Akkor:
 
CMD:ment(playerid) {
       for(new i = 0; i < MAX_PLAYERS; ++i) {
             if(!IsPlayerConnected(i)) continue;
             Ment(i);
             printf(\"%d. karakter mentve.\", i);
       }
       return 1;
}

Nem elérhető shadee

  • 1073
    • Profil megtekintése
CMD:Mentés
« Válasz #4 Dátum: 2013. Január 07. - 13:23:38 »
0 Show voters
Idézetet írta: Flash date=1357513040\" data-ipsquote-contentapp=\"forums\" data-ipsquote-contenttype=\"forums\" data-ipsquote-contentid=\"32060\" data-ipsquote-contentclass=\"forums_Topic
Akkor:
 
CMD:ment(playerid) {
       for(new i = 0; i < MAX_PLAYERS; ++i) {
             if(!IsPlayerConnected(i)) continue;
             Ment(i);
             printf(\"%d. karakter mentve.\", i);
       }
       return 1;
}

 

ez eleve már nemjó,mivel  csak ADMIN használhatja,itt csak lekéred h csatlakozva van e a játékos
 

 

Sziasztok.!!
Ismét hozzátok fordulok egy kisebb nagyobb segítségben.
Ezt a parancsot:
 
CMD:ment(playerid, params[])
{
Ment(playerid), Betolt(playerid);
return SendClientMessage(playerid, NARANCS, \"A karaktered mentve!\");
}

 
Kellene úgy megcsinálni hogy Admin tudja használni, és az összes karaktert Mentse.! remélem megoldható elõre is köszönöm.!
 
[/quote]
 
CMD:ment(playerid, params[]) {
        if(!PlayerInfo[playerid][pAdmin] >= szint) { SendClientMessage(playerid, -1, \"Nem vagy Admin\"); }
        else {
                for(new i = 0; i < MAX_PLAYERS; ++i) {
                Ment(i);
                printf(\"%d. karakter mentve.\", i);
                }
        }
}

 

[/quote]
Szint helyére,hogy hanyas adminszintõl lehessen használni.

 

SimplePortal 2.3.7 © 2008-2024, SimplePortal