SA-MP Forums Archive
Error 29 - 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)
+--- Thread: Error 29 (/showthread.php?tid=637609)



Error 29 - help... - Ramboi - 18.07.2017

I have been trying to fix this for at least 20 minutes, I haven't found any useful topics about it either...


Quote:

: warning 235: public function lacks forward declaration (symbol "OnPlayerModeInit")
: error 029: invalid expression, assumed zero
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase

1 Error.


Code:
Quote:

public OnPlayerModeInit()
{
SetGameModeText(GameMode);
return;
}


public OnPlayerRequestClass(playerid, classid)
{
SetSpawnInfo(playerid, 0, 121, Spawn_X, Spawn_Y, Spawn_Z, 0, -1, ,-1 ,-1 ,-1 ,-1 ,-1);ERROR 29 ON THIS LINE
GivePlayerMoney(playerid, 100);
SpawnPlayer(playerid);
return 1;
}




Re: Error 29 - AbyssMorgan - 18.07.2017

OnGameModeInit


Re: Error 29 - Ramboi - 18.07.2017

Quote:
Originally Posted by AbyssMorgan
Посмотреть сообщение
OnGameModeInit
Thanks, how do I fix the error now?


Re: Error 29 - Rolux - 18.07.2017

You had a double comma.

Yours:
Quote:

SetSpawnInfo(playerid, 0, 121, Spawn_X, Spawn_Y, Spawn_Z, 0, -1, ,-1 ,-1 ,-1 ,-1 ,-1);

Fixed:
Quote:

SetSpawnInfo(playerid, 0, 121, Spawn_X, Spawn_Y, Spawn_Z, 0, -1,-1 ,-1 ,-1 ,-1 ,-1);




Re: Error 29 - Ramboi - 18.07.2017

+REP for you guys, thanks for the quick replies!