Warning 235 Problem. - 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: Warning 235 Problem. (
/showthread.php?tid=242812)
Warning 235 Problem. -
Bliitzz - 20.03.2011
Well, basically, I'm unsure how to fixing:
warning 235: public function lacks forward declaration (symbol "OnPlayerSTATEChange")
I've tried the Case Sensitive differences, Such as 'OnPlayerStateChange'
Full line :- public OnPlayerSTATEChange(playerid, newState, oldState)
If you got any suggestions / Solutions. Lemme know please. Thanks.
Re: Warning 235 Problem. -
Stigg - 20.03.2011
Above your line put:
pawn Код:
forward OnPlayerSTATEChange(playerid, newState, oldState);
BTW. Why the caps ?
AW: Warning 235 Problem. -
xerox8521 - 20.03.2011
Quote:
Originally Posted by Bliitzz
Well, basically, I'm unsure how to fixing:
warning 235: public function lacks forward declaration (symbol "OnPlayerSTATEChange")
[/I]
|
This tells you that the public "OnPlayerSTATEChange" needs an forward
pawn Код:
forward OnPlayerSTATEChange(playerid, oldstate, newstate);
But btw in SA-MP is default
pawn Код:
public OnPlayerStateChange(playerid, newstate, oldstate)
Re: Warning 235 Problem. -
Bliitzz - 20.03.2011
Well, If i use 'OnPlayerStateChange' -
When i compile i get: error 025: function heading differs from prototype
When i use 'OnPlayerSTATEChange' -
When i compile i get: warning 235: public function lacks forward declaration (symbol "OnPlayerSTATEChange")
When i place the Line you both quoted, above my original line When i compile I get: error 025: function heading differs from prototype
Re: Warning 235 Problem. -
Stigg - 20.03.2011
Quote:
Originally Posted by Bliitzz
Well, If i use 'OnPlayerStateChange' - When i compile i get: error 025: function heading differs from prototype
When i use 'OnPlayerSTATEChange' - When i compile i get: warning 235: public function lacks forward declaration (symbol "OnPlayerSTATEChange")
When i place the Line you both quoted, above my original line When i compile I get: error 025: function heading differs from prototype
|
Because the line is supposed to be:
pawn Код:
public OnPlayerStateChange(playerid, newstate, oldstate)
That's samp default, as you've already been told.
AW: Warning 235 Problem. -
Pablo Borsellino - 20.03.2011
@Bliitzz: Your Problem is that you dont use the right SA:MP Callback. You have:
pawn Код:
public OnPlayerStateChange(playerid,oldstate,newstate)
but it must be: (change it to this!)
pawn Код:
public OnPlayerStateChange(playerid,newstate,oldstate)
Re: Warning 235 Problem. -
Bliitzz - 20.03.2011
& I can add the 'Forward' line, just in the line, right above my original line, and it should be fine, Yeah?
Re: AW: Warning 235 Problem. -
Stigg - 20.03.2011
Quote:
Originally Posted by Pablo Borsellino
@Bliitzz: Your Problem is that you dont use the right SA:MP Callback. You have:
pawn Код:
public OnPlayerStateChange(playerid,oldstate,newstate)
but it must be: (change it to this!)
pawn Код:
public OnPlayerStateChange(playerid,newstate,oldstate)
|
As he's 'ALREADY BEEN TOLD'.
Re: Warning 235 Problem. -
Biesmen - 20.03.2011
You donґt have to forward standard SA-MP callbacks.
Re: Warning 235 Problem. -
Bliitzz - 20.03.2011
If i just simply change my original line, to this - 'public OnPlayerStateChange(playerid,newstate,oldstate)'
All i get is 5 Errors, but i think i can work round to fixing those seperately.
Re: Warning 235 Problem. -
Stigg - 20.03.2011
Quote:
Originally Posted by Bliitzz
If i just simply change my original line, to this - 'public OnPlayerStateChange(playerid,newstate,oldstate)'
All i get is 5 Errors, but i think i can work round to fixing those seperately.
|
Debug those 5 error's then, or aleast show us them.
Re: Warning 235 Problem. -
Bliitzz - 20.03.2011
Yeah, it's all good now, Thanks alot people..