Raised This Month: $ Target: $400
 0% 

health


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 06-04-2010 , 11:12   Re: health
Reply With Quote #1

Better to use get_players.

PHP Code:
#include <amxmodx>

public plugin_init()
{
    
set_task(1.0"show_health", .flags="b")
}

public 
show_health()
{
    new 
iPlayers[32], iNumiHealth
    get_players
(iPlayersiNum"ae""CT")
    for(new 
ii<iNumi++)
    {
        
iHealth += get_user_health(iPlayers[i])
    }

    
set_hudmessage(00255, -1.00.100.0000011.00.5010.501, -1)
    
show_hudmessage(0"CT Total Health: %d"iHealth)

__________________
- tired and retired -

- my plugins -
ConnorMcLeod 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:16.


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