================= CL_FlushMemory Called by CL_MapLoading, CL_Connect_f, and CL_ParseGamestate the only ways a client gets into a game Also called by Com_Error ================= */
| 140 | ================= |
| 141 | */ |
| 142 | void CL_FlushMemory( void ) { |
| 143 | |
| 144 | // clear sounds (moved higher up within this func to avoid the odd sound stutter) |
| 145 | S_DisableSounds(); |
| 146 | |
| 147 | // unload the old VM |
| 148 | CL_ShutdownCGame(); |
| 149 | |
| 150 | CL_ShutdownUI(); |
| 151 | |
| 152 | if ( re.Shutdown ) { |
| 153 | re.Shutdown( qfalse, qfalse ); // don't destroy window or context |
| 154 | } |
| 155 | |
| 156 | //rwwFIXMEFIXME: The game server appears to continue running, so clearing common bsp data causes crashing and other bad things |
| 157 | /* |
| 158 | CM_ClearMap(); |
| 159 | */ |
| 160 | |
| 161 | cls.soundRegistered = qfalse; |
| 162 | cls.rendererStarted = qfalse; |
| 163 | } |
| 164 | |
| 165 | /* |
| 166 | ===================== |
no test coverage detected