Raised This Month: $ Target: $400
 0% 

help menu


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
azzou
Member
Join Date: Jan 2014
Location: AlGeRiA
Old 12-27-2014 , 13:56   help menu
Reply With Quote #1

Hi , last 2 year i creat a menu for cs 1.6 i c'ant compile it (EROR)

PHP Code:
#include <amxmodx>
#include <fun>
#include <cstrike>

new Plugin[] = "Menu" 
new Version[] = "0.1"
new Author[] = "Azzou"

public plugin_init() {

    
register_plugin("Plugin""Version""Author")
    
    
register_clmd("say /menu""menu_hendler")
}

public 
abrir_menu(id)
{
    new 
menu menu creat("Menu:""menu_hendler)
    menu_additem(menu, "
awp 5000 $ ]","1")
    menu_additem(menu, "
Ak46 4000 $ ]","2")
    menu_additem(menu, "
M4a1 4000 $ ]","3")
    menu_additem(menu, "
+50HP 4500 $ ]","4")
    menu_additem(menu, "
+100HP 9000 $ ]","5")
    menu_additem(menu, "
+100 ARMOR [2500 $]","6")
    
    menu_setprop(menu, MPROP_EXITNAME, "
Exit")
    menu_setprop(menu, MPROP_EXIT, MEXIT_ALL)
    
    menu_display(id, menu, 0)
}

public menu_handler(menu, id, item)
{
    if(item == MENU_EXIT)
    menu_destroy(menu)
        return PLUGIN_HANDLER
    }
    
    new data[6], iName[64]
    new access, callback
    new money = cs_get_user_money( id )
    menu_item_getinfo(menu, item, access, data,5,iName, 63,callback)
    
    new key = str_to_num(data)
    switch(key)
    {
        case 1:
        {
            if(cs_get_user_money(id) >= 5000)
            {
                cs_set_user_money(id, money - 5000)
                give_iteam(id, "
weapon_awp")
                cs_set_user_bpammo(id, CSW_AWP, 30)
                clien_print(id, print_chat, "
You get AWP !"
            }
        }
        case 2 :
        {
            if(cs_get_user_money(id) >= 4000)
            {
                cs_set_user_money(id, money - 5000)
                give_iteam(id, "
weapon_ak46")
                cs_set_user_bpammo(id, CSW_AK46, 30)
                clien_print(id, print_chat, "
You get AK46 !"
            }
        }
        case 3 :
        {
            if(cs_get_user_money(id) >= 5000)
            {
                cs_set_user_money(id, money - 5000)
                give_iteam(id, "
weapon_m4a1")
                cs_set_user_bpammo(id, CSW_M4A1, 30)
                clien_print(id, print_chat, "
You get M4A1 !"
                
            }
        }
        case 4 :
        {
            if(cs_get_user_money(id) >= 4500)
            {
                cs_set_user_money(id, money - 4500)
                set_user_health(id, get_user_health(id) + 50)
                clien_print(id, print_chat, "
You get 50HP !"
            }
        }
        case 5 :
        {
            if(cs_get_user_money(id) >= 9000)
            {
                cs_set_user_money(id, money - 9000)
                set_user_health(id, get_user_health(id) + 100)
                clien_print(id, print_chat, "
You get 100HP !"
        }
        case 6 : 
        {
            if(cs_get_user_money(id) >= 2500)
            {
                cs_set_user_money(id, money - 2500)
                set_user_armor(id, get_user_armor(id) + 100)
                clien_print(id, print_chat, "
You get 100AM !"
            }
        }
    }
    return PLUGIN_HANDLER

EROR

/tmp/text4yRyJj.sma(13) : error 017: undefined symbol "register_clmd" /tmp/text4yRyJj.sma(1 : error 001: expected token: ";", but found "-identifier-" /tmp/text4yRyJj.sma(1 : error 017: undefined symbol "creat" /tmp/text4yRyJj.sma(36) : warning 217: loose indentation /tmp/text4yRyJj.sma(36) : error 017: undefined symbol "PLUGIN_HANDLER" /tmp/text4yRyJj.sma(42) : error 021: symbol already defined: "menu_item_getinfo" /tmp/text4yRyJj.sma(45) : error 010: invalid function or declaration /tmp/text4yRyJj.sma(47) : error 010: invalid function or declaration /tmp/text4yRyJj.sma(49) : error 010: invalid function or declaration /tmp/text4yRyJj.sma(54) : error 010: invalid function or declaration /tmp/text4yRyJj.sma(56) : error 054: unmatched closing brace /tmp/text4yRyJj.sma(57) : error 010: invalid function or declaration /tmp/text4yRyJj.sma(59) : error 010: invalid function or declaration /tmp/text4yRyJj.sma(63) : error 021: symbol already defined: "give_iteam" /tmp/text4yRyJj.sma(63) : error 010: invalid function or declaration /tmp/text4yRyJj.sma(65) : error 021: symbol already defined: "clien_print" /tmp/text4yRyJj.sma(66) : error 054: unmatched closing brace /tmp/text4yRyJj.sma(67) : error 010: invalid function or declaration /tmp/text4yRyJj.sma(69) : error 010: invalid function or declaration /tmp/text4yRyJj.sma(73) : error 021: symbol already defined: "give_iteam" /tmp/text4yRyJj.sma(74) : error 010: invalid function or declaration /tmp/text4yRyJj.sma(76) : error 001: expected token: ")", but found "}" /tmp/text4yRyJj.sma(76) : error 021: symbol already defined: "clien_print" /tmp/text4yRyJj.sma(77) : error 054: unmatched closing brace /tmp/text4yRyJj.sma(7 : error 010: invalid function or declaration /tmp/text4yRyJj.sma(80) : error 010: invalid function or declaration /tmp/text4yRyJj.sma(85) : error 021: symbol already defined: "clien_print
__________________
Creator Menu = (50%)
Skin moddel = (100%)
Animation moddel = (25%)
_________________________

Sorry if me english is incorect

Last edited by azzou; 12-27-2014 at 14:03.
azzou is offline
 



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


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


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