示例#1
0
 public override void Initialize()
 {
     image = CClientCommon.AddComponent <CImage>(this.gameObject);
     this.CreateSprite(image, "newmainface", "xiaohongdian");
     image.raycastTarget       = false;
     m_rectTransform           = GetComponent <RectTransform>();
     m_rectTransform.pivot     = new Vector2(0.5f, 0.5f);
     m_rectTransform.anchorMin = Vector2.one;
     m_rectTransform.anchorMax = Vector2.one;
     image.SetNativeSize();
 }