示例#1
0
 public static void Deserialize(SkillAnimConfigDefine ins, System.IO.Stream stream)
 {
     tabtoy.DataReader reader = new tabtoy.DataReader(stream);
     if (!reader.ReadHeader())
     {
         throw new System.Exception(string.Format("Deserialize failed: {0}", ins.GetType()));
     }
     Deserialize(ins, reader);
 }
示例#2
0
        public SkillAnimConfigDefine GetByID(int ID, SkillAnimConfigDefine def = default(SkillAnimConfigDefine))
        {
            SkillAnimConfigDefine ret;

            if (_ByID.TryGetValue(ID, out ret))
            {
                return(ret);
            }

            if (def == default(SkillAnimConfigDefine))
            {
                TableLogger.ErrorLine("GetByID failed, ID: {0}", ID);
            }

            return(def);
        }
示例#3
0
        public static void Deserialize(SkillAnimConfigDefine ins, tabtoy.DataReader reader)
        {
            int tag = -1;

            while (-1 != (tag = reader.ReadTag()))
            {
                switch (tag)
                {
                case 0x10000:
                {
                    ins.ID = reader.ReadInt32();
                }
                break;

                case 0x10001:
                {
                    ins.Type = reader.ReadInt32();
                }
                break;

                case 0x60002:
                {
                    ins.Ctrl = reader.ReadString();
                }
                break;

                case 0x60003:
                {
                    ins.ActionID = reader.ReadString();
                }
                break;

                case 0x60004:
                {
                    ins.CastingEnter = reader.ReadString();
                }
                break;

                case 0x60005:
                {
                    ins.Casting = reader.ReadString();
                }
                break;

                case 0x60006:
                {
                    ins.CastingExit = reader.ReadString();
                }
                break;

                case 0x60007:
                {
                    ins.InstantEnter = reader.ReadString();
                }
                break;

                case 0x60008:
                {
                    ins.Instant = reader.ReadString();
                }
                break;

                case 0x60009:
                {
                    ins.LastingEnter = reader.ReadString();
                }
                break;

                case 0x6000a:
                {
                    ins.Lasting = reader.ReadString();
                }
                break;

                case 0x6000b:
                {
                    ins.LastingExit = reader.ReadString();
                }
                break;
                }
            }
        }