public class L5 : MonoBehaviour
{public UITexture tex;// Start is called before the first frame updatevoid Start(){//Sprite只能显示图集中图片,一般用于显示中小图片//如果使用大尺寸图片就没有必要制作图集//一般使用Texture控件进行大图片显示//代码设置//加载图片Texture texture = Resources.Load<Texture>("");//设置图片tex.mainTexture = texture;}
}