Exemple #1
0
        /// <summary>
        /// 序列化LitRawImage
        /// </summary>
        public static SerializeEntity Ser_RawImage(this LitRawImage img)
        {
            var se = img.Ser_MaskableGraphic();

            se.Type = "RImg";
            se.Add("path", SerializeUitls.GetResPath(img.texture))
            .Add("UV", SerializeUitls.S_Rect(img.uvRect));
            return(se);
        }
Exemple #2
0
        public static SerializeEntity Ser_MaskableGraphic(this MaskableGraphic mg)
        {
            SerializeEntity se = new SerializeEntity();

            se.Add("m", SerializeUitls.GetResPath(mg.material))
            .Add("col", SerializeUitls.S_Color(mg.color))
            .Add("RT", mg.raycastTarget);
            return(se);
        }
Exemple #3
0
        /// <summary>
        /// 序列化LitImage
        /// </summary>
        public static SerializeEntity Ser_Image(this LitImage img)
        {
            var se = img.Ser_MaskableGraphic();

            se.Type = "Img";
            se.Add("path", SerializeUitls.GetResPath(img.sprite))
            .Add("PA", img.preserveAspect);
            return(se);
        }
Exemple #4
0
 public void TestImagePath()
 {
     LitLogger.Log(SerializeUitls.GetResPath(sprite));
 }