error 001: expected token: ";", but found "new"
#1

Guys help me please, I was making a Maths Question(something like contest...) and I got this error:
pawn Код:
C:\Documents and Settings\Alex\Desktop\SA-MP Server\gamemodes\XtremeGame.pwn(24) : error 001: expected token: ";", but found "new"
Can you help me? Those are line 24-32. (The Questions):
pawn Код:
new MathsQuestions[][] = {
    "How much is 100+132+32?",
    "How much is 50+30+10?",
    "How much is 10x10+10?",
    "How much is 2000+3000+1400?",
    "How much is 43719283712+1?", // I know this is weird lol.
    "How much is 340+340?",
    "How much is 200+130+320?"
};
Reply
#2

You need to add a ' ; ' to whatever is before line 24
Reply
#3

pawn Код:
new MathsQuestions[7][0] = {
    "How much is 100+132+32?",
    "How much is 50+30+10?",
    "How much is 10x10+10?",
    "How much is 2000+3000+1400?",
    "How much is 43719283712+1?", // I know this is weird lol.
    "How much is 340+340?",
    "How much is 200+130+320?"
};
Try this, and tell me if you still get that error.
Reply
#4

what do you have before MathsQuestions array?
Reply
#5

Thanks. I had
pawn Код:
new MathsAnswer = -1 // (without ;)
and I added it, no errors. Thank you very much Shadow-.
Reply
#6

Quote:
Originally Posted by bestr32
Посмотреть сообщение
Thanks. I had
pawn Код:
new MathsAnswer = -1 // (without ;)
and I added it, no errors. Thank you very much Shadow-.
No Problem.

Xtreme_playa; Why would you even bother commenting if you didn't read the error? EVEN though the error is in the title. :S
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)