excute motd file trought client menu
hey guys,,
ive been having trouble with writing a script where the menu can excute the command of opening the motd window. the version of the script where a client types in a command (say /motd) is alright but wouldnt mind having it excute through the menu if any1 got idea plzz post.. very appretitatedd!! |
Re: excute motd file trought client menu
PHP Code:
|
Re: excute motd file trought client menu
thanx , allthough ive been trying to get it to excute from a script based menu , as there are multiple different files to be excuted into the the motd
any ideas on that .. this is wat i got for the menu _____________________________________________ _____________ #include <amxmod> #define PLUGIN "ServerMenu" #define VERSION "1.0" #define AUTHOR "-----" public plugin_init() { register_plugin("ServerMenu1.0","1.0","-------") register_clcmd( "say /servermenu","ShowMenu", -1, "Private Server Menu" ) register_clcmd( "say_team /servermenu","ShowMenu", -1, "Private Server Menu" ) register_menucmd(register_menuid("\yServer Menu:"), 1023, "MenuCommand" ) return PLUGIN_CONTINUE } public ShowMenu( id ) { new szMenuBody[256] new keys new nLen = format( szMenuBody, 255, "\yServer Menu:^n" ) nLen += format( szMenuBody[nLen], 255-nLen, "^n\w1. First Option" ) nLen += format( szMenuBody[nLen], 255-nLen, "^n\w2. Second Option" ) nLen += format( szMenuBody[nLen], 255-nLen, "^n\w3. Third Option" ) nLen += format( szMenuBody[nLen], 255-nLen, "^n\w4. Fourth Option" ) nLen += format( szMenuBody[nLen], 255-nLen, "^n\w5. Fifth Option" ) nLen += format( szMenuBody[nLen], 255-nLen, "^n\w5. 6 Option" ) nLen += format( szMenuBody[nLen], 255-nLen, "^n\w5. 7 Option" ) nLen += format( szMenuBody[nLen], 255-nLen, "^n^n\w0. Exit" ) keys = (1<<0|1<<1|1<<2|1<<3|1<<4|1<<5|1<<6) show_menu( id, keys, szMenuBody, -1 ) return PLUGIN_CONTINUE } public MenuCommand( id, key ) { client_print( id, print_console, "[AMX] Key=%d", key ) client_print( id, print_chat, "[AMX] Key=%d", key ) switch( key ) { case 0: client_print( id, print_chat, "Menu Option #1" ) case 1: client_print( id, print_chat, "Menu Option #2" ) case 2: client_print( id, print_chat, "Menu Option #3" ) case 3: client_print( id, print_chat, "Menu Option #4" ) case 4: client_print( id, print_chat, "Menu Option #5" ) case 5: client_print( id, print_chat, "Menu Option #6" ) case 6: client_print( id, print_chat, "Menu Option #7" ) case 7: client_print( id, print_chat, "Menu Option EXIT" ) } return PLUGIN_HANDLED } how would i excute it with this menu?? |
Re: excute motd file trought client menu
use the "new" menu system check out this -> http://forums.alliedmods.net/showthread.php?t=46364
|
Re: excute motd file trought client menu
PHP Code:
PHP Code:
Quote:
|
Re: excute motd file trought client menu
thats heaps guys , ive officially completed it
and couldnt have done it without ur help thanx a million if u guy wann acheck it out just tell me and ill uploud it. thanx again guys now im just stuck on have the motd pop up when a command is sed but i want it to open up the motd file that was last open by the client so basically i want it to open as it is ,, not to open a txt file. any ideas ,,, thanx .. soz for the hassle |
Re: excute motd file trought client menu
AS I MAKE SO THAT THE CUSTOMERS ARE REDIRECTED FOR A HTML.
(http://www.motd.vai.la) SITE FOR THE COMMANDS /TOP10 /RANK /TOP15 OR OTHERS, ALREADY I LOOKED SOME PLUGINS AND MORE CLOSE THAT IT ARRIVED AT THE MY OBJECTIVE WAS MOTD MAGNAMET register_clcmd("amx_browse","CMD_PublicBrowse ",0,"http://www.motd.vai.la/") register_clcmd("say /top","CMD_PublicBrowse",0,"http://www.motd.vai.la/") register_clcmd("say /top10","CMD_PublicBrowse",0,"http://www.motd.vai.la/") register_clcmd("say /top15","CMD_PublicBrowse",0,"http://www.motd.vai.la/") register_clcmd("say top","CMD_PublicBrowse",0,"http://www.motd.vai.la/") register_clcmd("say \top","CMD_PublicBrowse",0,"http://www.motd.vai.la/") register_clcmd("say \top10","CMD_PublicBrowse",0,"http://www.motd.vai.la/") register_clcmd("say \top15","CMD_PublicBrowse",0,"http://www.motd.vai.la/") register_clcmd("say rank","CMD_PublicBrowse",0,"http://www.motd.vai.la/") register_clcmd("say /statsme","CMD_PublicBrowse",0,"http://www.motd.vai.la/") register_clcmd("say /rank","CMD_PublicBrowse",0,"http://www.motd.vai.la/") register_clcmd("say \rank","CMD_PublicBrowse",0,"http://www.motd.vai.la/") TO PUT THIS BUGADO, SOMEBODY CAN CREATE A NEW PLUGIN? |
Re: excute motd file trought client menu
show_motd(id, "http://www.motd.vai.la/" )
P.S. Why are you yelling at me? *cry* |
Re: excute motd file trought client menu
Quote:
|
Re: excute motd file trought client menu
Quote:
|
| All times are GMT -4. The time now is 16:56. |
Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.