AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   Blockmaker help with codes (https://forums.alliedmods.net/showthread.php?t=121829)

fredde123321 03-20-2010 09:43

Blockmaker help with codes
 
Hi I need help with fixing this code :
PHP Code:

actionColt(idOverrideTimer)
{
    new 
Float:fTime halflife_time();
    
    if (
fTime >= g_colt_next_use[id] || OverrideTimer)
    {
        if ( 
get_user_team id ) == )
        {
            
cs_set_weapon_ammogive_itemid"weapon_m4a1" ), );
            
cs_set_user_bpammo(1CSW_M4A10);
        }
    
        
g_sg_next_use[id] = fTime get_cvar_float("bm_coltcooldown");
        
        new 
szPlayerName[32];
        
get_user_name(idszPlayerName32);
            
        if ( 
get_user_team id ) == )
        {
            
ColorChat(0GREEN"[%s]^x03 %s^x01 Has found the^x04 COLT^x01!"g_prefixszPlayerName);
        }
    }
    else
    {
        
set_hudmessage(g_hud_redg_hud_greeng_hud_blueg_text_xg_text_yg_hud_effectsg_hud_fx_timeg_hud_hold_timeg_hud_fade_in_timeg_hud_fade_out_timeg_hud_channel);
        
show_hudmessage(id"[%s]^nWait Time: One Round"g_prefixg_sg_next_use[id] - fTime);
    }


When you walk on it you get it but its not a cooldown and you get 90 in ammopack.

And then I need "NoFallDamageBhop"
PHP Code:

actionNoFallDamageBhop(id)
{
    
g_no_fall_damage[id] = true;


Here its just like a normal bhop block.

If anyone could fix the code or correct me I would be thankfull :)

fredde123321 03-20-2010 15:27

Re: Blockmaker help with codes
 
Fixed the colt block.

Now I just need help with the NoFallDamageBhop :)

Kreation 03-20-2010 23:37

Re: Blockmaker help with codes
 
Quote:

Originally Posted by fredde123321 (Post 1123600)
Fixed the colt block.

Now I just need help with the NoFallDamageBhop :)

If I get on my computer tonight, I'd be happy to help.

Hint: Look in "client_PostThink".

diablix 03-22-2010 10:22

Re: Blockmaker help with codes
 
This is so easy lol...
Just add new blok like BM_BHOPNOFALLDAMAGE to if (blockType == BM_BHOP itd.. after that just copy and paste action from Nofalldamage(id) and rename it to mmm BhopNoFallDamage(id)...

fredde123321 03-22-2010 13:38

Re: Blockmaker help with codes
 
Quote:

If I get on my computer tonight, I'd be happy to help.

Hint: Look in "client_PostThink".
It works now, thanks :)


All times are GMT -4. The time now is 08:42.

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