[Include] Fix for tire poping with EnableVehicleFriendlyFire() - 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] Fix for tire poping with EnableVehicleFriendlyFire() (
/showthread.php?tid=648320)
Fix for tire poping with EnableVehicleFriendlyFire() -
Gammix - 19.01.2018
I have seen lot of servers don't have this fix. I used
Admigo's vehicle part detection
library to detect tire poping.
This is a simple include, all you have to do is include this library in your script and there will be no tire poping on friendly vehicles anymore. But only if you have this:
EnableVehicleFriendlyFire(), in your script.
None the less, there is a drawback, the include only support 4 wheel vehicles (i.e. only cars). Bikes hasn't been added, i don't have time to make the algorithm for coordinates. But atleast cars are safe!
Download
https://github.com/Agneese-Saini/SA-...iendlyFire.inc
Try it out on your servers and let me know if any bugs!
Extra
For adding a further feature, i made a callback which is called every time a player confirm pops a team vehicle's tire:
PHP код:
/*
*** Parameters:
* playerid: the player who called the shots
* vehicleid: vehicle taking the hits on tires
* driverid: the drive of the vehicle
*/
forward OnPlayerFirendlyFireTires(playerid, vehicleid, driverid);
Re: Fix for tire poping with EnableVehicleFriendlyFire() -
liguanhua123 - 20.01.2018
Good Work
Re: Fix for tire poping with EnableVehicleFriendlyFire() -
RogueDrifter - 20.01.2018
Oh that's interesting good job!
Re: Fix for tire poping with EnableVehicleFriendlyFire() -
Admigo - 20.01.2018
Hey Gammix. Thanks for using my include. If i have time soon i will improve the include and support for bikes.
Great release. +1
Re: Fix for tire poping with EnableVehicleFriendlyFire() -
Gammix - 20.01.2018
Quote:
Originally Posted by Admigo
Hey Gammix. Thanks for using my include. If i have time soon i will improve the include and support for bikes.
Great release. +1
|
That would be great, bike support will complete this include.
Re: Fix for tire poping with EnableVehicleFriendlyFire() -
Cypress - 20.01.2018
That's a great fix. Being annoyed when people don't understand that you're at the same team as they, so your vehicle gets rip!