Quote:
Originally Posted by OciXCrom
If you're using the new menu system, you can't detect the back/next menu keys. For the other ones - you provided no code and we can only guess what you have done.
|
This is how the menu looks like

, it's just a aprt of the script.
Code:
public mh_PMenu(id, menu, item)
{
if(item == MENU_EXIT)
{
menu_cancel(id);
return PLUGIN_HANDLED;
}
new command[6], name[64], access, callback;
new line[3];
menu_item_getinfo(menu, item, access, command, sizeof command - 1, name, sizeof name - 1, callback);
switch(item)
{
case 0:
{
new menu_model = menu_create("Models Menu", "mh_MMenu")
for (new i; (i < file_size(conffile_model, 1)); i++)
{
new buffer;
read_file(conffile_model, i, file_model, 127, buffer)
//format(file_model,127,"%s^" ^"%d^"",local_models,local_skins)
parse(file_model,g_models, 127, g_skins, 127)
format(line,2,"%i",i)
menu_additem(menu_model, g_models, line);
}
menu_setprop(menu_model, MPROP_EXIT, MEXIT_ALL);
menu_setprop(menu_model, MPROP_BACKNAME, "Back");
menu_setprop(menu_model, MPROP_NEXTNAME, "Next");
menu_setprop(menu_model, MPROP_EXITNAME, "Close");
menu_destroy(menu);
menu_display(id, menu_model, 0);
}
case 1:
{
if (g_thirdperson==0)
{
client_print(id, print_chat, "You have selected Thirdperson View");
g_thirdperson=1;
set_view(id, CAMERA_3RDPERSON);
return PLUGIN_CONTINUE;
}
else
{
client_print(id, print_chat, "You have selected Firstperson View");
g_thirdperson=0;
set_view(id, CAMERA_NONE);
return PLUGIN_CONTINUE;
}
}
}
return PLUGIN_HANDLED;
}