Raised This Month: $ Target: $400
 0% 

can anyone help? (again)


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
silversinner
Member
Join Date: Feb 2006
Location: England
Old 03-02-2006 , 13:15  
Reply With Quote #3

Ok this is what i have so far (this is my first attempt at making a plugin, may expect lots of mistakes )

Code:
//Hacker abuse v0.1 - Silversinner
//with help from VEN

#include <amxmodx>
#include <amxmisc>




public plugin_init() {
	register_plugin("HaCkEr AbUsE","0.1","Silversinner")
	register_concmd("amx_hacker_attack","hackerattack",ADMIN_BAN," - Punishes hackers then bans them")
}
  	
public hackerattack(id) {
	if (!(get_user_flags(id)&ADMIN_LEVEL_A)) {
		console_print(id,"[AMXX] Access Denied!")
		return PLUGIN_HANDLED
}
	if (read_argc() == 0) { 
        console_print(id,"[AMXX] You must specify a user") 
        return PLUGIN_HANDLED 
    } 
     
     new user[32], uid  
    read_argv(1,user,32) 
    uid = find_player("bh",user) 
    if (uid == 0) { 
        console_print(id,"[AMXX] Invalid User Id") 
        return PLUGIN_HANDLED 
}
	set_task(0.0,"alert")
	set_task(1.0,"five")
	set_task(2.0,"four")
	set_task(3.0,"three")
	set_task(4.0,"two")
	set_task(5.0,"one")
	set_task(6.0,"zero")
	set_task(7.0,"slap")
	set_task(8.0,"fire")
	set_task(16.0,"ban")
	return PLUGIN_HANDLED
}

public alert() {
	client_print(0,print_chat,"***** ALERT! HACKER DETECTED!")
	server_print("[AMXX] ***** ALERT! HACKER DETECTED! *****")
	client_cmd(0,"spk ^"fvox/warning.wav^"") 
}


public five() {
	client_print(0,print_chat,"[AMXX] HaCkEr AbUsE in 5....")
	server_print("[AMXX] HaCkEr AbUsE in 5....")

	client_cmd(0,"spk ^"fvox/five.wav^"") 
}

public four() {
	client_print(0,print_chat,"[AMXX] HaCkEr AbUsE in 4....")
	server_print("[AMXX] HaCkEr AbUsE in 4....")

	client_cmd(0,"spk ^"fvox/four.wav^"") 
}

public three() {
	client_print(0,print_chat,"[AMXX] HaCkEr AbUsE in 3....")
	server_print("[AMXX] HaCkEr AbUsE in 3....")

	client_cmd(0,"spk ^"fvox/three.wav^"") 
}

public two() {
	client_print(0,print_chat,"[AMXX] HaCkEr AbUsE in 2....")
	server_print("[AMXX] HaCkEr AbUsE in 2....")
 
	client_cmd(0,"spk ^"fvox/two.wav^"") 
}

public one() {
	client_print(0,print_chat,"[AMXX] HaCkEr AbUsE in 1....")
	server_print("[AMXX] HaCkEr AbUsE in 1....")

	client_cmd(0,"spk ^"fvox/one.wav^"") 
}

public zero() {
	client_print(0,print_chat,"[AMXX] HaCkEr AbUsEd....")
	server_print("[AMXX] HaCkEr AbUsing!")

	client_cmd(0,"spk ^"fvox/safe_day.wav^"") 
}

public slap() { 
                              get_user_ip(id, ip, 15, 1) 
                              client_print(0,print_chat,"[AMXX] AbUsEd hacker"
                              server_cmd("amx_uberslap", get_user_userid(id)) 
}

public fire (){
                             get_user_ip(id, ip, 15, 1) 
                             client_print(0,print_chat,"[AMXX] AbUsEd hacker MoRe!!"
                             server_cmd("amx_fire", get_user_userid(id)) 
}

public ban (16) {
        get_user_ip(id, ip, 15, 1) 
        server_cmd("kick #%d ^"You have been banned for Hacking!.^"", get_user_userid(id)) 
        server_exec() 
        server_cmd("addip 5 ^"%s^"", ip)  
        server_print("[AMXX] HaCkEr AbUsEd & BaNnEd!") 
}
Now i havnt compiled it yet... im not even sure is its correct :s
__________________
My website
(under contruction)
silversinner is offline
Send a message via AIM to silversinner Send a message via MSN to silversinner Send a message via Yahoo to silversinner
 



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


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