Jump to content
Hostul a fost schimbat. Daca vedeti serverul offline readaugati rpg.b-zone.ro sau 141.95.124.78:7777 in clientul de sa-mp ×

Error 035: argument type mistmatch (argument 1)!


Pupsic
 Share

Recommended Posts

public OnPlayerCommandText(playerid, cmdtext[])
{
    if (strcmp("/hrest", cmdtext, true, 10) == 0)
    {
        SetPlayerHealth(playerid, 100);
        SendClientMessage(playerid, 0xBA274CFF, "HP-ul tau a fost restaurat!");

        return 1;
    }
   if (strcmp("/bonus", cmdtext, true, 10) == 0)
    {
         GivePlayerMoney(playerid, 1000000);
         SetPlayerScore(playerid, 3);
         SendClientMessage(playerid, 0xBA274CFF, "Ai primit bonusul!");
         
        return 1;
    }
    
       else return SendClientMessage("Ai folosit deja comanda /Bonus, nu o mai poti folosi inca odata!");
        
    return 0;

}

 

 

 

 

ASTA E PROBLEMA AJUTATIMA PLSSS!

 

//C:\Users\andrian\Desktop\GM\gamemodes\grandlarc.pwn(116) : error 035: argument type mismatch (argument 1)//

 

Edited by Pupsic
Link to comment
Share on other sites

Salut, incearca asa:

 

CMD:bonus(playerid, params[])
{
    if(gPlayerLogged[playerid] == 0) return SendClientMessage(playerid, COLOR_LIGHTRED, "Trebuie sa te inregistrezi prima data!");
	if(IsPlayerConnected(playerid))
 	{
 	    if(BonusActiv > 0)
 	    {
 	    	if(PlayerInfo[playerid][pLevel] <= 2)
 	    	{
 	        	GivePlayerCash(playerid, 100);
 	        	PlayerInfo[playerid][pLevel] = 3;
 	        	Update(playerid, pLevelx);
 	        	Update(playerid, pCashx);
 	        	SetPlayerScore(playerid, PlayerInfo[playerid][pLevel]);
 	        	SendClientMessage(playerid, COLOR_LIGHTBLUE, "Ai primit 100$ si level 3 de bun venit!");
			}
			else return SendClientMessage(playerid, COLOR_LIGHTRED, "Nu poti folosi aceasta comanda daca ai level 3+ !");
		}
	}
	return 1;
}

Impreuna cu:

CMD:activatebonus(playerid, params[])
{
    if(gPlayerLogged[playerid] == 0) return SendClientMessage(playerid, COLOR_LIGHTRED, "Trebuie sa te inregistrezi prima data.");
	if(IsPlayerConnected(playerid))
 	{
 	    if (PlayerInfo[playerid][pAdmin] >= 4)
		{
		    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_ERROR, AdminOnly);
		}
	}
	return 1;
}

 

Edited by Jackson Brooklyn
Link to comment
Share on other sites

Guest
This topic is now closed to further replies.
 Share

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