Raised This Month: $ Target: $400
 0% 

Warning and Symbol is never used!


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
xeloxded
Member
Join Date: Dec 2016
Old 12-23-2016 , 09:31   Warning and Symbol is never used!
Reply With Quote #1

PHP Code:
#include <amxmodx>
#include <amxmisc>
#include <hamsandwich>
#include <fakemeta>
#include <engine>
#include <cstrike>
#include <fun>

#include <jailbreak_fg>
#include <colour_print>

#define m_iLastHitGroup        75
new const m_rgpPlayerItems]     =     { 367368, ... }

#define ADMIN_ITEM            ADMIN_RCON

    /*
        <^> Models.
    */
    
enum
{
    
v_model,
    
p_model
}
    
new const 
g_szMdlCrowbar[][] = 
{
    
"models/v_crowbar.mdl",
    
"models/p_crowbar.mdl"
}
    
    
/*
        <^> Arrays.
    */

new Array: g_aItemsMarket, Array: g_aItemsPlayer33 ], Array:g_aItemData, Array:g_aShopItems;

    
/*
        <^> Setup structures for player item data and market item data.
    */

enum _:ItemsShop
{
    
_iSHOP_INDEX,
    
_szSHOP_NAME32 ],
    
_iSHOP_COST,
    
_iSHOP_STOCK
}
    
enum _:ItemsMarket
{
    
_iMARKET_INDEX,
    
_iMARKET_COST,
    
_iMARKET_OWNER,
    
_iMARKET_DURABILITY
}

enum _:ItemsPlayer
{
    
_iITEMS_INDEX,
    
_IITEMS_QUANTITY,
    
_iITEMS_DURABILITY,
    
bool:_bITEMS_EQUIPPED
}

    
/*
        <^> Default item data.
    */

enum _:ItemData
{
    
_szDATA_NAME32 ],
    
_iDATA_DURABILITY,
    
_iDATA_CHANCE,
    
bool:_bDATA_EQUIP,
    
_szDATA_INFO128 ]
}

enum
{
    
ITEM_PAINKILLERS,
    
ITEM_STEROIDS,
    
ITEM_SMOKENADE,
    
ITEM_HENADE,
    
ITEM_FLASHBANG,
    
ITEM_HELMET,
    
ITEM_GRAVBOOTS,
    
ITEM_LOCKPICK,
    
ITEM_MEDKIT,
    
ITEM_GLOCK,
    
ITEM_CROWBAR,
    
ITEM_DISGUISE
};    

new const 
g_mItemData[][ ItemData ] =
{
    { 
"[Analgesico]", -11false"Devuelve una pequeña cantidad de HP cuando estas lesionado !g[Solo para uso]" }, //DONE
    
"[Esteroides]", -11false"Correras un %%50 mas rapido por corta duracion !g[Solo para uso]" }, //DONE
    
"[Granada de Humo]"4, -1false"Recibes una granada de humo !g[Solo para uso]" }, //DONE
    
"[Granada HE]", -14false"Recibiras una Granada HE !g[Solo para uso]" }, //DONE
    
"[Granada Flash]", -17false"Recibiras una flashbang !g[Solo para uso]" }, //DONE
    
"[Casco]"2010true"Casco que previene daño de Headshot !g[Te lo equipas]" },
    { 
"[Botas Anti-gravedad]"108true,  "Botas anti-gravitatorias que te permiten saltar alto !g[Te lo equipas]" }, //DONE
    
"[Candado]", -18false"Abre una celda bloqueada !g[Solo para uso]" }, //DONE
    
"[Kit medico]", -12false"Recupera tu HP al maximo !g[Solo para uso]" },
    { 
"[Glock mortal]", -19false"Glock 18 con una bala letal !g[Solo para uso]" }, //DONE
    
"[Garrote]"510true"Arma cuerpo a cuerpo que causa grandes daños !g[Te lo equipas]" },
    { 
"[Disfraz]", -17false"Te permita disfrazarte de guardia !g[Te lo equipas]" }
}

#define MAX_STANDARD_ITEMS    sizeof g_mItemData

    /*
        <^> Tasks.
    */

enum( += 32 )
{
    
TASK_STEROIDS 2000
}

    
/*
        <^> Cvar setup.
    */

#define MAX_PCVAR    22

enum _:_pCvar
{
    
CurrencyPreFix,
    
CurrencyPostFix,
    
EnableInventory,
    
EnableMarket,
    
EnableMegaShop,
    
EnableDataSaving,
    
CrowbarDamageX,
    
InventoryWhileDead,
    
MarketWhileDead,
    
ShopWhileDead,
    
MarketSellMin,
    
MarketSellMax,
    
MarketSellNum,
    
PainkillersHealth,
    
MarketBuyTime,
    
ShopBuyTime,
    
MarketBeforeOpen,
    
ShopBeforeOpen,
    
ItemUseInstantly,
    
CurrencyPerKill,
    
CurrencyPerRebel,
    
ChanceItemPerKill
}

new 
g_pCvar_pCvar ], g_pValue_pCvar ];

    
/*    
        <^> Ham forward pointers.
    */
    
new HamHook:_CBasePlayer_TakeDamage;

    
/*
        <^> Custom forward pointers.
    */

new ForwardHandle_UseItemForwardHandle_ResetMaxSpeedForwardHandle_ItemInteraction;

    
/*
        <^> Vars.
    */
    
new g_szAuthId33 ][ 34 ];

new 
g_iPlayerCash33 ], g_iTargetItem33 ] = -1g_iEquipData33 ][ sizeof g_mItemData ];
new 
g_iMaxPlayersg_iMenuMarketg_iMenuSellg_iMenuCallBack;

new 
bool:g_bCellsOpenedg_iMsgScreenFade;

#define SPEED_STANDARD    300.0
new Floatg_flPlayer_MaxSpeed33 ], Float:g_flRoundStart;

    
/*
        <^> Let's get started!
    */

public plugin_precache()
{
    
/*
        <^> Precache models.
    */
    
    
precache_modelg_szMdlCrowbarv_model ] );
    
precache_modelg_szMdlCrowbarp_model ] );
}
    
public 
plugin_init()
{
    
register_plugin"JailBreak FG : Items + Market + MegaShop""0.0.1""hornet" );
    
register_dictionary"jailbreak_fg.txt" );
    
    
g_iMaxPlayers get_maxplayers();
    
    
g_aItemData ArrayCreateItemData );
    
g_aItemsMarket ArrayCreateItemsMarket );
    
g_aItemData ArrayCreateItemData );
    
g_aShopItems ArrayCreateItemsShop );
        
    for( new 
g_iMaxPlayers ++ )
        
g_aItemsPlayer] = ArrayCreateItemsPlayer );
        
    
g_iMenuMarket menu_create"\yObjetos en el mercado negro:""MenuHandle_Market" );
    
    
g_pCvarCurrencyPreFix ]     = register_cvar"hjb_currency_prefix""" );
    
g_pCvarCurrencyPostFix ]     = register_cvar"hjb_currency_postfix""Jail Credits" );
    
    
g_pCvarEnableInventory ]    = register_cvar"hjb_enable_inventory""1" );
    
g_pCvarEnableMarket ]        = register_cvar"hjb_enable_market""0" );
    
g_pCvarEnableMegaShop ]     = register_cvar"hjb_enable_megashop""1" );
    
g_pCvarEnableDataSaving ]     = register_cvar"hjb_data_saving""0" );
    
    
g_pCvarCrowbarDamageX ]    = register_cvar"hjb_crowbar_dmg_x""1.3" );
    
    
g_pCvarInventoryWhileDead ]     = register_cvar"hjb_inv_while_dead""0" );
    
g_pCvarMarketWhileDead ]     = register_cvar"hjb_market_while_dead""0" );
    
g_pCvarShopWhileDead ]     = register_cvar"hjb_shop_while_dead""0" );
    
    
g_pCvarMarketSellMin ]    = register_cvar"hjb_market_sell_min""100" );
    
g_pCvarMarketSellMax ]    = register_cvar"hjb_market_sell_max""10000" );
    
g_pCvarMarketSellNum ]    = register_cvar"hjb_market_sell_num""20" );
    
    
g_pCvarPainkillersHealth ]    = register_cvar"hjb_painkillers_health""25" );
    
    
g_pCvarMarketBuyTime ]    = register_cvar"hjb_market_buy_time""0" );
    
g_pCvarShopBuyTime ]        = register_cvar"hjb_shop_buy_time""0" );
    
g_pCvarMarketBeforeOpen ]    = register_cvar"hjb_market_before_open""0" );
    
g_pCvarShopBeforeOpen ]    = register_cvar"hjb_shop_before_open""1" );
    
g_pCvarItemUseInstantly ]    = register_cvar"hjb_item_use_instantly""0" );
    
    
g_pCvarCurrencyPerKill ]    = register_cvar"hjb_currency_per_kill""100" );
    
g_pCvarCurrencyPerRebel ]    = register_cvar"hjb_currency_per_rebel""25" );
    
g_pCvarChanceItemPerKill ]    = register_cvar"hjb_item_chance_kill""5" );
    
    
OnHJB_CvarsUpdated();
    
    
RegisterHamHam_CS_Player_ResetMaxSpeed"player""CBasePlayer_ResetMaxSpeed");
    
_CBasePlayer_TakeDamage RegisterHamHam_TakeDamage"player""CBasePlayer_TakeDamage" );
    
    
register_concmd"hjb_giveitem""ConsoleCommand_GiveItem" );
    
register_concmd"hjb_givecash""ConsoleCommand_GiveCash" );
    
    
//register_clcmd( "say /menu", "ClientCommand_Menu" );
    
register_clcmd"say /market""ClientCommand_Market" );
    
register_clcmd"say /shop""ClientCommand_MegaShop" );
    
register_clcmd"say /inv""ClientCommand_Inventory" );
    
    
g_iMsgScreenFadeget_user_msgid"ScreenFade" );
    
    
g_iMenuCallBack menu_makecallback"Menu_CallBack" );
    
    
register_impulse100"ClientCommand_Menu" );
    
    
ForwardHandle_UseItem CreateMultiForward"OnHJB_UseItem"ET_STOPFP_CELL );
    
ForwardHandle_ResetMaxSpeed CreateMultiForward"OnHJB_ResetMaxSpeed"ET_STOPFP_CELL );
    
ForwardHandle_ItemInteraction CreateMultiForward"OnHJB_ItemInteraction"ET_STOPFP_CELL );

    
set_task2.0"ConfigureMegaShop" );
    
//set_task( 3.0, "ConfigureMarket" );
    //set_task( 4.0, "BuildMarket" );
    
    
BuildMenuSell();
    
    
server_cmd"mp_flashlight 0" );
    
server_cmd"sv_maxspeed 400" );
}    

public 
ConfigureMegaShop()
{
    
/*
        <^> Reads the MegaShop configuration file.
    */
    
    
new szFile64 ];
    
get_configsdirszFilecharsmaxszFile ) );
    
    
formatexszFilecharsmaxszFile ), "%s/JailBreak FG/MegaShop.cfg"szFile );
    
    new 
iFile fopenszFile"r" );
    
    if( !
iFile )
    {
        
log_amx"Failed to find file 'configs/JailBreak FG/MegaShop.cfg'" );
        return;
    }
    
    const 
MAX_SHOP_FIELDS 2;
    
    new 
ArrayDataItemsShop ], ArrayData2ItemData ];
    new 
szText32 ], szField], szValue];
    new 
iCountiSizeiSize2;
    
    
//ArrayPushArray( g_aShopItems, ArrayData );
    
    
while( !feofiFile ) )
    {
        
fgetsiFileszTextcharsmaxszText ) );
        
trimszText );
        
        if( 
szText] == ';' || szText] == '/' || !strlenszText ) )
            continue;
        
        if( 
iCount >= MAX_SHOP_FIELDS )
        {
            
/*
                <^> This section matches the item names with the corresponding data
                    and adds them to the shop menu accordingly.
            */
            
            /*
                <^> First loop checks the standard items.
            */
            
            
iSize ArraySizeg_aShopItems );
            
            for( new 
MAX_STANDARD_ITEMS ++ )
            {    
                if( 
equalArrayData_szSHOP_NAME ], g_mItemData][ _szDATA_NAME ] ) )
                {
                    
ArrayData_iSHOP_INDEX ] = i;
                    
                    
ArrayInsertArrayAfterg_aShopItemsiSize 1ArrayData );
                    
                    goto 
Next;
                }
            }
            
            
/*
                <^> Second loop checks any items that are added from 3rd party
                    plugins.
            */
            
            
iSize ArraySizeg_aItemData );
            
iSize2 ArraySizeg_aShopItems ) - 1;
        
            for( new 
iSize2 ++ )
            {
                
ArrayGetArrayg_aItemDataiArrayData2 );
                
                if( 
equalArrayData_szSHOP_NAME ], ArrayData2_szDATA_NAME ] ) )
                {
                    
ArrayData_iSHOP_INDEX ] = MAX_STANDARD_ITEMS;
                    
                    
ArrayInsertArrayAfterg_aShopItemsiSizeArrayData );
                    
                    goto 
Next;
                }
            }
            
            
log_amx"Failed to add item %s to MegaShop"ArrayData_szSHOP_NAME ] );
            
            
Next:
            {
                
//
            
}
            
            
iCount 0;
        }
        
        if( 
szText] == '[' )
        {
            
/*
                <^> Obtain the item name.
            */
            
            
replaceszTextcharsmaxszText ), "[""" );
            
replaceszTextcharsmaxszText ), "]""" );
            
            
copyArrayData_szSHOP_NAME ], charsmaxArrayData_szSHOP_NAME ] ), szText );
        }
        else
        {
            
/*
                <^> Read all fields such as cost and stocks.
            */
            
            
parseszTextszFieldcharsmaxszField ), szValuecharsmaxszValue ) );
            
            if( 
equalszField"cost" ) )
            {
                
ArrayData_iSHOP_COST ] = str_to_numszValue );
            }
            else     if( 
equalszField"stock" ) )
            {
                
ArrayData_iSHOP_STOCK ] = str_to_numszValue );
            }
            else    
log_amx"Failed to load field for item %s"ArrayData_szSHOP_NAME ] );
            
            
iCount ++;
        }
    }
    
    
fcloseiFile );
}

public 
ConfigureMarket()
{
    
/*
        <^> Reads the Market configuration file.
    */
    
    
new szFile64 ];
    
get_configsdirszFilecharsmaxszFile ) );
    
    
formatexszFilecharsmaxszFile ), "%s/JailBreak FG/Market.cfg"szFile );
    
    new 
iFile fopenszFile"r" );
    
    if( !
iFile )
    {
        
log_amx"Failed to find file 'configs/JailBreak FG/Market.cfg'" );
        return;
    }
    
    const 
MAX_SHOP_FIELDS 2;
    
    new 
ArrayDataItemsShop ], ArrayData2ItemData ];
    new 
szText32 ], szField], szValue];
    new 
iCountiSizeiSize2;
    
    
//ArrayPushArray( g_aShopItems, ArrayData );
    
    
while( !feofiFile ) )
    {
        
fgetsiFileszTextcharsmaxszText ) );
        
trimszText );
        
        if( 
szText] == ';' || szText] == '/' || !strlenszText ) )
            continue;
    }
}

public 
BuildMarket()
{
    if( !
g_pValueEnableMarket ] || g_pValueItemUseInstantly ] )
        return;
    
    
/*
        <^> This section will put a random amount of items on the market and set 
            them up with a reasonably random price.
    */
    
    /*
        This section is to be revised.
    */
    
    
    
new iCountiRandItems14 ];
        
    if( !
random_num0) )
    {
        while( 
iCount 10 )
        {
            
iRand random_num0sizeof g_mItemData );
            
            if( 
g_mItemDataiRand ][ _bDATA_EQUIP ] )
            {
                
ItemsiCount ] = iRand;
                
iCount ++;
            }
        }
    
        
AddToMarket( -1Itemsrandom_num0sizeof Items ) ], 5000 );
    }
    
    new 
iPrices[] = { 5560657075 };
    
    
iCount 0;
    
    while( 
iCount 10 )
    {
        
iRand random_num0sizeof g_mItemData );
        
        if( 
g_mItemDataiRand ][ _iDATA_DURABILITY ] == -)
        {
            
ItemsiCount ] = iRand;
            
iCount ++;
        }
    }
    
    for( new 
sizeof Items ++ )
        if( 
random_num0) )
            
AddToMarket0Items], g_mItemDataItems] ][ _iDATA_CHANCE ] * iPricesrandom_num0sizeof iPrices ) ] );
}

BuildMenuSell()
{
    if( !
g_pValueEnableMarket ] || g_pValueItemUseInstantly ] )
        return;
    
    
/*
        <^> Builds the item sell menu.
    */
    
    
new szMenu64 ];
    
formatexszMenucharsmaxszMenu ), "\y%L"LANG_SERVER"MENU_SELL_FOR" );
    
    
g_iMenuSell menu_createszMenu"MenuHandle_SellItem" );
    
    
/*
        <^> The system is set so there will be half low options and half high options,
            divided in the middle between mins and maxs.
    */
    
    
new Float:flMin get_pcvar_floatg_pCvarMarketSellMin ] );
    new 
Float:flMax get_pcvar_floatg_pCvarMarketSellMax ] );
    new 
Float:flNum get_pcvar_floatg_pCvarMarketSellNum ] );
    
    new 
Float:iIncrement flMax / ( flNum ) / ( flNum );
    
    new 
iMid floatroundflNum 2floatround_floor );
    
    new 
szNum16 ], szInfo32 ];
    
    for( new 
iMid ++ )
    {
        
num_to_strfloatroundiIncrement flMin ), szNumcharsmaxszNum ) );
        
formatexszInfocharsmaxszInfo ), "%s%i %s"GetCvarStringCurrencyPreFix ), floatroundiIncrement flMin ), GetCvarStringCurrencyPostFix ) );
        
        
menu_additemg_iMenuSellszNumszInfo );
    }
    
    
iIncrement flMax / ( flNum );
    
iMid floatroundflNum 2floatround_ceil );
    
    for( new 
iMid flNum ++ )
    {
        
num_to_strfloatround( ( ( ) - iMid )  * ( iIncrement ) ), szNumcharsmaxszNum ) );
        
formatexszInfocharsmaxszInfo ), "%s%i %s"GetCvarStringCurrencyPreFix ), floatround( ( ( ) - iMid )  * ( iIncrement ) ), GetCvarStringCurrencyPostFix ) );
        
        
menu_additemg_iMenuSellszNumszInfo );
    }
}


    
/*---------------------------------|
    |    Connection           |
    |---------------------------------*/

public client_putinserverid )
{
    
/*
        <^> Bots are no good at this game. They tend to freekill :|
            And when you kick them they just come back ...
    */
    
    
if( is_user_botid ) )
        return;
    
    
/*
        <^> Load the players data.
    */
    
    
if( g_pValueEnableDataSaving ] )
    {
        
        
get_user_authididg_szAuthIdid ], charsmaxg_szAuthId[] ) );
        
LoadDataid );
    }
    
    
/*
        <^> Reset player's max speed.
    */
    
    
g_flPlayer_MaxSpeedid ] = SPEED_STANDARD;
}
    
public 
client_disconnectid )
{
    if( 
is_user_botid ) )
        return;
    
    
remove_taskid TASK_STEROIDS );
    
    
/*
        <^> Save the player's data and then return all their items to them if they
            had any on the market. Market menu must also be rebuilt.
    */
    
    
if( !g_pValueEnableDataSaving ] || g_pValueItemUseInstantly ] || cs_get_user_teamid ) != CS_TEAM_T )
        return;
    
    new 
iSize ArraySizeg_aItemsMarket );
    new 
ArrayDataItemsMarket ], ArrayData2ItemsPlayer ], iItem;
    
    for( new 
iSize ++ )
    {
        
ArrayGetArrayg_aItemsMarketiArrayData );
        
        if( 
ArrayData_iMARKET_OWNER ] == id )
        {
            
iItem HJB_GiveUserItemidArrayData_iMARKET_INDEX ] );
            
            
ArrayGetArrayg_aItemsPlayerid ], iItemArrayData2 );
            
ArrayData2_iITEMS_DURABILITY ] = ArrayData_iMARKET_DURABILITY ];
            
ArraySetArrayg_aItemsPlayerid ], iItemArrayData2 );
        }
    }
    
    
SaveDataid );
        
    
MenuRebuildg_iMenuMarket );
    
    
ArrayClearg_aItemsPlayerid ] );
    
    for( new 
sizeof g_mItemData ++ )
    {
        
g_iEquipDataid ][ ] = 0;
    }
}

public 
plugin_end()
{
    
/*
        <^> Save the player's data and then return all their items to them if they
            had any on the market.
    */
    
    
if( !g_pValueEnableDataSaving ] )
        return;
    
    new 
iSize ArraySizeg_aItemsMarket );
    new 
ArrayDataItemsMarket ];
    
    for( new 
iSize ++ )
    {
        
ArrayGetArrayg_aItemsMarketiArrayData );
        
HJB_GiveUserItemArrayData_iMARKET_OWNER ], ArrayData_iMARKET_INDEX ] );
    }
    
    new 
Players32 ], iNum;
    
get_playersPlayersiNum"eh""TERRORIST" );
    
    for( new 
iNum ++ )
        
SaveDataPlayers] );
        
    
/*
        <^> Destroy arrays.
    */
    
    //ArrayDestroy( g_aItemData );
    //ArrayDestroy( g_aItemsMarket );
    //ArrayDestroy( g_aItemData );
    //ArrayDestroy( g_aShopItems );
}

    
/*---------------------------------|
    |    HJB Forwards           |
    |---------------------------------*/

public OnHJB_CvarsUpdated()
{
    
/*
        <^> Retrieve all our cvar values now so we can cache them and dont have to call
            the native again later.
    */
    
    /*
        <^> int x is the amount of cvars that are actually strings.
    */
    
    /*
        <^> Method requires some reworking. It's a stupid idea ....
    */
    
    
new 2;
    
    for( new 
MAX_PCVAR ++ )
        
g_pValue] = get_pcvar_numg_pCvar] );
        
    
/*
        <^> Called at roundstart.
    */
    
    
g_flRoundStart get_gametime();
}

public 
OnHJB_PlayerSpawnid )
{
    
/*
        <^> Called when player spawns.
    */
    
    
UTIL_ScreenFadeid1<<121<<60x0000000255 );
    
    if( 
cs_get_user_teamid ) != CS_TEAM_T )
        return;
    
    
/*
        <^> Damages player's items.
    */
    
    
new ArrayDataItemsPlayer ], iSize ArraySizeg_aItemsPlayerid ] );
    
    for( new 
iSize ++ )
    {
        
ArrayGetArrayg_aItemsPlayerid ], iArrayData );
        
        if( 
g_mItemDataArrayData_iITEMS_INDEX ] ][ _bDATA_EQUIP ] && ArrayData_bITEMS_EQUIPPED ] )
        {
            
ArrayData_iITEMS_DURABILITY ] -= random_num0);
            
ArraySetArrayg_aItemsPlayerid ], iArrayData );
            
            if( 
ArrayData_iITEMS_DURABILITY ] < )
            {
                
ArrayDeleteItemg_aItemsPlayerid ], );
                Print( 
idtrue"Your !g%s !nwas destroyed!"g_mItemDataArrayData_iITEMS_INDEX ] ][ _szDATA_NAME ] );
            }
        }
    }
        
    
/*
        <^> Setup any items that will be used automatically if they are equipped.
    */
        
    
new iItemIndex;
        
    for( new 
iSize ++ )
    {
        
ArrayGetArrayg_aItemsPlayerid ], iArrayData );
            
        
iItemIndex ArrayData_iITEMS_INDEX ];
            
        if( 
iItemIndex == ITEM_GRAVBOOTS )
            
HandleItemidiItemIndex );
    }
}

public 
OnHJB_DeployKnifeid )
{
    
/*
        <^> Called when a player draws his knife.
    */
    
    
if( HJB_IsItemEquippedidITEM_CROWBAR ) )
    {
        
/*
            <^> Here we will set the player's crowbar model if he is using one.
        */
        
        
set_pevidpev_viewmodel2g_szMdlCrowbarv_model ] );
        
set_pevidpev_weaponmodel2g_szMdlCrowbarp_model ] );
        
        return 
PLUGIN_HANDLED;
    }
    
    return 
PLUGIN_CONTINUE;
}

public 
OnHJB_PlayerKilledidiKiller )
{
    
/*
        <^> Handles users wearing a disguise.
    */
    
    
switch( get_user_teamid ) )
    {
        case 
CS_TEAM_T:
        {
            
cs_reset_user_modelid );
        }
        
        case 
CS_TEAM_CT:
        {
            if( ( 
<= iKiller <= g_iMaxPlayers ) && cs_get_user_teamiKiller ) == CS_TEAM_T )
            {
                
/*
                    <^> Cash reward for killing Guards.
                */
                
                
new iAmount g_pValueCurrencyPerKill ];
                
                if( 
iAmount )
                    
HJB_GiveUserCurrencyiKilleriAmount );
                    
                
/*
                    <^> Item reward.
                */
                
                
if( !g_pValueItemUseInstantly ] )
                {
                    
iAmount g_pValueChanceItemPerKill ];
                    
                    if( 
iAmount )
                    {
                        if( 
random_num1iAmount ) == )
                            
HJB_GiveUserItemiKiller, -1true );
                    }
                }
            }
        }        
    }
}

public 
OnHJB_PlayerRebelledid )
{
    new 
iAmount g_pValueCurrencyPerRebel ];
    
    if( 
iAmount )
        
HJB_GiveUserCurrencyidiAmount );
}

public 
OnHJB_MainMenuBuildid )
{
    if( 
is_user_connectedid ) )
    {
        
HJB_SendMenuItemid"MENU_INVENTORY"MENU_INVENTORY, !g_pValueItemUseInstantly ] && cs_get_user_teamid ) == CS_TEAM_T true false );
        
HJB_SendMenuItemid"MENU_MEGASHOP_MAIN"MENU_SHOPg_pValueEnableMegaShop ] && cs_get_user_teamid ) == CS_TEAM_T true false );
        
HJB_SendMenuItemid"MENU_MARKET_MAIN"MENU_MARKETg_pValueEnableMarket ] && cs_get_user_teamid ) == CS_TEAM_T true false );
    }
}

public 
OnHJB_MainMenuOpenidiIndex )
{
    if( 
is_user_connectedid ) )
    {
        switch( 
iIndex )
        {
            case 
MENU_INVENTORY:
            {
                
ClientCommand_Inventoryid );
            }
            
            case 
MENU_SHOP:
            {
                
ClientCommand_MegaShopid );
            }
            
            case 
MENU_MARKET:
            {
                
ClientCommand_Marketid );
            }
        }
    }
}

    
/*
        <^> These forwards are only required if your running Last Request.
    */
    
public OnHJB_LastRequestStart()
{
    
DisableHamForward_CBasePlayer_TakeDamage );
}

public 
OnHJB_LastRequestEnd()
{
    
EnableHamForward_CBasePlayer_TakeDamage );
}

    
/*
        <^> These forwards are only required if your running Day Events.
    */

public OnHJB_DayEventStart()
{
    
DisableHamForward_CBasePlayer_TakeDamage );
}

public 
OnHJB_DayEventEnd()
{
    
EnableHamForward_CBasePlayer_TakeDamage );
}

public 
OnHJB_CellsOpened()
{
    
/*
        <^> Will be called from Cell Opener plugin. If your not using it and no other
            plugins calls this forward then the functionality will be useless.
    */
    
    
g_bCellsOpened true;
}

    
/*---------------------------------|
    |    Ham Forwards           |
    |---------------------------------*/

public CBasePlayer_ResetMaxSpeedid )
{
    if( !
is_user_aliveid ) )
        return 
HAM_IGNORED;
    
    
/*
        <^> This plugin can change a player's maxspeed with an item or other things.
            When this occurs then the plugin must send this info via a forward
            and give other plugins such as Last Request or Game Events the chance
            to supercede the player's speed from changing.
    */
    
    
new iReturn;
    
    
ExecuteForwardForwardHandle_ResetMaxSpeediReturnid );
    
    
/*
        <^> If PLUGIN_HANDLED wasn't returned then change speed!
    */
    
    
if( !iReturn )
    {
        
set_user_maxspeedidg_flPlayer_MaxSpeedid ] );
    }
    
    return 
HAM_IGNORED;
}

public 
CBasePlayer_TakeDamageiVictimiEntiAttackerFloat:flDamageBits )
{
    if( 
<= iAttacker <= g_iMaxPlayers )
    {
        
/*
            <^> Check if player is using a crowbar and add extra damage for it.
        */
        
        
if( cs_get_user_teamiAttacker ) == CS_TEAM_T && HJB_IsItemEquippediAttackerITEM_CROWBAR ) )
            
SetHamParamFloat4flDamage get_pcvar_floatg_pCvarCrowbarDamageX ] ) );
        
        
/*
            <^> Check if a player is wearing a helmet and remove damage.
        */
        
        
if( get_pdata_intiAttackerm_iLastHitGroup ) == HIT_HEAD && HJB_IsItemEquippediAttackerITEM_HELMET ) )
        {
            
emit_soundiVictimCHAN_VOICE"weapons/ric_metal-1.wav"1.0ATTN_NORM0PITCH_NORM );
            
SetHamParamFloat40.0 );
        }
    }
}

    
/*---------------------------------|
    |        Tasks           |
    |---------------------------------*/
    
public Task_Steroidsid )
{
    
id -= TASK_STEROIDS;
    
    
g_flPlayer_MaxSpeedid ] = get_user_maxspeedid );
    
    if( 
is_user_connectedid ) )
    {
        
ExecuteHamHam_CS_Player_ResetMaxSpeedid );
        
UTIL_ScreenFadeid3<<121<<60x000025500200 );
    }
}

    
/*---------------------------------|
    |    Admin Commands           |
    |---------------------------------*/
    
public ConsoleCommand_GiveItemid )
{
    
/*
        <^> This is the admin command to give a player an item.
    */
    
    
if( accessidADMIN_ITEM ) )
    {
        new 
szArg][ 32 ];
            
        
read_argv1szArg], charsmaxszArg[] ) );
        
read_argv2szArg], charsmaxszArg[] ) );
            
        new 
iTarget cmd_targetidszArg], CMDTARGET_ALLOW_SELF );
        new 
iItemIndex str_to_numszArg] );
            
        static 
szName][ 32 ], szAction128 ];
        
get_user_nameidszName], charsmaxszName[] ) );
        
get_user_nameiTargetszName], charsmaxszName[] ) );
        
        
HJB_GiveUserItemiTargetiItemIndex );
        
        
formatszActioncharsmaxszAction ), "%L"LANG_SERVER"ADMIN_GIVE_ITEM"szName], g_mItemDataiItemIndex ][ _szDATA_NAME ], szName] );
        
client_print0print_chatszAction );
        
        
log_amxszAction );
    }
    else 
    {
        
console_printid"%L"LANG_SERVER"CMD_NO_ACCESS" );
        return 
PLUGIN_HANDLED;
    }
    
    return 
PLUGIN_HANDLED;
}

public 
ConsoleCommand_GiveCashid )
{
    
/*
        <^> This is the admin command to give currency to players.
    */
    
    
if( accessidADMIN_ITEM ) )
    {
        new 
szArg][ 32 ];
            
        
read_argv1szArg], charsmaxszArg[] ) );
        
read_argv2szArg], charsmaxszArg[] ) );
            
        new 
iTarget cmd_targetidszArg], CMDTARGET_ALLOW_SELF );
        new 
iAmount str_to_numszArg] );
            
        static 
szName][ 32 ], szAction128 ];
        
get_user_nameidszName], charsmaxszName[] ) );
        
get_user_nameiTargetszName], charsmaxszName[] ) );
        
        
HJB_GiveUserCurrencyiTargetiAmount );
        
        
formatszActioncharsmaxszAction ), "%L"LANG_SERVER"ADMIN_GIVE_CURRENCY"szName], GetCvarStringCurrencyPreFix ), iAmountGetCvarStringCurrencyPostFix ), szName] );
        
client_print0print_chatszAction );
        
        
log_amxszAction );
    }
    else 
    {
        
console_printid"%L"LANG_SERVER"CMD_NO_ACCESS" );
        return 
PLUGIN_HANDLED;
    }
    
    return 
PLUGIN_HANDLED;
}

    
/*---------------------------------|
    |    Client Commands           |
    |---------------------------------*/
    
public Menu_CallBack()
{
    return 
ITEM_DISABLED;
}
    
public 
ClientCommand_Menuid )
{
    if( 
cs_get_user_teamid ) != CS_TEAM_T )
        return 
PLUGIN_HANDLED;
    
    
/*
        <^> Allow other plugins to prevent the Market from being opened.
    */
    
    
new iReturn;
    
ExecuteForwardForwardHandle_ItemInteractioniReturnid );
    
    if( 
iReturn )
    {
        Print( 
idRED"!g%L"id"MENU_UNAVAILABLE" );
        return 
PLUGIN_HANDLED;
    }
    
    new 
szMenu128 ];
    
formatexszMenucharsmaxszMenu ), "\y%s%L"MENU_TITLEid"MENU_PLAYER" );
    
    
/*
        <^> Search for player's inventory items and display them.
    */
    
    
new iMenu menu_createszMenu"MenuHandle_PlayerMenu" );
    
    
formatexszMenucharsmaxszMenu ), "%L"id"PLAYERMENU_INVENTORY" );
    
menu_additemiMenuszMenu__g_pValueEnableInventory ] && g_pValueItemUseInstantly ] ? g_iMenuCallBack : -);
    
    
formatexszMenucharsmaxszMenu ), "%L"id"PLAYERMENU_MEGASHOP" );
    
menu_additemiMenuszMenu_, ( g_pValueShopBeforeOpen ] && g_bCellsOpened ) || ( g_pValueShopBuyTime ] && GetRoundTime() > g_pValueShopBuyTime ] ) ? g_iMenuCallBack : -);
    
    
formatexszMenucharsmaxszMenu ), "%L"id"PLAYERMENU_MARKET" );
    
menu_additemiMenuszMenu__, ( g_pValueMarketBeforeOpen ] && g_bCellsOpened ) || ( g_pValueMarketBuyTime ] && GetRoundTime() > g_pValueMarketBuyTime ] ) ? g_iMenuCallBack : -);
    
    
menu_displayidiMenu );
    
    return 
PLUGIN_HANDLED;
}
    
public 
ClientCommand_Marketid )
{
    
/*
        <^> Brings up the market menu if it's not disabled.
            Controllable via cvar.
    */
    
    
if( !g_pValueEnableMarket /*|| g_pValue[ ItemUseInstantly ]*/ )
    {
        Print( 
idRED"%L"id"MARKET_DISABLED" );
        
        return;
    }
    
    
/*
        <^> Allow other plugins to prevent the Market from being opened.
    */
    
    
new iReturn;
    
ExecuteForwardForwardHandle_ItemInteractioniReturnid );
    
    if( 
iReturn || ( !g_pValueMarketWhileDead ] && !is_user_aliveid ) ) )
    {
        Print( 
idRED"!g%L"id"MENU_UNAVAILABLE" );
        return;
    }
    
    if( ( 
g_pValueMarketBeforeOpen ] && g_bCellsOpened ) || ( g_pValueMarketBuyTime ] && GetRoundTime() > g_pValueMarketBuyTime ] ) )
    {
        Print( 
idRED"%L"id"MARKET_CLOSED" );
        return;
    }
    
    Print( 
idBLUE"%L"id"CURRENCY_YOU_HAVE"GetCvarStringCurrencyPreFix ), g_iPlayerCashid ], GetCvarStringCurrencyPostFix ) );
    
    new 
iSize ArraySizeg_aItemsMarket );
    
    if( !
iSize )
    {
        Print( 
idRED"%L"id"MARKET_NO_ITEMS" );
        return;
    }
    
    
menu_displayidg_iMenuMarket );
}

public 
ClientCommand_MegaShopid )
{
    if( 
cs_get_user_teamid ) != CS_TEAM_T )
        return;
    
    
/*
        <^> Command to bring up the megashop.
    */
    
    /*
        <^> Allow other plugins to prevent from being opened.
    */
    
    
new iReturn;
    
ExecuteForwardForwardHandle_ItemInteractioniReturnid );
    
    if( 
iReturn )
    {
        Print( 
idRED"!g%L"id"MENU_UNAVAILABLE" );
        return;
    }
    
    if( ( 
g_pValueShopBeforeOpen ] && g_bCellsOpened ) || ( g_pValueShopBuyTime ] && GetRoundTime() > g_pValueShopBuyTime ] ) )
    {
        Print( 
idRED"%L"id"MEGASHOP_CLOSED" );
        return;
    }
    
    if( 
g_pValueEnableMegaShop ] )
    {
        new 
szMenu256 ];
        
formatexszMenucharsmaxszMenu ), "\y%s%L"MENU_TITLEid"MENU_MEGASHOP"GetCvarStringCurrencyPreFix ), g_iPlayerCashid ], GetCvarStringCurrencyPostFix ) );
        
        new 
iMenu menu_createszMenu"MenuHandle_MegaShop" );
        
        new 
ArrayDataItemsShop ], szInfo128 ], szStock16 ];
        new 
iSize ArraySizeg_aShopItems ), iStock
        
        
const ITEMS_PER_PAGE 3;
        
        for( new 
iSize ++ )
        {
            
ArrayGetArrayg_aShopItemsiArrayData );
            
            
iStock ArrayData_iSHOP_STOCK ];
            
            if( 
iStock == -)
                
szStock "Unlimited";
            else if( 
iStock == )
                
szStock "Out Of Stock";
            else    
num_to_striStockszStockcharsmaxszStock ) );
            
            
formatexszInfocharsmaxszInfo ), "%s^n    \yCost: %i^n    \yStock: %s^n"ArrayData_szSHOP_NAME ], ArrayData_iSHOP_COST ], szStock );
            
menu_additemiMenuszInfo );
            
            
/*
                <^> This part is the key to making items appear nicely on the menu.
            */

            
if( !( ( ) % ITEMS_PER_PAGE ) )
            {
                for( new 
ITEMS_PER_PAGE MPROP_ORDER ++ )
                    
menu_addblank2iMenu );
            }
            
        }
        
        
//menu_setprop( iMenu, MPROP_PERPAGE, ITEMS_PER_PAGE );
        
        
menu_displayidiMenu );
    }
    else
    {
        Print( 
idRED"%L"id"MEGASHOP_DISABLED" );
    }
}
    
public 
ClientCommand_Inventoryid )
{
    
/*
        <^> Only Prisoners may use this menu.
    */
    
    
if( cs_get_user_teamid ) != CS_TEAM_T || !g_pValueEnableInventory ] )
        return;
        
    if( 
g_pValueItemUseInstantly ] || ( !g_pValueInventoryWhileDead ] && !is_user_aliveid ) ) )
        return;
    
    
/*
        <^> Send this forward so other plugins know that the player is trying to open
            his inventory. This gives them the chance to prevent this, just in case
            Last Request is running or Day Event is running.
    */
    
    
new iReturn;
    
    
ExecuteForwardForwardHandle_ItemInteractioniReturnid );
    
    if( 
iReturn )
        return;
    
    
/*
        <^> Otherwise continue on.
    */
    
    
new iSize ArraySizeg_aItemsPlayerid ] );
    
    if( !
iSize )
    {
        Print( 
idRED"%L"id"ITEMS_HAVE_NONE" );
        Print( 
idRED"%L"id"CURRENCY_YOU_HAVE"GetCvarStringCurrencyPreFix ), g_iPlayerCashid ], GetCvarStringCurrencyPostFix ) );

        return;
    }
    
    new 
szMenu256 ];
    
formatexszMenucharsmaxszMenu ), "\y%s%L"MENU_TITLEid"MENU_ITEM_SELECT"GetCvarStringCurrencyPreFix ), g_iPlayerCashid ], GetCvarStringCurrencyPostFix ) );
    
    
/*
        <^> Search for player's inventory items and display them.
    */
    
    
new iMenu menu_createszMenu"MenuHandle_Inventory" );
    new 
szItem64 ], ArrayDataItemsPlayer ];
    
    for( new 
iSize ++ )
    {
        
ArrayGetArrayg_aItemsPlayerid ], ArrayData );
        
        if( 
g_mItemDataArrayData_iITEMS_INDEX ] ][ _bDATA_EQUIP ] )
        {
            
formatexszItemcharsmaxszItem ), "%s%s \y[ \w%%%i Durability \y]"ArrayData_bITEMS_EQUIPPED ] ? "\y" ""g_mItemDataArrayData_iITEMS_INDEX ] ][ _szDATA_NAME ], floatroundFloat:ArrayData_iITEMS_DURABILITY ] / Float:g_mItemDataArrayData_iITEMS_INDEX ] ][ _iDATA_DURABILITY ] * 100.0 ) );
        }
        else
        {
            
formatexszItemcharsmaxszItem ), "%s \R \rx%i"g_mItemDataArrayData_iITEMS_INDEX ] ][ _szDATA_NAME ], ArrayData_IITEMS_QUANTITY ] );
        }
        
        
menu_additemiMenuszItem );
    }
    
    
menu_displayidiMenu );
}

    
/*---------------------------------|
    |    Menus and Handlers       |
    |---------------------------------*/

public MenuHandle_PlayerMenuidiMenuiItem )
{
    
menu_destroyiMenu );
    
    switch( 
iItem )
    {
        case 
MENU_EXIT:    
        {
            return;
        }
        
        case 
0:
        {
            
ClientCommand_Inventoryid );
        }
        
        case 
1:
        {
            
ClientCommand_MegaShopid );
        }
        
        case 
2:
        {
            
ClientCommand_Marketid );
        }
    }
}
    
public 
MenuHandle_MarketidiMenuiItem )
{
    
/*
        <^> A player has clicked on a market item.
    */
    
    
if( iItem == MENU_EXIT )
    {
        return;
    }
    
    new 
ArrayDataItemsMarket ];
    
ArrayGetArrayg_aItemsMarketiItemArrayData );
    
    new 
iCost ArrayData_iMARKET_COST ];
    
    if( 
g_iPlayerCashid ] >= iCost )
    {
        
/*
            <^> The player bought the item.
                Remove the item from the array and give it to the player, and also
                rebuild the market menu.
        */
        
        
new szName32 ];
        
get_user_nameidszNamecharsmaxszName ) );
        
g_iPlayerCashid ] -= iCost;
        
        if( 
ArrayData_iMARKET_OWNER ] > )
        {
            
g_iPlayerCashArrayData_iMARKET_OWNER ] ] += iCost;
            
            if( 
ArrayData_iMARKET_INDEX ] > )
                Print( 
ArrayData_iMARKET_OWNER ], BLUE"!g%s !tBOUGHT !nyour !g%s !nfor !g$%i"szNameg_mItemDataArrayData_iMARKET_INDEX ] ][ _szDATA_NAME ], iCost );
        }
        
        Print( 
idBLUE"!tBOUGHT ITEM !g%s !nfor !g$%i"g_mItemDataArrayData_iMARKET_INDEX ] ][ _szDATA_NAME ], iCost );
        
        new 
iSize ArraySizeg_aItemsPlayerid ] ), ArrayData2ItemsPlayer ];
        
        
/*
            <^> Determine whether the player should get another one by quantity or a
                whole new item. If item is equippable he will get a new array index
                for it.
        */
        
        
if( !g_mItemDataArrayData_iMARKET_INDEX ] ][ _bDATA_EQUIP ] )
        {
            for( new 
iSize ++ )
            {
                
ArrayGetArrayg_aItemsPlayerid ], iArrayData2 );
                
                if( 
ArrayData2_iITEMS_INDEX ] == ArrayData_iMARKET_INDEX ] )
                {
                    
ArrayData2_IITEMS_QUANTITY ] ++;
                    
ArraySetArrayg_aItemsPlayerid ], iArrayData2 );
                    
ArrayDeleteItemg_aItemsMarketiItem );
                    
                    
MenuRebuildg_iMenuMarket );
                    
                    return;
                }
            }
        }
        
        
/*    
            <^> Add to player array.
        */
        
        
ArrayData2_iITEMS_INDEX ] = ArrayData_iMARKET_INDEX ];
        
ArrayData2_IITEMS_QUANTITY ] = 1;
        
ArrayData2_iITEMS_DURABILITY ] = g_mItemDataArrayData2_iITEMS_INDEX ] ][ _iDATA_DURABILITY ];
        
ArrayData2_bITEMS_EQUIPPED ] = false;
        
        
ArrayPushArrayg_aItemsPlayerid ], ArrayData2 );
        
ArrayDeleteItemg_aItemsMarketiItem );
        
        
MenuRebuildg_iMenuMarket );
    }
    else    
    {
        Print( 
idRED"%L"id"CURRENCY_NOT_ENOUGH"GetCvarStringCurrencyPreFix ), GetCvarStringCurrencyPostFix ) );

        
ClientCommand_Marketid );
    }
}
    
public 
MenuHandle_MegaShopidiMenuiItem )
{
    if( 
iItem == MENU_EXIT )
    {
        
menu_destroyiMenu );
        return;
    }
    
    
/*
        <^> Prisoners only.
    */
    
    
if( cs_get_user_teamid ) != CS_TEAM_T && iItem >= )
        return;
        
    
    
//quick fix due to really bad brainhurt    
    
if( iItem 
    {
        
iItem -= 8;
    }
    else if( 
iItem )
    {
        
iItem -= 4;
    }
        
    
//iItem -= 2 * ( floatround( ( Float:iItem ) / ( Float:3 ), floatround_floor ) );
        
    
new ArrayDataItemsShop ];
    
ArrayGetArrayg_aShopItemsiItemArrayData );
    
    
/*
        <^> Check for stock supply.
    */
    
    
new iStock =  ArrayData_iSHOP_STOCK ];
    
    if( 
iStock )
    {
        
/*
            <^> Check for currency.
        */
        
        
new iCost ArrayData_iSHOP_COST ];
        
        if( 
iCost <= g_iPlayerCashid ] )
        {
            
/*
                <^> Player bought the item!
            */
            
            
g_iPlayerCashid ] -= iCost;
            
HJB_GiveUserItemidArrayData_iSHOP_INDEX ], true );
            
            if( 
iStock )
            {
                
/*
                    <^> Update the stock count in the array.
                */
                
                
ArrayData_iSHOP_STOCK ] --;
                
                
ArraySetArrayg_aShopItemsiItemArrayData );
            }
            
            Print( 
idBLUE"%L"id"ITEMS_BOUGHT" );
            
            
/*
                <^> Rebuild the menu.
            */
            
            
menu_destroyiMenu );
        }
        else    Print( 
idRED"%L"id"CURRENCY_NOT_ENOUGH"GetCvarStringCurrencyPreFix ), GetCvarStringCurrencyPostFix ) );
    }
    else    Print( 
idRED"%L"id"SHOP_OUT_OF_STOCK" );
    
    
//new iTemp, iPage;
    //player_menu_info( id, iTemp, iTemp, iPage );
    
    
ClientCommand_MegaShopid );
    
    
//menu_display( id, iMenu/*, iPage*/ );
}
    
public 
MenuHandle_InventoryidiMenuiItem )
{
    
/*    
        <^> A player selected an item in his inventory.
    */
    
    
if( iItem == MENU_EXIT )
    {
        
menu_destroyiMenu );
        return;
    }
    
    
g_iTargetItemid ] = iItem;
    
    
/*
        <^> Set up the next menu for item options.
    */
    
    
Menu_ItemidiItem );
}

public 
Menu_ItemidiIndex )
{
    
/*
        <^> Item options menu.
    */
    
    
new ArrayDataItemsPlayer ];
    
ArrayGetArrayg_aItemsPlayerid ], iIndexArrayData );
    
    new 
szMenu64 ];
    
formatexszMenucharsmaxszMenu ), "\y%s%L"MENU_TITLEid"ITEM_OPTION"g_mItemDataArrayData_iITEMS_INDEX ] ][ _szDATA_NAME ] );
    
    new 
iMenu menu_createszMenu"HandleMenu_Item" );
    
    if( 
g_mItemDataArrayData_iITEMS_INDEX ] ][ _bDATA_EQUIP ] )
    {
        if( !
ArrayData_bITEMS_EQUIPPED ] )
            
menu_additemiMenu"Equip Item" );
        else     
menu_additemiMenu"Unequip Item" );
    }
    else     
menu_additemiMenu"Use item" );
    
    
    
menu_additemiMenu"Show Item Info" );
    
    if( 
g_pValueEnableMarket ] && !g_pValueItemUseInstantly ] )
        
menu_additemiMenu"Put On Market" );
    
    
menu_setpropiMenuMPROP_EXITNAME"Previous" );
    
    
menu_displayidiMenu ); 
}

public 
HandleMenu_ItemidiMenuiKey )
{
    if( 
iKey == MENU_EXIT )
    {
        
menu_destroyiMenu );
        
ClientCommand_Inventoryid );
        
        return;
    }
    
    new 
iSelected g_iTargetItemid ];
    
    new 
ArrayDataItemsPlayer ];
    
ArrayGetArrayg_aItemsPlayerid ], iSelectedArrayData );
    
    switch( 
iKey )
    {
        case 
0:
        {
            
/*
                <^> Players cannot use items while they are dead.
            */
            
            
if( !is_user_aliveid ) )
            {
                Print( 
idRED"%L"id"ITEM_USE_DEAD" );
                
ClientCommand_Inventoryid );
                
                return;
            }
            
            if( !
g_mItemDataArrayData_iITEMS_INDEX ] ][ _bDATA_EQUIP ] )
            {
                
ArrayData_IITEMS_QUANTITY ] --;
                
                if( 
ArrayData_IITEMS_QUANTITY ] < )
                    
ArrayDeleteItemg_aItemsPlayerid ], iSelected );
                else    
ArraySetArrayg_aItemsPlayerid ], iSelectedArrayData );
                
                
ClientCommand_Inventoryid );
            }
            else
            {
                if( 
ArrayData_bITEMS_EQUIPPED ] )
                {
                    
ArrayData_bITEMS_EQUIPPED ] = false;
                    
g_iEquipDataid ][ ArrayData_iITEMS_INDEX ] ] --;
                }
                else
                {
                    
ArrayData_bITEMS_EQUIPPED ] = true;
                    
g_iEquipDataid ][ ArrayData_iITEMS_INDEX ] ] ++;
                }
                
                
ArraySetArrayg_aItemsPlayerid ], g_iTargetItemid ], ArrayData );
                
Menu_ItemidiSelected );
            }
            
            
HandleItemidArrayData_iITEMS_INDEX ] );
        }
        
        case 
1:
        {
            
/*
                <^> Make sure that data for externally added items is 
                    available aswell.
            */
            
            
if( iSelected >= MAX_STANDARD_ITEMS )
            {
                new 
ArrayData2ItemData ];
                
                
ArrayGetArrayg_aItemDataiSelectedArrayData2 );
                Print( 
idREDArrayData2_szDATA_INFO ] );
            }
            else     Print( 
idREDg_mItemDataArrayData_iITEMS_INDEX ] ][ _szDATA_INFO ] );
            
            
menu_destroyiMenu );
            
            
Menu_Itemidg_iTargetItemid ] );
        }
        
        case 
2:
        {
            
menu_displayidg_iMenuSell );
        }
    }
}

public 
MenuHandle_SellItemidiMenuiItem )
{
    if( 
iItem == MENU_EXIT )
    {
        
Menu_Itemidg_iTargetItemid ] );
        return;
    }
    
    new 
_access_callback;
    new 
szInfo];
    
    
menu_item_getinfoiMenuiItem_accessszInfocharsmaxszInfo ), ___callback );
    
    new 
iCost str_to_numszInfo );
    
    
AddToMarketid, -1iCost );
    
    
menu_destroyiMenu );
    
    new 
ArrayDataItemsPlayer ];
    
ArrayGetArrayg_aItemsPlayerid ], g_iTargetItemid ], ArrayData );
    
    Print( 
idtrue"Added item !t%s !nto the !gMarket !nfor !t$%i"g_mItemDataArrayData_szDATA_NAME ] ], iCost );
    
    
ClientCommand_Inventoryid );
}

public 
HandleItemidiItemIndex )
{
    
/*
        <^> "Uses" the item for the player.
    */
    
    
static szName32 ], szMsg256 ];
    
get_user_nameidszNamecharsmaxszName ) );
    
    new 
bool:bUsed true;
    
    
/*
        <^> Send a forward to allow other plugins to handle their custom items
            if they have one. Other plugins should return PLUGIN_HANDLED
            if the player should not be allowed to use the item for whatever
            reason may be.
    */
    
    
if( !IsItemStandardSetiItemIndex ) )
    {
        new 
iReturn;
        
        
ExecuteForwardForwardHandle_UseItemiReturnidiItemIndex );
        
        goto 
Message;
    }
    
    
/*
        <^> Handles all default items.
    */
    
    
switch( iItemIndex )
    {
        case 
ITEM_PAINKILLERS:
        {
            new 
iHealth get_user_healthid );
            
            if( 
iHealth 100 )
            {
                
iHealth += g_pValuePainkillersHealth ];
                
                if( 
iHealth 100 )
                    
iHealth 100;
                    
                
set_user_healthidiHealth );
                
                
UTIL_ScreenFadeid1<<121<<60x000002550255 );
            }
            else
            {
                
formatszMsgcharsmaxszMsg ), "%L"id"ITEM_FULL_HEALTH" );
                
bUsed false;
                
                
HJB_GiveUserItemidITEM_PAINKILLERSfalse );
            }
        }
        
        case 
ITEM_STEROIDS:
        {
            if( 
g_flPlayer_MaxSpeedid ] > SPEED_STANDARD )
            {
                
formatszMsgcharsmaxszMsg ), "%L"id"ITEM_STEROID_STILL_GOING" );
                
bUsed false;
                
                
HJB_GiveUserItemidITEM_STEROIDSfalse );
            }
            else
            {
                
g_flPlayer_MaxSpeedid ] += 150.0
                set_user_maxspeed
idg_flPlayer_MaxSpeedid ] );
                
                
UTIL_ScreenFadeid5<<121<<60x0000050255200 );
                
                
set_task10.0"Task_Steroids"id TASK_STEROIDS );
            }
        }
        
        case 
ITEM_SMOKENADE:
        {
            
give_itemid"weapon_smokegrenade" );
        }
        
        case 
ITEM_HENADE:
        {
            
give_itemid"weapon_hegrenade" );
        }
        
        case 
ITEM_FLASHBANG:
        {
            
give_itemid"weapon_flashbang" );
        }
        
        case 
ITEM_HELMET:
        {
            
//
        
}
        
        case 
ITEM_GRAVBOOTS:
        {
            if( 
HJB_IsItemEquippedidiItemIndex ) )
                
set_user_gravityid0.625 );
            else    
set_user_gravityid1.0 );
        }
        
        case 
ITEM_LOCKPICK:
        {
            new 
iTarget_body;
    
            
get_user_aimingidiTarget_body100 );
            
            if( 
iTarget g_iMaxPlayers )
            {
                new 
szClass32 ];
                
peviTargetpev_classnameszClasscharsmaxszClass ) );
            
                if( 
equalszClass"func_door" ) )
                {
                    new 
szInfo];
                    
num_to_striTargetszInfocharsmaxszInfo ) );
                    
                    
dllfuncDLLFunc_UseiTarget);
                    
emit_soundiTargetCHAN_VOICE"weapons/ric_metal-1.wav"1.0ATTN_NORM0PITCH_NORM );
                    
                    return;
                }
            }
            
            
bUsed false;
            
formatszMsgcharsmaxszMsg ), "%L"id"ITEM_USE_FAILED" );
            
            
HJB_GiveUserItemidITEM_LOCKPICKfalse );
            
        }
        
        case 
ITEM_MEDKIT:
        {
            
set_user_healthid120 );
        }
        
        case 
ITEM_GLOCK:
        {
            
cs_set_weapon_ammogive_itemid"weapon_glock18" ), );
            
engclient_cmdid"weapon_knife" );
        }
        
        case 
ITEM_CROWBAR:
        {    
            if( 
HJB_IsItemEquippedidITEM_CROWBAR ) )
                
OnHJB_DeployKnifeid );
            
            
ExecuteHamBHam_Item_Deployget_pdata_cbaseidm_rgpPlayerItems] ) );
        }
            
        case 
ITEM_DISGUISE:
        {
            
cs_set_user_modelid"gsg9" );
        }
    }
    
    
Message:
    
    if( !
bUsed )
        Print( 
idfalseszMsg );
}

public 
MenuRebuildiMenu )
{
    
menu_destroyiMenu );
    
g_iMenuMarket g_iMenuMarket menu_create"\yItems on the market:""MenuHandle_Market" );
    
    new 
iSize ArraySizeg_aItemsMarket );
    
    new 
szName32 ], szItem128 ], ArrayDataItemsMarket ], iOwner;
    
    for( new 
iSize ++ )
    {
        
ArrayGetArrayg_aItemsMarketiArrayData );
        
        
iOwner ArrayData_iMARKET_OWNER ];
        
        if( 
iOwner )
            
get_user_nameiOwnerszNamecharsmaxszName ) );
        else    
szName "Market";
        
        if( 
g_mItemDataArrayData_iMARKET_INDEX ] ][ _bDATA_EQUIP ] )
        {
            if( 
iOwner )
                
formatexszItemcharsmaxszItem ), "%s \y[ \w%%%i \rD/ \y] [ %s ] \R \r$%i"g_mItemDataArrayData_iMARKET_INDEX ] ][ _szDATA_NAME ], floatroundFloat:ArrayData_iMARKET_DURABILITY ] / Float:g_mItemDataArrayData_iMARKET_INDEX ] ][ _iDATA_DURABILITY ]  * 100.0 ), szNameArrayData_iMARKET_COST ] );
            else    
formatexszItemcharsmaxszItem ), "%s \y[ \w%%100 \rD/ \y] [ %s ] \R \r$%i"g_mItemDataArrayData_iMARKET_INDEX ] ][ _szDATA_NAME ], szNameArrayData_iMARKET_COST ] );

        }
        else
        {
            
formatexszItemcharsmaxszItem ), "%s \y[ %s ] \R \r$%i"g_mItemDataArrayData_iMARKET_INDEX ] ][ _szDATA_NAME ], szNameArrayData_iMARKET_COST ] );
        }
        
        
menu_additemg_iMenuMarketszItem );
    }
}

    
/*---------------------------------|
    |        Data           |
    |---------------------------------*/


public SaveDataid )
{
    if( !
g_pValueEnableDataSaving ] )
        return;
    
    
/*    ITEM DATA    */
    
    
new szKey64 ], szData512 ];
    
    
formatexszKeycharsmaxszKey ), "%s-DATA"g_szAuthIdid ] );
    
    new 
iSize ArraySizeg_aItemsPlayerid ] ), ArrayDataItemsPlayer ];
    
    for( new 
iSize ++ )
    {
        
ArrayGetArrayg_aItemsPlayerid ], iArrayData );
        
        if( 
g_mItemDataArrayData_iITEMS_INDEX ] ][ _bDATA_EQUIP ] )
        {
            
formatexszDatacharsmaxszData ), "%s%i-%i-%i "szDataArrayData_iITEMS_INDEX ], ArrayData_bITEMS_EQUIPPED ] ? 0ArrayData_iITEMS_DURABILITY ] );
        }
        else
        {
            
formatexszDatacharsmaxszData ), "%s%i-%i "szDataArrayData_iITEMS_INDEX ], ArrayData_IITEMS_QUANTITY ] );
        }
    }
    
    
set_vaultdataszKeyszData );
    
    
formatexszKeycharsmaxszKey ), "%s-CASH"g_szAuthIdid ] );
    
formatexszDatacharsmaxszData ), "%i"g_iPlayerCashid ] );
    
    
HJB_LogActionid"Saved $%i"g_iPlayerCashid ] );
    
set_vaultdataszKeyszData );
}

public 
LoadDataid )
{
    new 
szKey64 ], szData512 ];
    
    
/*    ITEM DATA    */
    
    //CASH
    
    
formatexszKeycharsmaxszKey ), "%s-CASH"g_szAuthIdid ] );
    
//formatex( szData, charsmax( szData ), "%i", g_iPlayerCash[ id ] );
    
get_vaultdataszKeyszDatacharsmaxszData ) );
    
g_iPlayerCashid ] = str_to_numszData );
    
    
HJB_LogActionid"Loaded $%i"g_iPlayerCashid ] );
    
    
//ITEMS
    
    
formatexszKeycharsmaxszKey ), "%s-DATA"g_szAuthIdid ] );
    
    
get_vaultdataszKeyszDatacharsmaxszData ) );
    
    new 
szPiece32 ], szSec][ 24 ];
    
    new 
iItemIndexiDurabilityiQuantityboolbEquippedArrayDataItemsPlayer ];
    
    while( 
containszData" " ) >= 
    {         
        
strtokszDataszPiececharsmaxszPiece ), szDatacharsmaxszData ), ' ' )   ;      
        
        
replace_allszPiececharsmaxszPiece ), "-"" " );
        
parseszPieceszSec], charsmaxszSec[] ), szSec], charsmaxszSec[] ), szSec], charsmaxszSec[] ) );
        
        
iItemIndex str_to_numszSec] );
        
        
ArrayData_iITEMS_INDEX ] = iItemIndex;
        
        if( 
g_mItemDataiItemIndex ][ _bDATA_EQUIP ] )
        {
            
bEquipped bool:str_to_numszSec] );
            
iDurability str_to_numszSec] );
            
            
ArrayData_bITEMS_EQUIPPED ] = bEquipped;
            
ArrayData_iITEMS_DURABILITY ] = iDurability;
            
ArrayData_IITEMS_QUANTITY ] = 1;
            
            if( 
bEquipped )
                
g_iEquipDataid ][ ArrayData_iITEMS_INDEX ] ] ++;
        }
        else    
        {
            
iQuantity str_to_numszSec] );
            
            
ArrayData_IITEMS_QUANTITY ] = iQuantity;
        }
        
        
HJB_LogActionid"Loaded Item %i"iItemIndex );
        
        
ArrayPushArrayg_aItemsPlayerid ], ArrayData );
    }
}

//

public _ResetPlayerItemsid )
{
    
ArrayClearg_aItemsPlayerid ] );
    
g_iPlayerCashid ] = 0;
    
    
SaveDataid );
}

    
/*---------------------------------|
    |        Stocks           |
    |---------------------------------*/

AddToMarketidiItemIndexiCost )
{
    
/*
        <^> Adds an item to the market.
    */
    
    
new ArrayDataItemsMarket ], ArrayData2ItemsPlayer ];
    
    new 
szName32 ], szItem128 ];
    
get_user_nameidszNamecharsmaxszName ) );
    
    
ArrayData_iMARKET_COST ] = iCost;
    
ArrayData_iMARKET_INDEX ] = iItemIndex;
    
ArrayData_iMARKET_OWNER ] = id;
    
    if( 
id )
    {
            
/*
                <^> Item added by the game itself.
            */
            
        
szName "Market";
        
        new 
szInfo64 ];
        
        if( 
id == )
            
copyszInfocharsmaxszInfo ), g_mItemDataiItemIndex ][ _szDATA_NAME ] );
        else     
formatexszInfocharsmaxszInfo ), "\rMARKET GAMBLE SPECIAL" );
    
            
/*
                <^> Setup item info - the item might have durability or not.
            */
        
        
if( g_mItemDataiItemIndex ][ _bDATA_EQUIP ] )
        {
            
ArrayData_iMARKET_DURABILITY ] = 100;
            
//formatex( szItem, charsmax( szItem ), "%s \y[ \w%%100 \rD/ \y] [ %s ] \R \r$%i", g_mItemData[ iItemIndex ][ _szDATA_NAME ], szName, iCost );
            
formatexszItemcharsmaxszItem ), "%s \y[ %s ] \R \r$%i"szInfoszNameiCost );
        }
        else
        {
            
formatexszItemcharsmaxszItem ), "%s \y[ %s ] \R \r$%i"g_mItemDataiItemIndex ][ _szDATA_NAME ], szNameiCost );
        }
    }
    else    
    {
            
/*
                <^> Item added by a player.
            */
        
        
ArrayGetArrayg_aItemsPlayerid ], g_iTargetItemid ], ArrayData2 );
    
        
ArrayData_iMARKET_INDEX ] = ArrayData2_iITEMS_INDEX ];
    
        if( 
g_mItemDataArrayData2_iITEMS_INDEX ] ][ _bDATA_EQUIP ] )
        {
            
ArrayData_iMARKET_DURABILITY ] = ArrayData2_iITEMS_DURABILITY ];
            
formatexszItemcharsmaxszItem ), "%s \y[ \w%%%i \rD/ \y] [ %s ] \R \r$%i"g_mItemDataArrayData2_iITEMS_INDEX ] ][ _szDATA_NAME ], floatroundArrayData2_iITEMS_DURABILITY ] / g_mItemDataArrayData2_iITEMS_INDEX ] ][ _iDATA_DURABILITY ] * 100.0 ), szNameiCost );
        }
        else
        {
            
formatexszItemcharsmaxszItem ), "%s \y[ %s ] \R \r$%i"g_mItemDataArrayData2_iITEMS_INDEX ] ][ _szDATA_NAME ], szNameiCost );
        }
    }
    
    
/*
        <^> Put the new data into the market array and Aad the item to the market menu.
    */
    
    
ArrayInsertArrayAfterg_aItemsMarketArraySizeg_aItemsMarket ) - 1ArrayData );
    
    
menu_additemg_iMenuMarketszItem );
    
    if( 
id )
    {
        
ArrayData2_IITEMS_QUANTITY ] --;
        
        if( 
id )
        {
            if( 
ArrayData2_IITEMS_QUANTITY ] < )
                
ArrayDeleteItemg_aItemsPlayerid ], g_iTargetItemid ] );
            else    
ArraySetArrayg_aItemsPlayerid ], g_iTargetItemid ], ArrayData2 );
        }
    }
}
    
GetCvarStringpCvar )
{
    
/*
        <^> An easy way to return a cvar string without creating string arrays
            all over the place.
    */
    
    
static szValue32 ];
    
get_pcvar_stringg_pCvarpCvar ], szValuecharsmaxszValue ) );
    
    return 
szValue;
}

Float:GetRoundTime()
{
    return 
get_gametime() - g_flRoundStart;
}

HJB_LogAction( const id, const szInput[], any:... )
{
    
/*
        <^> This is used to log certain actions such as a player buying an item,
            selling an item, using an item or anything else that an a server
            operator might like to log. 
            Essentially this is useful if a player is claiming that an item
            has gone missing or something of the like.
    */
    
    
static file64 ], ftime16 ], name32 ], auth32 ];
    
    
format_timeftimecharsmaxftime ), "%m%d%Y");
    
    
formatfilecharsmaxfile ), "addons/amxmodx/logs/jailbreak_%s.log"ftime );
    
    
get_user_nameidnamecharsmaxname ) )
    
get_user_authididauthcharsmaxauth ) );
        
    static 
log512 ];
    
    
vformatlogcharsmaxlog ), szInput);
    
    
formatlogcharsmaxlog ), "%s [ %s ] :: %s"nameauthlog );
    
log_to_filefilelog );
}

bool:IsItemStandardSetiItemIndex )
{
    if( 
iItemIndex >= MAX_STANDARD_ITEMS )
        return 
false;
        
    return 
true;
}

UTIL_ScreenFadeidiDurationiHoldFlagsiRediGreeniBlueiAlpha )
{
    
message_beginMSG_ONE_UNRELIABLEg_iMsgScreenFade,{ 00}, id );
    
write_shortiDuration );
    
write_shortiHold );
    
write_shortFlags );
    
write_byteiRed );
    
write_byteiGreen );
    
write_byteiBlue );
    
write_byteiAlpha );
    
message_end();
}

    
/*---------------------------------|
    |        Natives           |
    |---------------------------------*/
    
public plugin_natives()
{
    
register_native"HJB_GiveUserItem""_HJB_GiveUserItem");
    
register_native"HJB_GiveUserCurrency""_HJB_GiveUserCurrency");
    
register_native"HJB_IsItemEquipped""_HJB_IsItemEquipped");
    
register_native"HJB_RegisterItem""_HJB_RegisterItem" );
    
register_native"ResetPlayerItems""_ResetPlayerItems");
}
    
public 
_HJB_GiveUserCurrencyidiAmount )
{
    
g_iPlayerCashid ] += iAmount;
    
    Print( 
idBLUE"!t%L"id"CURRENCY_RECEIVED"GetCvarStringCurrencyPreFix ), iAmountGetCvarStringCurrencyPostFix ) );
    
    
SaveDataid );
}

public 
_HJB_GiveUserItemidiItemIndexbool:Message )
{
    
/*
        <^> This native gives a player an item.
    */
    
    
if( id <= )
        return 
PLUGIN_HANDLED;
    
    if( 
iItemIndex == -
    {
        
/*
            <^> This functionality of random item is not accessible if items are used
                when purchased.
        */
        
        
if( g_pValueItemUseInstantly ] )
            return 
PLUGIN_HANDLED;
        
        
/*
            <^> This determines the chance of what item you will get.
        */
        
        
new iChance random_num110 ), iItemssizeof g_mItemData ], iCount;
    
        
/*
            <^> This first loop will check for items that have the certain grade
                of chance from the standard set of item data.
        */
    
        
for( new sizeof g_mItemData ++ )
        {
            if( 
iChance >= g_mItemData][ _iDATA_CHANCE ] )
            {
                
iItemsiCount ] = i;
                
iCount ++;
            }
        }
        
        
/*
            <^> The second loop will check for items that have the certain grade
                of chance from the externally registered items from other plugins.
        */
        
        
new iSize ArraySizeg_aItemData );
        new 
ArrayDataItemData ];
        
        for( new 
iSize ++ )
        {
            
ArrayGetArrayg_aItemDataiArrayData );
            
            if( 
iChance >= ArrayData_iDATA_CHANCE ] )
            {
                
iItemsiCount ] = MAX_STANDARD_ITEMS;
                
iCount ++;
            }
        }
        
        
iItemIndex iItemsrandom_num0iCount ) ];
    }
    
    if( 
Message )
        Print( 
idWHITE"!t%L"id"ITEM_RECEIVED"g_mItemDataiItemIndex ][ _szDATA_NAME ] );
        
    
HJB_LogActionid"Received a %s"g_mItemDataiItemIndex ][ _szDATA_NAME ] );
    
    new 
ArrayDataItemsPlayer ], iSize ArraySizeg_aItemsPlayerid ] );
    
    
/*
        <^> Push the item into the player's item array.
    */
    
    /*
        <^> If item is equipable, give them another one.
    */
    
    
if( g_mItemDataiItemIndex ][ _bDATA_EQUIP ] )
    {
        
ArrayData_iITEMS_DURABILITY ] = g_mItemDataiItemIndex ][ _iDATA_DURABILITY ];
        
ArrayData_iITEMS_INDEX ] = iItemIndex;
        
ArrayData_IITEMS_QUANTITY ] = 1;
        
ArrayData_bITEMS_EQUIPPED ] = false;
        
        
ArrayPushArrayg_aItemsPlayerid ], ArrayData );
        
        
SaveDataid );
        
        
/*
            <^> Use the item instantly according to cvar.
        */
        
        
if( g_pValueItemUseInstantly ] )
            
HandleItemidiItemIndex );
        
        return 
0;
    }
    
    
/*    
        <^> If the item is use only, then add to the current quantity.
    */
    
    
for( new iSize ++ )
    {
        
ArrayGetArrayg_aItemsPlayerid ], iArrayData );
        
        if( 
ArrayData_iITEMS_INDEX ] == iItemIndex )
        {
            
ArrayData_IITEMS_QUANTITY ] ++;
            
ArraySetArrayg_aItemsPlayerid ], iArrayData );
            
            return -
1;
        }
    }
    
    
ArrayData_iITEMS_INDEX ] = iItemIndex;
    
ArrayData_IITEMS_QUANTITY ] = 1;
    
ArrayData_iITEMS_DURABILITY ] = -1;
    
ArrayData_bITEMS_EQUIPPED ] = false;
    
    
ArrayPushArrayg_aItemsPlayerid ], ArrayData );
    
    
SaveDataid );
    
    
/*
        <^> Use the item instantly according to cvar.
    */
    
    
if( g_pValueItemUseInstantly ] )
        
HandleItemidiItemIndex );
    
    return -
1;
}

public 
_HJB_IsItemEquippedidiItem )
{
    return 
g_iEquipDataid ][ iItem ] ? true false;
}

public 
_HJB_RegisterItem()
{
    new 
ArrayDataItemData ];
    
    
get_string1ArrayData_szDATA_NAME ], charsmaxArrayData_szDATA_NAME ] ) );
    
ArrayData_iDATA_DURABILITY ] = get_param);
    
ArrayData_iDATA_CHANCE ] = get_param);
    
ArrayData_bDATA_EQUIP ] = bool:get_param);
    
get_string5ArrayData_szDATA_INFO ], charsmaxArrayData_szDATA_INFO ] ) );
    
    new 
iSize ArraySizeg_aItemData );
    
ArrayInsertArrayAfterg_aItemDataiSize 1ArrayData );
    
    return 
iSize;


Errors:
PHP Code:
AMX Mod X Compiler 1.8.3-dev+4968
Copyright 
(c1997-2006 ITB CompuPhase
Copyright 
(c2004-2013 AMX Mod X Team

Warning
Symbol is never used"iSize2" on line 428
Warning
Symbol is never used"iSize" on line 428
Warning
Symbol is never used"iCount" on line 428
Warning
Symbol is assigned a value that is never used"szValue" on line 427
Warning
Symbol is assigned a value that is never used"szField" on line 427
Warning
Symbol is assigned a value that is never used"ArrayData2" on line 426
Warning
Symbol is assigned a value that is never used"ArrayData" on line 426
Warning
Symbol is never used"MAX_SHOP_FIELDS" on line 424
Warning
Symbol "client_disconnect" is marked as deprecated: Use client_disconnected() insteadon line 578

Header size
:           4108 bytes
Code size
:            51820 bytes
Data size
:            36000 bytes
Stack
/heap size:      16384 bytes
Total requirements
:  108312 bytes

9 Warnings
.
Done
Thats the code, I have tested many ways to solve the problem but i have not, if some1 can help me, amazing!
xeloxded is offline
OciXCrom
Veteran Member
Join Date: Oct 2013
Location: Macedonia
Old 12-23-2016 , 09:42   Re: Warning and Symbol is never used!
Reply With Quote #2

It clearly says that the specified symbols are not used in the code, so delete them.
__________________
OciXCrom is offline
Send a message via Skype™ to OciXCrom
xeloxded
Member
Join Date: Dec 2016
Old 12-23-2016 , 09:43   Re: Warning and Symbol is never used!
Reply With Quote #3

Quote:
Originally Posted by OciXCrom View Post
It clearly says that the specified symbols are not used in the code, so delete them.

If i delete those errors, will the plugin work correctly? it is good?
xeloxded is offline
OciXCrom
Veteran Member
Join Date: Oct 2013
Location: Macedonia
Old 12-23-2016 , 12:39   Re: Warning and Symbol is never used!
Reply With Quote #4

If they are not used, they can't possibly break anything in the plugin.
__________________
OciXCrom is offline
Send a message via Skype™ to OciXCrom
Craxor
Veteran Member
Join Date: Jan 2016
Location: Romania
Old 12-23-2016 , 12:59   Re: Warning and Symbol is never used!
Reply With Quote #5

Just simple send a PM to hornet, it is his plugin.

I believe that's the original thread: https://forums.alliedmods.net/showthread.php?t=281811
__________________
Project: Among Us

Last edited by Craxor; 12-23-2016 at 13:00.
Craxor is offline
Send a message via ICQ to Craxor
Reply



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


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