SA-MP Forums

Go Back   SA-MP Forums > SA-MP Scripting and Plugins > Scripting Help

Reply
 
Thread Tools Display Modes
Old 31/12/2018, 11:43 AM   #1
NexyAG
Banned
 
Join Date: Oct 2017
Posts: 23
Reputation: 0
Default OnPlayerGiveDamage : error 025: function heading differs from prototype

I got this error ( I alredy got this error before ) :
HTML Code:
error 025: function heading differs from prototype
HTML Code:
public OnPlayerGiveDamage(playerid, damagedid, Float:amount, weaponid, bodypart)
{
	return 1;
}
Problem is i alredy have YSI 4.0.2 and all latest includes and plugins, here is my #include :
Code:
/*-------------------------------------------------------------*/
#include 												<a_samp>
#include 												 <FCNPC>
#include 										  "CoD-Mape.pwn"
#undef MAX_PLAYERS
#define MAX_PLAYERS 										 250
/*-------------------------------------------------------------*/
#include 											   <sscanf2>
#include 											  <streamer>
#include 											  <Pawn.CMD>
#include 											  <YSI\y_va>
#include 											 <YSI\y_ini>
#include 											<Pawn.RegEx>
#include 										 <YSI\y_iterate>
#include 											<mapandreas>
/*-------------------------------------------------------------*/
NexyAG is offline   Reply With Quote
Old 31/12/2018, 11:45 AM   #2
Hawsn
Little Clucker
 
Hawsn's Avatar
 
Join Date: Jan 2017
Location: Vietnam
Posts: 10
Reputation: 0
Default Re: OnPlayerGiveDamage : error 025: function heading differs from prototype

https://forum.sa-mp.com/showthread.php?t=488198
Hawsn is offline   Reply With Quote
Old 31/12/2018, 11:48 AM   #3
NexyAG
Banned
 
Join Date: Oct 2017
Posts: 23
Reputation: 0
Default Re: OnPlayerGiveDamage : error 025: function heading differs from prototype

As i alredy said, I'M USING YSI 4.0.2 which alredy got stuff from that link, don't be dumb and hunt for reps
NexyAG is offline   Reply With Quote
Old 31/12/2018, 12:00 PM   #4
NexyAG
Banned
 
Join Date: Oct 2017
Posts: 23
Reputation: 0
Default Re: OnPlayerGiveDamage : error 025: function heading differs from prototype

Quote:
Originally Posted by [HLF]Southclaw View Post
The easiest way to debug things like this is to simply do a build with the -l flag. This flag runs only the pre-compile stage which resolves all preprocessor directives such as #include and #define. This will produce a single text file with all the Pawn source code where you can do a search for the function. Once you've found the offending function, you'll have a better idea of why it has the incorrect prototype.

Possible causes:
- Typo (most likely)
- Outdated standard library
- Outdated YSI (which you ruled out, but the pre-process test will validate this)
Actually it was ** OUTDATED ** a_samp.inc WHICH i was REPLACING 3 TIMES IN A ROW WITH THE SAME ARCHIVE...
I don't know, but it was like i update and it goes back on old ( standard lib ), weird...
I fixed this
NexyAG is offline   Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
error 025: function heading differs from prototype ZToPMaN Scripting Help 3 20/03/2016 09:26 AM
OnPlayerGiveDamage 0.3z error 025: function heading differs from prototype x_O Русский/Russian 8 13/02/2014 02:26 PM
[REQ-HELP] error 025: function heading differs from prototype Vythrin Scripting Help 4 20/02/2013 08:07 PM
error 025: function heading differs from prototype Beastlynoob Scripting Help 3 09/04/2012 12:15 PM
[Help] error 025: function heading differs from prototype FinestCalis Help Archive 5 14/04/2011 04:48 PM


All times are GMT. The time now is 09:28 PM.


Powered by vBulletin® Version 3.8.6
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.