Raised This Month: $ Target: $400
 0% 

drop weapon damage- crash to desktop


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
noob cannon lol
SourceMod Donor
Join Date: Sep 2005
Old 10-26-2005 , 00:34   drop weapon damage- crash to desktop
Reply With Quote #1

Whenever I try to use this plugin I always crash to the desktop with no error log and no indication of what is wrong.

Code:
/* Plugin generated by AMXX-Studio */

#include <amxmodx>
#include <amxmisc>
#include <engine>
#include <fun>

#define PLUGIN "ZP Weapon Drop Damage"
#define VERSION "1.0"
#define AUTHOR "noob cannon lol"


public plugin_init() {
	register_plugin(PLUGIN, VERSION, AUTHOR)
	register_clcmd("drop","handle_drop"); 
}

public handle_drop(id) {
	new targetid, body
	if (get_user_aiming(id, targetid, body) <= 100.0)
	{
		if(is_valid_ent(targetid) && is_user_connected(targetid))
		{
			if(is_user_alive(targetid))
			{
				emit_sound(targetid, CHAN_WEAPON, "sound/punch.wav", 1.5, ATTN_NORM, 0, PITCH_NORM );
				set_user_health(targetid, get_user_health(targetid) - 20)
			}
		}
	}
	return PLUGIN_CONTINUE
}
Perhaps someone knows the error in this?
noob cannon lol is offline
Send a message via AIM to noob cannon lol Send a message via MSN to noob cannon lol
 



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


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