Raised This Month: $ Target: $400
 0% 

user weapon name.


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Bugsy
AMX Mod X Moderator
Join Date: Feb 2005
Location: NJ, USA
Old 08-08-2009 , 01:09   Re: user weapon name.
Reply With Quote #9

Please learn to indent and space out your code.

PHP Code:
/**************************************************
* AMXX Script  *      *
* Author: Yuri *      *
*  Version 0.1  * * * * * * * * * * * * * *
* Look at a player and see their name. lolz   *
***************************************************/
#include <amxmodx>
#include <amxmisc>

new friend[33]
public 
set_team(id)
friend[id] = read_data(2)

public 
hide_status(id)
{
    
set_hudmessage(0,0,0,0.0,0.0,00.00.010.00.04)
    
show_hudmessage(id,"")
}
 
public 
show_status(id)
{
    static 
name32 ] , szWeapon20 ] , pidpid read_data(2)
    
get_user_namepid name 31 )
    
get_weaponnameget_user_weaponpid ) , szWeapon 19 );
    if ( 
friendid ] == )
    { 
/* friend */
        
set_hudmessage225 , -1.0 0.60 0.01 3.0 0.01 0.01 /* blue */
        
show_hudmessageid "Friend: %s - Health: %d | Armor: %d | Weapon: %s"name get_user_healthpid ) , get_user_armorpid ) , szWeapon] );
    }
    else 
    {
        
set_hudmessage(255,0,0,-1.0,0.60,10.013.00.010.014/* red */
        
show_hudmessageid "Enemy: %s" name )
    }
}

public 
plugin_init()
{
    
register_plugin("Player Name","0.1","Yuri")
    
register_event("StatusValue","set_team","be","1=1")
    
register_event("StatusValue","show_status","be","1=2","2!0")
    
register_event("StatusValue","hide_status","be","1=1","2=0")

__________________
Bugsy 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 18:22.


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