SA-MP Forums Archive
Whats wrong in here..? - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: Whats wrong in here..? (/showthread.php?tid=249734)



Whats wrong in here..? - anantanni - 20.04.2011

So this is a textdraw I just made; but i get a few errors when I try to compile.
Under ongamemodeinit
pawn Код:
new pnumber = PlayerInfo[pPnumber];
    new freq = PlayerInfo[pWalkieFreq];
    Textdraw0 = TextDrawCreate(478.000000, 126.000000, "WT Chan %s", freq);
    TextDrawBackgroundColor(Textdraw0, 255);
    TextDrawFont(Textdraw0, 1);
    TextDrawLetterSize(Textdraw0, 0.500000, 1.000000);
    TextDrawColor(Textdraw0, 8256255);
    TextDrawSetOutline(Textdraw0, 0);
    TextDrawSetProportional(Textdraw0, 1);
    TextDrawSetShadow(Textdraw0, 1);
    Textdraw1 = TextDrawCreate(479.000000, 143.000000, "Phone No. %s", pnumber);
    TextDrawBackgroundColor(Textdraw1, 255);
    TextDrawFont(Textdraw1, 1);
    TextDrawLetterSize(Textdraw1, 0.500000, 1.000000);
    TextDrawColor(Textdraw1, 8256255);
    TextDrawSetOutline(Textdraw1, 0);
    TextDrawSetProportional(Textdraw1, 1);
    TextDrawSetShadow(Textdraw1, 1);
Errors -
Код:
D:\VERY IMPORTANT STUFF\EL-RP\gamemodes\el-rp.pwn(6868) : error 033: array must be indexed (variable "-unknown-")
D:\VERY IMPORTANT STUFF\EL-RP\gamemodes\el-rp.pwn(6869) : error 032: array index out of bounds (variable "PlayerInfo")
D:\VERY IMPORTANT STUFF\EL-RP\gamemodes\el-rp.pwn(6869) : error 033: array must be indexed (variable "-unknown-")
D:\VERY IMPORTANT STUFF\EL-RP\gamemodes\el-rp.pwn(6870) : warning 202: number of arguments does not match definition
D:\VERY IMPORTANT STUFF\EL-RP\gamemodes\el-rp.pwn(6878) : warning 202: number of arguments does not match definition
D:\VERY IMPORTANT STUFF\EL-RP\gamemodes\el-rp.pwn(6869) : warning 204: symbol is assigned a value that is never used: "freq"
D:\VERY IMPORTANT STUFF\EL-RP\gamemodes\el-rp.pwn(6868) : warning 204: symbol is assigned a value that is never used: "pnumber"
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


3 Errors.
Lines -
pawn Код:
Line 6868 - new pnumber = PlayerInfo[pPnumber];
Line 6869 - new freq = PlayerInfo[pWalkieFreq];
Line 6870 - Textdraw0 = TextDrawCreate(478.000000, 126.000000, "WT Chan %s", freq);
Line 6878 - Textdraw1 = TextDrawCreate(479.000000, 143.000000, "Phone No. %s", pnumber);
Help appreciated.


Re: Whats wrong in here..? - anantanni - 20.04.2011

Lemme go and test :P Thanks