AlliedModders

AlliedModders (https://forums.alliedmods.net/index.php)
-   Scripting Help (https://forums.alliedmods.net/forumdisplay.php?f=11)
-   -   [HELP] VIP Menu (https://forums.alliedmods.net/showthread.php?t=252438)

HeartbeatHNS 12-02-2014 15:10

[HELP] VIP Menu
 
Hello,

I have a huge problem with my VIP Menu. Thanks for helping! :bacon!:

Problem to solve: I can open the menu but i can't use the sub-menus. I don't understand what's wrong. Please help me!

Here is the code:
PHP Code:

native hnsxp_get_user_xp(client);

native hnsxp_set_user_xp(clientxp);

stock hnsxp_add_user_xp(clientxp)
{
    return 
hnsxp_set_user_xp(clienthnsxp_get_user_xp(client) + xp);
}

stock hnsxp_sub_user_xp(clientxp)
{
    return 
hnsxp_set_user_xp(clienthnsxp_get_user_xp(client) - xp);


#include <amxmodx>
#include <amxmisc>
#include <hamsandwich>
#include <fun>
#include <cstrike>
#include <colorchat>

#define PLUGIN    "[HB] VIP Mod"
#define AUTHOR    "HBxander, Larcyn"
#define VERSION    "1.4"

#define clantac "^x04[HB]"

new g_iMoney[33];

new 
awp_cost;
new 
deagle_cost;
new 
shotgun_cost;
new 
fiveseven_cost;
new 
hegren_cost;
new 
respawn_cost;
new 
colt_cost;
new 
xp_amount;
new 
xp_cost;
new 
hp_amount;
new 
hp_cost;
new 
scout_cost;
new 
frost_cost;

new 
price;

new 
bought_respawn;
new 
bought_xp;
new 
bought_hp;
new 
bool:gbConnected[33];
new 
bool:got_access[33]

public 
plugin_init()
{
    
register_clcmd("say /vip""vip_shop");
    
register_clcmd("say /buyvip""buy_vip");
    
register_clcmd("say_team /vip""vip_shop");
    
register_clcmd("say_tean /buyvip""buy_vip");

    
//weapons price
    
awp_cost register_cvar("vip_awpcost""16000");
    
deagle_cost register_cvar("vip_dglcost""12000");
    
shotgun_cost register_cvar("vip_m3cost""12000");
    
fiveseven_cost register_cvar("vip_fivesevencost""8000");
    
colt_cost register_cvar("vip_coltcost""8000");
    
scout_cost register_cvar("vip_scoutcost""3000");
    
//grenades price
    
hegren_cost register_cvar("vip_hegrencost""8000");
    
frost_cost register_cvar("vip_frostcost""12000");
    
//items price
    
respawn_cost register_cvar("vip_respawncost""10000");
    
hp_cost register_cvar("vip_hpcost""6000");
    
xp_cost register_cvar("vip_xpcost""6000");
    
//item amount
    
xp_amount register_cvar("vip_xpamount""10");
    
hp_amount register_cvar("vip_hpamount""25");
    
//clantac
    
price register_cvar ("vip_price""2000");
}

public 
vip_shop(id)
{
    new 
MainMenu menu_create("\r[HB] VIP Mod by Larcyn^n^nMain Menu""MainMenu_Handle");
    
menu_additem(MainMenu"\wWeapon Menu""\r1"0);
    
menu_additem(MainMenu"\wItem Menu""\r2"0);
    
menu_additem(MainMenu"\wGrenades Menu""\r3"0);
    
menu_setprop(MainMenuMPROP_EXITMEXIT_ALL);
    if ( 
got_access[id] )
    {
        
menu_display(idMainMenu0);
    }
}

public 
MainMenu_Handle(idmenuitem)
{
    if (
item == MENU_EXIT)
    {
        
menu_destroy(menu);
        return 
PLUGIN_HANDLED;
    }
    
    new 
data[6], iName[64];
    new 
accesscallback;

    
menu_item_getinfo(menuitemaccessdata,5iName63callback);
    new 
key str_to_num(data[1]);
    
    switch(
key)
    {
        case 
1:
        {
            
weapon_Menu(id);
        }
        case 
2:
        {
            
item_Menu(id);
        }
        case 
3:
        {
            
grenades_Menu(id);
        }
    }
    return 
PLUGIN_CONTINUE;
}
public 
grenades_Menu(id)
{
    new 
buy_hegren[60];
    new 
buy_frost[60];
    
    
formatex(buy_hegrensizeof(buy_hegren) - 1"\wHeGrenade \r[Amount: \w1\r]        \r[$\y%i\r]"get_pcvar_num(hegren_cost));
    
formatex(buy_frostsizeof(buy_frost) - 1"\wFrostGrenade \r[Amount: \w1\r]        \r[$\y%i\r]"get_pcvar_num(frost_cost));
    
    new 
gren_Menu menu_create("\r[HB] VIP Mod by Larcyn^n^nGrenade Menu""GrenadesMenu_Handle");
    
    
menu_additem(gren_Menubuy_hegren"\r1"0);
    if ( 
cs_get_user_team(id) == CS_TEAM_T )
    {
        
menu_additem(gren_Menubuy_frost"\r2"0);
    }
    
menu_setprop(gren_MenuMPROP_EXITMEXIT_ALL);
    {
        
menu_display(idgren_Menu0);
    }
}

public 
GrenadesMenu_Handle(idmenuitem)
{
    if (
item == MENU_EXIT)
    {
        
menu_destroy(menu);
        return 
PLUGIN_HANDLED;
    }
    
    new 
data[6], iName[64];
    new 
accesscallback;
    
    
menu_item_getinfo(menuitemaccessdata,5iName63callback);
    new 
key str_to_num(data[1]);
    
    switch(
key)
    {
        case 
1:
        {
            if ( 
cs_get_user_money(id) < get_pcvar_num(hegren_cost) )
            {
                
ColorChat(idGREY"%s VIP Mod:^x03 You dont have enough money to buy`x04 He Grenade^x03!"clantac);
                return 
PLUGIN_HANDLED;
            }
            
            if ( !
is_user_alive(id) )
            {
                
ColorChat(idGREY"%s VIP Mod:^x03 You need to be alive!"clantac);
                return 
PLUGIN_HANDLED;
            }
            
            if ( 
user_has_weapon(idCSW_HEGRENADE) )
            {
                
ColorChat(idGREY"%s VIP Mod:^x03 You already own the^x04 He Grenade^x03!"clantac);
                return 
PLUGIN_HANDLED;
            }
            new 
name[32];
            
get_user_name(idname32);
            
cs_set_user_money(idcs_get_user_money(id) - get_pcvar_num(hegren_cost));
            
cs_set_weapon_ammogive_item(id"weapon_hegren"), 0);
            
cs_set_user_bpammo(idCSW_HEGRENADE, (cs_get_user_bpammo(idCSW_HEGRENADE) + 1));
            
ColorChat(0GREY"%s VIP Mod:^x03 %s bought the^x04 He Grenade^x03 [^x04$%i^x03]"clantacnameget_pcvar_num(hegren_cost));
        }
        case 
2:
        {
            if ( 
cs_get_user_money(id) < get_pcvar_num(frost_cost) )
            {
                
ColorChat(idGREY"%s VIP Mod:^x03 You dont have enough money to buy`x04 Frost Grenade^x03!"clantac);
                return 
PLUGIN_HANDLED;
            }
            
            if ( !
is_user_alive(id) )
            {
                
ColorChat(idGREY"%s VIP Mod:^x03 You need to be alive!"clantac);
                return 
PLUGIN_HANDLED;
            }
            
            if ( 
user_has_weapon(idCSW_SMOKEGRENADE) )
            {
                
ColorChat(idGREY"%s VIP Mod:^x03 You already own the^x04 Frost Grenade^x03!"clantac);
                return 
PLUGIN_HANDLED;
            }
            new 
name[32];
            
get_user_name(idname32);
            
cs_set_user_money(idcs_get_user_money(id) - get_pcvar_num(frost_cost));
            
cs_set_weapon_ammogive_item(id"weapon_sgren"), 0);
            
cs_set_user_bpammo(idCSW_SMOKEGRENADE, (cs_get_user_bpammo(idCSW_SMOKEGRENADE) + 1));
            
ColorChat(0GREY"%s VIP Mod:^x03 %s bought the^x04 Frost Grenade^x03 [^x04$%i^x03]"clantacnameget_pcvar_num(frost_cost));
        }
    }
    return 
PLUGIN_CONTINUE;
}
public 
TaskRespawn(id)
{
    if ( 
cs_get_user_money(id) < get_pcvar_num(respawn_cost) )
    {
        
ColorChat(idGREY"%s VIP Mod:^x03 You dont have enough money to buy this item!"clantac);
        return 
PLUGIN_HANDLED;
    }
    if ( 
bought_respawn == )
    {
        
ColorChat(idGREY"%s VIP Mod:^x03 You have already bought respawn this round!"clantac);
        return 
PLUGIN_HANDLED;
    }
    if ( 
is_user_alive(id) )
    {
        
ColorChat(idGREY"%s VIP Mod:^x03 You cannot buy respawn while your alive!"clantac);
        return 
PLUGIN_HANDLED;
    }
    new 
name[32];
    
get_user_name(idname32);
    
cs_set_user_money(idcs_get_user_money(id) - get_pcvar_num(respawn_cost) );
    
ExecuteHamB(Ham_CS_RoundRespawnid);
    
ColorChat(0GREY"%s VIP Mod:^x03 %s bought ^x04respawn^x03!"clantacname);
    
bought_respawn 1;
    
    return 
PLUGIN_HANDLED;
}

public 
weapon_Menu(id)
{
    new 
buy_awp[60];
    new 
buy_deagle[60];
    new 
buy_shotgun[60];
    new 
buy_colt[60];
    new 
buy_fiveseven[60];
    new 
buy_scout[60];
    
    new 
wep_Menu menu_create("\r [HB] VIP Mod by Larcyn^n^nWeapon Menu""wepMenu_Handle");
    
formatex(buy_awpsizeof(buy_awp) - 1"\wAWP \r[Bullets: \w1\r]      \r[$\y%i\r]"get_pcvar_num(awp_cost));
    
formatex(buy_deaglesizeof(buy_deagle) - 1"\wDeagle \r[Bullets: \w1\r]      \r[$\y%i\r]"get_pcvar_num(deagle_cost));
    
formatex(buy_shotgunsizeof(buy_shotgun) - 1"\wShotGun \r[Bullets: \w1\r]    \r[$\y%i\r]"get_pcvar_num(shotgun_cost));
    
formatex(buy_coltsizeof(buy_colt) - 1"\wColt \r[Bullets: \w1\r]    \r[$\y%i\r]"get_pcvar_num(colt_cost));
    
formatex(buy_fivesevensizeof(buy_fiveseven) - 1"\wFiveSeven \r[Bullets: \w2\r]        \r[$\y%i\r]"get_pcvar_num(fiveseven_cost));
    
formatex(buy_scoutsizeof(buy_scout) - 1"\wScout \r[Bullets: \w0\r]        \r[$\y%i\r]"get_pcvar_num(scout_cost));
    
    
menu_additem(wep_Menubuy_awp"\r1"0);
    
menu_additem(wep_Menubuy_deagle"\r2"0);
    
menu_additem(wep_Menubuy_shotgun"\r3"0);
    
menu_additem(wep_Menubuy_colt"\r4"0);
    
menu_additem(wep_Menubuy_fiveseven"\r5"0);
    
menu_additem(wep_Menubuy_scout"\r6"0);

    
menu_setprop(wep_MenuMPROP_EXITMEXIT_ALL);
    {
        
menu_display(idwep_Menu0);
    }
}

public 
wepMenu_Handle(idmenuitem)
{
    if (
item == MENU_EXIT)
    {
        
menu_destroy(menu);
        return 
PLUGIN_HANDLED;
    }
    
    new 
data[6], iName[64];
    new 
accesscallback;
    
    
menu_item_getinfo(menuitemaccessdata,5iName63callback);
    new 
key str_to_num(data[1]);
    
    switch(
key)
    {
        case 
1:
        {
            if ( 
cs_get_user_money(id) < get_pcvar_num(awp_cost) )
            {
                
ColorChat(idGREY"%s VIP Mod:^x03 You dont have enough money to buy this item!"clantac);
                return 
PLUGIN_HANDLED;
            }
            
            if ( !
is_user_alive(id) )
            {
                
ColorChat(idGREY"%s VIP Mod:^x03 You need to be alive!"clantac);
                return 
PLUGIN_HANDLED;
            }
            
            if ( 
user_has_weapon(idCSW_AWP) )
            {
                
ColorChat(idGREY"%s VIP Mod:^x03 You already own this weapon!"clantac);
                return 
PLUGIN_HANDLED;
            }
            
            new 
name[32];
            
get_user_name(idname32)
            
cs_set_user_money(idcs_get_user_money(id) - get_pcvar_num(awp_cost) );
            
cs_set_weapon_ammogive_item(id"weapon_awp"), 1);
            
ColorChat(0GREY"%s VIP Mod:^x03 %s bought the^x04 AWP^x03 [^x04$%i^x03]"clantacnameget_pcvar_num(awp_cost));
            
        }
        case 
2:
        {
            if ( 
cs_get_user_money(id) < get_pcvar_num(deagle_cost) )
            {
                
ColorChat(idGREY"%s VIP Mod:^x03 You dont have enough money to buy this item!"clantac);
                return 
PLUGIN_HANDLED;
            }
            
            if ( !
is_user_alive(id) )
            {
                
ColorChat(idGREY"%s VIP Mod:^x03 You need to be alive!"clantac);
                return 
PLUGIN_HANDLED;
            }
            
            if ( 
user_has_weapon(idCSW_DEAGLE) )
            {
                
ColorChat(idGREY"%s VIP Mod:^x03 You already own this weapon!"clantac);
                return 
PLUGIN_HANDLED;
            }
            
            new 
name[32];
            
get_user_name(idname32)
            
cs_set_user_money(idcs_get_user_money(id) - get_pcvar_num(deagle_cost));
            
cs_set_weapon_ammogive_item(id"weapon_deagle"), 1);
            
ColorChat(0GREY"%s VIP Mod:^x03 %s bought the^x04 Deagle^x03 [$%i]"clantacnameget_pcvar_num(deagle_cost));
        }
        case 
3:
        {
            if ( 
cs_get_user_money(id) < get_pcvar_num(shotgun_cost) )
            {
                
ColorChat(idGREY"%s VIP Mod:^x03 You dont have enough money to buy this item!"clantac);
                return 
PLUGIN_HANDLED;
            }
            
            if ( !
is_user_alive(id) )
            {
                
ColorChat(idGREY"%s VIP Mod:^x03 You need to be alive!"clantac);
                return 
PLUGIN_HANDLED;
            }
            
            if ( 
user_has_weapon(idCSW_M3) )
            {
                
ColorChat(idGREY"%s VIP Mod:^x03 You already own this weapon!"clantac);
                return 
PLUGIN_HANDLED;
            }
            new 
name[32];
            
get_user_name(idname32);
            
cs_set_user_money(idcs_get_user_money(id) - get_pcvar_num(shotgun_cost));
            
cs_set_weapon_ammogive_item(id"weapon_shotgun"), 1);
            
ColorChat(0GREY"%s VIP Mod:^x03 %s bought the^x04 ShotGun^x03 [^x04$%i^x03]"clantacnameget_pcvar_num(shotgun_cost));
        }
        case 
4:
        {
            if ( 
cs_get_user_money(id) < get_pcvar_num(colt_cost) )
            {
                
ColorChat(idGREY"%s VIP Mod:^x03 You dont have enough money to buy this item!"clantac);
                return 
PLUGIN_HANDLED;
            }
            
            if ( !
is_user_alive(id) )
            {
                
ColorChat(idGREY"%s VIP Mod:^x03 You need to be alive!"clantac);
                return 
PLUGIN_HANDLED;
            }
            
            if ( 
user_has_weapon(idCSW_M4A1) )
            {
                
ColorChat(idGREY"%s VIP Mod:^x03 You already own this weapon!"clantac);
                return 
PLUGIN_HANDLED;
            }
            new 
name[32];
            
get_user_name(idname32);
            
cs_set_user_money(idcs_get_user_money(id) - get_pcvar_num(colt_cost));
            
cs_set_weapon_ammogive_item(id"weapon_m4a1"), 1);
            
ColorChat(0GREY"%s VIP Mod:^x03 %s bought the^x04 Colt^x03 [^x04$%i^x03]"clantacnameget_pcvar_num(colt_cost));
        }
        case 
5:
        {
            if ( 
cs_get_user_money(id) < get_pcvar_num(fiveseven_cost) )
            {
                
ColorChat(idGREY"%s VIP Mod:^x03 You dont have enough money to buy this item!"clantac);
                return 
PLUGIN_HANDLED;
            }
            
            if ( !
is_user_alive(id) )
            {
                
ColorChat(idGREY"%s VIP Mod:^x03 You need to be alive!"clantac);
                return 
PLUGIN_HANDLED;
            }
            
            if ( 
user_has_weapon(idCSW_FIVESEVEN) )
            {
                
ColorChat(idGREY"%s VIP Mod:^x03 You already own this weapon!"clantac);
                return 
PLUGIN_HANDLED;
            }
            new 
name[32];
            
get_user_name(idname32);
            
cs_set_user_money(idcs_get_user_money(id) - get_pcvar_num(fiveseven_cost));
            
cs_set_weapon_ammogive_item(id"weapon_fiveseven"), 2    );
            
ColorChat(0GREY"%s VIP Mod:^x03 %s bought the^x04 FiveSeven^x03 [^x04$%i^x03]"clantacnameget_pcvar_num(fiveseven_cost));
        }
        case 
6:
        {
            if ( 
cs_get_user_money(id) < get_pcvar_num(scout_cost) )
            {
                
ColorChat(idGREY"%s VIP Mod:^x03 You dont have enough money to buy this item!"clantac);
                return 
PLUGIN_HANDLED;
            }
            
            if ( !
is_user_alive(id) )
            {
                
ColorChat(idGREY"%s VIP Mod:^x03 You need to be alive!"clantac);
                return 
PLUGIN_HANDLED;
            }
            
            if ( 
user_has_weapon(idCSW_SCOUT) )
            {
                
ColorChat(idGREY"%s VIP Mod:^x03 You already own this weapon!"clantac);
                return 
PLUGIN_HANDLED;
            }
            new 
name[32];
            
get_user_name(idname32);
            
cs_set_user_money(idcs_get_user_money(id) - get_pcvar_num(scout_cost));
            
cs_set_weapon_ammogive_item(id"weapon_scout"), 0);
            
ColorChat(0GREY"%s VIP Mod:^x03 %s bought the^x04 Scout^x03 [^x04$%i^x03]"clantacnameget_pcvar_num(scout_cost));
        }
    }
    return 
PLUGIN_CONTINUE;
}

public 
item_Menu(id)
{
    new 
buy_respawn[60];
    new 
buy_xp[60];
    new 
buy_hp[60];
    
    
formatex(buy_respawnsizeof(buy_respawn) - 1"\wRespawn    \r[$\y%i\r]"get_pcvar_num(respawn_cost));
    
formatex(buy_xpsizeof(buy_xp) - 1"\w%i XP    \y[$\y%i\r]"get_pcvar_num(xp_amount), get_pcvar_num(xp_cost));
    
formatex(buy_hpsizeof(buy_hp) - 1"\w%i HP    \r[$\y%i\r]"get_pcvar_num(shotgun_cost));
    
    new 
ite_Menu menu_create("\r[HB] VIP Mod by Larcyn^n^nItem Menu""ItemMenu_Handle");
    
    
menu_additem(ite_Menubuy_respawn"\r1"0);
    
menu_additem(ite_Menubuy_xp"\r2"0);
    
menu_additem(ite_Menubuy_hp"\r3"0);
    
menu_setprop(ite_MenuMPROP_EXITMEXIT_ALL);
    {
        
menu_display(idite_Menu0);
    }
}

public 
ItemMenu_Handle(idmenuitem)
{
    if (
item == MENU_EXIT)
    {
        
menu_destroy(menu);
        return 
PLUGIN_HANDLED;
    }
    
    new 
data[6], iName[64];
    new 
accesscallback;
    
    
menu_item_getinfo(menuitemaccessdata,5iName63callback);
    new 
key str_to_num(data);
    
    switch(
key)
    {
        case 
1:
        {
            
set_task(0.2"TaskRespawn"id);
        }
        case 
2:
        {
            if ( 
cs_get_user_money(id) < get_pcvar_num(xp_cost) )
            {
                
ColorChat(idGREY"%s VIP Mod:^x03 You dont have enough money to buy this item!"clantac);
                return 
PLUGIN_HANDLED;
            }
            if ( 
bought_xp == )
            {
                
ColorChat(idGREY"%s VIP Mod:^x03 You have already bought^x04 XP^x03 this round!"clantac);
                return 
PLUGIN_HANDLED;
            }
            new 
name[32];
            
get_user_name(idname32);
            
cs_set_user_money(idcs_get_user_money(id) - get_pcvar_num(xp_cost));
            
hnsxp_add_user_xp(idget_pcvar_num(xp_amount));
            
ColorChat(0GREY"%s VIP Mod:^x03 %s bought^x04 %i^x03 more XP!"clantacnameget_pcvar_num(xp_amount));
            
bought_xp 1;
        }
        case 
3:
        {
            if ( 
cs_get_user_money(id) < get_pcvar_num(hp_cost) )
            {
                
ColorChat(idGREY"%s VIP Mod:^x03 You dont have enough money to buy this item!"clantac);
                return 
PLUGIN_HANDLED;
            }
            if ( 
bought_hp == )
            {
                
ColorChat(idGREY"%s VIP Mod:^x03 You have already bought^x04 HP^x03 this round!"clantac);
                return 
PLUGIN_HANDLED;
            }
            new 
name[32];
            
get_user_name(idname32);
            
cs_set_user_money(idcs_get_user_money(id) - get_pcvar_num(hp_cost));
            
ColorChat(0GREY"%s VIP Mod:^x03 %s bought^x04 %i^x03 more HP!"clantacnameget_pcvar_num(hp_amount));
            new 
health get_user_health(id);
            
health += get_pcvar_num(hp_amount);
        }
    }
    return 
PLUGIN_CONTINUE;
}

public 
client_authorized(id)
{
    
gbConnected[id] = true;
    
    if ( 
access(idADMIN_LEVEL_A) )
    {
        
got_access[id] = true;
    }
}

public 
client_disconnect(id)
{
    
gbConnected[id] = false;
    if ( 
got_access[id] )
    {
        
got_access[id] = false;
    }
}

public 
client_putinserver(id)
{
    
set_task(5.0"Task_LogonMessage"id);
    
g_iMoneyid ] = -1;
}

public 
FwdPlayerSpawn(id)
{
    if( !
gbConnected[id] )
        return 
HAM_IGNORED;
    
    
bought_respawn 0;
    
bought_xp 0;
    
bought_hp 0;
    return 
HAM_HANDLED;
}

public 
Task_LogonMessage(id)
{
    
ColorChat(idGREY"%s VIP Mod:^x03 Checking status for^x04 VIP^x03..."clantac);
    if ( 
got_access[id] )
    {
        
ColorChat(idGREY"%s VIP Mod:^x03 Logged in as^x04 VIP^x03!"clantac);
        
ColorChat(idGREY"%s VIP Mod:^x03 Type^x04 /vip^x03,^x04 /vipshop^x03 or^x04 /vshop^x03 to use^x04 VIP^x03!"clantac);
    }
    else
    {
        
ColorChat(idGREY"%s VIP Mod:^x03 Error logging in as^x04 VIP^x03!"clantac);
        
ColorChat(idGREY"%s VIP Mod:^x03 Reason: You havent bought^x04 VIP^x03 yet!"clantac);
        
ColorChat(idGREY"%s VIP Mod:^x03 Buy VIP by typing ^x04/buyvip^x03!"clantac);
    }
}

public 
buy_vip (id)

    new 
name[32];
    
get_user_name(idname32);
    
    if ( 
got_access [id] )
    {
        
ColorChat(idGREY"%s VIP Mod:^x03 You are already a VIP!"clantac);
    }
    else
    {
        
hnsxp_set_user_xp(idhnsxp_get_user_xp(id) - get_pcvar_num(price));
        
set_user_flags(idADMIN_LEVEL_A);
        
ColorChat(0GREY"%s VIP Mod:^x03 %s bought^x04 VIP^x03!"clantacname);
    }
}
/* AMXX-Studio Notes - DO NOT MODIFY BELOW HERE
*{\\ rtf1\\ ansi\\ ansicpg1252\\ deff0\\ deflang1030{\\ fonttbl{\\ f0\\ fnil Tahoma;}}\n\\ viewkind4\\ uc1\\ pard\\ f0\\ fs16 \n\\ par }
*/
/* AMXX-Studio Notes - DO NOT MODIFY BELOW HERE
*{\\ rtf1\\ ansi\\ ansicpg1252\\ deff0\\ deflang1030{\\ fonttbl{\\ f0\\ fnil Tahoma;}}\n\\ viewkind4\\ uc1\\ pard\\ f0\\ fs16 \n\\ par }
*/
/* AMXX-Studio Notes - DO NOT MODIFY BELOW HERE
*{\\ rtf1\\ ansi\\ ansicpg1252\\ deff0\\ deflang1030{\\ fonttbl{\\ f0\\ fnil Tahoma;}}\n\\ viewkind4\\ uc1\\ pard\\ f0\\ fs16 \n\\ par }
*/
/* AMXX-Studio Notes - DO NOT MODIFY BELOW HERE
*{\\ rtf1\\ ansi\\ ansicpg1252\\ deff0\\ deflang1030{\\ fonttbl{\\ f0\\ fnil Tahoma;}}\n\\ viewkind4\\ uc1\\ pard\\ f0\\ fs16 \n\\ par }
*/ 


Fuck For Fun 12-02-2014 15:53

Re: [HELP] VIP Menu
 
Code:

native hnsxp_get_user_xp(client);

native hnsxp_set_user_xp(client, xp);

stock hnsxp_add_user_xp(client, xp)
{
    return hnsxp_set_user_xp(client, hnsxp_get_user_xp(client) + xp);
}

stock hnsxp_sub_user_xp(client, xp)
{
    return hnsxp_set_user_xp(client, hnsxp_get_user_xp(client) - xp);
}

#include <amxmodx>
#include <amxmisc>
#include <hamsandwich>
#include <fun>
#include <cstrike>
#include <colorchat>

#define PLUGIN    "[HB] VIP Mod"
#define AUTHOR    "HBxander, Larcyn"
#define VERSION    "1.4"

#define clantac "^x04[HB]"

new g_iMoney[33];

new awp_cost;
new deagle_cost;
new shotgun_cost;
new fiveseven_cost;
new hegren_cost;
new respawn_cost;
new colt_cost;
new xp_amount;
new xp_cost;
new hp_amount;
new hp_cost;
new scout_cost;
new frost_cost;

new price;

new bought_respawn;
new bought_xp;
new bought_hp;
new bool:gbConnected[33];
new bool:got_access[33]

public plugin_init()
{
    register_clcmd("say /vip", "vip_shop");
    register_clcmd("say /buyvip", "buy_vip");
    register_clcmd("say_team /vip", "vip_shop");
    register_clcmd("say_tean /buyvip", "buy_vip");

    //weapons price
    awp_cost = register_cvar("vip_awpcost", "16000");
    deagle_cost = register_cvar("vip_dglcost", "12000");
    shotgun_cost = register_cvar("vip_m3cost", "12000");
    fiveseven_cost = register_cvar("vip_fivesevencost", "8000");
    colt_cost = register_cvar("vip_coltcost", "8000");
    scout_cost = register_cvar("vip_scoutcost", "3000");
    //grenades price
    hegren_cost = register_cvar("vip_hegrencost", "8000");
    frost_cost = register_cvar("vip_frostcost", "12000");
    //items price
    respawn_cost = register_cvar("vip_respawncost", "10000");
    hp_cost = register_cvar("vip_hpcost", "6000");
    xp_cost = register_cvar("vip_xpcost", "6000");
    //item amount
    xp_amount = register_cvar("vip_xpamount", "10");
    hp_amount = register_cvar("vip_hpamount", "25");
    //clantac
    price = register_cvar ("vip_price", "2000");
}

public vip_shop(id)
{
    new MainMenu = menu_create("\r[HB] VIP Mod by Larcyn^n^nMain Menu", "MainMenu_Handle");
    menu_additem(MainMenu, "\wWeapon Menu", "1", 0);
    menu_additem(MainMenu, "\wItem Menu", "2", 0);
    menu_additem(MainMenu, "\wGrenades Menu", "3", 0);
    menu_setprop(MainMenu, MPROP_EXIT, MEXIT_ALL);
    if ( got_access[id] )
    {
        menu_display(id, MainMenu, 0);
    }
}

public MainMenu_Handle(id, menu, item)
{
    if (item == MENU_EXIT)
    {
        menu_destroy(menu);
        return PLUGIN_HANDLED;
    }
   
    new data[6], iName[64];
    new access, callback;

    menu_item_getinfo(menu, item, access, data,5, iName, 63, callback);
    new key = str_to_num(data[1]);
   
    switch(key)
    {
        case 1:
        {
            weapon_Menu(id);
        }
        case 2:
        {
            item_Menu(id);
        }
        case 3:
        {
            grenades_Menu(id);
        }
    }
    return PLUGIN_CONTINUE;
}
public grenades_Menu(id)
{
    new buy_hegren[60];
    new buy_frost[60];
   
    formatex(buy_hegren, sizeof(buy_hegren) - 1, "\wHeGrenade \r[Amount: \w1\r]        \r[$\y%i\r]", get_pcvar_num(hegren_cost));
    formatex(buy_frost, sizeof(buy_frost) - 1, "\wFrostGrenade \r[Amount: \w1\r]        \r[$\y%i\r]", get_pcvar_num(frost_cost));
   
    new gren_Menu = menu_create("\r[HB] VIP Mod by Larcyn^n^nGrenade Menu", "GrenadesMenu_Handle");
   
    menu_additem(gren_Menu, buy_hegren, "\r1", 0);
    if ( cs_get_user_team(id) == CS_TEAM_T )
    {
        menu_additem(gren_Menu, buy_frost, "\r2", 0);
    }
    menu_setprop(gren_Menu, MPROP_EXIT, MEXIT_ALL);
    {
        menu_display(id, gren_Menu, 0);
    }
}

public GrenadesMenu_Handle(id, menu, item)
{
    if (item == MENU_EXIT)
    {
        menu_destroy(menu);
        return PLUGIN_HANDLED;
    }
   
    new data[6], iName[64];
    new access, callback;
   
    menu_item_getinfo(menu, item, access, data,5, iName, 63, callback);
    new key = str_to_num(data[1]);
   
    switch(key)
    {
        case 1:
        {
            if ( cs_get_user_money(id) < get_pcvar_num(hegren_cost) )
            {
                ColorChat(id, GREY, "%s VIP Mod:^x03 You dont have enough money to buy`x04 He Grenade^x03!", clantac);
                return PLUGIN_HANDLED;
            }
           
            if ( !is_user_alive(id) )
            {
                ColorChat(id, GREY, "%s VIP Mod:^x03 You need to be alive!", clantac);
                return PLUGIN_HANDLED;
            }
           
            if ( user_has_weapon(id, CSW_HEGRENADE) )
            {
                ColorChat(id, GREY, "%s VIP Mod:^x03 You already own the^x04 He Grenade^x03!", clantac);
                return PLUGIN_HANDLED;
            }
            new name[32];
            get_user_name(id, name, 32);
            cs_set_user_money(id, cs_get_user_money(id) - get_pcvar_num(hegren_cost));
            cs_set_weapon_ammo( give_item(id, "weapon_hegren"), 0);
            cs_set_user_bpammo(id, CSW_HEGRENADE, (cs_get_user_bpammo(id, CSW_HEGRENADE) + 1));
            ColorChat(0, GREY, "%s VIP Mod:^x03 %s bought the^x04 He Grenade^x03 [^x04$%i^x03]", clantac, name, get_pcvar_num(hegren_cost));
        }
        case 2:
        {
            if ( cs_get_user_money(id) < get_pcvar_num(frost_cost) )
            {
                ColorChat(id, GREY, "%s VIP Mod:^x03 You dont have enough money to buy`x04 Frost Grenade^x03!", clantac);
                return PLUGIN_HANDLED;
            }
           
            if ( !is_user_alive(id) )
            {
                ColorChat(id, GREY, "%s VIP Mod:^x03 You need to be alive!", clantac);
                return PLUGIN_HANDLED;
            }
           
            if ( user_has_weapon(id, CSW_SMOKEGRENADE) )
            {
                ColorChat(id, GREY, "%s VIP Mod:^x03 You already own the^x04 Frost Grenade^x03!", clantac);
                return PLUGIN_HANDLED;
            }
            new name[32];
            get_user_name(id, name, 32);
            cs_set_user_money(id, cs_get_user_money(id) - get_pcvar_num(frost_cost));
            cs_set_weapon_ammo( give_item(id, "weapon_sgren"), 0);
            cs_set_user_bpammo(id, CSW_SMOKEGRENADE, (cs_get_user_bpammo(id, CSW_SMOKEGRENADE) + 1));
            ColorChat(0, GREY, "%s VIP Mod:^x03 %s bought the^x04 Frost Grenade^x03 [^x04$%i^x03]", clantac, name, get_pcvar_num(frost_cost));
        }
    }
    return PLUGIN_CONTINUE;
}
public TaskRespawn(id)
{
    if ( cs_get_user_money(id) < get_pcvar_num(respawn_cost) )
    {
        ColorChat(id, GREY, "%s VIP Mod:^x03 You dont have enough money to buy this item!", clantac);
        return PLUGIN_HANDLED;
    }
    if ( bought_respawn == 1 )
    {
        ColorChat(id, GREY, "%s VIP Mod:^x03 You have already bought respawn this round!", clantac);
        return PLUGIN_HANDLED;
    }
    if ( is_user_alive(id) )
    {
        ColorChat(id, GREY, "%s VIP Mod:^x03 You cannot buy respawn while your alive!", clantac);
        return PLUGIN_HANDLED;
    }
    new name[32];
    get_user_name(id, name, 32);
    cs_set_user_money(id, cs_get_user_money(id) - get_pcvar_num(respawn_cost) );
    ExecuteHamB(Ham_CS_RoundRespawn, id);
    ColorChat(0, GREY, "%s VIP Mod:^x03 %s bought ^x04respawn^x03!", clantac, name);
    bought_respawn = 1;
   
    return PLUGIN_HANDLED;
}

public weapon_Menu(id)
{
    new buy_awp[60];
    new buy_deagle[60];
    new buy_shotgun[60];
    new buy_colt[60];
    new buy_fiveseven[60];
    new buy_scout[60];
   
    new wep_Menu = menu_create("\r [HB] VIP Mod by Larcyn^n^nWeapon Menu", "wepMenu_Handle");
    formatex(buy_awp, sizeof(buy_awp) - 1, "\wAWP \r[Bullets: \w1\r]      \r[$\y%i\r]", get_pcvar_num(awp_cost));
    formatex(buy_deagle, sizeof(buy_deagle) - 1, "\wDeagle \r[Bullets: \w1\r]      \r[$\y%i\r]", get_pcvar_num(deagle_cost));
    formatex(buy_shotgun, sizeof(buy_shotgun) - 1, "\wShotGun \r[Bullets: \w1\r]    \r[$\y%i\r]", get_pcvar_num(shotgun_cost));
    formatex(buy_colt, sizeof(buy_colt) - 1, "\wColt \r[Bullets: \w1\r]    \r[$\y%i\r]", get_pcvar_num(colt_cost));
    formatex(buy_fiveseven, sizeof(buy_fiveseven) - 1, "\wFiveSeven \r[Bullets: \w2\r]        \r[$\y%i\r]", get_pcvar_num(fiveseven_cost));
    formatex(buy_scout, sizeof(buy_scout) - 1, "\wScout \r[Bullets: \w0\r]        \r[$\y%i\r]", get_pcvar_num(scout_cost));
   
    menu_additem(wep_Menu, buy_awp, "\r1", 0);
    menu_additem(wep_Menu, buy_deagle, "\r2", 0);
    menu_additem(wep_Menu, buy_shotgun, "\r3", 0);
    menu_additem(wep_Menu, buy_colt, "\r4", 0);
    menu_additem(wep_Menu, buy_fiveseven, "\r5", 0);
    menu_additem(wep_Menu, buy_scout, "\r6", 0);

    menu_setprop(wep_Menu, MPROP_EXIT, MEXIT_ALL);
    {
        menu_display(id, wep_Menu, 0);
    }
}

public wepMenu_Handle(id, menu, item)
{
    if (item == MENU_EXIT)
    {
        menu_destroy(menu);
        return PLUGIN_HANDLED;
    }
   
    new data[6], iName[64];
    new access, callback;
   
    menu_item_getinfo(menu, item, access, data,5, iName, 63, callback);
    new key = str_to_num(data[1]);
   
    switch(key)
    {
        case 1:
        {
            if ( cs_get_user_money(id) < get_pcvar_num(awp_cost) )
            {
                ColorChat(id, GREY, "%s VIP Mod:^x03 You dont have enough money to buy this item!", clantac);
                return PLUGIN_HANDLED;
            }
           
            if ( !is_user_alive(id) )
            {
                ColorChat(id, GREY, "%s VIP Mod:^x03 You need to be alive!", clantac);
                return PLUGIN_HANDLED;
            }
           
            if ( user_has_weapon(id, CSW_AWP) )
            {
                ColorChat(id, GREY, "%s VIP Mod:^x03 You already own this weapon!", clantac);
                return PLUGIN_HANDLED;
            }
           
            new name[32];
            get_user_name(id, name, 32)
            cs_set_user_money(id, cs_get_user_money(id) - get_pcvar_num(awp_cost) );
            cs_set_weapon_ammo( give_item(id, "weapon_awp"), 1);
            ColorChat(0, GREY, "%s VIP Mod:^x03 %s bought the^x04 AWP^x03 [^x04$%i^x03]", clantac, name, get_pcvar_num(awp_cost));
           
        }
        case 2:
        {
            if ( cs_get_user_money(id) < get_pcvar_num(deagle_cost) )
            {
                ColorChat(id, GREY, "%s VIP Mod:^x03 You dont have enough money to buy this item!", clantac);
                return PLUGIN_HANDLED;
            }
           
            if ( !is_user_alive(id) )
            {
                ColorChat(id, GREY, "%s VIP Mod:^x03 You need to be alive!", clantac);
                return PLUGIN_HANDLED;
            }
           
            if ( user_has_weapon(id, CSW_DEAGLE) )
            {
                ColorChat(id, GREY, "%s VIP Mod:^x03 You already own this weapon!", clantac);
                return PLUGIN_HANDLED;
            }
           
            new name[32];
            get_user_name(id, name, 32)
            cs_set_user_money(id, cs_get_user_money(id) - get_pcvar_num(deagle_cost));
            cs_set_weapon_ammo( give_item(id, "weapon_deagle"), 1);
            ColorChat(0, GREY, "%s VIP Mod:^x03 %s bought the^x04 Deagle^x03 [$%i]", clantac, name, get_pcvar_num(deagle_cost));
        }
        case 3:
        {
            if ( cs_get_user_money(id) < get_pcvar_num(shotgun_cost) )
            {
                ColorChat(id, GREY, "%s VIP Mod:^x03 You dont have enough money to buy this item!", clantac);
                return PLUGIN_HANDLED;
            }
           
            if ( !is_user_alive(id) )
            {
                ColorChat(id, GREY, "%s VIP Mod:^x03 You need to be alive!", clantac);
                return PLUGIN_HANDLED;
            }
           
            if ( user_has_weapon(id, CSW_M3) )
            {
                ColorChat(id, GREY, "%s VIP Mod:^x03 You already own this weapon!", clantac);
                return PLUGIN_HANDLED;
            }
            new name[32];
            get_user_name(id, name, 32);
            cs_set_user_money(id, cs_get_user_money(id) - get_pcvar_num(shotgun_cost));
            cs_set_weapon_ammo( give_item(id, "weapon_shotgun"), 1);
            ColorChat(0, GREY, "%s VIP Mod:^x03 %s bought the^x04 ShotGun^x03 [^x04$%i^x03]", clantac, name, get_pcvar_num(shotgun_cost));
        }
        case 4:
        {
            if ( cs_get_user_money(id) < get_pcvar_num(colt_cost) )
            {
                ColorChat(id, GREY, "%s VIP Mod:^x03 You dont have enough money to buy this item!", clantac);
                return PLUGIN_HANDLED;
            }
           
            if ( !is_user_alive(id) )
            {
                ColorChat(id, GREY, "%s VIP Mod:^x03 You need to be alive!", clantac);
                return PLUGIN_HANDLED;
            }
           
            if ( user_has_weapon(id, CSW_M4A1) )
            {
                ColorChat(id, GREY, "%s VIP Mod:^x03 You already own this weapon!", clantac);
                return PLUGIN_HANDLED;
            }
            new name[32];
            get_user_name(id, name, 32);
            cs_set_user_money(id, cs_get_user_money(id) - get_pcvar_num(colt_cost));
            cs_set_weapon_ammo( give_item(id, "weapon_m4a1"), 1);
            ColorChat(0, GREY, "%s VIP Mod:^x03 %s bought the^x04 Colt^x03 [^x04$%i^x03]", clantac, name, get_pcvar_num(colt_cost));
        }
        case 5:
        {
            if ( cs_get_user_money(id) < get_pcvar_num(fiveseven_cost) )
            {
                ColorChat(id, GREY, "%s VIP Mod:^x03 You dont have enough money to buy this item!", clantac);
                return PLUGIN_HANDLED;
            }
           
            if ( !is_user_alive(id) )
            {
                ColorChat(id, GREY, "%s VIP Mod:^x03 You need to be alive!", clantac);
                return PLUGIN_HANDLED;
            }
           
            if ( user_has_weapon(id, CSW_FIVESEVEN) )
            {
                ColorChat(id, GREY, "%s VIP Mod:^x03 You already own this weapon!", clantac);
                return PLUGIN_HANDLED;
            }
            new name[32];
            get_user_name(id, name, 32);
            cs_set_user_money(id, cs_get_user_money(id) - get_pcvar_num(fiveseven_cost));
            cs_set_weapon_ammo( give_item(id, "weapon_fiveseven"), 2    );
            ColorChat(0, GREY, "%s VIP Mod:^x03 %s bought the^x04 FiveSeven^x03 [^x04$%i^x03]", clantac, name, get_pcvar_num(fiveseven_cost));
        }
        case 6:
        {
            if ( cs_get_user_money(id) < get_pcvar_num(scout_cost) )
            {
                ColorChat(id, GREY, "%s VIP Mod:^x03 You dont have enough money to buy this item!", clantac);
                return PLUGIN_HANDLED;
            }
           
            if ( !is_user_alive(id) )
            {
                ColorChat(id, GREY, "%s VIP Mod:^x03 You need to be alive!", clantac);
                return PLUGIN_HANDLED;
            }
           
            if ( user_has_weapon(id, CSW_SCOUT) )
            {
                ColorChat(id, GREY, "%s VIP Mod:^x03 You already own this weapon!", clantac);
                return PLUGIN_HANDLED;
            }
            new name[32];
            get_user_name(id, name, 32);
            cs_set_user_money(id, cs_get_user_money(id) - get_pcvar_num(scout_cost));
            cs_set_weapon_ammo( give_item(id, "weapon_scout"), 0);
            ColorChat(0, GREY, "%s VIP Mod:^x03 %s bought the^x04 Scout^x03 [^x04$%i^x03]", clantac, name, get_pcvar_num(scout_cost));
        }
    }
    return PLUGIN_CONTINUE;
}

public item_Menu(id)
{
    new buy_respawn[60];
    new buy_xp[60];
    new buy_hp[60];
   
    formatex(buy_respawn, sizeof(buy_respawn) - 1, "\wRespawn    \r[$\y%i\r]", get_pcvar_num(respawn_cost));
    formatex(buy_xp, sizeof(buy_xp) - 1, "\w%i XP    \y[$\y%i\r]", get_pcvar_num(xp_amount), get_pcvar_num(xp_cost));
    formatex(buy_hp, sizeof(buy_hp) - 1, "\w%i HP    \r[$\y%i\r]", get_pcvar_num(shotgun_cost));
   
    new ite_Menu = menu_create("\r[HB] VIP Mod by Larcyn^n^nItem Menu", "ItemMenu_Handle");
   
    menu_additem(ite_Menu, buy_respawn, "\r1", 0);
    menu_additem(ite_Menu, buy_xp, "\r2", 0);
    menu_additem(ite_Menu, buy_hp, "\r3", 0);
    menu_setprop(ite_Menu, MPROP_EXIT, MEXIT_ALL);
    {
        menu_display(id, ite_Menu, 0);
    }
}

public ItemMenu_Handle(id, menu, item)
{
    if (item == MENU_EXIT)
    {
        menu_destroy(menu);
        return PLUGIN_HANDLED;
    }
   
    new data[6], iName[64];
    new access, callback;
   
    menu_item_getinfo(menu, item, access, data,5, iName, 63, callback);
    new key = str_to_num(data);
   
    switch(key)
    {
        case 1:
        {
            set_task(0.2, "TaskRespawn", id);
        }
        case 2:
        {
            if ( cs_get_user_money(id) < get_pcvar_num(xp_cost) )
            {
                ColorChat(id, GREY, "%s VIP Mod:^x03 You dont have enough money to buy this item!", clantac);
                return PLUGIN_HANDLED;
            }
            if ( bought_xp == 1 )
            {
                ColorChat(id, GREY, "%s VIP Mod:^x03 You have already bought^x04 XP^x03 this round!", clantac);
                return PLUGIN_HANDLED;
            }
            new name[32];
            get_user_name(id, name, 32);
            cs_set_user_money(id, cs_get_user_money(id) - get_pcvar_num(xp_cost));
            hnsxp_add_user_xp(id, get_pcvar_num(xp_amount));
            ColorChat(0, GREY, "%s VIP Mod:^x03 %s bought^x04 %i^x03 more XP!", clantac, name, get_pcvar_num(xp_amount));
            bought_xp = 1;
        }
        case 3:
        {
            if ( cs_get_user_money(id) < get_pcvar_num(hp_cost) )
            {
                ColorChat(id, GREY, "%s VIP Mod:^x03 You dont have enough money to buy this item!", clantac);
                return PLUGIN_HANDLED;
            }
            if ( bought_hp == 1 )
            {
                ColorChat(id, GREY, "%s VIP Mod:^x03 You have already bought^x04 HP^x03 this round!", clantac);
                return PLUGIN_HANDLED;
            }
            new name[32];
            get_user_name(id, name, 32);
            cs_set_user_money(id, cs_get_user_money(id) - get_pcvar_num(hp_cost));
            ColorChat(0, GREY, "%s VIP Mod:^x03 %s bought^x04 %i^x03 more HP!", clantac, name, get_pcvar_num(hp_amount));
            new health = get_user_health(id);
            health += get_pcvar_num(hp_amount);
        }
    }
    return PLUGIN_CONTINUE;
}

public client_authorized(id)
{
    gbConnected[id] = true;
   
    if ( access(id, ADMIN_LEVEL_A) )
    {
        got_access[id] = true;
    }
}

public client_disconnect(id)
{
    gbConnected[id] = false;
    if ( got_access[id] )
    {
        got_access[id] = false;
    }
}

public client_putinserver(id)
{
    set_task(5.0, "Task_LogonMessage", id);
    g_iMoney[ id ] = -1;
}

public FwdPlayerSpawn(id)
{
    if( !gbConnected[id] )
        return HAM_IGNORED;
   
    bought_respawn = 0;
    bought_xp = 0;
    bought_hp = 0;
    return HAM_HANDLED;
}

public Task_LogonMessage(id)
{
    ColorChat(id, GREY, "%s VIP Mod:^x03 Checking status for^x04 VIP^x03...", clantac);
    if ( got_access[id] )
    {
        ColorChat(id, GREY, "%s VIP Mod:^x03 Logged in as^x04 VIP^x03!", clantac);
        ColorChat(id, GREY, "%s VIP Mod:^x03 Type^x04 /vip^x03,^x04 /vipshop^x03 or^x04 /vshop^x03 to use^x04 VIP^x03!", clantac);
    }
    else
    {
        ColorChat(id, GREY, "%s VIP Mod:^x03 Error logging in as^x04 VIP^x03!", clantac);
        ColorChat(id, GREY, "%s VIP Mod:^x03 Reason: You havent bought^x04 VIP^x03 yet!", clantac);
        ColorChat(id, GREY, "%s VIP Mod:^x03 Buy VIP by typing ^x04/buyvip^x03!", clantac);
    }
}

public buy_vip (id)
{
    new name[32];
    get_user_name(id, name, 32);
   
    if ( got_access [id] )
    {
        ColorChat(id, GREY, "%s VIP Mod:^x03 You are already a VIP!", clantac);
    }
    else
    {
        hnsxp_set_user_xp(id, hnsxp_get_user_xp(id) - get_pcvar_num(price));
        set_user_flags(id, ADMIN_LEVEL_A);
        ColorChat(0, GREY, "%s VIP Mod:^x03 %s bought^x04 VIP^x03!", clantac, name);
    }
}
/* AMXX-Studio Notes - DO NOT MODIFY BELOW HERE
*{\\ rtf1\\ ansi\\ ansicpg1252\\ deff0\\ deflang1030{\\ fonttbl{\\ f0\\ fnil Tahoma;}}\n\\ viewkind4\\ uc1\\ pard\\ f0\\ fs16 \n\\ par }
*/
/* AMXX-Studio Notes - DO NOT MODIFY BELOW HERE
*{\\ rtf1\\ ansi\\ ansicpg1252\\ deff0\\ deflang1030{\\ fonttbl{\\ f0\\ fnil Tahoma;}}\n\\ viewkind4\\ uc1\\ pard\\ f0\\ fs16 \n\\ par }
*/
/* AMXX-Studio Notes - DO NOT MODIFY BELOW HERE
*{\\ rtf1\\ ansi\\ ansicpg1252\\ deff0\\ deflang1030{\\ fonttbl{\\ f0\\ fnil Tahoma;}}\n\\ viewkind4\\ uc1\\ pard\\ f0\\ fs16 \n\\ par }
*/
/* AMXX-Studio Notes - DO NOT MODIFY BELOW HERE
*{\\ rtf1\\ ansi\\ ansicpg1252\\ deff0\\ deflang1030{\\ fonttbl{\\ f0\\ fnil Tahoma;}}\n\\ viewkind4\\ uc1\\ pard\\ f0\\ fs16 \n\\ par }
*/


HeartbeatHNS 12-02-2014 16:33

Re: [HELP] VIP Menu
 
It isn't working. I don't think you changed anything.

Kia 12-03-2014 05:45

Re: [HELP] VIP Menu
 
At the end of each sub-menu you have this:
Code:
{     menu_display(id, wep_Menu, 0); }

Remove the brackets so it is like this:
Code:
menu_display(id, wep_Menu, 0);

HeartbeatHNS 12-03-2014 09:19

Re: [HELP] VIP Menu
 
Thanks for trying to help. But it's still not working.. :(

Fuck For Fun 12-04-2014 11:55

Re: [HELP] VIP Menu
 
Quote:

Originally Posted by HeartbeatHNS (Post 2230778)
Thanks for trying to help. But it's still not working.. :(

HAVE Logs?

can u explain, where the bug? which handler?

*I think the first menu - MainMenu_Handle you need to return a negative value


All times are GMT -4. The time now is 15:21.

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