Raised This Month: $ Target: $400
 0% 

Jail break shop


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
Tonda
Senior Member
Join Date: Aug 2009
Old 07-12-2010 , 16:59   Jail break shop
Reply With Quote #1

Hi, i like jail break shop plugin : http://forums.alliedmods.net/showthr...ight=jail+shop

but i need crate script: Admin with flag H get special points (40) and admin with acces flag get 50 points if kill enemy. I try this, but compile error, can you help me?

Code:
#include <amxmodx>
#include <hamsandwich>
#define ACCESS_FLAG ADMIN_LEVEL_H
new
g_jbpacks[33]
public plugin_init()
{
register_plugin("Ammo Pack", "1.2", "Tonda")
RegisterHam(Ham_Killed,  "player", "fw_player_killed")
}
public fw_player_killed(victim, attacker, shouldgib) {
    
    new iFlags = is_user_admin( attacker );
    new iPacks = g_jbpacks( attacker );
    
    if( iFlags & ACCESS_FLAG ) {
        if( iFlags & ADMIN_LEVEL_H ) {
            iPacks += 50;
            
            if( iPacks > 200 )
                iPacks = 200;
        } else {
            iPacks += 40;
            
            if( iPacks > 160 )
                iPacks = 160;
        }
        
        g_jbpacks( Attacker, iPacks );
    } 
    else {
        if( iPacks > 40 )
            g_jbpacks( attacker, 40 );
    }
}
Tonda 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 07:10.


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