Jump to content

Yashin Adevaratu

Membru
  • Posts

    6
  • Joined

  • Last visited

Posts posted by Yashin Adevaratu

  1. Salut, astazi vreau sa va prezint un tutorial, cam cum puteti creea o comanda de tip /stopwar
    sa dati disable la war-uri, etc.

    Adaugam in gamemode pe la inceput:

    new stopwar;

    Mergem la OnGameModeIni si adaugam:

    stopwar = 0;

    Apoi mergem la comenzi si facem dupa urmatorul exemplu, 

    CMD:stopwar(playerid, params[]) {
    if(PlayerInfo[playerid][pAdmin] >= 5) {
    if(stopwar == 0)
    {
    stopwar = 1; // disable war
    //Aici adaugati mesaj daca vreti
    SCM(playerid, -1, "Ai dezactivat war-urile.");
    }
    else {
    stopwar = 0; // active war
    //Aici adaugati mesaj daca vreti
    SCM(playerid, -1, "Ai activat war-urile.");
    }
    }
    else return SCM(playerid, -1, "Trebuie sa fii admin pentru a putea folosi comanda asta!");
    return 1;
    }

    La comanda voastra de /attack adaugati urmatoarea verificare: 

    if(stopwar == 1) return SCM(playerid, -1, "War is disable.");

    E ceva basic, ceea ce oricine cu cunostinte minime in pawn poate face, succes.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue. For more details you can also review our Terms of Use and Privacy Policy.