02.04.2011, 23:07
I have an array with an enumeration:
The compiler didn't complain about that code and it was working fine (the textdraw was working). Then I tried to add a new textdraw called "WEBSITE":
And got these errors:
Lines 219 - 220:
Other lines:
Can anyone help me please?
pawn Код:
enum
Enumeration
{
Text:CLOCK[MAX_PLAYERS] // A textdraw showing a different clock for each player.
};
new TD_Array[Enumeration];
pawn Код:
enum
Enumeration
{
Text:CLOCK[MAX_PLAYERS], // A textdraw showing a different clock for each player.
Text:WEBSITE // Textdraw showing the server website to all the players.
};
new TD_Array[Enumeration];
Код:
Line(219) : error 001: expected token: "-identifier-", but found "-string-" Line(220) : error 010: invalid function or declaration Line(442) : error 001: expected token: "-string end-", but found "-identifier-" Line(443) : error 001: expected token: "-string end-", but found "-identifier-" Line(444) : error 001: expected token: "-string end-", but found "-identifier-" Line(445) : error 001: expected token: "-string end-", but found "-identifier-" Line(446) : error 001: expected token: "-string end-", but found "-identifier-" Line(447) : error 001: expected token: "-string end-", but found "-identifier-" Line(448) : error 001: expected token: "-string end-", but found "-identifier-" Line(449) : error 001: expected token: "-string end-", but found "-identifier-" Line(450) : error 001: expected token: "-string end-", but found "-identifier-" Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 11 Errors.
pawn Код:
enum
TextDrawGroups
{
Text:CLOCK[MAX_PLAYERS], // 219
Text:WEBSITE // 220
};
pawn Код:
TextDraw[WEBSITE] = TextDrawCreate(141.000000, 420.000000, "thelsw.com");
TextDrawAlignment(TextDraw[WEBSITE], 3);
TextDrawBackgroundColor(TextDraw[WEBSITE], BLACK);
TextDrawFont(TextDraw[WEBSITE], 1);
TextDrawLetterSize(TextDraw[WEBSITE], 0.57, 2.8);
TextDrawColor(TextDraw[WEBSITE], PlayerColor[random(sizeof(PlayerColor))]);
TextDrawSetOutline(TextDraw[WEBSITE], 1);
TextDrawSetProportional(TextDraw[WEBSITE], 1);
TextDrawShowForAll(TextDraw[WEBSITE]);