collectionfinder

package
v0.0.0-...-7032b66 Latest Latest
Warning

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

Go to latest
Published: Oct 16, 2020 License: MIT Imports: 6 Imported by: 0

Documentation

Overview

Package collectionfinder parses the Magic The Gathering: Logs, returning user decks.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func FindCollection

func FindCollection(mtgalogs io.Reader) ([]map[uint64]uint32, error)

FindCollection returns the list of user collections from the MTGA Logs.

Types

type BoosterContents

type BoosterContents struct {
	CommonWildcards   int
	UncommonWildcards int
	RareWildcards     int
	MythicWildcards   int
	CardIds           []uint64
}

BoosterContents represent the contents from a booster pack.

func FindBoosters

func FindBoosters(mtgalogs io.Reader, progressList []ProgressVaultJSON) ([]BoosterContents, error)

FindBoosters returns the list of all opened boosters in the MTG Arena Logs.

type PlayerInventory

type PlayerInventory struct {
	PlayerID   string `json:"playerId"`
	WcCommon   int    `json:"wcCommon"`
	WcUncommon int    `json:"wcUncommon"`
	WcRare     int    `json:"wcRare"`
	WcMythic   int    `json:"wcMythic"`
}

PlayerInventory represents the inventory of a player.

func FindInventory

func FindInventory(mtgalogs io.Reader) ([]PlayerInventory, error)

FindInventory returns a list of all the inventories that appear in the MTG Logs

type ProgressVaultJSON

type ProgressVaultJSON struct {
	CardsOpened            []json.RawMessage `json:"cardsOpened"`
	TotalVaultProgress     int               `json:"totalVaultProgress"`
	WildCardTrackMoves     int               `json:"wildCardTrackMoves"`
	WildCardTrackPosition  int               `json:"wildCardTrackPosition"`
	WildCardTrackCommons   int               `json:"wildCardTrackCommons"`
	WildCardTrackUnCommons int               `json:"wildCardTrackUnCommons"`
	WildCardTrackRares     int               `json:"wildCardTrackRares"`
	WildCardTrackMythics   int               `json:"wildCardTrackMythics"`
}

func FindProgress

func FindProgress(mtgalogs io.Reader) ([]ProgressVaultJSON, error)

Jump to

Keyboard shortcuts

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