misc

package
v0.0.0-...-5c5ef0c Latest Latest
Warning

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

Go to latest
Published: May 10, 2026 License: GPL-3.0 Imports: 26 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// region / file
	URL_BASE            = "https://raw.githubusercontent.com/ggmolly/belfast-data/main/%s/%s"
	REGIONLESS_URL_BASE = "https://raw.githubusercontent.com/ggmolly/belfast-data/main/%s"
)

Variables

This section is empty.

Functions

func GetGitHash

func GetGitHash() string

GetGitHash returns the git hash of the current build

func GetSpecifiedRegion

func GetSpecifiedRegion() string

GetSpecifiedRegion returns the value of the environment variable AL_REGION it is needed for the web UI to highlight the correct region since we cannot call os.Getenv from the web template engine ¯\_(ツ)_/¯

func LastCacheUpdate

func LastCacheUpdate() time.Time

func LastCacheUpdateVersion

func LastCacheUpdateVersion() string

func LoadEscortState

func LoadEscortState(accountID uint32) ([]*protobuf.ESCORT_INFO, error)

func ResolveRegionVersion

func ResolveRegionVersion(region string) (string, error)

func UpdateAllData

func UpdateAllData(region string)

func UpdateEscortTimestamps

func UpdateEscortTimestamps(accountID uint32, lineID uint32, awardTS uint32, flashTS uint32) error

Types

type EscortConfig

type EscortConfig struct {
	Templates map[uint32]EscortTemplate
	Maps      []EscortMapTemplate
}

func GetEscortConfig

func GetEscortConfig() (*EscortConfig, error)

type EscortMapTemplate

type EscortMapTemplate struct {
	ID           uint32          `json:"id"`
	RefreshTime  uint32          `json:"refresh_time"`
	DropByWarn   []uint32        `json:"drop_by_warn"`
	EscortIDList json.RawMessage `json:"escort_id_list"`
}

type EscortTemplate

type EscortTemplate struct {
	ID             uint32          `json:"id"`
	GardroadReward json.RawMessage `json:"gardroad_reward"`
}

type Field

type Field struct {
	Label string
	Name  string
	Type  string
	Index int
}

func GetPacketFields

func GetPacketFields(packetId int) []Field

type GameChecksum

type GameChecksum struct {
	Category string
	Hash     string
}

type HashMap

type HashMap []GameChecksum

func GetGameHashes

func GetGameHashes() HashMap

func GetGameHashesWithUpdate

func GetGameHashesWithUpdate() HashMap

type Version

type Version struct {
	Region  string
	Version string
}

type VersionMap

type VersionMap map[string]Version

func GetLatestVersions

func GetLatestVersions() VersionMap

Jump to

Keyboard shortcuts

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