//------------------------------------------------------------------------------ // // This code was generated by a tool. // // Changes to this file may cause incorrect behavior and will be lost if // the code is regenerated. // //------------------------------------------------------------------------------ namespace G { using System.Collections; using System.Collections.Generic; using F; using F.Item; /// /// Generated from: adventures.xlsx /// public partial class ItemAdventure : Item, IItem { public const string ASSET_NAME = "adventures"; /// /// 主事件标识 1;主事件 2:任务事件 /// index:1 /// public int type { get; private set; } /// /// 事件参数 /// index:2 /// public int[] typeArgs { get; private set; } /// /// /// index:3 /// public int story { get; private set; } /// /// 事件1 0:无事件 1:跳转 2: 3:试用装备(单局有效) 4:立刻给与buff(单局有效) 5:立刻给与技能(单局有效) 6:送装备(永久) 7:解锁技能(永久) /// index:4 /// public string matter_1 { get; private set; } /// /// 事件1条件 /// index:5 /// public int[] option_1 { get; private set; } /// /// 事件2 /// index:6 /// public string matter_2 { get; private set; } /// /// 事件2条件 /// index:7 /// public int[] option_2 { get; private set; } /// /// 事件3 /// index:8 /// public string matter_3 { get; private set; } /// /// 事件3条件 /// index:9 /// public int[] option_3 { get; private set; } /// /// 文本 /// index:10 /// public string describe { get; private set; } public void Load(IList list) { id = list.GetInt(0); type = list.GetInt(1); typeArgs = list.GetIntArray(2); story = list.GetInt(3); matter_1 = list.GetString(4); option_1 = list.GetIntArray(5); matter_2 = list.GetString(6); option_2 = list.GetIntArray(7); matter_3 = list.GetString(8); option_3 = list.GetIntArray(9); describe = list.GetString(10); } public static bool LoadAll(IDictionary dictionary, List result) { if (result == null) { return false; } var list = dictionary.GetList("Adventure"); if (list == null || list.Count == 0) { return false; } int i = 0; for (int c = list.Count; i < c; i++) { var item = CreateThis(); item.Load((IList)list[i]); result.Add(item); } return true; } private static ItemAdventure CreateThis() { return new ItemAdventure(); } } }