diff --git a/Forest/Assets/Scenes/Build/Build_2.unity b/Forest/Assets/Scenes/Build/Build_2.unity index 5a60d1f..e8de356 100644 --- a/Forest/Assets/Scenes/Build/Build_2.unity +++ b/Forest/Assets/Scenes/Build/Build_2.unity @@ -1316,7 +1316,7 @@ Transform: m_GameObject: {fileID: 274027926} serializedVersion: 2 m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} - m_LocalPosition: {x: -0.068, y: 0.116, z: 0} + m_LocalPosition: {x: -0.068, y: 0.075, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: @@ -6365,7 +6365,7 @@ Transform: m_GameObject: {fileID: 1505741850} serializedVersion: 2 m_LocalRotation: {x: 0, y: 0, z: 0, w: 1} - m_LocalPosition: {x: 0, y: 0, z: 0} + m_LocalPosition: {x: 0, y: -0.021, z: 0} m_LocalScale: {x: 1, y: 1, z: 1} m_ConstrainProportionsScale: 0 m_Children: diff --git a/Forest/Assets/Scripts/Gameplay2/BuildManager.cs b/Forest/Assets/Scripts/Gameplay2/BuildManager.cs index dfa8976..0d66fd2 100644 --- a/Forest/Assets/Scripts/Gameplay2/BuildManager.cs +++ b/Forest/Assets/Scripts/Gameplay2/BuildManager.cs @@ -269,7 +269,7 @@ namespace Framework.Manager } var buildData = await JsonHelper.LoadFromAddressable(buildConfig.BuildData); - + await Init(buildData, true); await Addressables.LoadSceneAsync(buildConfig.Path).ToUniTask(); _userBuildInfo.CurBuildId = buildConfigId; @@ -502,12 +502,12 @@ namespace Framework.Manager { try { - var bluePath = string.Format(Constants.PathConstants.BuildBlueprint, _curBuildData.buildID); + var bluePath = string.Format(PathConstants.BuildBlueprint, _curBuildData.buildID); + AssetManager.Instance.Unload(bluePath); CurBlueprint = await AssetManager.Instance.LoadAssetAsync(bluePath); var buildUIPath = string.Format(PathConstants.BuildTopUIPath, _curBuildData.buildID); + AssetManager.Instance.Unload(buildUIPath); CurTopBuildUI = await AssetManager.Instance.LoadAssetAsync(buildUIPath); - _loadAssets.Add(bluePath); - _loadAssets.Add(buildUIPath); } catch (Exception e) { @@ -664,10 +664,8 @@ namespace Framework.Manager AssetManager.Instance.Unload(icon.Key); } - foreach (var ass in _loadAssets) - { - AssetManager.Instance.Unload(ass); - } + CurBlueprint = null; + CurTopBuildUI = null; } } } \ No newline at end of file