SA-MP Forums Archive
[Include] OnPlayerShoot callback - 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: Filterscripts (https://sampforum.blast.hk/forumdisplay.php?fid=17)
+---- Forum: Includes (https://sampforum.blast.hk/forumdisplay.php?fid=83)
+---- Thread: [Include] OnPlayerShoot callback (/showthread.php?tid=328964)



OnPlayerShoot callback - dexi - 26.03.2012

Hy! First: Sorry for my bad English.

In my boredom i create this include.
Then calls when we shoot.

Usage(example):

Код:
#include < a_samp >
#include < OnPlayerShoot >

public OnPlayerShoot( playerid, weaponid, ammo )
{
	if( weaponid == 38 )
	{
	    ResetPlayerWeapons( playerid ); // If player shot with 'Minigun', reset player weapons.
	}
	return 1;
}
Download the include

This include request YSI:

YSI Link


Re: OnPlayerShoot callback - TreePuncher - 16.07.2012

function is not implemented..... Ok then...


Re: OnPlayerShoot callback - IstuntmanI - 17.07.2012

Код:
SetTimerEx( "Update", 5, 1, "i", playerid );
SetTimerEx( "Leker", 5, 1, "i", playerid );
What the ...

Use OnPlayerTakeDamage/OnPlayerGiveDamage callbacks from SA:MP, no timers or other ... things.


Re: OnPlayerShoot callback - MP2 - 17.07.2012

Are you serious? Use OnPlayerKeyStateChange and OnPlayerUpdate..


Re: OnPlayerShoot callback - iWhite - 17.07.2012

THIEF!

It's a OnPlayerShootPlayer include made by wups!


Re: OnPlayerShoot callback - Blunt - 17.07.2012

Quote:
Originally Posted by iWhite
Посмотреть сообщение
THIEF!

It's a OnPlayerShootPlayer include made by wups!
Clearly it's not, this way more un-efficient and supports less features than Wup's version.

Also, this is OnPlayerShoot. Not OnPlayerShootPlayer, there's a big difference, however nice work.