using LitJson; using Newtonsoft.Json.Linq; using System.Collections; using System.Collections.Generic; using UnityEngine; public class LangChaoMailManager : MonoSingleton { public Transform Mail_ImageList; public Transform showImagePoint; public GameObject mail_imageItem; // 显示邮件 // 加载邮件图片 // 接受邮件 public void ReceiverMail(JObject data) { // 邮件分类 // 加载显示邮件 if (data["image_data"] != null) { GameObject obj = GameObject.Instantiate(mail_imageItem, Mail_ImageList); obj.transform.position = showImagePoint.position; obj.transform.eulerAngles = showImagePoint.eulerAngles; obj.SetActive(true); obj.GetComponent().SetImageData(data["image_data"].ToString()); } } }