Documentation ¶
Index ¶
- Constants
- func ReadBoolean(buffer *bufio.Reader) (bool, error)
- func ReadInteger(buffer io.Reader) (uint32, error)
- func ReadLZMA(reader *bufio.Reader, length uint32) (string, error)
- func ReadLong(buffer io.Reader) (uint64, error)
- func ReadShort(buffer io.Reader) (uint16, error)
- func ReadString(reader *bufio.Reader) (string, error)
- func ReadUleb(reader *bufio.Reader) (uint64, error)
- type Action
- type Common
- type HealthGraphPoint
- type Key
- type Mod
- type Mode
- type ReplayData
Constants ¶
View Source
const ( // Hex values for all modes ModeStandard Mode = 0x0 ModeTaiko Mode = 0x1 ModeCTB Mode = 0x2 ModeMania Mode = 0x3 // Names for all modes ModeStandardName = "osu!standard" ModeTaikoName = "osu!taiko" ModeCTBName = "osu!catch" ModeManiaName = "osu!mania" )
Variables ¶
This section is empty.
Functions ¶
func ReadBoolean ¶
Get the boolean value of the next byte of a reader
func ReadString ¶
Get the string value from bufio.Reader
Types ¶
type Common ¶
type Common struct { Mode Mode `json:"mode"` GameVersion uint32 `json:"game_version"` BeatMapHash string `json:"beat_map_hash"` PlayerName string `json:"player_name"` ReplayHash string `json:"replay_hash"` Amount300s uint16 `json:"amount_300_s"` Amount100s uint16 `json:"amount_100_s"` Amount50s uint16 `json:"amount_50_s"` AmountSpecial300s uint16 `json:"amount_special_300_s"` AmountSpecial100s uint16 `json:"amount_special_100_s"` AmountMisses uint16 `json:"amount_misses"` TotalScore uint32 `json:"total_score"` LongestCombo uint16 `json:"longest_combo"` IsPerfect bool `json:"is_perfect"` Timestamp uint64 `json:"timestamp"` ScoreID uint64 `json:"score_id"` }
type HealthGraphPoint ¶
type Mod ¶
type Mode ¶
type Mode byte
OSU! mode (Standard, Taiko, Catch the Beat, Mania)
func (Mode) MarshalJSON ¶
type ReplayData ¶
type ReplayData struct { Common Mods []Mod `json:"mods"` HealthGraph []HealthGraphPoint `json:"health_graph"` ReplayData []Action `json:"replay_data"` }
export replay structure
func GetFileReplay ¶
func GetFileReplay(file string) (*ReplayData, error)
Click to show internal directories.
Click to hide internal directories.