Raised This Month: $32 Target: $400
 8% 

Hook when an entity is destroyed


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
eat1k
Senior Member
Join Date: Apr 2018
Old 02-09-2019 , 14:15   Hook when an entity is destroyed
Reply With Quote #1

Is there any way to hook when an entity is destroyed? Example: a player has a weapon and we remove it, at this moment we need to do something (disable some hooks). Is it possible to hook this moment?
__________________

Last edited by eat1k; 02-09-2019 at 14:19.
eat1k is offline
CrazY.
Veteran Member
Join Date: May 2015
Location: SP, Brazil
Old 02-09-2019 , 14:39   Re: Hook when an entity is destroyed
Reply With Quote #2

FM_OnFreeEntPrivateData, Ham_Item_Kill, Ham_RemovePlayerItem, Ham_Killed.
__________________









Last edited by CrazY.; 02-09-2019 at 14:40.
CrazY. is offline
eat1k
Senior Member
Join Date: Apr 2018
Old 02-09-2019 , 15:29   Re: Hook when an entity is destroyed
Reply With Quote #3

FM_OnFreeEntPrivateData is also called when map starts. Ham_Item_Kill/Ham_RemovePlayerItem/Ham_Killed doesn't work but thanks.

It works with FM_RemoveEntity (thanks to voed).
__________________
eat1k is offline
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 18:22.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode