An undefined Playerid? o.o
#1

pawn Код:
CMD:Weloveben(cmdtext, params[])
{
    if(IsPlayerAdmin(playerid))
    {
      SendClientMessage(playerid, 0xFF00FFFF, "I love you too. Have sum moneh, dear admen.");
      GivePlayerMoney(playerid, 50000);
    }
    else if(!IsPlayerAdmin(playerid))
    {
      SendClientMessage(playerid, 0xFF00FFFF, "I love you too. Have sum moneh and have a great wank, dear playerboi.");
        GivePlayerMoney(playerid, 10);
        ApplyAnimation(playerid,"PAULNMAC","wank_loop",4,0,1,1,1,1,1);
    }
    return 1;
}
Код:
D:\Documents and Settings\Rizky\Bureaublad\weloveben command.pwn(92) : error 017: undefined symbol "playerid"
D:\Documents and Settings\Rizky\Bureaublad\weloveben command.pwn(94) : error 017: undefined symbol "playerid"
D:\Documents and Settings\Rizky\Bureaublad\weloveben command.pwn(95) : error 017: undefined symbol "playerid"
D:\Documents and Settings\Rizky\Bureaublad\weloveben command.pwn(97) : error 017: undefined symbol "playerid"
D:\Documents and Settings\Rizky\Bureaublad\weloveben command.pwn(99) : error 017: undefined symbol "playerid"
D:\Documents and Settings\Rizky\Bureaublad\weloveben command.pwn(100) : error 017: undefined symbol "playerid"
D:\Documents and Settings\Rizky\Bureaublad\weloveben command.pwn(101) : error 017: undefined symbol "playerid"
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


7 Errors.
Reply
#2

Change:
Quote:
Originally Posted by Ragidon
CMD:Weloveben(cmdtext, params[])
to:
pawn Код:
CMD:Weloveben(playerid, params[])
Reply
#3

Also, use just "else" instead of "else if".
Reply
#4

Thank you guys.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)