Raised This Month: $ Target: $400
 0% 

First Blood


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
[ --<-@ ] Black Rose
ANNIHILATED
Join Date: Sep 2005
Location: Stockholm, Sweden.
Old 02-04-2007 , 11:40   Re: First Blood
Reply With Quote #1

Code:
#include <amxmodx> new bool:g_death_msg, bool:g_damage_msg public new_round() {     if ((get_cvar_num("mp_roundtime") * 60) == read_data(1)) {         new fbmode[8]         get_cvar_string("amx_fb_mode",fbmode,7)         new fbmode_bit = read_flags(fbmode)         if (fbmode_bit & 16) {             g_death_msg = true         }         else             g_damage_msg = true     }     return PLUGIN_CONTINUE } public death_msg() {     if ( !g_death_msg )         return PLUGIN_CONTINUE     new aIndex = read_data(1)     new vIndex = read_data(2)     if ( !aIndex || aIndex==vIndex || get_user_team(aIndex)==get_user_team(vIndex))         return PLUGIN_CONTINUE     fb_event(aIndex,vIndex)     g_death_msg = false     return PLUGIN_CONTINUE } public damage_msg() {     if ( !g_damage_msg )         return PLUGIN_CONTINUE     new vIndex = read_data(0)     new aIndex = get_user_attacker(vIndex)         if ( !aIndex || aIndex==vIndex || get_user_team(aIndex)==get_user_team(vIndex))         return PLUGIN_CONTINUE     fb_event(aIndex,vIndex)     g_damage_msg = false     return PLUGIN_CONTINUE } public fb_event(aIndex,vIndex) {     new msg[128], fbmode[8]     get_cvar_string("amx_fb_mode",fbmode,7)     new fbmode_bit = read_flags(fbmode)         if (fbmode_bit & 8) {         new aName[32]         get_user_name(aIndex,aName,31)         format(msg,127,"%s: First Blood!",aName)     }     else         format(msg,127,"First Blood!")         if (fbmode_bit & 1) {         set_hudmessage(220,80,100,-1.0,0.30,0, 6.0, 5.0, 1.0, 2.0, 2)         show_hudmessage(0,msg)     }     if (fbmode_bit & 2)   client_print(0,print_chat,"[AMXX] %s",msg)     if (fbmode_bit & 4)   client_cmd(0,"spk misc/firstblood2_ultimate")     return PLUGIN_CONTINUE } public plugin_init() {     register_plugin("FirstBlood","0.9.3","Sonic ([email protected])")     register_event("RoundTime", "new_round", "bc")     register_event("DeathMsg","death_msg","a")     register_event("Damage", "damage_msg","b","2!0","4!0")     register_cvar("amx_fb_mode","ace")     return PLUGIN_CONTINUE }

Last edited by [ --<-@ ] Black Rose; 02-04-2007 at 13:06.
[ --<-@ ] Black Rose 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:42.


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