Quote:
Originally Posted by Dampyr
Awesome include,
it would be nice if the player could destroy these towers ![Cheesy](images/smilies/biggrin.png)
|
It's possible. You can use
GetSAMObjectID to get the SAM launcher's object ID. Then under OnPlayerWeaponShot, check if the hittype is equal to HIT_TYPE_OBJECT and if hitid is equal to the object ID which was obtained from GetSAMObjectID. You can either directly destroy it or use custom health rates.
I wrote a tutorial similar to what you've asked for which can be used for all objects -
https://sampforum.blast.hk/showthread.php?tid=488317