]> git.xonotic.org Git - xonotic/darkplaces.git/blobdiff - host.c
Start video _during_ initialization, rather than when finding a model
[xonotic/darkplaces.git] / host.c
diff --git a/host.c b/host.c
index 03375f69a6b39fcdbf0f6a215f5b64f1b84e22ca..313745a977e9d72b45d93f01a71bebf3e449362e 100644 (file)
--- a/host.c
+++ b/host.c
@@ -1162,6 +1162,8 @@ void Host_UnlockSession(void)
        }
 }
 
+extern hook_t *csqc_concmd;
+
 /*
 ====================
 Host_Init
@@ -1229,6 +1231,8 @@ static void Host_Init (void)
        // initialize memory subsystem cvars/commands
        Memory_Init_Commands();
 
+       Hook_Init();
+       csqc_concmd = Hook_Register(csqc_concmd,CL_VM_ConsoleCommand,1);
        // initialize console and logging and its cvars/commands
        Con_Init();
 
@@ -1332,6 +1336,9 @@ static void Host_Init (void)
 
        Log_Start();
        
+       // Starting after we parse commands so the screen resolution doesn't get weird for the first few seconds
+       Host_StartVideo();
+       
        // put up the loading image so the user doesn't stare at a black screen...
        SCR_BeginLoadingPlaque(true);