Anti crash
#7

This seems to be more of a client-related issue this quote is referencing how-ever it should still be fairly relevant to the issue at-hand:
http://forum.sa-mp.com/forumdisplay.php?f=19

More specifically,
Quote:
Originally Posted by Matite
Посмотреть сообщение
"Vehicle component crasher" = Add code to OnVehicleMod to check if the component being synced is not valid for the vehicle (return 0 if it is bad). Look for a post by JernejL with this code.

"Bullet crasher (Player)" = Add code to OnPlayerWeaponShot to check the type of shot. If the player is shooting themselves (not possible) then do not sync it (return 0). If the bullet hit location is outside what would be considered a normal range then do not sync it (return 0). If the bullet hit location is INF or NaN then kick/ban and do not sync it (return 0). Look for code on the forum to do this if you need more help.

"Bullet crasher (Vehicle)" = Same as above for "Bullet crasher (Weapon)".

"Train crasher" = Add code to OnPlayerUpdate or a timer that checks the train and trams Z position. If it is outside the range of -10 to 100 then it is not valid. In OnPlayerUpdate you could de-sync this data (return 0) or in a timer you could alert admins and kick/ban the player.

"Attached object crasher" = Add code to OnPlayerEditAttachedObject to check the model ID returned is valid. You should not attach an object in this callback using the model ID that is returned... it should be stored in a variable elsewhere when the player first starts editing the attached object.
Reply


Messages In This Thread
Anti crash - by Glossy42O - 16.01.2015, 15:24
Re: Anti crash - by KayJ - 16.01.2015, 15:26
Re: Anti crash - by Glossy42O - 16.01.2015, 15:28
Re: Anti crash - by M4D - 16.01.2015, 19:12
Re: Anti crash - by Glossy42O - 16.01.2015, 20:30
Re: Anti crash - by Threshold - 17.01.2015, 01:29
Re: Anti crash - by Abagail - 17.01.2015, 01:56

Forum Jump:


Users browsing this thread: 1 Guest(s)