Code:
#include <amxmodx>
#include <amxmisc>
#define PLUGIN "Cz Bot Voter"
#define VERSION "1.0"
#define AUTHOR "Broertje"
new const g_BotsOn[45] = "bot_add"
new const g_BotsOff[45] = "bot_kick"
public plugin_init() {
register_plugin(PLUGIN, VERSION, AUTHOR)
register_clcmd("say /votebots", "sayBots", 0, "- Show Menu To Activate Bots ...")
register_menucmd(register_menuid("menu_ChooseType"),1023,"ChooseType");
}
public sayBots(id)
{
new menu[192]
new keys = (1<<0)|(1<<1)
format(menu, 191, "^n1. Vote: Kick All Bots^n2. Vote: Join Bots")
show_menu(id, keys, menu, -1, "giveStuff")
return PLUGIN_HANDLED
}
public giveStuff(id, key)
{
if (key==0)
{
server_cmd(g_BotsOff)
}
if (key==1) {
server_cmd(g_BotsOn)
server_cmd(g_BotsOn)
server_cmd(g_BotsOn)
server_cmd(g_BotsOn)
server_cmd(g_BotsOn)
server_cmd(g_BotsOn)
}
}
I Want If You Press In The Menu On One Of The Options A Vote Will Start And If They Voted No Nothing Happens(Duh) And if They Vote Yes The Bots Will Be Added Or Kicked,I Cant Get This To Work,Someone Request This...