#9

now my command looks like that:

Код:
	public OnPlayerCommandText(playerid, cmdtext[])
	{
	if (strcmp(cmdtext"/buylevel", true) == 0;
	{
    gPlayerMoney[playerid] = GetPlayerMoney(playerid);
    if (GetPlayerMoney(playerid) >= 250000)
    {
      gPlayerLevel[playerid] += 1;
      SetPlayerMoney(playerid, gPlayerMoney[playerid] - 250000);
    }
    return 1;
  }
  if (strcmp(cmdtext"/flip", true) == 0)
  {
    if (gPlayerLevel[playerid] > 1)
    {
      SendClientMessage(playerid, 0xFFFFFFFF, "I just... flipped?");
      return 1;
    }
    else
      return SendClientMessage(playerid, 0xFFFFFFFF, "You are not high enough level to use this!");
  }
}
but i still got errors:

Код:
C:\Documents and Settings\Install\Desktop\HOSTS\gamemodes\xlight.pwn(1127) : error 001: expected token: ",", but found "-string-"
C:\Documents and Settings\Install\Desktop\HOSTS\gamemodes\xlight.pwn(1127) : warning 215: expression has no effect
C:\Documents and Settings\Install\Desktop\HOSTS\gamemodes\xlight.pwn(1127) : warning 215: expression has no effect
C:\Documents and Settings\Install\Desktop\HOSTS\gamemodes\xlight.pwn(1127) : error 001: expected token: ";", but found ")"
C:\Documents and Settings\Install\Desktop\HOSTS\gamemodes\xlight.pwn(1127) : error 029: invalid expression, assumed zero
C:\Documents and Settings\Install\Desktop\HOSTS\gamemodes\xlight.pwn(1127) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


4 Errors.
all warnings and errors are on this line:

Код:
if (strcmp(cmdtext"/buylevel", true) == 0;
If it's important - my gm is made from sftdm!

Reply


Messages In This Thread
Help - by cigo - 04.06.2009, 14:22
Re: Help - by Weirdosport - 04.06.2009, 14:27
Re: Help - by cigo - 04.06.2009, 16:30
Re: Help - by efeX - 04.06.2009, 17:26
Re: Help - by Weirdosport - 04.06.2009, 17:54
Re: Help - by cigo - 04.06.2009, 18:22
Re: Help - by samgreen - 04.06.2009, 19:29
Re: Help - by efeX - 04.06.2009, 20:12
Re: Help - by cigo - 04.06.2009, 21:07
Re: Help - by HuRRiCaNe - 04.06.2009, 21:19

Forum Jump:


Users browsing this thread: 1 Guest(s)