Raised This Month: $ Target: $400
 0% 

DeathMsg question


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
Kard1nal
Senior Member
Join Date: Dec 2012
Location: Russia
Old 03-03-2013 , 06:08   DeathMsg question
Reply With Quote #1

So, I've got register_event("DeathMsg", "deatha", "a") in my plugin, but I need to not execute it if player was killed by user_silentkill.
Is it possible?
__________________
Sorry for my English, I'm Russian.
Kard1nal is offline
Send a message via Skype™ to Kard1nal
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 03-03-2013 , 06:11   Re: DeathMsg question
Reply With Quote #2

Are both code in the same plugin ?

In that casen just set a global bool variable on true before you use silentkill, and set it back to false after.
In DeathMsg callback, check that global variable.
__________________
- tired and retired -

- my plugins -
ConnorMcLeod is offline
Kard1nal
Senior Member
Join Date: Dec 2012
Location: Russia
Old 03-03-2013 , 06:15   Re: DeathMsg question
Reply With Quote #3

Already thought about it, but no, it's different plugins...
So there is no another way and I have to knock it into one.
Thank you.
__________________
Sorry for my English, I'm Russian.

Last edited by Kard1nal; 03-03-2013 at 06:16.
Kard1nal is offline
Send a message via Skype™ to Kard1nal
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 03-03-2013 , 06:47   Re: DeathMsg question
Reply With Quote #4

You can create a public variable in one plugin, then use ***_xvar_*** natives.
__________________
- tired and retired -

- my plugins -
ConnorMcLeod is offline
Reply



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 21:47.


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