Jump to content
  • 0

Comanda /Bonus


Tibirogamer

Question

Problema intalnita (descriere): Comanda /bonus.
Ero(area / rile) / warning-(ul / urile):-
Liniile de cod / sursa / script-ul(obligatoriu):-
Imagini / Video (optional):-
Ati incercat sa rezolvati singur?: Comanda /bonus nu stiu cum sa o fac am incercat cateva variante pe net dar nu merge ma ajuta cineva?Va rog?Folosesc ZMCD.

Link to comment
Share on other sites

14 answers to this question

Recommended Posts

  • 0

Poftim : 

CMD:bonus(playerid, params[])
{
    if(gPlayerLogged[playerid] == 0) return SendClientMessage(playerid, COLOR_LIGHTRED, "You need to login first.");
    if(IsPlayerConnected(playerid))
     {
         if(BonusActiv > 0)
         {
             if(PlayerInfo[playerid][pLevel] <= 2)
             {
                 GivePlayerCash(playerid, 300000);
                 PlayerInfo[playerid][pLevel] = 3;
                 Update(playerid, pLevelx);
                 Update(playerid, pCashx);
                 SetPlayerScore(playerid, PlayerInfo[playerid][pLevel]);
                 SendClientMessage(playerid, COLOR_LIGHTBLUE, "Ai primit $300,000 si level 3 de bun venit!");
            }
            else return SendClientMessage(playerid, COLOR_LIGHTRED, "Nu poti folosi aceasta comanda daca ai level 3+ !");
        }
    }
    return 1;
}
CMD:activatebonus(playerid, params[])
{
    if(gPlayerLogged[playerid] == 0) return SendClientMessage(playerid, COLOR_LIGHTRED, "You need to login first.");
    if(IsPlayerConnected(playerid))
     {
         if (PlayerInfo[playerid][pAdmin] >= 6)
        {
            if(BonusActiv == 0)
             {
                 BonusActiv = 1;
                 SendClientMessage(playerid, COLOR_LIGHTBLUE, "Ai activat comanda /bonus!");
            }
            else
            {
                BonusActiv = 0;
                SendClientMessage(playerid, COLOR_LIGHTBLUE, "Ai dezactivat comanda /bonus!");
            }
        }
        else
        {
            SendClientMessage(playerid, COLOR_WHITE, AdminOnly);
        }
    }
    return 1;
}

Link to comment
Share on other sites

  • 0

La Copilare...

 

C:\Users\CV\Desktop\Comunitate Athlon\GAMEMODE SERVER\gamemodes\bugged.pwn(44157) : error 017: undefined symbol "gPlayerLogged"
C:\Users\CV\Desktop\Comunitate Athlon\GAMEMODE SERVER\gamemodes\bugged.pwn(44157) : warning 215: expression has no effect
C:\Users\CV\Desktop\Comunitate Athlon\GAMEMODE SERVER\gamemodes\bugged.pwn(44157) : error 001: expected token: ";", but found "]"
C:\Users\CV\Desktop\Comunitate Athlon\GAMEMODE SERVER\gamemodes\bugged.pwn(44157) : error 029: invalid expression, assumed zero
C:\Users\CV\Desktop\Comunitate Athlon\GAMEMODE SERVER\gamemodes\bugged.pwn(44157) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664              Copyright (c) 1997-2006, ITB CompuPhase


4 Errors.

 

Ma ajuta cineva ?Va rog.

 

Edited by Tibirogamer
Link to comment
Share on other sites

  • 0
Acum 2 ore, Tibirogamer a spus:

La Copilare...

 

C:\Users\CV\Desktop\Comunitate Athlon\GAMEMODE SERVER\gamemodes\bugged.pwn(44157) : error 017: undefined symbol "gPlayerLogged"
C:\Users\CV\Desktop\Comunitate Athlon\GAMEMODE SERVER\gamemodes\bugged.pwn(44157) : warning 215: expression has no effect
C:\Users\CV\Desktop\Comunitate Athlon\GAMEMODE SERVER\gamemodes\bugged.pwn(44157) : error 001: expected token: ";", but found "]"
C:\Users\CV\Desktop\Comunitate Athlon\GAMEMODE SERVER\gamemodes\bugged.pwn(44157) : error 029: invalid expression, assumed zero
C:\Users\CV\Desktop\Comunitate Athlon\GAMEMODE SERVER\gamemodes\bugged.pwn(44157) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664              Copyright (c) 1997-2006, ITB CompuPhase


4 Errors.

 

Ma ajuta cineva ?Va rog.

 

Pune cu ce ai tu inloc de "gPlayerLogged" pune ce ai tu un gm !

Link to comment
Share on other sites

  • 0
17 hours ago, MrAndy said:

Poftim : 

CMD:bonus(playerid, params[])
{
    if(gPlayerLogged[playerid] == 0) return SendClientMessage(playerid, COLOR_LIGHTRED, "You need to login first.");
    if(IsPlayerConnected(playerid))
     {
         if(BonusActiv > 0)
         {
             if(PlayerInfo[playerid][pLevel] <= 2)
             {
                 GivePlayerCash(playerid, 300000);
                 PlayerInfo[playerid][pLevel] = 3;
                 Update(playerid, pLevelx);
                 Update(playerid, pCashx);
                 SetPlayerScore(playerid, PlayerInfo[playerid][pLevel]);
                 SendClientMessage(playerid, COLOR_LIGHTBLUE, "Ai primit $300,000 si level 3 de bun venit!");
            }
            else return SendClientMessage(playerid, COLOR_LIGHTRED, "Nu poti folosi aceasta comanda daca ai level 3+ !");
        }
    }
    return 1;
}
CMD:activatebonus(playerid, params[])
{
    if(gPlayerLogged[playerid] == 0) return SendClientMessage(playerid, COLOR_LIGHTRED, "You need to login first.");
    if(IsPlayerConnected(playerid))
     {
         if (PlayerInfo[playerid][pAdmin] >= 6)
        {
            if(BonusActiv == 0)
             {
                 BonusActiv = 1;
                 SendClientMessage(playerid, COLOR_LIGHTBLUE, "Ai activat comanda /bonus!");
            }
            else
            {
                BonusActiv = 0;
                SendClientMessage(playerid, COLOR_LIGHTBLUE, "Ai dezactivat comanda /bonus!");
            }
        }
        else
        {
            SendClientMessage(playerid, COLOR_WHITE, AdminOnly);
        }
    }
    return 1;
}

Si tu crezi ca daca dai copy-paste din gm bigzone il ajuta? 

                                                                                                 

Link to comment
Share on other sites

  • 0

CMD:bonus(playerid, params[])
   {
            if(PlayerInfo[playerid][pLevel] == 1 )
         {
            GivePlayerCash(playerid, 5000000);
            new playerlevel = PlayerInfo[playerid][pLevel];
            PlayerInfo[playerid][pLevel] = playerlevel + 2;
            SetPlayerScore(playerid,PlayerInfo[playerid][pLevel]);
            SendClientMessage(playerid, COLOR_LIGHTBLUE, "*Ai primit un cadou din partea staffului");
         }
         else
         {
            SendClientMessage(playerid,COLOR_RED,"Cadoul este doar pentru incepatori (Level 1)!");
            }
      return 1;
      }

Link to comment
Share on other sites

  • 0
Just now, Mihail. said:

CMD:bonus(playerid, params[])
   {
            if(PlayerInfo[playerid][pLevel] == 1 )
         {
            GivePlayerCash(playerid, 5000000);
            new playerlevel = PlayerInfo[playerid][pLevel];
            PlayerInfo[playerid][pLevel] = playerlevel + 2;
            SetPlayerScore(playerid,PlayerInfo[playerid][pLevel]);
            SendClientMessage(playerid, COLOR_LIGHTBLUE, "*Ai primit un cadou din partea staffului");
         }
         else
         {
            SendClientMessage(playerid,COLOR_RED,"Cadoul este doar pentru incepatori (Level 1)!");
            }
      return 1;
      }

Asta cred ca este comanda cea buna, ce gamemode folosesti ?

Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
×
×
  • 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.