legend.go 2.9 KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374
  1. package model
  2. const (
  3. LegendCompoundNum = 5 // 合成一个高品质铭文消耗的低级铭文数量
  4. //类型
  5. //1--传承铭文
  6. //2--纷争铭文
  7. //3--冥想铭文
  8. //4--神圣铭文
  9. LegendTypeInherit = 1
  10. LegendTypeWrangle = 2
  11. LegendTypeMeditation = 3
  12. LegendTypeHoly = 4
  13. // 槽位类型
  14. //1:普通槽位
  15. //2:神圣槽位
  16. SlotTypeNormal = 1
  17. SlotTypeHoly = 2
  18. )
  19. // 铭文槽位-LegendSlot exported from 铭文配置.xlsx
  20. type LegendSlot struct {
  21. Uid int64 `json:"Uid"` // 唯一编号
  22. Type int64 `json:"Type"` // 大类型 1--传承铭文 2--纷争铭文 3--冥想铭文
  23. SlotType int64 `json:"SlotType"` // 槽位类型 1:普通槽位 2:神圣槽位
  24. Order int64 `json:"Order"` // 槽位顺序编号
  25. Condition int64 `json:"Condition"` // 位置解锁条件 主线关卡ID
  26. } // package model
  27. type LegendSlotList []*LegendSlot
  28. func (l LegendSlotList) Len() int { return len(l) }
  29. func (l LegendSlotList) Swap(i, j int) { l[i], l[j] = l[j], l[i] }
  30. func (l LegendSlotList) Less(i, j int) bool {
  31. if l[i].Type == l[j].Type {
  32. return l[i].Order < l[j].Order
  33. }
  34. return l[i].Type < l[j].Type
  35. }
  36. // 铭文表-Legend exported from 铭文配置.xlsx
  37. type Legend struct {
  38. Uid int64 `json:"Uid"` // ID
  39. Type int64 `json:"Type"` // 类型 1--传承铭文 2--纷争铭文 3--冥想铭文 4--神圣铭文
  40. Name string `json:"Name"` // 名称
  41. Quality int64 `json:"Quality"` // 品质
  42. Icon string `json:"Icon"` // 图标
  43. Des string `json:"Des"` // 属性描述
  44. Skill int64 `json:"Skill"` // 词条类型
  45. Value []float64 `json:"Value"` // 数值
  46. OnlyEntry int64 `json:"OnlyEntry"` // 唯一词条,全铭文唯一 1--是唯一属性 0--不是唯一属性
  47. } // package model
  48. // 铭文精通等级-LegendExcel exported from 铭文配置.xlsx
  49. type LegendExcel struct {
  50. Grade int64 `json:"Grade"` // 等级
  51. Condition int64 `json:"Condition"` // 所需铭文总品质等级
  52. // EntrySkill1 [][]int64 `json:"EntrySkill1"` // 要塞攻击力 【【技能类型】,【参数】】
  53. // EntrySkill2 [][]int64 `json:"EntrySkill2"` // 要塞爆伤 【【技能类型】,【参数】】
  54. Consume []int64 `json:"Consume"` // 本机升级消耗 【道具ID,数量】
  55. Skill1 int64 `json:"Skill1"` // 服务端校验用 第一类型
  56. Parameter1 float64 `json:"Parameter1"` // 服务器校验用 第一类型参数
  57. Skill2 int64 `json:"Skill2"` // 服务器校验用 第二类型
  58. Parameter2 float64 `json:"Parameter2"` // 服务器校验用 第二类型 参数
  59. } // package model
  60. // 铭文重铸消耗-LegendConsume exported from 铭文配置.xlsx
  61. type LegendConsume struct {
  62. Uid int64 `json:"Uid"` // ID
  63. Quality int64 `json:"Quality"` // 铭文品质
  64. ConsumeQuantity []int64 `json:"ConsumeQuantity"` // 消耗数量 空值--不可重铸 [道具ID,数量]
  65. }