OnGameModeInit Error? - 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: OnGameModeInit Error? (
/showthread.php?tid=349526)
OnGameModeInit Error? -
NeymarJr - 09.06.2012
I compiled my script and I got this:
Код:
error 025: function heading differs from prototype
and thats from this line:
Код:
public OnGameModeInit(playerid)
Help please? I got that because I had to put playerid between the brackets cause i put RemoveBuildingForPlayer
Re: OnGameModeInit Error? -
Calgon - 09.06.2012
"playerid" does not exist in OnGameModeInit. You can't reference a playerid because when OnGameModeInit executes, no players have connected. Instead, you can copy your 'RemoveBuildingForPlayer' code in to OnPlayerConnect.
Simply change the public line to:
Re: OnGameModeInit Error? -
FalconX - 09.06.2012
there must be no playerid parameter in OnGameModeInit.
So it should be
hope this helps
EDIT: lol Calgon you are faster
-FalconX
Re: OnGameModeInit Error? -
NeymarJr - 09.06.2012
Quote:
Originally Posted by Calgon
"playerid" does not exist in OnGameModeInit. You can't reference a playerid because when OnGameModeInit executes, no players have connected. Instead, you can copy your 'RemoveBuildingForPlayer' code in to OnPlayerConnect.
Simply change the public line to:
|
Quote:
Originally Posted by FalconX
there must be no playerid parameter in OnGameModeInit.
So it should be
hope this helps
EDIT: lol Calgon you are faster
-FalconX
|
Thanks guys! I appreaciate the help!