Raised This Month: $ Target: $400
 0% 

[SOLVED] DeathMsg Event Help.!


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
xxxperts
Senior Member
Join Date: Oct 2013
Location: India
Old 03-29-2014 , 08:59   [SOLVED] DeathMsg Event Help.!
Reply With Quote #1

Whenever i switch the team then also the message display. please see the attached screenshot & also the my code.. Below

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

#include <amxmodx>
#include <amxmisc>

#define PLUGIN "Attacker Shower"
#define VERSION "1.0"
#define AUTHOR "LOL ?"

public plugin_init() 
{
    
register_plugin(PLUGINVERSIONAUTHOR)
    
register_event("DeathMsg""event_dead""a""1>0")
}

public 
event_dead()
{
    new 
iKiller read_data(1)
    new 
iVictim read_data(2)
    new 
iHskill read_data(3)
    
    new 
vicname[32], attackername[32];
    
get_user_name(iVictimvicname31)
    
get_user_name(iKillerattackername31)
    
    new 
weapon[32]
    
read_data(4weapon31)
    
    if (
iHskill)
    {
        
client_print(0print_chat"%s Had Just Killed %s with (%s) Headshot"attackernamevicnameweapon)
    }
    else
    {
        
client_print(iKillerprint_chat"You Had Just Killed %s with (%s)"vicnameweapon)
    }
}

/* AMXX-Studio Notes - DO NOT MODIFY BELOW HERE
*{\\ rtf1\\ ansi\\ deff0{\\ fonttbl{\\ f0\\ fnil Tahoma;}}\n\\ viewkind4\\ uc1\\ pard\\ lang1033\\ f0\\ fs16 \n\\ par }
*/ 
Attached Thumbnails
Click image for larger version

Name:	screenshot.jpg
Views:	148
Size:	91.9 KB
ID:	132060  
__________________
All my work is here

Last edited by xxxperts; 03-30-2014 at 02:50. Reason: Solved
xxxperts is offline
amx_tiger
Junior Member
Join Date: Aug 2012
Old 03-29-2014 , 09:45   Re: DeathMsg Event Help.!
Reply With Quote #2

So what's the problem? You don't want to see that message when you change the team?

This should work:

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

#define PLUGIN "Attacker Shower"  
#define VERSION "1.0"  
#define AUTHOR "LOL ?"  

public plugin_init()   
{  
    
register_plugin(PLUGINVERSIONAUTHOR)  
    
register_event("DeathMsg""event_dead""a""1>0")  
}  

public 
event_dead()  
{  
    new 
iKiller read_data(1)  
    new 
iVictim read_data(2)  

    if (!
is_user_connected(iKiller) || iKiller == iVictim
          return 
PLUGIN_CONTINUE

    new 
iHskill read_data(3)  
      
    new 
vicname[32], attackername[32];  
    
get_user_name(iVictimvicname31)  
    
get_user_name(iKillerattackername31)  
      
    new 
weapon[32]  
    
read_data(4weapon31)  
      
    if (
iHskill)  
    {  
        
client_print(0print_chat"%s Had Just Killed %s with (%s) Headshot"attackernamevicnameweapon)  
    }  
    else  
    {  
        
client_print(iKillerprint_chat"You Had Just Killed %s with (%s)"vicnameweapon)  
    }  
    
    return 
PLUGIN_CONTINUE;

amx_tiger is offline
swapped
BANNED
Join Date: Mar 2014
Location: OrpheuRegisterHook
Old 03-29-2014 , 10:52   Re: DeathMsg Event Help.!
Reply With Quote #3

Nop, this is for the same team (if friendly fire is on), they want only for a specific team
tell us the team ..
swapped 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 05:57.


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