My notes:
1) This is menus.inc and adminmenu.inc are included by sourcemod.inc
sourcemod.inc are included by compiler by default
2) Don't mix syntax
Code:
public OnPluginStart() // Old syntax
public void OnPluginStart()
3) Menus have exitbutton true by default
Code:
menu.ExitButton = true;
4) Remove it?
Code:
case MenuAction_Start:{}
5) Just use menu.SetTitle(), but for that you need to update it? You can just set it on creation like you did.
Code:
case MenuAction_Display:
{
Panel panel = view_as<Panel>(param2);
panel.SetTitle("Reviver Jogador");
}
6) This will cause error (invalid handle) when menu canceled.
Close menu only in End action.
PHP Code:
case MenuAction_Cancel:
{
delete menu;
}
case MenuAction_End:
{
delete menu;
}
7) you can pass NULL_STRING and 0 for info buffer. (Again, why you use this callback action and why 'MENU_ACTIONS_ALL', may be just remove?)
PHP Code:
case MenuAction_DrawItem:
{
int style;
menu.GetItem(param2, NULL_STRING, 0, style);
return style;
}