There's a few things you can do to speed things up. Instead of going through a whole bunch of "if" statements comparing #MENUBUTTON, suppose you name your functions that run each button as the value that comes back as #MENUBUTTON, then your handler becomes very easy:
if #MENUBUTTON <> N/A
{
set %function #MENUBUTTON
set #MENUBUTTON N/A
gosub %function
}
Does that make sense? This will make things pretty snappy, especially if you kick your #LPC up to 100. Don't go too high, because that effects the speed of surrounding scripts.