try this if u want that everyone can use this command...
Code:
#include <amxmodx>
#include <amxmisc>
#include <amxconst>
#include <cstrike>
public plugin_init() {
register_plugin("Maplist","1.0","Kamikizzle")
register_clcmd("kami_maplist","ClCmd_kami_maplist",0,"- Displays all of maps on the server (MOTD)")
}
public ClCmd_kami_maplist(id,lvl,cid) {
show_motd(id,"addons/amxmodx/configs/maps.htm","Maps On Server")
return PLUGIN_HANDLED
}
if u want to make it with your rights ...
Code:
#include <amxmodx>
#include <amxmisc>
#include <amxconst>
#include <cstrike>
public plugin_init()
{
register_plugin("Maplist","1.0","Kamikizzle")
register_clcmd("kami_maplist","ClCmd_kami_maplist",ADMIN_MAP,"- Displays all of maps on the server (MOTD)")
}
public ClCmd_kami_maplist(id,lvl,cid)
{
if( !cmd_access(id,lvl,cid,1) )
{
return PLUGIN_HANDLED
}
else{
show_motd(id,"addons/amxmodx/configs/maps.htm" ,"Maps On Server")
return PLUGIN_HANDLED
}
}