[FS] Sound when you shoot to player -
luby - 26.03.2009
Hello.
At lessons (at polish lesson) I got idea to do this.
This will play sound(beep) to you when you shoot to another player
Also added support for callback OnPlayerLoseHealth and if you uncomment rest of OnPlayerUpdate you can use OnPlayerGainHealth and OnPlayerHealthChange
Code :
http://pastebin.com/f8d69c29
Just simple and easy.
Re: [FS] Sound when you shoot to player -
SpiderPork - 26.03.2009
Why is this needed?
Re: [FS] Sound when you shoot to player -
Rks25 - 26.03.2009
You got a preview movie?
Re: [FS] Sound when you shoot to player -
MenaceX^ - 26.03.2009
Quote:
Originally Posted by ʞɹod ɹǝpıds || SpiderPork
Why is this needed?
|
For RP servers is needed. The radious of hearing the sound is low on gta
a.
Re: [FS] Sound when you shoot to player -
luby - 26.03.2009
I was thinking about Quake3 and Enemy Territory when I was writing this.
In idea it was similar to beep when you shot to another player and the player gets hurt (Q3)
Re: [FS] Sound when you shoot to player -
XeoN_13 - 26.03.2009
nice
would u like a mirrow?
Re: [FS] Sound when you shoot to player -
CracK - 26.03.2009
Bad that sometimes there will be a sound even if you don't shoot at all and there are players near losing health. But I'll test it anyway, in Q3 this sound is very useful
Re: [FS] Sound when you shoot to player -
luby - 26.03.2009
Quote:
Originally Posted by CrαcK
Bad that sometimes there will be a sound even if you don't shoot at all and there are players near losing health. But I'll test it anyway, in Q3 this sound is very useful
|
it not checks near player
it check who aimed you when you lost health with angle and distance. Just read code
)
Re: [FS] Sound when you shoot to player -
Norn - 27.03.2009
Quote:
Originally Posted by Luby
Quote:
Originally Posted by CrαcK
Bad that sometimes there will be a sound even if you don't shoot at all and there are players near losing health. But I'll test it anyway, in Q3 this sound is very useful
|
it not checks near player
it check who aimed you when you lost health with angle and distance. Just read code )
|
And what happens when you jump off a wall whilst someones aiming at you? You'll hear random gunfire?
Re: [FS] Sound when you shoot to player -
luby - 27.03.2009
Quote:
Originally Posted by Norn
Quote:
Originally Posted by Luby
Quote:
Originally Posted by CrαcK
Bad that sometimes there will be a sound even if you don't shoot at all and there are players near losing health. But I'll test it anyway, in Q3 this sound is very useful
|
it not checks near player
it check who aimed you when you lost health with angle and distance. Just read code )
|
And what happens when you jump off a wall whilst someones aiming at you? You'll hear random gunfire?
|
You can uncomment and correct GetPlayerKeys section and then you will not hear anything
But hmm, you can check if player shoots in OnPlayerKeyStateChange and then run functions
It's really easy to do.