Raised This Month: $ Target: $400
 0% 

Get user attack


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
NeverDie
Junior Member
Join Date: Mar 2006
Old 03-01-2006 , 12:38   Get user attack
Reply With Quote #1

Hi i was wonding how i can get a user attacker and make it so if a user is attacked with anything but a knife it will force them to drop a weapon i been trying to use something like
Code:
register_event("Damage", "checkDamage", "b", "2!0")

public checkDamage(id)
{
	new weapon, bodypart, attacker = get_user_attacker(id, weapon, bodypart)
	
	if ( attacker <= 0 ) 
	{
		return
	}	
	else if ( weapon == CSW_KNIFE )
	{
		return
	}
	else
	{
		client_cmd(attacker, "drop")
	}
	
	return
}
But this seems not to work because when you fall of something it makes the victim still drop his weapon and when u att some1 it makes them drop there weapon.
NeverDie is offline
 



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 20:23.


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