Raised This Month: $ Target: $400
 0% 

death event


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Sanjay Singh
Veteran Member
Join Date: Sep 2016
Old 01-24-2020 , 13:06   death event
Reply With Quote #1

which is better to use for detect death

PHP Code:
register_event("DeathMsg""onDeathMsgEvent""a"); 
PHP Code:
client_death() 
__________________

Last edited by Sanjay Singh; 01-24-2020 at 13:06.
Sanjay Singh is offline
Send a message via AIM to Sanjay Singh
georgik57
Veteran Member
Join Date: Oct 2008
Location: 🎧Music World
Old 01-24-2020 , 13:28   Re: death event
Reply With Quote #2

PHP Code:
Ham_Killed 
__________________
georgik57 is offline
Send a message via MSN to georgik57 Send a message via Yahoo to georgik57 Send a message via Skype™ to georgik57
Sanjay Singh
Veteran Member
Join Date: Sep 2016
Old 01-24-2020 , 14:50   Re: death event
Reply With Quote #3

I want to detect knife kill
__________________
Sanjay Singh is offline
Send a message via AIM to Sanjay Singh
Bugsy
AMX Mod X Moderator
Join Date: Feb 2005
Location: NJ, USA
Old 01-24-2020 , 15:00   Re: death event
Reply With Quote #4

This has been covered a million times, try searching
__________________
Bugsy is offline
thEsp
BANNED
Join Date: Aug 2017
Old 01-24-2020 , 15:33   Re: death event
Reply With Quote #5

And for god's sake, stop registering "DeathMsg" thinking it hooks a true death. It only shows a frag message on top-right corner and "Dead" status in the scoreboard. I said this like 50 times... or more?
thEsp is offline
HamletEagle
AMX Mod X Plugin Approver
Join Date: Sep 2013
Location: Romania
Old 01-24-2020 , 15:39   Re: death event
Reply With Quote #6

Quote:
Originally Posted by thEsp View Post
It only shows a frag message on top-right corner
While this is true, DeathMsg message is sent from Ham_Killled, therefore it's a solid indication a kill has occurred. If you are not looking to change anything and you simply want to know when someone died then DeathMsg is perfectly fine.
Plus it comes in handy when trying to detect headshots. For Ham_Killed extra code is needed.
__________________
HamletEagle is offline
thEsp
BANNED
Join Date: Aug 2017
Old 01-24-2020 , 18:30   Re: death event
Reply With Quote #7

Your statement is also valid Hamlet, but my point was that "DeathMsg" is unsafe compared to Ham_Killed or even Client_Death from CSX. For example, there is one little plugin that makes certain players appear dead, and that is done exactly through "DeathMsg" message, having both plugins would cause a problem.
thEsp is offline
Bugsy
AMX Mod X Moderator
Join Date: Feb 2005
Location: NJ, USA
Old 01-24-2020 , 18:33   Re: death event
Reply With Quote #8

Quote:
Originally Posted by thEsp View Post
Your statement is also valid Hamlet, but my point was that "DeathMsg" is unsafe compared to Ham_Killed or even Client_Death from CSX. For example, there is one little plugin that makes certain players appear dead, and that is done exactly through "DeathMsg" message, having both plugins would cause a problem.
That same mindset can apply to many things with writing plugins though, not just with DeathMsg. When I answer questions on the forums it is with the mindset that you are not taking other plugins/mods behavior into consideration. On a 'clean' server, DeathMsg is ideal IMO as you can easily get additional info about the kill and/or only make it fire based on the value of the elements in the message.
__________________

Last edited by Bugsy; 01-24-2020 at 18:47.
Bugsy is offline
HamletEagle
AMX Mod X Plugin Approver
Join Date: Sep 2013
Location: Romania
Old 01-25-2020 , 03:04   Re: death event
Reply With Quote #9

Quote:
Originally Posted by thEsp View Post
Your statement is also valid Hamlet, but my point was that "DeathMsg" is unsafe compared to Ham_Killed or even Client_Death from CSX. For example, there is one little plugin that makes certain players appear dead, and that is done exactly through "DeathMsg" message, having both plugins would cause a problem.
Ham_Killed can be wrongly triggered with ExecuteHamB, client_death by triggering pfnClientKill with orpheu.
__________________
HamletEagle 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 02:49.


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