Jump to content
Autentificarea cu Google și Facebook nu mai este disponibilă. ×
  • 0

Question

Posted (edited)

vreau sa fac un system de bonus pentru incepatori si daca am level 5 si dau /bonus imi ea level 4 si imi da 2 de-ce oare

CMD:bonus(playerid, params[]){
    {
        if(IsPlayerConnected(playerid))
        {

              
                playerVariables[playerid][pLevel] = 2;
    playerVariables[playerid][pCash] = 500000;
                SendClientMessage(playerid, COLOR_LIGHTBLUE, "Felicitari, ai primit Level 2 + $500,000  din partea staff-ului !");
            }
            else
            {
            SendClientMessage(playerid, COLOR_GREEN, "{CCCCCC}[BONUS] Ai folosit deja aceasta comanda sau nu ai level 1 !");
            }
        }
        return 1;
    } Ma puteti Ajuta multumesc!

Edited by Geani

FiveGame  Lands

Pawno Developer, Mapping , Scripter

Since 2016

2 answers to this question

Recommended Posts

  • 1
Posted
CMD:bonus(playerid, params[]){
    {
        if(IsPlayerConnected(playerid))
        {
			if(playerVariables[playerid][pLevel] == 1)
			{
                playerVariables[playerid][pLevel] = 2;
    			playerVariables[playerid][pCash] = 500000;
                SendClientMessage(playerid, COLOR_LIGHTBLUE, "Felicitari, ai primit Level 2 + $500,000  din partea staff-ului !");
            }
            else
            {
            SendClientMessage(playerid, COLOR_GREEN, "{CCCCCC}[BONUS] Ai folosit deja aceasta comanda sau nu ai level 1 !");
            }
        }
        return 1;
    }

Tu ai pus condiția la IsPlayerConnected. Acum ar trebui să meargă, condiția este să aibă level 1, în caz contrar să-i afișeze mesajul acela.

  • 0
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.