From 3593274eeb59e08c84ae1d317646e9fb39484d84 Mon Sep 17 00:00:00 2001 From: Bill Currie Date: Mon, 4 Oct 2010 19:44:37 +0900 Subject: [PATCH] Fix wad loading when loading the map. This broke with the fix for the entity inspector. --- tools/Forge/Bundles/MapEdit/Map.m | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/tools/Forge/Bundles/MapEdit/Map.m b/tools/Forge/Bundles/MapEdit/Map.m index 0d06cfd9e..cd6728fec 100644 --- a/tools/Forge/Bundles/MapEdit/Map.m +++ b/tools/Forge/Bundles/MapEdit/Map.m @@ -264,17 +264,18 @@ readMapFile [self addSelected]; + ent = [self objectAtIndex: 0]; // load the apropriate texture wad - wad = [currentEntity valueForQKey: "wad"]; + wad = [ent valueForQKey: "wad"]; if (wad && wad[0]) { // remove old style fullpaths if (wad[0] == '/') - [currentEntity removeKeyPair: "wad"]; + [ent removeKeyPair: "wad"]; else if (strcmp ([texturepalette_i currentWad], wad)) [project_i setTextureWad: wad]; } - [self setCurrentEntity: [self objectAtIndex: 0]]; + [self setCurrentEntity: ent]; // center the camera and XY view on the playerstart c = [self count];