EpigraphTable.cs 1.6 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152
  1. // Generate By EToy
  2. // Don't Edit It!!
  3. using XGame.Framework.Database;
  4. using XGame.Framework.Serialization;
  5. namespace XGame.Database
  6. {
  7. /// <summary> Epigraph </summary>
  8. public sealed class EpigraphTable : ITable
  9. {
  10. long ITable.Key => Id;
  11. /// <summary> 铭文ID </summary>
  12. public int Id { get; private set; }
  13. /// <summary> 图标 </summary>
  14. public string Icon { get; private set; } // c
  15. /// <summary> 名字 </summary>
  16. public string Name { get; private set; } // c
  17. /// <summary> 1: 白2:绿3:蓝4:紫5: 黄6:橙7:红8: 粉9:蓝钻10:鎏金11:璀璨 </summary>
  18. public EQualityLevel Quality { get; private set; }
  19. /// <summary> 元素系1:火2:雷3:冰4:毒5:风0:无元素 </summary>
  20. public EElementType Element { get; private set; }
  21. /// <summary> 效果参数 </summary>
  22. public int[] EffectArgs { get; private set; }
  23. void ISerializable.Deserialize(IReader reader)
  24. {
  25. Id = reader.ReadInt();
  26. Icon = reader.ReadString();
  27. Name = reader.ReadString();
  28. Quality = (EQualityLevel)reader.ReadInt();
  29. Element = (EElementType)reader.ReadInt();
  30. EffectArgs = reader.ReadEnumerable<int[]>();
  31. }
  32. void ISerializable.Serialize(IWriter writer)
  33. {
  34. writer.Write(Id);
  35. writer.Write(Icon);
  36. writer.Write(Name);
  37. writer.Write((int)Quality);
  38. writer.Write((int)Element);
  39. writer.Write(EffectArgs);
  40. }
  41. }
  42. }