dota2

package
v0.0.0-...-fe78ce7 Latest Latest
Warning

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

Go to latest
Published: Jan 17, 2022 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const (
	UserAgent = "Valve/Steam HTTP Client 1.0 (570)"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Client

type Client struct {
	*dota2.Dota2

	Session *Session
}

func NewClient

func NewClient(d *dota2.Dota2) *Client

type ErrClientSuspended

type ErrClientSuspended struct {
	Until time.Time
}

func (*ErrClientSuspended) Error

func (err *ErrClientSuspended) Error() string

type ErrLostSession

type ErrLostSession struct {
	Status d2pb.GCConnectionStatus
}

func (*ErrLostSession) Error

func (err *ErrLostSession) Error() string

type ErrNoSession

type ErrNoSession struct {
	*nserr.Err
}

type ErrWelcomeTimeout

type ErrWelcomeTimeout struct {
	RetryCount    int
	RetryInterval time.Duration
}

func (*ErrWelcomeTimeout) Error

func (err *ErrWelcomeTimeout) Error() string

type Session

type Session struct {
	State          state.Dota2State
	LastTransition *StateTransition
	// contains filtered or unexported fields
}

func (*Session) IsReady

func (s *Session) IsReady() bool

func (*Session) StateChange

func (s *Session) StateChange(t *StateTransition)

type StateTransition

type StateTransition struct {
	Previous       state.Dota2State
	Next           state.Dota2State
	ReadyToUnready bool
	UnreadyToReady bool
}

func NewStateTransition

func NewStateTransition(prev, next state.Dota2State) *StateTransition

Jump to

Keyboard shortcuts

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