dm_post.go 1.0 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546
  1. package dm
  2. import "encoding/json"
  3. const (
  4. // ActionPost dm action
  5. ActionPost = "post"
  6. // BroadcastCMD dm broadcast command
  7. BroadcastCMD = "DM"
  8. // BroadcastCMDACT BroadcastCMDACT
  9. BroadcastCMDACT = "ACT"
  10. )
  11. // XML dm xml info
  12. type XML struct {
  13. PlayTime float32 `json:"playtime"`
  14. Mode int32 `json:"mode"`
  15. FontSize int32 `json:"fontsize"`
  16. Color int32 `json:"color"`
  17. Times int64 `json:"times"`
  18. PoolID int32 `json:"poolid"`
  19. Hash string `json:"hash"`
  20. DMID int64 `json:"dmid"`
  21. Msg string `json:"msg"`
  22. Random string `json:"rnd"`
  23. }
  24. // Broadcast dm broadcast
  25. type Broadcast struct {
  26. RoomID int64 `json:"roomid"`
  27. CMD string `json:"cmd"`
  28. Info json.RawMessage `json:"info"`
  29. }
  30. // ActDM ActDM
  31. type ActDM struct {
  32. Act int64 `json:"act"`
  33. Aid int64 `json:"aid"`
  34. Next int64 `json:"next"`
  35. No int64 `json:"no"`
  36. Yes int64 `json:"yes"`
  37. Stage int64 `json:"stage"`
  38. Title string `json:"title"`
  39. Author string `json:"author"`
  40. Tname string `json:"tname"`
  41. }