Raised This Month: $ Target: $400
 0% 

[REQ] If the player commits suicide...


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
crazyeffect
Veteran Member
Join Date: Jul 2008
Location: Belgium
Old 02-15-2010 , 18:24   Re: [REQ] If the player commits suicide...
Reply With Quote #1

Quote:
Originally Posted by T-z3P View Post
When you fall down from a high spot and die & trigger_hurt also .
__________________
crazyeffect is offline
Send a message via MSN to crazyeffect
meTaLiCroSS
Gaze Upon My Hat
Join Date: Feb 2009
Location: Viņa del Mar, Chile
Old 02-15-2010 , 18:26   Re: [REQ] If the player commits suicide...
Reply With Quote #2

Ouh, ok.
__________________
Quote:
Originally Posted by joropito View Post
You're right Metalicross
meTaLiCroSS is offline
T-z3P
Senior Member
Join Date: Apr 2008
Location: Iasi, Romania
Old 02-15-2010 , 16:59   Re: [REQ] If the player commits suicide...
Reply With Quote #3

Anyone ?
__________________


T-z3P is offline
Send a message via Yahoo to T-z3P Send a message via Skype™ to T-z3P
meTaLiCroSS
Gaze Upon My Hat
Join Date: Feb 2009
Location: Viņa del Mar, Chile
Old 02-15-2010 , 18:23   Re: [REQ] If the player commits suicide...
Reply With Quote #4

You're talking about "kill" command?
__________________
Quote:
Originally Posted by joropito View Post
You're right Metalicross
meTaLiCroSS is offline
wrecked_
Veteran Member
Join Date: Jan 2010
Location: New York (GMT-5)
Old 02-15-2010 , 18:42   Re: [REQ] If the player commits suicide...
Reply With Quote #5

PHP Code:
#include <amxmodx>
#include <fun>

new const VERSION[] = "0.0.1"

public plugin_init()
{
    
register_plugin"No Suicide Frag Loss"VERSION"0.0.1" )
    
    
register_event"DeathMsg""ev_DeathMsg""a""1=0" )
}

public 
ev_DeathMsg()
{
    new 
victim read_data)
    
set_user_fragsvictimget_user_fragsvictim ) + )
    
set_user_deatshvictimget_user_deathsvictim ) + )

To avoid any flaming - the last parameter of register_event tells it to call it only when the killer is worldspawn, acid, no oxygen, etc.
__________________
[ Paid Requests ]
DO NOT PM ME ABOUT BLOCKMAKER
NO PRIVATE SUPPORT

Last edited by wrecked_; 02-16-2010 at 17:43.
wrecked_ is offline
T-z3P
Senior Member
Join Date: Apr 2008
Location: Iasi, Romania
Old 02-16-2010 , 14:27   Re: [REQ] If the player commits suicide...
Reply With Quote #6

Thanks but , if I fell down of a cliff it adds me 1 frag and 1 death .
__________________


T-z3P is offline
Send a message via Yahoo to T-z3P Send a message via Skype™ to T-z3P
puttsmobiles
Senior Member
Join Date: Mar 2009
Location: Chicago
Old 02-16-2010 , 16:14   Re: [REQ] If the player commits suicide...
Reply With Quote #7

I don't know much coding. But I would think this would work.

PHP Code:
#include <amxmodx>
#include <fun>

new const VERSION[] = "0.0.2"

public plugin_init()
{
    
register_plugin"No Suicide Frag Loss"VERSION"wrecked" )
    
    
register_event"DeathMsg""ev_DeathMsg""a""1=0" )
}

public 
ev_DeathMsg()
{
    new 
victim read_data)
    
set_user_fragsvictimget_user_fragsvictim ) + )
    
set_user_deathsvictimget_user_deathsvictim ) - )

__________________
Dan Hiorns - www.danhiorns.us
puttsmobiles is offline
Send a message via AIM to puttsmobiles Send a message via MSN to puttsmobiles Send a message via Yahoo to puttsmobiles Send a message via Skype™ to puttsmobiles
wrecked_
Veteran Member
Join Date: Jan 2010
Location: New York (GMT-5)
Old 02-16-2010 , 16:26   Re: [REQ] If the player commits suicide...
Reply With Quote #8

First post is fixed.
__________________
[ Paid Requests ]
DO NOT PM ME ABOUT BLOCKMAKER
NO PRIVATE SUPPORT
wrecked_ is offline
XxAvalanchexX
Veteran Member
Join Date: Oct 2004
Location: abort73.com
Old 02-16-2010 , 19:51   Re: [REQ] If the player commits suicide...
Reply With Quote #9

Quote:
Originally Posted by wrecked_ View Post
First post is fixed.
Did you mean to do get_user_deaths + 1?
__________________
No longer around. Thanks your support, everyone! As always:
THIS ONES FOR YOU
3000 PTS
XxAvalanchexX is offline
hleV
Veteran Member
Join Date: Mar 2007
Location: Lithuania
Old 02-16-2010 , 16:49   Re: [REQ] If the player commits suicide...
Reply With Quote #10

wrecked_, your code is useless.
__________________
hleV 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 00:19.


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