//------------------------------------------------------------------------------ // // 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: enemy.xlsx /// public partial class ItemBoss : Item, IItem { public const string ASSET_NAME = "enemy"; /// /// /// index:1 /// public string name { get; private set; } /// /// 资源 /// index:2 /// public string assets { get; private set; } /// /// /// index:3 /// public int level { get; private set; } /// /// 血量 /// index:4 /// public int hp { get; private set; } /// /// 伤害 /// index:5 /// public int[] power { get; private set; } /// /// 防御 /// index:6 /// public int defence { get; private set; } /// /// 格挡 (命中) /// index:7 /// public int block { get; private set; } /// /// 抵抗 (暴击) /// index:8 /// public int resist { get; private set; } /// /// /// index:9 /// public float[] fireRange { get; private set; } /// /// /// index:10 /// public int turnSpeed { get; private set; } /// /// /// index:11 /// public float runSpeed { get; private set; } /// /// /// index:12 /// public int[] dash { get; private set; } /// /// /// index:13 /// public float[][] moving_attack { get; private set; } /// /// /// index:14 /// public int[] attach_ef { get; private set; } /// /// /// index:15 /// public int[] colliderOff { get; private set; } /// /// /// index:16 /// public float speed_move { get; private set; } /// /// /// index:17 /// public float[] speed_attack { get; private set; } /// /// /// index:18 /// public float[] speed_attack_i { get; private set; } /// /// /// index:19 /// public float speed_idle { get; private set; } /// /// /// index:20 /// public float speed_down { get; private set; } /// /// /// index:21 /// public int sizeKind { get; private set; } /// /// 质量 /// index:22 /// public float mass { get; private set; } /// /// 半径 /// index:23 /// public float radius { get; private set; } /// /// 子弹预制体 /// index:24 /// public string bullet { get; private set; } /// /// 攻击预警 /// index:25 /// public string preview { get; private set; } /// /// /// index:26 /// public float attackCd { get; private set; } /// /// 掉落类型 /// index:27 /// public int boxDrop { get; private set; } public void Load(IList list) { id = list.GetInt(0); name = list.GetString(1); assets = list.GetString(2); level = list.GetInt(3); hp = list.GetInt(4); power = list.GetIntArray(5); defence = list.GetInt(6); block = list.GetInt(7); resist = list.GetInt(8); fireRange = list.GetFloatArray(9); turnSpeed = list.GetInt(10); runSpeed = list.GetFloat(11); dash = list.GetIntArray(12); moving_attack = list.GetFloatArray2(13); attach_ef = list.GetIntArray(14); colliderOff = list.GetIntArray(15); speed_move = list.GetFloat(16); speed_attack = list.GetFloatArray(17); speed_attack_i = list.GetFloatArray(18); speed_idle = list.GetFloat(19); speed_down = list.GetFloat(20); sizeKind = list.GetInt(21); mass = list.GetFloat(22); radius = list.GetFloat(23); bullet = list.GetString(24); preview = list.GetString(25); attackCd = list.GetFloat(26); boxDrop = list.GetInt(27); } public static bool LoadAll(IDictionary dictionary, List result) { if (result == null) { return false; } var list = dictionary.GetList("Boss"); 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 ItemBoss CreateThis() { return new ItemBoss(); } } }