Exemplo n.º 1
0
    static public void LoadIconCallBack(AssetBundle AssetData, ParamData paramData)
    {
        if (null == paramData || null == AssetData || null == AssetData.mainAsset)
        {
            IconAssetMgr.DeleteAsset(AssetData, true);
            return;
        }

        Texture2D Tex2D = AssetData.mainAsset as Texture2D;

        if (null == Tex2D)
        {
            IconAssetMgr.DeleteAsset(AssetData, true);
            return;
        }

        HeadIconLoaderItem Item = HeadIconLoader.Instance.GetLoaderItem(paramData.szAssetName);

        if (null == Item)
        {
            IconAssetMgr.DeleteAsset(AssetData, true);
            return;
        }

        Item.m_AssetData = AssetData;
        Item.m_Tex       = Tex2D;
        Item.m_Tex.name  = paramData.szAssetName;
        Item.FlushAll();
        IconAssetMgr.DeleteAsset(AssetData, false);
    }
Exemplo n.º 2
0
 public void Delete()
 {
     IconAssetMgr.DeleteAsset(m_AssetData, true);
 }