Raised This Month: $ Target: $400
 0% 

JailBreak packets


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
GhostMan
Senior Member
Join Date: Jun 2012
Old 07-12-2012 , 10:59   Re: JailBreak packets
Reply With Quote #5

Im not sure if your given code for second part is a corrert, becouse for killing CT it gives 3 JB packts (just an e.g.) and for doing it with HS it gives just +1, so in sum it will be 4 jb packets. And if look in your code for killing a ct it gives 3 packets and if you do it with HS it also gives 3 packets, so in sum it will be 6 packets.


Now, one more question, i would like to print for player how many packets he gets, so is there any better way than this?

PHP Code:
public fw_player_killed(victimattackershouldgib)
{

    if(!
is_user_connected(victim) || !is_user_connected(attacker) || attacker == victim || get_playersnum() < 4)
    return 
HAM_IGNORED
    
    
new killvip[attacker], kill[attacker], killviphs[attacker], killhs[attacker]

    if(
get_user_team(attacker) == 1)
    {
        if(
get_user_flags(attacker) & ADMIN_LEVEL_H)
        {
            
killvip[attacker] = true
            g_jbpacks
[attacker] += get_pcvar_num(g_killjp) * 2
        
}
        else
        {
            
kill[attacker] = true
            g_jbpacks
[attacker] += get_pcvar_num(g_killjp)
        }
        
        if(
get_pdata_int(victim75) == HIT_HEAD)
        {
            if(
get_user_flags(attacker) & ADMIN_LEVEL_H)
            {
                
killviphs[attacker] = true
                g_jbpacks
[attacker] += get_pcvar_num(g_killhsjp) * 2
            
}
            else
            {
                
killhs[attacker] = true
                g_jbpacks
[attacker] += get_pcvar_num(g_killhsjp)
            }
        }
        
        if(
killviphs[attacker]) {
            
ChatColor(attacker"|AMX| You got %d JP Packets for killing a CT + %d JB Packets for doing it with HS."get_pcvar_num(g_killjp) * 2get_pcvar_num(g_killhsjp) * 2)
            
killviphs false
        
}
        else if(
killhs[attacker]) {
            
ChatColor(attacker"|AMX| You got %d JP Packets for killing a CT + %d JB Packets for doing it with HS."get_pcvar_num(g_killjp), get_pcvar_num(g_killhsjp))
            
killhs[attacker] = false
        
}
        else if(!(
killviphs[attacker]) && killvip[attacker]) {
            
ChatColor(attacker"|AMX| You got %d JP Packets for killing a CT."get_pcvar_num(g_killjp))
            
killvip[attacker] = false
        
}
        else if(!(
killhs[attacker]) && kill[attacker]) {
            
ChatColor(attacker"|AMX| You got %d JP Packets for killing a CT."get_pcvar_num(g_killjp))
            
kill[attacker] = false
        
}
        
    }
    return 
HAM_IGNORED

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