dto

package
v1.5.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Sep 9, 2022 License: GPL-3.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type HeroDto

type HeroDto struct {
	Name          string `json:"name"`
	ID            int    `json:"id"`
	LocalizedName string `json:"localized_name"`
}

type MatchPlayerDto

type MatchPlayerDto struct {
	PlayerID     string
	MatchID      int64 `json:"match_id"`
	PlayerSlot   int   `json:"player_slot"`
	RadiantWin   bool  `json:"radiant_win"`
	Duration     int   `json:"duration"` // Seconds
	GameMode     int   `json:"game_mode"`
	LobbyType    int   `json:"lobby_type"`
	HeroID       int   `json:"hero_id"`
	StartTime    int   `json:"start_time"`
	Version      int   `json:"version"`
	Kills        int   `json:"kills"`
	Deaths       int   `json:"deaths"`
	Assists      int   `json:"assists"`
	Skill        *int  `json:"skill"`
	LeaverStatus int   `json:"leaver_status"`
	PartySize    int   `json:"party_size"`
}

func FromSubscriptionMatch

func FromSubscriptionMatch(sm *ent.SubscriptionMatch) *MatchPlayerDto

func (MatchPlayerDto) DurationMinutes

func (m MatchPlayerDto) DurationMinutes() int

func (MatchPlayerDto) IsWin

func (m MatchPlayerDto) IsWin() bool

func (MatchPlayerDto) SkillString

func (m MatchPlayerDto) SkillString() string

type SteamApiResult

type SteamApiResult struct {
	Result struct {
		Heroes []HeroDto `json:"heroes"`
		Status int       `json:"status"`
		Count  int       `json:"count"`
	} `json:"result"`
}

type SubscriptionDto

type SubscriptionDto struct {
	GroupID  int
	PlayerID string
	Alias    string
}

func (SubscriptionDto) Name

func (sp SubscriptionDto) Name() string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL