headframe.go 2.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123
  1. package msg
  2. import (
  3. "leafstalk/covenant/model"
  4. )
  5. // HeadList 获取头像列表
  6. type HeadList struct {
  7. PlayerId int64 `json:"userId"`
  8. }
  9. type ResponseHeadList struct {
  10. ErrCode int `json:"errCode"`
  11. Msg string `json:"msg,omitempty"`
  12. Data HeadListData `json:"data"`
  13. }
  14. type HeadListData struct {
  15. Heads map[int64]struct{} `json:"heads"`
  16. Frames map[int64]struct{} `json:"frames"`
  17. }
  18. // 选择头像
  19. type SelectHead struct {
  20. PlayerId int64 `json:"userId"`
  21. Type int64 `json:"type"` // 1头像 2头像框
  22. HeadId int64 `json:"headId"`
  23. }
  24. type ResponseSelectHead struct {
  25. ErrCode int `json:"errCode"`
  26. Msg string `json:"msg,omitempty"`
  27. Data int64 `json:"data"`
  28. }
  29. // 激活头像头像框
  30. type ActiveHead struct {
  31. PlayerId int64 `json:"userId"`
  32. Type int64 `json:"type"` // 1头像 2头像框
  33. Id int64 `json:"id"`
  34. }
  35. type ResponseActiveHead struct {
  36. ErrCode int `json:"errCode"`
  37. Msg string `json:"msg,omitempty"`
  38. Data *ActiveHeadData `json:"data"`
  39. }
  40. type ActiveHeadData struct {
  41. Type int64 `json:"type"` // 1头像 2头像框
  42. Id int64 `json:"id"`
  43. CostId int64 `json:"costId"` // 消耗一个道具id
  44. }
  45. // 激活聊天框
  46. type ActiveChatFrame struct {
  47. PlayerId int64 `json:"userId"`
  48. Id int64 `json:"id"`
  49. }
  50. type ResponseActiveChatFrame struct {
  51. ErrCode int `json:"errCode"`
  52. Msg string `json:"msg,omitempty"`
  53. Data *ActiveChatFrameData `json:"data"`
  54. }
  55. type ActiveChatFrameData struct {
  56. Id int64 `json:"id"` // 激活的聊天框id
  57. CostId int64 `json:"costId"` // 消耗一个道具id
  58. }
  59. // // HeadFrameList 获取头像列表
  60. // type HeadFrameList struct {
  61. // PlayerId int64 `json:"userId"`
  62. // }
  63. // type ResponseHeadFrameList struct {
  64. // ErrCode int `json:"errCode"`
  65. // Msg string `json:"msg,omitempty"`
  66. // Data map[int64]struct{} `json:"data"`
  67. // }
  68. // // 选择头像
  69. // type SelectHeadFrame struct {
  70. // PlayerId int64 `json:"userId"`
  71. // HeadFrameId int64 `json:"headFrameId"`
  72. // }
  73. // type ResponseSelectHeadFrame struct {
  74. // ErrCode int `json:"errCode"`
  75. // Msg string `json:"msg,omitempty"`
  76. // Data int64 `json:"data"`
  77. // }
  78. // 改名
  79. type ChangeNickName struct {
  80. PlayerId int64 `json:"userId"`
  81. NickName string `json:"nickName"`
  82. GateId int64 `json:"-"` //服务端用
  83. }
  84. type ResponseChangeNickName struct {
  85. ErrCode int `json:"errCode"`
  86. Msg string `json:"msg,omitempty"`
  87. Data ChangeNickNameData `json:"data"`
  88. }
  89. type ChangeNickNameData struct {
  90. NickName string `json:"nickName"`
  91. Costs map[int64]int64 `json:"costs"`
  92. ChangedNum int64 `json:"changedNum"`
  93. }
  94. // 信用记录
  95. type CreditRecords struct {
  96. PlayerId int64 `json:"userId"`
  97. }
  98. type ResponseCreditRecords struct {
  99. ErrCode int `json:"errCode"`
  100. Msg string `json:"msg,omitempty"`
  101. Data []*model.CreditRecord `json:"data"`
  102. }