using CodeStage.AntiCheat.ObscuredTypes; using Newtonsoft.Json; using System; using System.Collections.Generic; [Serializable] public class FruitTableData : TableDataBase { ObscuredInt _FruitID; public int n_FruitID { get { return _FruitID; } set { _FruitID = value; _FruitID.RandomizeCryptoKey(); } } // ¿­¸Å ID ObscuredInt _STR; public int n_STR { get { return _STR; } set { _STR = value; _STR.RandomizeCryptoKey(); } } // STR ObscuredInt _DEX; public int n_DEX { get { return _DEX; } set { _DEX = value; _DEX.RandomizeCryptoKey(); } } // DEX ObscuredInt _INT; public int n_INT { get { return _INT; } set { _INT = value; _INT.RandomizeCryptoKey(); } } // INT ObscuredInt _LUK; public int n_LUK { get { return _LUK; } set { _LUK = value; _LUK.RandomizeCryptoKey(); } } // LUK public string Get_Desc() { var str_STR = table_localtext.Ins.Get_Text(40001); var str_DEX = table_localtext.Ins.Get_Text(40003); var str_INT = table_localtext.Ins.Get_Text(40005); var str_LUK = table_localtext.Ins.Get_Text(40007); if (n_STR > 0 && n_DEX > 0 && n_INT > 0) return DSUtil.Format(314, str_STR, str_DEX, str_INT); else if (n_STR > 0) return DSUtil.Format(315, str_STR); else if (n_DEX > 0) return DSUtil.Format(315, str_DEX); else if (n_INT > 0) return DSUtil.Format(315, str_INT); else if (n_LUK > 0) return DSUtil.Format(315, str_LUK); return ""; } } public class table_fruit : table_missionbase { public static table_fruit Ins; List tableDatas; Dictionary dic_Data = new Dictionary(); protected override void Awake() { base.Awake(); Ins = this; } protected override void Start() { tableDatas = JsonConvert.DeserializeObject>(json_last); for (int i = 0; i < Get_DataList().Count; i++) { var temp = Get_DataList()[i]; dic_Data.Add(temp.n_FruitID, temp); } base.Start(); } public FruitTableData Get_Data_orNull(int id) { return dic_Data[id]; } public List Get_DataList() { return tableDatas; } }