WorkData.cs 675 B

1234567891011121314151617181920212223242526272829303132333435363738394041
  1. using System;
  2. using System.IO;
  3. using wf;
  4. namespace MaidStatus
  5. {
  6. public class WorkData
  7. {
  8. public uint playCount
  9. {
  10. get
  11. {
  12. return this.playCount_;
  13. }
  14. set
  15. {
  16. this.playCount_ = (uint)wf.Math.RoundMinMax((long)((ulong)value), 0L, (long)((ulong)-1));
  17. }
  18. }
  19. public void Serialize(BinaryWriter binary)
  20. {
  21. binary.Write(this.id);
  22. binary.Write(this.playCount);
  23. binary.Write(this.level);
  24. }
  25. public void Deserialize(BinaryReader binary, int version)
  26. {
  27. this.id = binary.ReadInt32();
  28. this.playCount = binary.ReadUInt32();
  29. this.level = binary.ReadInt32();
  30. }
  31. public int id;
  32. public int level;
  33. private uint playCount_;
  34. }
  35. }