]> de.git.xonotic.org Git - xonotic/netradiant.git/commitdiff
refresh vfs before parsing map
authorThomas Debesse <dev@illwieckz.net>
Sat, 14 Jul 2018 17:19:56 +0000 (19:19 +0200)
committerThomas Debesse <dev@illwieckz.net>
Wed, 3 Oct 2018 00:00:16 +0000 (02:00 +0200)
radiant/map.cpp

index d83f42cdbc512d0385680934214122b5a97d393f..978d83daaeb2355c32efc7098cc28c55f2d74809 100644 (file)
@@ -1001,6 +1001,12 @@ CopiedString g_strLastMapFolder = "";
 
 void Map_LoadFile(const char *filename)
 {
+    g_map.m_name = filename;
+
+    // refresh VFS to apply new pak filtering based on mapname
+    // needed for daemon DPK VFS
+    VFS_Refresh();
+
     globalOutputStream() << "Loading map from " << filename << "\n";
     ScopeDisableScreenUpdates disableScreenUpdates("Processing...", "Loading Map");
 
@@ -1021,8 +1027,8 @@ void Map_LoadFile(const char *filename)
                 Map_Free();
             }
             Brush_toggleFormat(i);
-            g_map.m_name = filename;
             Map_UpdateTitle(g_map);
+
             g_map.m_resource = GlobalReferenceCache().capture(g_map.m_name.c_str());
             if (format) {
                 format->wrongFormat = false;
@@ -1052,10 +1058,6 @@ void Map_LoadFile(const char *filename)
     Map_StartPosition();
 
     g_currentMap = &g_map;
-
-    // refresh VFS to apply new pak filtering based on mapname
-    // needed for daemon DPK VFS
-    VFS_Refresh();
 }
 
 class Excluder {