VGUI:Custom Title Screen FAQ
NOTE: you must create a basic MOD folder from the "Create A Mod" option, on the green Source SDK box before you begin planning your MOD/Game, you need to do this, in order to get hold a files you WILL have to edit, in order for your MOD to be usable.
Just thought I'd safe some poor first-timers the trouble I've had, trying to set up my first MOD.
This page hopes to resolve some frequently asked questions regarding customization of the title screen.
The title screen/main menu isn't defined in the Source SDK. It's defined in GameUI.dll. Modders are unable to edit this file, so customizing the main menu requires a few hacks.
Set its parent as the GAMEUI base panel.
vgui::VPANEL GameUIRoot = enginevgui->GetPanel( PANEL_GAMEUIDLL ); SetParent( GameUIRoot );
This requires some hacking. First of all you need to make your panel a popup. In your panel's constructor do:
It'll now act like a window/frame. You will be able to interact with it but when you open a new window, like the console, you will be able to push it behind this panel.
The best way I've found to prevent this is to always force it to the back by putting this in your panels Think function
vgui::surface()->MovePopupToBack( GetVPanel() );