OnPlayerWeaponShoot
#1

Hi,

If i return 0 OnPlayerTakeDamage never get called?
Reply
#2

It will still be called if there is no other script running OnPlayerTakeDamage, but it might be that the player doesn't receive any damage anymore (Im not sure about this).
Reply
#3

https://sampwiki.blast.hk/wiki/OnPlayerWeaponShot

When you return 0 in this callback, the bullet does not do damage and is effectively not seen by other clients. So to them, it will look like you're not shooting anything.

No bullet = No damage = No damage taken (Therefore, no OnPlayerTakeDamage)

I believe OnPlayerGiveDamage is still called however. But if you shoot someone, and return 0 in OnPlayerWeaponShot, that bullet will never reach them.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)