Raised This Month: $ Target: $400
 0% 

Is this would work ?


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
DoviuX
Senior Member
Join Date: Jun 2009
Location: Lithuania
Old 10-10-2009 , 15:09   Is this would work ?
Reply With Quote #1

PHP Code:
#include <amxmodx>
#include <amxmisc>
#define PLUGIN "Server Info"
#define AUTHOR "DoviuX"
#define VERSION "0.1"
/*================================================================================
 [New Const's]
=================================================================================*/
new const gMotdInfo[] = { "ServerInfo/Motd.wav" }
/*================================================================================
 [Precache]
=================================================================================*/
public plugin_precache() 
{
  
precache_sound(gMotdInfo);
}
/*================================================================================
 [Plugin start]
=================================================================================*/
public plugin_init()
{
        
register_pluginPLUGINVERSIONAUTHOR );
 
register_clcmd("say /ServerInfo""Info")
 
register_clcmd("say_team /ServerInfo""Info")
}
public 
Info(id)
{
 new 
menu menu_create("\yServer Info Menu""menu_handler")
 
 
menu_additem(menu"Admin Prices""1"0)
 
menu_additem(menu"Mod Info""2"0)
 
menu_additem(menu"Info About Server""3"0)
 
 
menu_setprop(menuMPROP_EXITMEXIT_ALL)
 
menu_display(idmenu0)
}
public 
menu_handler(idmenuitem)
{
 if (
item == MENU_EXIT)
 {
  
menu_destroy(menu)
  return 
PLUGIN_HANDLED
 
}
 
 new 
data[6], iName[64]
 new 
accesscallback
 menu_item_getinfo
(menuitemaccessdata5iName63callback)
 
 new 
key str_to_num(data)
 
 switch(
key)
 {
  case 
1
  {
   {
      
show_motd(id"AdminPrices.txt""Prices")
             
client_cmd(0,"spk %s"gMotdInfo)
      return 
PLUGIN_CONTINUE
   

  }
  case 
2
  {
   {
      
show_motd(id"ModInfo.txt""Mod")
             
client_cmd(0,"spk %s"gMotdInfo)
      return 
PLUGIN_CONTINUE
   
}
  }
  case 
3
  {
   {
      
show_motd(id"ServerInfo.txt""Info")
             
client_cmd(0,"spk %s"gMotdInfo)
      return 
PLUGIN_CONTINUE
   
}
  }
 }
 
menu_destroy(menu)
 return 
PLUGIN_HANDLED;

DoviuX is offline
Send a message via Skype™ to DoviuX
 



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 22:41.


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