1234567891011121314151617181920212223 |
- #if UNITY_EDITOR
- namespace XGame.Framework.Asset.Addressable
- {
- interface IAddressableEditorHandler
- {
- string GetAssetGUID(string addressableName);
- }
- internal partial class CSharpAddressableManifest : IAddressableEditorHandler
- {
- public string GetAssetGUID(string addressableName)
- {
- if (_nameToIdMap.TryGetValue(addressableName, out var addressableId) &&
- _assetInfoMap.TryGetValue(addressableId, out var assetInfo))
- {
- return assetInfo.assetGUID;
- }
- return string.Empty;
- }
- }
- }
- #endif
|