您当前的位置: 首页 >  c#

苍狼王unity学院

暂无认证

  • 0浏览

    0关注

    305博文

    0收益

  • 0浏览

    0点赞

    0打赏

    0留言

私信
关注
热门博文

自己的C#框架之第四篇____补充之图片的加载

苍狼王unity学院 发布时间:2019-03-19 14:12:34 ,浏览量:0

public void LoadTexture2Sprite(string path) { Texture2D aa = (Texture2D)Resources.Load(“Texture/图片2019.3.7/”+ path) as Texture2D; Sprite kk = Sprite.Create(aa,new Rect (0,0,aa.width,aa.height),new Vector2 (0.5f,0.5f)); UIManager.Instance.GetGameObject(“EmpleeyPicture”).GetComponent().sprite = kk; Debug.Log("aa "+aa.name); }

关注
打赏
1665389160
查看更多评论
立即登录/注册

微信扫码登录

0.0377s