Raised This Month: $ Target: $400
 0% 

What I do wrong?


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
JahMan
New Member
Join Date: Jun 2008
Old 09-07-2008 , 13:13   What I do wrong?
Reply With Quote #1

PHP Code:
/* Plugin generated by AMXX-Studio */

#include <amxmodx>
#include <amxmisc>

#define PLUGIN "Nowy Plugin"
#define VERSION "1.0"
#define AUTHOR "JahMan"

 
new const sounds[][] = {  
"sound/misc/OE/oe_01.mp3",  
"sound/misc/OE/oe_02.mp3",  
"sound/misc/OE/oe_03.mp3",  
"sound/misc/OE/oe_04.mp3",  
"sound/misc/OE/oe_05.mp3",  
"sound/misc/OE/oe_06.mp3",  
"sound/misc/OE/oe_07.mp3",  
"sound/misc/OE/oe_08.mp3",  
"sound/misc/OE/oe_09.mp3",  
"sound/misc/OE/oe_10.mp3",  
"sound/misc/OE/oe_11.mp3",  
"sound/misc/OE/oe_12.mp3",  
"sound/misc/OE/oe_13.mp3",  
"sound/misc/OE/oe_14.mp3",  
"sound/misc/OE/oe_15.mp3",  
"sound/misc/OE/oe_16.mp3",  
"sound/misc/OE/oe_17.mp3",  
"sound/misc/OE/oe_18.mp3",  
"sound/misc/OE/oe_19.mp3",  
"sound/misc/OE/oe_20.mp3"}  

public 
plugin_init() {
    
register_plugin(PLUGINVERSIONAUTHOR)
    
register_clcmd("amx_menu""menu")
    
}

public 
menu(id)
{
    new 
menu menu_create("rMenu muzyki!:""wybieranie")
    
    
menu_additem(menu"\wops""3"ADMIN_KICK
    
menu_additem(menu"\wops""3"ADMIN_KICK)
    
menu_additem(menu"\wops""3"ADMIN_KICK)  
    
    
menu_setprop(menuMPROP_EXITMEXIT_ALL)
    
    
menu_display(idmenu0)

}

public 
wybieranie(idmenuitem)
{
    if (
item == MENU_EXIT)
    {
        
menu_destroy(menu)
        return 
PLUGIN_HANDLED
    
}
    new 
data[6], iName[64]
    new 
accescallback
    menu_item_getinfo
(menuitemaccesdata,5iName63callback)
    
    new 
key str_to_num(data)
    
    switch(
key)
    {
        case 
1:
           
client_cmd(0"mp3 play sound/misc/OE/oe_13.mp3")
            return 
PLUGIN_CONTINUE
        
}
        
        case 
2:
            
client_cmd(0"mp3 play sound/misc/OE/oe_13.mp3")
            return 
PLUGIN_CONTINUE
        
}
        
        case 
3:
           
client_cmd(0"mp3 play sound/misc/OE/oe_13.mp3"
             return 
PLUGIN_CONTINUE
        
}
    }
 public 
plugin_precache()
{
    new 
i
    
for(0sizeof soundsi++)
    
precache_generic(sounds[i])
}  
     return 
PLUGIN_CONTINUE


What I do wrong ? In PAWN studio I have this erors:

Code:
/home/groups/amxmodx/tmp3/texthgvcun.sma(69) : error 002: only a single statement (or expression) can follow each "case" /home/groups/amxmodx/tmp3/texthgvcun.sma(69 -- 70) : warning 215: expression has no effect /home/groups/amxmodx/tmp3/texthgvcun.sma(70) : warning 209: function "wybieranie" should return a value /home/groups/amxmodx/tmp3/texthgvcun.sma(72) : error 010: invalid function or declaration /home/groups/amxmodx/tmp3/texthgvcun.sma(74) : error 010: invalid function or declaration /home/groups/amxmodx/tmp3/texthgvcun.sma(77) : error 010: invalid function or declaration /home/groups/amxmodx/tmp3/texthgvcun.sma(79) : error 010: invalid function or declaration /home/groups/amxmodx/tmp3/texthgvcun.sma(88) : error 010: invalid function or declaration
JahMan 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 03:12.


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