]> git.rm.cloudns.org Git - xonotic/darkplaces.git/commitdiff
better detection of model load failures in viewmodel command
authorhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Sun, 19 Jun 2005 17:47:30 +0000 (17:47 +0000)
committerhavoc <havoc@d7cf8633-e32d-0410-b094-e92efae38249>
Sun, 19 Jun 2005 17:47:30 +0000 (17:47 +0000)
git-svn-id: svn://svn.icculus.org/twilight/trunk/darkplaces@5450 d7cf8633-e32d-0410-b094-e92efae38249

host_cmd.c

index 59eaee050b52538e971683b43fb1c0394e16a32f..79665d2e3193205899450516071c7fcfa364229f 100644 (file)
@@ -1681,9 +1681,9 @@ void Host_Viewmodel_f (void)
                return;
 
        m = Mod_ForName (Cmd_Argv(1), false, true, false);
-       if (!m)
+       if (!m || !m->loaded || !m->Draw)
        {
-               Con_Printf("Can't load %s\n", Cmd_Argv(1));
+               Con_Printf("viewmodel: can't load %s\n", Cmd_Argv(1));
                return;
        }