Raised This Month: $ Target: $400
 0% 

Compiling errors stink


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
PvtSmithFSSF
Senior Member
Join Date: Jul 2008
Old 07-30-2008 , 10:32   Compiling errors stink
Reply With Quote #1

Error:
could not locate output file c:\program files\steam\steamapps\*HIDDEN*\dedicated server\czero\addons\amxmodx\scripting\compile d\cs_shop.amx <compile failed>

Plugin:
http://forums.alliedmods.net/showthread.php?t=74862

I have no idea why this is happening but maybe somebody can help fix it.
+karma if you can help
PvtSmithFSSF is offline
PremunitioN
BANNED
Join Date: Jul 2008
Location: Always use Search before
Old 07-30-2008 , 10:37   Re: Compiling errors stink
Reply With Quote #2

Quote:
Originally Posted by PvtSmithFSSF View Post
Error:
could not locate output file c:\program files\steam\steamapps\*HIDDEN*\dedicated server\czero\addons\amxmodx\scripting\compile d\cs_shop.amx <compile failed>

Plugin:
http://forums.alliedmods.net/showthread.php?t=74862

I have no idea why this is happening but maybe somebody can help fix it.
+karma if you can help
Aha thanks for hiding that
PremunitioN is offline
PvtSmithFSSF
Senior Member
Join Date: Jul 2008
Old 07-30-2008 , 10:40   Re: Compiling errors stink
Reply With Quote #3

NP btw I believe I found the error, PMed.
Maybe not though.
PvtSmithFSSF is offline
ConnorMcLeod
Veteran Member
Join Date: Jul 2006
Location: France (95)
Old 07-30-2008 , 10:41   Re: Compiling errors stink
Reply With Quote #4

Compiles now.
PHP Code:
#include <amxmodx>
#include <amxmisc>
#include <fakemeta_util>
#include <cstrike>

// For FM_ Convertion
#define FM_MONEY_OFFSET 115

// Plugin Information
#define PLUGIN_NAME "CS Shop"
#define PLUGIN_VERS "1.0"
#define PLUGIN_AUTH "PvtSmithFSSF & iNhp-"

// For Stocks
#define PRIMARY_WEAPONS_BIT_SUM ((1<<CSW_SCOUT)|(1<<CSW_XM1014)|(1<<CSW_MAC10)|(1<<CSW_AUG)|(1<<CSW_UMP45)|(1<<CSW_SG550)|(1<<CSW_GALIL)|(1<<CSW_FAMAS)|(1<<CSW_AWP)|(1<<CSW_MP5NAVY)|(1<<CSW_M249)|(1<<CSW_M3)|(1<<CSW_M4A1)|(1<<CSW_TMP)|(1<<CSW_G3SG1)|(1<<CSW_SG552)|(1<<CSW_AK47)|(1<<CSW_P90))
#define SECONDARY_WEAPONS_BIT_SUM ((2<<CSW_P228)|(2<<CSW_ELITE)|(2<<CSW_FIVESEVEN)|(CSW_USP)|(1<<CSW_GLOCK18)|(1<<CSW_DEAGLE))

// Pcvars
new Cvar_Enable

new Ct_Guns[7// 7 so it can handle from 0 to 6
new Tt_Guns[7]

new 
Invis_Menu[4]
new 
Grav_Menu[5]
new 
Hp_Menu[5]
new 
Other_Menu[2]

public 
plugin_init()
{
    
register_plugin(PLUGIN_NAMEPLUGIN_VERSPLUGIN_AUTH)
    
    
// Hook Say for the plugin 
    
register_clcmd("say /shop""Hook_Say")
    
register_clcmd("say_team /shop""Hook_Say")
    
    
// Event for reset the user invisibility & the user gravity & message
    
register_logevent("LogEvent_RoundStart"2"1=Round_Start")
    
    
// Enable Cvar (1 = Enabled | 0 = Disabled)
    
Cvar_Enable register_cvar("amx_smenu_on""1")
    
    
// Menu for Counter-Terrorist Guns (1 = Enabled | 0 = Disabled)
    // Weapons Cvars: M4a1 - Bullpup - TMP - Fiveseven (Price)
    
Ct_Guns[0] = register_cvar("amx_smenu_ct""1")
    
Ct_Guns[1] = register_cvar("amx_smenu_m4a1""3200")
    
Ct_Guns[2] = register_cvar("amx_smenu_bullpup""3500")
    
Ct_Guns[3] = register_cvar("amx_smenu_tmp""2500")
    
Ct_Guns[4] = register_cvar("amx_smenu_fiveseven""850")
    
Ct_Guns[5] = register_cvar("amx_smenu_famas""3000")
    
Ct_Guns[6] = register_cvar("amx_smenu_shield""6000")
    
    
// Menu for Counter-Terrorist Guns (1 = Enabled | 0 = Disabled)
    // Weapons Cvars: Ak47 - Krieg552 - Mac 10 - Elites (Price)
    
Tt_Guns[0] = register_cvar("amx_smenu_tt""1")
    
Tt_Guns[1] = register_cvar("amx_smenu_ak47""2500")
    
Tt_Guns[2] = register_cvar("amx_smenu_krieg""3000")
    
Tt_Guns[3] = register_cvar("amx_smenu_mac10""1500")
    
Tt_Guns[4] = register_cvar("amx_smenu_elites""1000")
    
Tt_Guns[5] = register_cvar("amx_smenu_galil""3000")
    
    
// Menu for Invisibility (1 = Enabled | 0 = Disabled)
    // Cvars: Price of each item
    // Low Invisibility = Possible to see (like noclip)
    // Medium Invisibility = More invisible but is possible to see
    // High Invisibility = Totally Invisiblity
    
Invis_Menu[0] = register_cvar("amx_smenu_invis""1")
    
Invis_Menu[1] = register_cvar("amx_smenu_low""3000")
    
Invis_Menu[2] = register_cvar("amx_smenu_medium""6000")
    
Invis_Menu[3] = register_cvar("amx_smenu_high""12000")
    
    
// Menu for Gravity (1 = Enabled | 0 = Disabled)
    // Cvars: Price of each item
    
Grav_Menu[0] = register_cvar("amx_smenu_grav""1")
    
Grav_Menu[1] = register_cvar("amx_smenu_g200""6000")
    
Grav_Menu[2] = register_cvar("amx_smenu_g300""4500")
    
Grav_Menu[3] = register_cvar("amx_smenu_g400""3000")
    
Grav_Menu[4] = register_cvar("amx_smenu_g500""1500")
    
    
// Menu for HP (Health) (1 = Enabled | 0 = Disabled)
    // Cvars: Price of each item
    
Hp_Menu[0] = register_cvar("amx_smenu_hp""1"
    
Hp_Menu[1] = register_cvar("amx_smenu_15hp""1500")
    
Hp_Menu[2] = register_cvar("amx_smenu_35hp""3000")
    
Hp_Menu[3] = register_cvar("amx_smenu_65hp""6000")
    
Hp_Menu[4] = register_cvar("amx_smenu_95hp""7500")
    
    
// Other Menu CVars
    
Other_Menu[0] = register_cvar("amx_smenu_other""1"
    
Other_Menu[1] = register_cvar("amx_smenu_skins""7500"
}

public 
Hook_Say(id)
{
    if (!
get_pcvar_num(Cvar_Enable))
        
client_print(idprint_chat"[CS Shop] CS Shop Menu is Actually Disabled.")
    else
        
Create_Menu(id)
    
    return 
PLUGIN_CONTINUE
}

public 
Create_Menu(id)
{
    new 
Menu menu_create("\rCS Shop Menu""Menu_Handler")
    
    
menu_additem(Menu"CT's Guns""1"0)
    
menu_additem(Menu"T's Guns""2"0)
    
menu_additem(Menu"Invisibility Menu""3"0)
    
menu_additem(Menu"Gravity Menu""4"0)
    
menu_additem(Menu"Health Menu""5"0)
    
menu_additem(Menu"Other""6"0)
    
    
menu_setprop(MenuMPROP_EXITMEXIT_ALL)
    
menu_display(idMenu0)
}

public 
Menu_Handler(idMenuitem)
{
    if (
item == MENU_EXIT)
    {
        
// We destroy the menu if clients press the key of exit
        
menu_destroy(Menu)
        return 
PLUGIN_HANDLED
    
}
    
    new 
Data[6];
    new 
Access;
    new 
Callback;
    new 
Name[64];
    
menu_item_getinfo(MenuitemAccessData5Name63Callback)
    
    new 
Key str_to_num(Data);
    
    switch (
Key)
    {
        case 
1:
        {
            new 
Cts_Menu menu_create("\wCT's Guns""CT_Menu_Handler")
            
            new 
Item_M4a1[200]
            
formatex(Item_M4a1199"\wBuy M4A1 - $%d"get_pcvar_num(Ct_Guns[1]))
            
menu_additem(Cts_MenuItem_M4a1"1"0)
            
            new 
Item_Bullpup[200]
            
formatex(Item_Bullpup199"\wBuy Bullpup - $%d"get_pcvar_num(Ct_Guns[2]))
            
menu_additem(Cts_MenuItem_Bullpup"2"0)
            
            new 
Item_Tmp[200]
            
formatex(Item_Tmp199"\wBuy Tmp - $%d"get_pcvar_num(Ct_Guns[3]))
            
menu_additem(Cts_MenuItem_Tmp"3"0)
            
            new 
Item_FSeven[200]
            
formatex(Item_FSeven199"\wBuy Five Seven - $%d"get_pcvar_num(Ct_Guns[4]))
            
menu_additem(Cts_MenuItem_FSeven"4"0)
            
            new 
Item_Famas[200]
            
formatex(Item_Famas199"\wBuy Famas - $%d"get_pcvar_num(Ct_Guns[5]))
            
menu_additem(Cts_MenuItem_Famas"5"0)
            
            new 
Item_Shield[200]
            
formatex(Item_Shield199"\wBuy Shield - $%d"get_pcvar_num(Ct_Guns[6]))
            
menu_additem(Cts_MenuItem_Shield"6"0)
            
            
menu_setprop(Cts_MenuMPROP_EXITMEXIT_ALL)
            
            if (
get_pcvar_num(Ct_Guns[0]) == 1)
                
menu_display(idCts_Menu0)
        }
        
        case 
2:
        {
            new 
Tts_Menu menu_create("\wT's Guns""TT_Menu_Handler")
            
            new 
Item_Ak47[200]
            
formatex(Item_Ak47199"\wBuy Ak47 - $%d"get_pcvar_num(Tt_Guns[1]))
            
menu_additem(Tts_MenuItem_Ak47"1"0)
            
            new 
Item_Krieg[200]
            
formatex(Item_Krieg199"\wBuy Krieg552 - $%d"get_pcvar_num(Tt_Guns[2]))
            
menu_additem(Tts_MenuItem_Krieg"2"0)
            
            new 
Item_Mac10[200]
            
formatex(Item_Mac10199"\wBuy Mac10 - $%d"get_pcvar_num(Tt_Guns[3]))
            
menu_additem(Tts_MenuItem_Mac10"3"0)
            
            new 
Item_Elites[200]
            
formatex(Item_Elites199"\wBuy Dual Elites - $%d"get_pcvar_num(Tt_Guns[4]))
            
menu_additem(Tts_MenuItem_Elites"4"0)
            
            new 
Item_Galil[200]
            
formatex(Item_Galil199"\wBuy Galil - $%d"get_pcvar_num(Tt_Guns[5]))
            
menu_additem(Tts_MenuItem_Galil"5"0)
            
            
menu_setprop(Tts_MenuMPROP_EXITMEXIT_ALL)
            
            if (
get_pcvar_num(Tt_Guns[0]) == 1)
                
menu_display(idTts_Menu0)
        }
        
        case 
3:
        {
            new 
Inv_Menu menu_create("\wInvisibility Menu""Invis_Handler")
            
            new 
Item_Low[200]
            
formatex(Item_Low199"\wInvisibility Low - $%d"get_pcvar_num(Invis_Menu[1]))
            
menu_additem(Inv_MenuItem_Low"1"0)
            
            new 
Item_Medium[200]
            
formatex(Item_Medium199"\wInvisibility Medium - $%d"get_pcvar_num(Invis_Menu[2]))
            
menu_additem(Inv_MenuItem_Medium"2"0)
            
            new 
Item_High[200]
            
formatex(Item_High199"\wInvisibility High - $%d"get_pcvar_num(Invis_Menu[3]))
            
menu_additem(Inv_MenuItem_High"3"0)
            
            
menu_setprop(Inv_MenuMPROP_EXITMEXIT_ALL)
            
            if (
get_pcvar_num(Invis_Menu[0]) == 1)
                
menu_display(idInv_Menu0)
        }
        
        case 
4:
        {
            new 
Gravity_Menu menu_create("\wGravity Menu""Grav_Handler")
            
            new 
Item_Grav_200[200]
            
formatex(Item_Grav_200199"\w500 Gravity - $%d"get_pcvar_num(Grav_Menu[4]))
            
menu_additem(Gravity_MenuItem_Grav_200"1"0)
            
            new 
Item_Grav_300[200]
            
formatex(Item_Grav_300199"\w400 Gravity - $%d"get_pcvar_num(Grav_Menu[3]))
            
menu_additem(Gravity_MenuItem_Grav_300"2"0)
            
            new 
Item_Grav_400[200]
            
formatex(Item_Grav_400199"\w300 Gravity - $%d"get_pcvar_num(Grav_Menu[2]))
            
menu_additem(Gravity_MenuItem_Grav_400"3"0)
            
            new 
Item_Grav_500[200]
            
formatex(Item_Grav_500199"\w200 Gravity - $%d"get_pcvar_num(Grav_Menu[1]))
            
menu_additem(Gravity_MenuItem_Grav_500"4"0)
            
            
menu_setprop(Gravity_MenuMPROP_EXITMEXIT_ALL)
            
            if (
get_pcvar_num(Grav_Menu[0]) == 1)
                
menu_display(idGravity_Menu0)
        }
        
        case 
5:
        {
            new 
Health_Menu menu_create("\wHealth Menu""Hp_Handler")
            
            new 
Item_Hp15[200]
            
formatex(Item_Hp15199"\w15 Health - $%d"get_pcvar_num(Hp_Menu[1]))
            
menu_additem(Health_MenuItem_Hp15"1"0)
            
            new 
Item_Hp35[200]
            
formatex(Item_Hp35199"\w35 Health - $%d"get_pcvar_num(Hp_Menu[2]))
            
menu_additem(Health_MenuItem_Hp35"2"0)
            
            new 
Item_Hp65[200]
            
formatex(Item_Hp65199"\w65 Health - $%d"get_pcvar_num(Hp_Menu[3]))
            
menu_additem(Health_MenuItem_Hp65"3"0)
            
            new 
Item_Hp95[200]
            
formatex(Item_Hp95199"\w95 Health - $%d"get_pcvar_num(Hp_Menu[4]))
            
menu_additem(Health_MenuItem_Hp95"4"0)
            
            
menu_setprop(Health_MenuMPROP_EXITMEXIT_ALL)
            
            if (
get_pcvar_num(Hp_Menu[0]) == 1)
                
menu_display(idHealth_Menu0)
        }
        
        case 
6:
        {
            
// Don't use the same name as the global variable here !!
            
new __Other_Menu menu_create("\wOther Items""Other_Menu_Handler")
            
            new 
Item_Tskin[200]
            
formatex(Item_Tskin199"\wTerrorist Skin - $%d"get_pcvar_num(Other_Menu[1]))
            
menu_additem(__Other_MenuItem_Tskin"1"0)
            
            new 
Item_CTskin[200]
            
formatex(Item_CTskin199"\wCounter-Terrorist Skin - $%d"get_pcvar_num(Other_Menu[1]))
            
menu_additem(__Other_MenuItem_CTskin"2"0)
            
            
menu_setprop(__Other_MenuMPROP_EXITMEXIT_ALL)
            
            if (
get_pcvar_num(Other_Menu[0]) == 1)
                
menu_display(id__Other_Menu0)
        }
    }
    
menu_destroy(Menu)
    return 
PLUGIN_HANDLED
}

public 
Other_Menu_Handler(id__Other_Menuitem)
{
    if (
item == MENU_EXIT)
    {
        
menu_destroy(__Other_Menu)
        return 
PLUGIN_HANDLED
    
}
    
    new 
Data[6]
    new 
Name[64]
    new 
Access
    
new Callback;
    
menu_item_getinfo(__Other_MenuitemAccessData5Name63Callback)
    
    new 
Key str_to_num(Data)
    
    switch (
Key)
    {
        case 
1:
        {
            new 
Money fm_get_user_money(id)
            new 
Pcvar get_pcvar_num(Other_Menu[1])
            
            if (
Money Pcvar)
            {
                
client_print(idprint_chat"[CS Shop] You don't have enough money!")
            }
            else
            {
                
client_print(idprint_chat"[CS Shop] You now look like a terrorist!")
                
fm_set_user_money(idMoney-Pcvar)
                
                
cs_set_user_model(id"leet")
            }
        }
        
        case 
2:
        {
            new 
Money fm_get_user_money(id)
            new 
Pcvar get_pcvar_num(Other_Menu[1])
            
            if (
Money Pcvar)
            {
                
client_print(idprint_chat"[CS Shop] You don't have enough money!")
            }
            else
            {
                
client_print(idprint_chat"[CS Shop] You now look like a counter-terrorist!")
                
fm_set_user_money(idMoney-Pcvar)
                
                
cs_set_user_model(id"gign")
            }
        }
    }
    
menu_destroy(__Other_Menu)
    return 
PLUGIN_HANDLED
}

public 
CT_Menu_Handler(idCts_Menuitem)
{
    if (
item == MENU_EXIT)
    {
        
menu_destroy(Cts_Menu)
        return 
PLUGIN_HANDLED
    
}
    
    new 
Data[6]
    new 
Name[64]
    new 
Access
    
new Callback;
    
menu_item_getinfo(Cts_MenuitemAccessData5Name63Callback)
    
    new 
Key str_to_num(Data)
    
    switch (
Key)
    {
        case 
1:
        {
            new 
Money fm_get_user_money(id)
            new 
Pcvar get_pcvar_num(Ct_Guns[1])
            
            if (
Money Pcvar)
            {
                
client_print(idprint_chat"[CS Shop] You don't have enough money!")
            }
            else
            {
                
client_print(idprint_chat"[CS Shop] Have Fun with your new M4a1")
                
fm_set_user_money(idMoney-Pcvar)
                
                
drop_prim(id)
                
fm_give_item(id"weapon_m4a1")
                
fm_give_item(id"ammo_556nato")
                
fm_give_item(id"ammo_556nato")
                
fm_give_item(id"ammo_556nato")
            }
        }
        
        case 
2:
        {
            new 
Money fm_get_user_money(id)
            new 
Pcvar get_pcvar_num(Ct_Guns[2])
            
            if (
Money Pcvar)
            {
                
client_print(idprint_chat"[CS Shop] You don't have enough money!")
            }
            else
            {
                
client_print(idprint_chat"[CS Shop] Have Fun with your new Bullpup")
                
fm_set_user_money(idMoney-Pcvar)
                
                
drop_prim(id)
                
fm_give_item(id"weapon_aug")
                
fm_give_item(id"ammo_556nato")
                
fm_give_item(id"ammo_556nato")
                
fm_give_item(id"ammo_556nato")
            }
        }
        
        case 
3:
        {
            new 
Money fm_get_user_money(id)
            new 
Pcvar get_pcvar_num(Ct_Guns[3])
            
            if (
Money Pcvar)
            {
                
client_print(idprint_chat"[CS Shop] You don't have enough money!")
            }
            else
            {
                
client_print(idprint_chat"[CS Shop] Have Fun with your new Tmp")
                
fm_set_user_money(idMoney-Pcvar)
                
                
drop_prim(id)
                
fm_give_item(id"weapon_tmp")
                
fm_give_item(id"ammo_9mm")
                
fm_give_item(id"ammo_9mm")
                
fm_give_item(id"ammo_9mm")
                
fm_give_item(id"ammo_9mm")
                
fm_give_item(id"ammo_9mm")
            }
        }
        
        case 
4:
        {
            new 
Money fm_get_user_money(id)
            new 
Pcvar get_pcvar_num(Ct_Guns[4])
            
            if (
Money Pcvar)
            {
                
client_print(idprint_chat"[CS Shop] You don't have enough money!")
            }
            else
            {
                
client_print(idprint_chat"[CS Shop] Have Fun with your new Five Seven")
                
fm_set_user_money(idMoney-Pcvar)
                
                
drop_sec(id)
                
fm_give_item(id"weapon_fiveseven")
                
fm_give_item(id"ammo_57mm")
                
fm_give_item(id"ammo_57mm")
            }
        }
    }
    
menu_destroy(Cts_Menu)
    return 
PLUGIN_HANDLED
}

public 
TT_Menu_Handler(idTts_Menuitem)
{
    if (
item == MENU_EXIT)
    {
        
menu_destroy(Tts_Menu)
        return 
PLUGIN_HANDLED
    
}
    
    new 
Data[6]
    new 
Name[64]
    new 
Access
    
new Callback;
    
menu_item_getinfo(Tts_MenuitemAccessData5Name63Callback)
    
    new 
Key str_to_num(Data)
    
    switch (
Key)
    {
        case 
1:
        {
            new 
Money fm_get_user_money(id)
            new 
Pcvar get_pcvar_num(Tt_Guns[1])
            
            if (
Money Pcvar)
            {
                
client_print(idprint_chat"[CS Shop] You don't have enough money!")
            }
            else
            {
                
client_print(idprint_chat"[CS Shop] Have Fun with your new Ak 47")
                
fm_set_user_money(idMoney-Pcvar)
                
                
drop_prim(id)
                
fm_give_item(id"weapon_ak47")
                
fm_give_item(id"ammo_762nato")
                
fm_give_item(id"ammo_762nato")
                
fm_give_item(id"ammo_762nato")
            }
        }
        
        case 
2:
        {
            new 
Money fm_get_user_money(id)
            new 
Pcvar get_pcvar_num(Tt_Guns[2])
            
            if (
Money Pcvar)
            {
                
client_print(idprint_chat"[CS Shop] You don't have enough money!")
            }
            else
            {
                
client_print(idprint_chat"[CS Shop] Have Fun with your new Krieg 552")
                
fm_set_user_money(idMoney-Pcvar)
                
                
drop_prim(id)
                
fm_give_item(id"weapon_sg552")
                
fm_give_item(id"ammo_556nato")
                
fm_give_item(id"ammo_556nato")
                
fm_give_item(id"ammo_556nato")
            }
        }
        
        case 
3:
        {
            new 
Money fm_get_user_money(id)
            new 
Pcvar get_pcvar_num(Tt_Guns[3])
            
            if (
Money Pcvar)
            {
                
client_print(idprint_chat"[CS Shop] You don't have enough money!")
            }
            else
            {
                
client_print(idprint_chat"[CS Shop] Have Fun with your new Mac 10")
                
fm_set_user_money(idMoney-Pcvar)
                
                
drop_prim(id)
                
fm_give_item(id"weapon_mac10")
                
fm_give_item(id"ammo_45acp")
                
fm_give_item(id"ammo_45acp")
                
fm_give_item(id"ammo_45acp")
                
fm_give_item(id"ammo_45acp")
                
fm_give_item(id"ammo_45acp")
                
fm_give_item(id"ammo_45acp")
                
fm_give_item(id"ammo_45acp")
                
fm_give_item(id"ammo_45acp")
                
fm_give_item(id"ammo_45acp")
            }
        }
        
        case 
4:
        {
            new 
Money fm_get_user_money(id)
            new 
Pcvar get_pcvar_num(Tt_Guns[4])
            
            if (
Money Pcvar)
            {
                
client_print(idprint_chat"[CS Shop] You don't have enough money!")
            }
            else
            {
                
client_print(idprint_chat"[CS Shop] Have Fun with your new Elites")
                
fm_set_user_money(idMoney-Pcvar)
                
                
drop_sec(id)
                
fm_give_item(id"weapon_elite")
                
fm_give_item(id"ammo_9mm")
                
fm_give_item(id"ammo_9mm")
                
fm_give_item(id"ammo_9mm")
                
fm_give_item(id"ammo_9mm")
                
fm_give_item(id"ammo_9mm")
                
fm_give_item(id"ammo_9mm")
            }
        }
    }
    
menu_destroy(Tts_Menu)
    return 
PLUGIN_HANDLED
}

public 
Invis_Handler(idInv_Menuitem)
{
    if (
item == MENU_EXIT)
    {
        
menu_destroy(Inv_Menu)
        return 
PLUGIN_HANDLED
    
}
    
    new 
Data[6]
    new 
acces
    
new name[64]
    new 
callback;
    
menu_item_getinfo(Inv_MenuitemaccesData5name63callback)
    
    new 
Key str_to_num(Data)
    
    switch (
Key)
    {
        case 
1:
        {
            new 
Money fm_get_user_money(id)
            new 
Pcvar get_pcvar_num(Invis_Menu[1])
            
            if (
Money Pcvar)
            {
                
client_print(idprint_chat"[CS Shop] You don't have enough money!")
            }
            else
            {
                
client_print(idprint_chat"[CS Shop] Have Fun with your Low Invisibility [1 Round]")
                
fm_set_user_rendering(id,kRenderFxGlowShell,0,0,0,kRenderNormal,20)
            }
        }
        
        case 
2:
        {
            new 
Money fm_get_user_money(id)
            new 
Pcvar get_pcvar_num(Invis_Menu[2])
            
            if (
Money Pcvar)
            {
                
client_print(idprint_chat"[CS Shop] You don't have enough money!")
            }
            else
            {
                
client_print(idprint_chat"[CS Shop] Have Fun with your Medium Invisibility [1 Round]")
                
fm_set_user_rendering(id,kRenderFxGlowShell,0,0,0,kRenderNormal,10)
            }
        }
        
        case 
3:
        {
            new 
Money fm_get_user_money(id)
            new 
Pcvar get_pcvar_num(Invis_Menu[3])
            
            if (
Money Pcvar)
            {
                
client_print(idprint_chat"[CS Shop] You don't have enough money!")
            }
            else
            {
                
client_print(idprint_chat"[CS Shop] Have Fun with your HIGH Invisibility [1 Round]")
                
fm_set_user_rendering(id,kRenderFxGlowShell,0,0,0,kRenderNormal,2)
            }
        }
    }
    
menu_destroy(Inv_Menu)
    return 
PLUGIN_HANDLED
}

public 
Grav_Handler(idGravity_Menuitem)
{
    if (
item == MENU_EXIT)
    {
        
menu_destroy(Gravity_Menu)
        return 
PLUGIN_HANDLED
    
}
    
    new 
Data[6]
    new 
Name[64]
    new 
Access
    
new Callback;
    
menu_item_getinfo(Gravity_MenuitemAccessData5Name63Callback)
    
    new 
Key str_to_num(Data)
    
    switch (
Key)
    {
        case 
1:
        {
            new 
Money fm_get_user_money(id)
            new 
Pcvar get_pcvar_num(Grav_Menu[4])
            
            if (
Money Pcvar)
            {
                
client_print(idprint_chat"[CS Shop] You don't have enough money!")
            }
            else
            {
                
client_print(idprint_chat"[CS Shop] You just purchased 500 gravity")
                
fm_set_user_money(idMoney-Pcvar)
                
fm_set_user_gravity (id,0.63);
            }
        }
        
        case 
2:
        {
            new 
Money fm_get_user_money(id)
            new 
Pcvar get_pcvar_num(Grav_Menu[3])
            
            if (
Money Pcvar)
            {
                
client_print(idprint_chat"[CS Shop] You don't have enough money!")
            }
            else
            {
                
client_print(idprint_chat"[CS Shop] You just purchased 400 gravity")
                
fm_set_user_money(idMoney-Pcvar)
                
fm_set_user_gravity (id,0.50);
            }
        }
        
        case 
3:
        {
            new 
Money fm_get_user_money(id)
            new 
Pcvar get_pcvar_num(Grav_Menu[2])
            
            if (
Money Pcvar)
            {
                
client_print(idprint_chat"[CS Shop] You don't have enough money!")
            }
            else
            {
                
client_print(idprint_chat"[CS Shop] You just purchased 300 gravity")
                
fm_set_user_money(idMoney-Pcvar)
                
fm_set_user_gravity (id,0.38);
            }
        }
        
        case 
4:
        {
            new 
Money fm_get_user_money(id)
            new 
Pcvar get_pcvar_num(Grav_Menu[1])
            
            if (
Money Pcvar)
            {
                
client_print(idprint_chat"[CS Shop] You don't have enough money!")
            }
            else
            {
                
client_print(idprint_chat"[CS Shop] You just purchased 200 gravity")
                
fm_set_user_money(idMoney-Pcvar)
                
fm_set_user_gravity (id,0.25);
            }
        }
        
    }
    
menu_destroy(Gravity_Menu)
    return 
PLUGIN_HANDLED
}                

public 
Hp_Handler(idHealth_Menuitem)
{
    if (
item == MENU_EXIT)
    {
        
menu_destroy(Health_Menu)
        return 
PLUGIN_HANDLED
    
}
    
    new 
Data[6]
    new 
Name[64]
    new 
Access
    
new Callback;
    
menu_item_getinfo(Health_MenuitemAccessData5Name63Callback)
    
    new 
Key str_to_num(Data)
    
    switch (
Key)
    {
        case 
1:
        {
            new 
Money fm_get_user_money(id)
            new 
Pcvar get_pcvar_num(Hp_Menu[1])
            new 
Health get_user_health(id)
            
            if (
Money Pcvar)
            {
                
client_print(idprint_chat"[CS Shop] You don't have enough money!")
            }
            else
            {
                
client_print(idprint_chat"[CS Shop] You just purchased 15+ Health")
                
fm_set_user_money(idMoney-Pcvar)
                
fm_set_user_health (idHealth+15)
            }
        }
        
        case 
2:
        {
            new 
Money fm_get_user_money(id)
            new 
Pcvar get_pcvar_num(Hp_Menu[2])
            new 
Health get_user_health(id)
            
            if (
Money Pcvar)
            {
                
client_print(idprint_chat"[CS Shop] You don't have enough money!")
            }
            else
            {
                
client_print(idprint_chat"[CS Shop] You just purchased 35+ Health")
                
fm_set_user_money(idMoney-Pcvar)
                
fm_set_user_health (idHealth+35)
            }
        }
        
        
        case 
3:
        {
            new 
Money fm_get_user_money(id)
            new 
Pcvar get_pcvar_num(Hp_Menu[3])
            new 
Health get_user_health(id)
            
            if (
Money Pcvar)
            {
                
client_print(idprint_chat"[CS Shop] You don't have enough money!")
            }
            else
            {
                
client_print(idprint_chat"[CS Shop] You just purchased 65+ Health")
                
fm_set_user_money(idMoney-Pcvar)
                
fm_set_user_health (idHealth+65)
            }
        }
        
        
        case 
4:
        {
            new 
Money fm_get_user_money(id)
            new 
Pcvar get_pcvar_num(Hp_Menu[4])
            new 
Health get_user_health(id)
            
            if (
Money Pcvar)
            {
                
client_print(idprint_chat"[CS Shop] You don't have enough money!")
            }
            else
            {
                
client_print(idprint_chat"[CS Shop] You just purchased 95+ Health")
                
fm_set_user_money(idMoney-Pcvar)
                
fm_set_user_health (idHealth+95)
            }
        }
        
    }
    
menu_destroy(Health_Menu)
    return 
PLUGIN_HANDLED
}                            

public 
LogEvent_RoundStart()
{
    new 
Players[32], NumiPlayer
    get_players
(PlayersNum)
    
    for (new 
0Numi++)
    {
        
iPlayer Players[i]
        
fm_set_user_rendering(iPlayerkRenderFxNone000kRenderTransAlpha255)
        
fm_set_user_gravity(iPlayer1.0)
        
cs_reset_user_model(iPlayer)
        
client_print(iPlayerprint_chat"Type /shop to get cool upgrades!")
    }
}

stock drop_prim(id)
{
    new 
weapons[32], num
    get_user_weapons
(idweaponsnum)
    
    for (new 
0numi++) 
    {
        if (
PRIMARY_WEAPONS_BIT_SUM & (1<<weapons[i]))
        {
            static 
wname[32]
            
get_weaponname(weapons[i], wnamesizeof wname 1)
            
            
engclient_cmd(id"drop"wname)
        }
    }
}

stock drop_sec(id)
{
    new 
weapons[32], num
    get_user_weapons
(idweaponsnum)
    
    for (new 
0numi++)
    {
        if (
SECONDARY_WEAPONS_BIT_SUM & (2<<weapons[i]))
        {
            static 
wname[32]
            
get_weaponname(weapons[i], wnamesizeof wname 1)
            
engclient_cmd(id"drop"wname)
        }
    }
}    

stock fm_set_user_money(indexmoneyflash 1
{
    
set_pdata_int(indexFM_MONEY_OFFSETmoney);
    
    
message_begin(MSG_ONEget_user_msgid("Money"), _index);
    
write_long(money);
    
write_byte(flash 0);
    
message_end();
}

stock fm_get_user_money(index
{
    return 
get_pdata_int(indexFM_MONEY_OFFSET)

__________________
- tired and retired -

- my plugins -
ConnorMcLeod is offline
PvtSmithFSSF
Senior Member
Join Date: Jul 2008
Old 07-30-2008 , 10:42   Re: Compiling errors stink
Reply With Quote #5

thanks
forgot about changing that number

Last edited by PvtSmithFSSF; 07-30-2008 at 10:45.
PvtSmithFSSF is offline
Reply


Thread Tools
Display Modes

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 05:34.


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