pointdata.go 3.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117
  1. package model
  2. import (
  3. "encoding/json"
  4. "sync"
  5. )
  6. //Item .
  7. type Item struct {
  8. PercentMovementSpeedMod interface{} `json:"percent_movement_speed_mod"`
  9. PercentLifeStealMod interface{} `json:"percent_life_steal_mod"`
  10. PercentAttackSpeedMod interface{} `json:"percent_attack_speed_mod"`
  11. Name string `json:"name"`
  12. ImageURL string `json:"image_url"`
  13. ID int64 `json:"id"`
  14. GoldTotal interface{} `json:"gold_total"`
  15. GoldSell interface{} `json:"gold_sell"`
  16. GoldPurchasable bool `json:"gold_purchasable"`
  17. GoldBase interface{} `json:"gold_base"`
  18. FlatSpellBlockMod interface{} `json:"flat_spell_block_mod"`
  19. FlatPhysicalDamageMod interface{} `json:"flat_physical_damage_mod"`
  20. FlatMpRegenMod interface{} `json:"flat_mp_regen_mod"`
  21. FlatMpPoolMod interface{} `json:"flat_mp_pool_mod"`
  22. FlatMovementSpeedMod interface{} `json:"flat_movement_speed_mod"`
  23. FlatMagicDamageMod interface{} `json:"flat_magic_damage_mod"`
  24. FlatHpRegenMod interface{} `json:"flat_hp_regen_mod"`
  25. FlatHpPoolMod interface{} `json:"flat_hp_pool_mod"`
  26. FlatCritChanceMod interface{} `json:"flat_crit_chance_mod"`
  27. FlatArmorMod interface{} `json:"flat_armor_mod"`
  28. }
  29. //Game .
  30. type Game struct {
  31. WinnerType string `json:"winner_type"`
  32. Winner json.RawMessage `json:"winner"`
  33. Teams json.RawMessage `json:"teams"`
  34. Position int64 `json:"position"`
  35. Players json.RawMessage `json:"players"`
  36. MatchID int64 `json:"match_id"`
  37. Match json.RawMessage `json:"match"`
  38. Length int64 `json:"length"`
  39. ID int64 `json:"id"`
  40. Finished interface{} `json:"finished"`
  41. BeginAt interface{} `json:"begin_at"`
  42. }
  43. //Champion .
  44. type Champion struct {
  45. VideogameVersions []string `json:"videogame_versions"`
  46. Spellblockperlevel float64 `json:"spellblockperlevel"`
  47. Spellblock float64 `json:"spellblock"`
  48. Name string `json:"name"`
  49. Mpregenperlevel float64 `json:"mpregenperlevel"`
  50. Mpregen float64 `json:"mpregen"`
  51. Mpperlevel interface{} `json:"mpperlevel"`
  52. Mp float64 `json:"mp"`
  53. Movespeed interface{} `json:"movespeed"`
  54. ImageURL string `json:"image_url"`
  55. ID int64 `json:"id"`
  56. Hpregenperlevel float64 `json:"hpregenperlevel"`
  57. Hpregen interface{} `json:"hpregen"`
  58. Hpperlevel interface{} `json:"hpperlevel"`
  59. Hp interface{} `json:"hp"`
  60. Critperlevel interface{} `json:"critperlevel"`
  61. Crit interface{} `json:"crit"`
  62. BigImageURL string `json:"big_image_url"`
  63. Attackspeedperlevel float64 `json:"attackspeedperlevel"`
  64. Attackspeedoffset interface{} `json:"attackspeedoffset"`
  65. Attackrange interface{} `json:"attackrange"`
  66. Attackdamageperlevel float64 `json:"attackdamageperlevel"`
  67. Attackdamage float64 `json:"attackdamage"`
  68. Armorperlevel float64 `json:"armorperlevel"`
  69. Armor interface{} `json:"armor"`
  70. }
  71. //Hero .
  72. type Hero struct {
  73. *LdInfo
  74. LocalizedName string `json:"localized_name"`
  75. }
  76. // LdInfo .
  77. type LdInfo struct {
  78. Name string `json:"name"`
  79. ImageURL string `json:"image_url"`
  80. ID int64 `json:"id"`
  81. }
  82. // SyncGame store leida game list
  83. type SyncGame struct {
  84. Data map[int64][]*Game
  85. sync.Mutex
  86. }
  87. // SyncItem store item list
  88. type SyncItem struct {
  89. Data map[int64]*Item
  90. sync.Mutex
  91. }
  92. // SyncChampion store champion list
  93. type SyncChampion struct {
  94. Data map[int64]*Champion
  95. sync.Mutex
  96. }
  97. // SyncHero store hero list
  98. type SyncHero struct {
  99. Data map[int64]*Hero
  100. sync.Mutex
  101. }
  102. // SyncInfo store leida base info list
  103. type SyncInfo struct {
  104. Data map[int64]*LdInfo
  105. sync.Mutex
  106. }