SA-MP Forums Archive
how to fix 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: how to fix error (/showthread.php?tid=520763)



how to fix error - ReD_DeVi - 20.06.2014

this error

Код:
C:\Users\aman\Desktop\SATDM~RP V14\pawno\include\streamer.inc(487) : warning 235: public function lacks forward declaration (symbol "OnPlayerWeaponShot")
C:\Users\aman\Desktop\SATDM~RP V14\pawno\include\streamer.inc(489) : error 017: undefined symbol "BULLET_HIT_TYPE_PLAYER_OBJECT"
this is the code

public OnPlayerWeaponShot(playerid, weaponid, hittype, hitid, Float:fX, Float:fY, Float:fZ)
{
if (hittype == BULLET_HIT_TYPE_PLAYER_OBJECT)
{
Streamer_CallbackHook(STREAMER_OPWS, playerid, weaponid, hittype, hitid, fX, fY, fZ);
}
#if defined Streamer_OnPlayerWeaponShot
return Streamer_OnPlayerWeaponShot(playerid, weaponid, hittype, hitid, fX, fY, fZ);
#else
return 1;
#endif
}


Re: how to fix error - Golf - 20.06.2014

download a lastest version of your plugin streamer, update your package server


Re: how to fix error - Haydz - 20.06.2014

The hittype's aren't defined in the SAMP includes yet so you have to add this to the top of your script.

pawn Код:
#define BULLET_HIT_TYPE_NONE            0
#define BULLET_HIT_TYPE_PLAYER          1
#define BULLET_HIT_TYPE_VEHICLE         2
#define BULLET_HIT_TYPE_OBJECT          3
#define BULLET_HIT_TYPE_PLAYER_OBJECT   4
I'm not to sure about the first line but updating your streamer will probably fix that.


Re: how to fix error - Laurey - 20.06.2014

Your include version pretty much belongs to 0.3x version unmatching the 0.3z plugin version, update your include to the latest version available.