using Newtonsoft.Json; using System.Collections.Generic; public class albumtabledata { public int n_Index, n_GirlID, n_Coin, n_Gem, n_Heart; public string s_Image; } public class table_album : table_base { public static table_album Ins; List tableDatas; Dictionary> dic_datas = new Dictionary>(); protected override void Awake() { Ins = this; base.Awake(); } protected override void Start() { tableDatas = JsonConvert.DeserializeObject>(json_last); for (int i = 0; i < tableDatas.Count; i++) { var temp = tableDatas[i]; if (!dic_datas.ContainsKey(temp.n_GirlID)) dic_datas.Add(temp.n_GirlID, new List()); dic_datas[temp.n_GirlID].Add(temp); } base.Start(); } public List Get_DataList() { return tableDatas; } public List Get_DataList(int girl) { return dic_datas[girl]; } }