Raised This Month: $ Target: $400
 0% 

have something need to help,about judge death


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
etet
Junior Member
Join Date: Aug 2008
Old 10-20-2010 , 05:41   have something need to help,about judge death
Reply With Quote #1

if i want this plugin change to at player dead show server information,not original set,wt code i need changed ?

sorry for my bad english

thx a loot

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

new hud_rgbhud_xhud_yhud_effects,maxplayers,hudsynccurr_uptime[22], g_round 1;

public 
plugin_init() {
    
register_plugin("Server Side Info","1.6","xakintosh")
    
    
hud_rgb register_cvar"srv_hud_rgb""0 255 0" )
    
hud_x register_cvar"srv_hud_x""0.11" )
    
hud_y register_cvar"srv_hud_y""0.00" )
    
hud_effects register_cvar"srv_hud_effects""0" )
    
hudsync CreateHudSyncObj()
    
maxplayers get_maxplayers()
    
    
register_dictionary("srv_info.txt");
    
    
set_task(0.1"Fwd_StartFrame"1""0"b")
    
set_task(0.1"check_uptime"___"b")
    
    
register_forward(FM_StartFrame"Fwd_StartFrame")
    
register_event("HLTV""event_newround""a""1=0""2=0");
}
public 
event_newround() {
    
g_round++
}

public 
Fwd_StartFrame(id) {
    new 
timestring[31]
    
get_time("%H:%M:%S",timestring,8)
    
    static 
Float:GameTimeFloat:FramesPer 0.0
    
static Float:Fps
    
    GameTime 
get_gametime()
    
    if(
FramesPer >= GameTime)
        
Fps += 1.0;
    else {
        
FramesPer FramesPer 1.0
        
for( new id 1id <= maxplayersid++ ) { 
            
            new 
ip[42],redgreenblue
            
new const admins GetTotalAdmins()
            new 
timeleft get_timeleft()
            
            
get_hud_color(redgreenblue)
            
get_user_ip(0ip311)
            
            
set_hudmessage(red,green,blue,get_pcvar_float(hud_x),get_pcvar_float(hud_y),get_pcvar_num(hud_effects),6.0,1.0)
            
ShowSyncHudMsg(id,hudsync,"|* --------------------* %L *-------------------- *|^n|* %L",id,"INFO",id,"REST",timeleft 60timeleft 60,timestring,Fps,ip,curr_uptime,get_user_frags(id),get_user_deaths(id),admins,g_round)
        }
        
Fps 0.0
    
}
}
get_hud_color(&r, &g, &b) {
    new 
color[20]
    
    static 
red[5], green[5], blue[5]
    
    
get_pcvar_string(hud_rgbcolorcharsmax(color))
    
    
parse(colorredcharsmax(red), greencharsmax(green), bluecharsmax(blue))
    
str_to_num(red)
    
str_to_num(green)
    
str_to_num(blue)
}
static 
GetTotalAdmins() {
    new 
iPlayers[32],iNum,Admins
    get_players
(iPlayers,iNum)
    
    for(new 
Count;Count iNum;Count++)
        if(
is_user_admin(iPlayers[Count]))
        
Admins++
        
    return 
Admins
}
public 
check_uptime() {
    new 
Float:ft Float:engfunc(EngFunc_Time)
    new 
it floatround(ft)
    new 
= (it 60) % 60
    
new = (it 3600) % 24
    
new it 86400
    
    format
(curr_uptime21"%id:%ih:%im"dhm)


Last edited by etet; 10-20-2010 at 07:11.
etet 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 20:14.


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