From f31e5e0d22a8d826d88f001a4ed1a5906522b735 Mon Sep 17 00:00:00 2001 From: hevinci Date: Sat, 26 Nov 2022 17:39:35 +0800 Subject: [PATCH] update runtime code --- Assets/YooAsset/Runtime/YooAssets.cs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/Assets/YooAsset/Runtime/YooAssets.cs b/Assets/YooAsset/Runtime/YooAssets.cs index aefac70..b6ad3d0 100644 --- a/Assets/YooAsset/Runtime/YooAssets.cs +++ b/Assets/YooAsset/Runtime/YooAssets.cs @@ -27,6 +27,7 @@ namespace YooAsset _driver = new UnityEngine.GameObject($"[{nameof(YooAssets)}]"); _driver.AddComponent(); UnityEngine.Object.DontDestroyOnLoad(_driver); + YooLogger.Log($"{nameof(YooAssets)} initialize !"); #if DEBUG // 添加远程调试脚本 @@ -55,11 +56,10 @@ namespace YooAsset } _packages.Clear(); - if(_driver != null) - GameObject.Destroy(_driver); - _isInitialize = false; - YooLogger.Log("YooAssets destroy all !"); + if (_driver != null) + GameObject.Destroy(_driver); + YooLogger.Log($"{nameof(YooAssets)} destroy all !"); } }