Documentation
¶
Index ¶
Constants ¶
View Source
const ( OSU = iota TAIKO CTB MANIA )
View Source
const ( MOUSELEFT = 1 << iota MOUSERIGHT K1 K2 SMOKE )
Variables ¶
View Source
var ModsEnum = []BanchoMod{
{0, "NM", "NoMod"},
{1, "NF", "NoFail"},
{2, "EZ", "Easy"},
{4, "TD", "TouchDevice"},
{8, "HD", "Hidden"},
{16, "HR", "HardRock"},
{32, "SD", "SuddenDeath"},
{64, "DT", "DoubleTime"},
{128, "RX", "Relax"},
{256, "HT", "HalfTime"},
{512, "NC", "NightCore"},
{1024, "FL", "Flashlight"},
{2048, "AT", "Auto"},
{4096, "SO", "SpunOut"},
{8192, "AP", "AutoPilot"},
{16384, "PF", "Perfect"},
}
Functions ¶
func ParseGamemode ¶
func ReturnBitFlags ¶
ReturnBitFlags iterate through BanchoMod slice and returns a bit value
Types ¶
type BanchoMod ¶
func ParseBitFlags ¶
ParseBitFlags parses an osu! mods bit values and return an BanchoMod slice
type CompressedReplay ¶
type CompressedReplay []byte
func (*CompressedReplay) Decompress ¶
func (cr *CompressedReplay) Decompress() (dr DecompressedReplay, err error)
Decompress a ReplayData to DecompressedReplay slice
type DecompressedReplay ¶
type DecompressedReplay []ReplayValue
func (*DecompressedReplay) Compress ¶
func (dr *DecompressedReplay) Compress() (cr CompressedReplay)
Compress a DecompressedReplay slice to CompressedReplay byte slice
type KeyPressed ¶
type Replay ¶
type Replay struct {
Gamemode int8
Version int32
BeatmapMD5 string
PlayerName string
ReplayMD5 string
Count300 uint16
Count100 uint16
Count50 uint16
CountGeki uint16
CountKatu uint16
CountMiss uint16
TotalScore int32
Combo int16
PerfectCombo bool
Mods uint32
LifeBarGraph string
TimeStamp time.Time
ReplayData CompressedReplay
OnlineScoreID int64
AdditionalMod float64
}
func NewReplay ¶
func NewReplay() (r *Replay)
NewReplay returns an empty Replay struct with TimeStamp
func NewReplayFromFile ¶
NewReplayFromFile reads a replay file, parses it and returns a Replay pointer
func (*Replay) WriteToFile ¶
WriteToFile writes a replay file to specified path
type ReplayValue ¶
type ReplayValue struct {
Ms int64
X float32
Y float32
KeyPressed KeyPressed
}
Click to show internal directories.
Click to hide internal directories.