error 012: invalid function call
#1

pawn Код:
if(killerid != INVALID_PLAYER_ID)
    {
        new text[128];
        KillStreak[killerid] ++;
        if(KillStreak[killerid] == 3)
        {
            format(text, sizeof(text), "** %s Triple kill!! (3 killing spree)!", Name(killerid));
            SendClientMessageToAll(C_CYAN, text);
            SendClientMessage(killerid, C_LBLUE, "You get $1500 and +2 score! (killing spree bonus)");
            GivePlayerMoney(killerid, 1500);
            GivePlayerScore(killerid, 2);
        }
        if(KillStreak[killerid] == 5)
        {
            format(text, sizeof(text), "** %s Killing spree!! (5 killing spree)!", Name(killerid));
            SendClientMessageToAll(C_CYAN, text);
            SendClientMessage(killerid, C_LBLUE, "You get $2500 and +3 score! (killing spree bonus)");
            GivePlayerMoney(killerid, 2500);
            GivePlayerScore(killerid, 3);
        }
        if(KillStreak[killerid] == 10)
        {
            format(text, sizeof(text), "** %s Rampage!! (10 killing spree)!", Name(killerid));
            SendClientMessageToAll(C_CYAN, text);
            SendClientMessage(killerid, C_LBLUE, "You get $5000 and +4 score! (killing spree bonus)");
            GivePlayerMoney(killerid, 5000);
            GivePlayerScore(killerid, 4);
        }
        if(KillStreak[killerid] == 15)
        {
            format(text, sizeof(text), "** %s Killtacular!! (15 killing spree)!", Name(killerid));
            SendClientMessageToAll(C_CYAN, text);
            SendClientMessage(killerid, C_LBLUE, "You get $7500 and +6 score! (killing spree bonus)");
            GivePlayerMoney(killerid, 7500);
            GivePlayerScore(killerid, 6);
        }
        if(KillStreak[killerid] == 20)
        {
            format(text, sizeof(text), "** %s Killimanjaro!! (20 killing spree)!", Name(killerid));
            SendClientMessageToAll(C_CYAN, text);
            SendClientMessage(killerid, C_LBLUE, "You get $12500 and +10 score! (killing spree bonus)");
            GivePlayerMoney(killerid, 12500);
            GivePlayerScore(killerid, 10);
        }
        if(KillStreak[killerid] == 25)
        {
            format(text, sizeof(text), "** %s Hell raiser!! (25 killing spree)!", Name(killerid));
            SendClientMessageToAll(C_CYAN, text);
            SendClientMessage(killerid, C_LBLUE, "You get $20000 and +15 score! (killing spree bonus)");
            GivePlayerMoney(killerid, 20000);
            GivePlayerScore(killerid, 15);
        }
    }
And these are the errors im getting

Код:
C:\Documents and Settings\Owner\Desktop\test\gamemodes\DDPTDM.pwn(294) : error 012: invalid function call, not a valid address
C:\Documents and Settings\Owner\Desktop\test\gamemodes\DDPTDM.pwn(294) : warning 215: expression has no effect
C:\Documents and Settings\Owner\Desktop\test\gamemodes\DDPTDM.pwn(294) : error 001: expected token: ";", but found ")"
C:\Documents and Settings\Owner\Desktop\test\gamemodes\DDPTDM.pwn(294) : error 029: invalid expression, assumed zero
C:\Documents and Settings\Owner\Desktop\test\gamemodes\DDPTDM.pwn(294) : fatal error 107: too many error messages on one line

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


4 Errors.
Reply
#2

Please post the error line, and also, change the title of your topic, it's way to long!
Reply
#3

Nevermind this
Reply
#4

error line

pawn Код:
format(text, sizeof(text), "** %s Triple kill!! (3 killing spree)!", Name(killerid));
And sorry about that i will change this title. was an accident.
Reply
#5

Hmm, show us function Name.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)