关于unity3d 4.6 image 修改图片的问题,image.GetComponent<Image>() 
没有.sourceImage的属性呢?如果是图集的话要等于什么呢?

image.GetComponent<Image>() .XXXX=????

这样做对么?

  1. public Image dd;
  2. // Use this for initialization
  3. void Start()
  4. {
  5. dd.overrideSprite = Resources.Load("GUI/Textures/bg-2D水位-水位提示-蓝色提醒", typeof(Sprite)) as Sprite;
  6. InvokeRepeating("check",0,0.3f);
  7. }
  8. 结果:Unknown type: UnityEngine.Sprite