using BITFALL; using System.Collections; using System.Collections.Generic; using UnityEngine; namespace BITKit { public static class ItemExtensions { public static ScriptableItem GetAssetable(this IBasicItem self) { var task = YooAsset.YooAssets.LoadAssetAsync(self.AddressablePath); task.WaitForAsyncComplete(); return task.AssetObject.As(); //return Addressables.LoadAssetAsync(self.AddressablePath).WaitForCompletion(); } public static ScriptableItem GetAssetable(string address) { var task = YooAsset.YooAssets.LoadAssetAsync(address); task.WaitForAsyncComplete(); return task.AssetObject.As(); } } }