EVENT CHANGEMENU
EVENT_CHANGEWEAPON is a game event.
This event functions similarly to the cmenu command--in fact, it happens while that command is being processed. It is primarily useful in specfic circumstances where you want to skip a menu/screen value, but the design of the source code would cause the screen to be displayed before you could use cmenu in EVENT_DISPLAYMENU, causing the unwanted screen to flash for a split second.
The following example cuts out two of the three Duke 3D v1.5 credits screens. After the first one, the panel order will go directly to the EDuke32 port credits.
onevent EVENT_CHANGEMENU ifvare RETURN 991 // going forwards setvar RETURN 993 ifvare RETURN 992 // going backwards setvar RETURN 990 endevent
Do not use the cmenu command within this event, as it causes unnecessary recursion and probably won't do what you want.
Remember that working around, hiding, or skipping the EDuke32 port credits (current_menu values 993 and 994) is a violation of the EDuke32 license.