Raised This Month: $ Target: $400
 0% 

A little problem. Can you help me?


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
mottzi
Veteran Member
Join Date: May 2010
Location: Switzerland
Old 06-22-2010 , 14:27   Re: A little problem. Can you help me?
Reply With Quote #5

Thanks i tried, but now it says "you already used" everytime i trz to use, but that cant be i never used it so limited[id] soudth be 1 -.-!

code:

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


new bartime1;
new 
bool:limited[33] = true;
 
public 
plugin_init()
{
    
bartime1 get_user_msgid("BarTime");
    
register_event"HLTV""roundstart1""a""1=0""2=0" )
    
register_clcmd("say pack","show_bar1")
}

public 
show_bar1(id)
{
    
    if(
limited[id] == true
    {
        
set_user_rendering(id,kRenderFxGlowShell,255,0,0,kRenderNormal,25)
        
message_begin(MSG_ONE,bartime1, {0,0,0} ,id);
        
write_short(10);
        
message_end();
        
set_task(9.5"after_bar1"id)
    }
    else
    {
        
client_print(idprint_chat"[HP] You already used ur healthpack! Nextround, you can use a new one.")
    }

}

public 
roundstart1(id)
{
    
  new 
players[32], pnumtempid;
  
get_players(playerspnum);

    
    for( new 
ii<pnumi++ )
    {
         
tempid players[i];
    
limited[tempid] = true;
    }
}

public 
after_bar1(id)
{

        
set_user_rendering(id,kRenderFxGlowShell,0,0,0,kRenderNormal,25
        
set_user_health(idget_user_health(id) + 40)
        
limited[id] = false;

mottzi is offline
Send a message via MSN to mottzi
 



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 14:46.


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