using Assets.Framework.Tool;
using System;
using UnityEngine;
namespace Assets.MyGame.Scripts.Net.API.GameConfig_SubClass
{
///
/// 道具碎片信息
///
[Serializable]
public class PropFragmentConfig : BasePropInfo
{
public Sprite sprite_Icon;
public void GetSprite(Action callback)
{
if (sprite_Icon == null)
{
WebTool.DownImage(APIManager.baseURL + imageUrl, (a) => { sprite_Icon = Sprite.Create(a, new Rect(0, 0, a.width, a.height), Vector2.one * 0.5f); callback?.Invoke(sprite_Icon); });
}
else
{
callback?.Invoke(sprite_Icon);
}
}
///
/// 合成所需碎片数量
///
public int fragmentCount;
///
/// 合成后的道具编号
///
public string productNumber;
}
}