-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathstruct.go
More file actions
113 lines (101 loc) · 3.62 KB
/
struct.go
File metadata and controls
113 lines (101 loc) · 3.62 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
package dota2api
type GetLeagueListingWrapper struct {
Result GetLeagueListingResult `json:"result"`
}
type GetLeagueListingResult struct {
Leagues []League `json:"leagues"`
}
type League struct {
Name string `json:"name"`
LeagueID int `json:"leagueid"`
Description string `json:"description"`
TournamentURL string `json:"tournament_url"`
ItemDef int `json:"itemdef"`
}
type GetLiveLeagueGamesWrapper struct {
Result GetLiveLeagueGamesResult `json:"result"`
}
type GetLiveLeagueGamesResult struct {
Games []Game `json:"games"`
}
type Game struct {
Players []Player `json:"players"`
RadientTeam Team `json:"radiant_team"`
DireTeam Team `json:"dire_time"`
LobbyID uint64 `json:"lobby_id"`
MatchID uint64 `json:"match_id"`
Spectators int `json:"spectators"`
GameNumber int `json:"game_number"`
LeagueID int `json:"league_id"`
StreamDelayS int `json:"stream_delay_s"`
RadiantSeriesWins int `json:"radiant_series_wins"`
DireSeriessWins int `json:"dire_series_wins"`
SeriesType int `json:"series_type"`
LeagueSeriesID int `json:"league_series_id"`
LeagueGameID int `json:"league_game_id"`
StageName string `json:"stage_name"`
LeagueTier int `json:"league_tier"`
Scoreboard Scoreboard `json:"scoreboard"`
}
type Player struct {
AccountID int `json:"account_id"`
Name string `json:"name"`
HeroID int `json:"hero_id"`
Team int `json:"team"`
TeamDescription string `json:"-"`
}
type Team struct {
TeamName string `json:"team_name"`
TeamID int `json:"team_id"`
TeamLogo int `json:"team_logo"`
Complete bool `json:"complete"`
}
type Scoreboard struct {
Duration float64 `json:"duration"`
RoshanRespawnTimer int `json:"roshan_respawn_timer"`
Radiant ScoreboardTeam `json:"radiant"`
Dire ScoreboardTeam `json:"dire"`
}
type ScoreboardTeam struct {
Score int `json:"score"`
TowerState int `json:"tower_state"`
BarracksState int `json:"barracks_state"`
Picks []struct {
HeroID int `json:"hero_id"`
} `json:"picks"`
Bans []struct {
HeroID int `json:"hero_id"`
} `json:"bans"`
Players []ScoreboardTeamPlayer `json:"players"`
Abilities []ScoreboardTeamAbility `json:"abilities"`
}
type ScoreboardTeamPlayer struct {
PlayerSlot int `json:"player_slot"`
AccountID uint64 `json:"account_id"`
HeroID int `json:"hero_id"`
Kills int `json:"kills"`
Death int `json:"death"`
Assists int `json:"assists"`
LastHits int `json:"last_hits"`
Denies int `json:"denies"`
Gold int `json:"gold"`
Level int `json:"level"`
GoldPerMin int `json:"gold_per_min"`
XPPerMin int `json:"xp_per_min"`
UltimateState int `json:"ultimate_state"`
UltimateCooldown int `json:"ultimate_cooldown"`
Item0 int `json:"item0"`
Item1 int `json:"item1"`
Item2 int `json:"item2"`
Item3 int `json:"item3"`
Item4 int `json:"item4"`
Item5 int `json:"item5"`
RespawnTimer int `json:"respawn_timer"`
PositionX float64 `json:"position_x"`
PositionY float64 `json:"position_y"`
NetWorth int `json:"net_worth"`
}
type ScoreboardTeamAbility struct {
AbilityID int `json:"ability_id"`
AbilityLevel int `json:"ability_level"`
}