-
Notifications
You must be signed in to change notification settings - Fork 0
/
main.go
29 lines (24 loc) · 934 Bytes
/
main.go
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
package main
import (
"fmt"
"github.com/Ra2-IFV/TRN-BF1/pkg/bf1/trn"
)
type Config struct {
Proxy string `yaml:"proxy"`
}
func init() {}
func main() {
display_name := "404-HK416-MOD3"
playerInfo, _ := trn.GetPlayerInfo(display_name)
//match_list, _ := get_match_list(display_name)
fmt.Println("Player name", playerInfo.Data.Segments[0].Stats)
fmt.Println("Rank", playerInfo.Data.Segments[0].Stats.Rank.Value)
fmt.Println("KD", playerInfo.Data.Segments[0].Stats.KdRatio.DisplayValue)
fmt.Println("KPM", playerInfo.Data.Segments[0].Stats.KillsPerMinute.DisplayValue)
fmt.Println("Heals", playerInfo.Data.Segments[0].Stats.Heals.Value)
fmt.Println("Revives", playerInfo.Data.Segments[0].Stats.Revive.Value)
//fmt.Println("The last 3 matches ID")
//fmt.Println(match_list.Data.Matches[0].Attributes.ID)
//fmt.Println(match_list.Data.Matches[1].Attributes.ID)
//fmt.Println(match_list.Data.Matches[2].Attributes.ID)
}