SA-MP Forums Archive
Error - Im not understanding why? - 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: Error - Im not understanding why? (/showthread.php?tid=72442)



Error - Im not understanding why? - Lynx. - 08.04.2009

Quote:

C:\Users\test.pwn(10617) : error 001: expected token: ")", but found "{"
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase


1 Error.


Quote:

Line 10617:
public OnPlayerRegister(playerid, password[]
{
if(IsPlayerConnected(playerid))
{
MySQLCheckConnection();
new playername3[MAX_PLAYER_NAME];
GetPlayerName(playerid, playername3, sizeof(playername3));
new newaccountsqlid = MySQLCreateAccount(playername3, password);
if (newaccountsqlid != 0)
{


Why am i getting an error?


Re: Error - Im not understanding why? - HB - 08.04.2009

The error says this: He wants to see a ) but sees a {.

So go to the line and replace { with )


Re: Error - Im not understanding why? - westre - 08.04.2009

Quote:
Originally Posted by Lynx.
Quote:

C:\Users\test.pwn(10617) : error 001: expected token: ")", but found "{"
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase


1 Error.


Quote:

Line 10617:
public OnPlayerRegister(playerid, password[]
{
if(IsPlayerConnected(playerid))
{
MySQLCheckConnection();
new playername3[MAX_PLAYER_NAME];
GetPlayerName(playerid, playername3, sizeof(playername3));
new newaccountsqlid = MySQLCreateAccount(playername3, password);
if (newaccountsqlid != 0)
{


Why am i getting an error?
Код:
public OnPlayerRegister(playerid, password[])
{
	if(IsPlayerConnected(playerid))
	{
		MySQLCheckConnection();
		new playername3[MAX_PLAYER_NAME];
		GetPlayerName(playerid, playername3, sizeof(playername3));
		new newaccountsqlid = MySQLCreateAccount(playername3, password);
		if (newaccountsqlid != 0)
You forgot a ) after password[].


Re: Error - Im not understanding why? - Lynx. - 08.04.2009

Ahhh Thanks.



Re: Error - Im not understanding why? - Lynx. - 08.04.2009

Ahhh Thanks.



Re: Error - Im not understanding why? - Rks25 - 08.04.2009

Double post?


Re: Error - Im not understanding why? - Lynx. - 09.04.2009

Quote:
Originally Posted by Rk_
Double post?
It was a mistake, if i knew how to delete it, i would.