03.01.2015, 19:36
https://sampforum.blast.hk/showthread.php?tid=326614
This is pretty effective against weapon hacks, but if the player hacks ammo for an existing weapon, this doesn't detect.
I was half way through my script which detects ammo too but i got stuck at the place where I'll have to detect when ammo of a player changes, i decided to use GetPlayerAmmo in a 1 second timer, but the problem is, some weapons can shoot several bullets in a second, if i find out a way to trigger a function everytime the ammo of a player changes (for holding weapon).
If i get to find out a way, I'll be able to make a decent anti weapon/ammo hack script.
So is there a way to trigger a function everytime a single bullet for a weapon changes (Ofcourse without making a 1 millisecond timer :-p )?
This is pretty effective against weapon hacks, but if the player hacks ammo for an existing weapon, this doesn't detect.
I was half way through my script which detects ammo too but i got stuck at the place where I'll have to detect when ammo of a player changes, i decided to use GetPlayerAmmo in a 1 second timer, but the problem is, some weapons can shoot several bullets in a second, if i find out a way to trigger a function everytime the ammo of a player changes (for holding weapon).
If i get to find out a way, I'll be able to make a decent anti weapon/ammo hack script.
So is there a way to trigger a function everytime a single bullet for a weapon changes (Ofcourse without making a 1 millisecond timer :-p )?