12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152 |
-
- using XGame.Framework.Database;
- using XGame.Framework.Serialization;
- namespace XGame.Database
- {
-
- public sealed class EquipmentTable : ITable
- {
- long ITable.Key => Id;
-
- public int Id { get; private set; }
-
- public string Name { get; private set; }
-
- public int Type { get; private set; }
-
- public int Level { get; private set; }
-
- public EEquipType Part { get; private set; }
-
- public EQualityLevel Quality { get; private set; }
- void ISerializable.Deserialize(IReader reader)
- {
- Id = reader.ReadInt();
- Name = reader.ReadString();
- Type = reader.ReadInt();
- Level = reader.ReadInt();
- Part = (EEquipType)reader.ReadInt();
- Quality = (EQualityLevel)reader.ReadInt();
- }
- void ISerializable.Serialize(IWriter writer)
- {
- writer.Write(Id);
- writer.Write(Name);
- writer.Write(Type);
- writer.Write(Level);
- writer.Write((int)Part);
- writer.Write((int)Quality);
- }
- }
- }
|