Raised This Month: $ Target: $400
 0% 

JailBreak packets


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
GhostMan
Senior Member
Join Date: Jun 2012
Old 07-12-2012 , 05:33   JailBreak packets
Reply With Quote #1

PHP Code:
register_logevent("logevent_round_end"2"1=Round_End")  

logevent_round_end(id)
{
    if(
cs_get_user_team(id) == CS_TEAM_CT && is_user_alive(id))
    {    
        
g_jbpacks[id] += 5
        ChatColor
(id"| AMX | You got 5 JB Packets for ending this round alive." )
    }

Do i wrote all correct if i want to give 5 JP packets to alive ct on round end? It is jb shop 3.0 http://forums.alliedmods.net/showthread.php?t=118107

By the way, one more question from same plugin.

If i want that for players with T flag would be given 2x more JB Packs this is the best way to do it or is there more optimised or something?

PHP Code:
public fw_player_killed(victimattackershouldgib)
{

    if(!
is_user_connected(victim) || !is_user_connected(attacker) || attacker == victim || get_playersnum() < 4)
    return 
HAM_IGNORED

    
if(get_user_team(attacker) == 1)
    {
        if(
get_user_flags(attacker) & ADMIN_LEVEL_H)
        {
            
g_jbpacks[attacker] += get_pcvar_num(g_killjp) * 2
        
}
        else
        {
            
g_jbpacks[attacker] += get_pcvar_num(g_killjp)
        }
        
        if(
get_pdata_int(victim75) == HIT_HEAD)
        {
            if(
get_user_flags(attacker) & ADMIN_LEVEL_H)
            {
                
g_jbpacks[attacker] += get_pcvar_num(g_killhsjp) * 2
            
}
            else
            {
                
g_jbpacks[attacker] += get_pcvar_num(g_killhsjp)
            }
        }
    }
    return 
HAM_IGNORED


Last edited by GhostMan; 07-12-2012 at 05:44.
GhostMan 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 15:22.


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