=============== UI_MainMenu The main menu only comes up when not in a game, so make sure that the attract loop server is down and that local cinematics are killed =============== */
| 4163 | =============== |
| 4164 | */ |
| 4165 | void UI_MainMenu(void) |
| 4166 | { |
| 4167 | char buf[256]; |
| 4168 | ui.Cvar_Set("sv_killserver", "1"); // let the demo server know it should shut down |
| 4169 | |
| 4170 | ui.Key_SetCatcher( KEYCATCH_UI ); |
| 4171 | |
| 4172 | menuDef_t *m = Menus_ActivateByName("mainMenu"); |
| 4173 | if (!m) |
| 4174 | { //wha? try again |
| 4175 | UI_LoadMenus("ui/menus.txt",qfalse); |
| 4176 | } |
| 4177 | ui.Cvar_VariableStringBuffer("com_errorMessage", buf, sizeof(buf)); |
| 4178 | if (strlen(buf)) { |
| 4179 | Menus_ActivateByName("error_popmenu"); |
| 4180 | } |
| 4181 | } |
| 4182 | |
| 4183 | |
| 4184 | /* |
no test coverage detected