Documentation ¶
Index ¶
Constants ¶
View Source
const ( HitTypeNote = 1 << iota HitTypeSlider NewCombo HitTypeSpinner ComboColourSkip1 ComboColourSkip2 ComboColourSkip3 HitTypeHoldNote )
View Source
const ( HitSoundNormal = iota HitSoundWhistle HitSoundFinish HitSoundClap )
View Source
const ( TaikoKatMask = HitSoundWhistle | HitSoundClap TaikoDonMask = ^TaikoKatMask // TODO: need a test TaikoBigMask = HitSoundFinish )
View Source
const ComboMask = ^(NewCombo + ComboColourSkip1 + ComboColourSkip2 + ComboColourSkip3)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Difficulty ¶
type Difficulty struct { HPDrainRate float64 `json:"hpDrainRate"` CircleSize float64 `json:"circleSize"` OverallDifficulty float64 `json:"overallDifficulty"` ApproachRate float64 `json:"approachRate"` SliderMultiplier float64 `json:"sliderMultiplier"` SliderTickRate float64 `json:"sliderTickRate"` }
type Event ¶
type Event struct { Type string StartTime int EndTime int // optional Filename string XOffset int YOffset int }
storyboard not implemented yet
type Format ¶
type Format struct { FormatVersion int `json:"formatVersion"` General Editor Metadata Difficulty Events TimingPoints Colours HitObjects }
type General ¶
type General struct { AudioFilename string `json:"audioFilename"` AudioLeadIn int `json:"audioLeadIn"` AudioHash string `json:"audioHash"` // deprecated PreviewTime int `json:"previewTime"` Countdown int `json:"countdown"` // nofloat SampleSet string `json:"sampleSet"` StackLeniency float64 `json:"stackLeniency"` Mode int `json:"mode"` // nofloat LetterboxInBreaks bool `json:"letterboxInBreaks"` StoryFireInFront bool `json:"storyFireInFront"` // deprecated UseSkinSprites bool `json:"useSkinSprites"` AlwaysShowPlayfield bool `json:"alwaysShowPlayfield"` // deprecated OverlayPosition string `json:"overlayPosition"` SkinPreference string `json:"skinPreference"` EpilepsyWarning bool `json:"epilepsyWarning"` CountdownOffset int `json:"countdownOffset"` SpecialStyle bool `json:"specialStyle"` WidescreenStoryboard bool `json:"widescreenStoryboard"` SamplesMatchPlaybackRate bool `json:"samplesMatchPlaybackRate"` }
type HitObject ¶
type HitObject struct { X int `json:"x"` Y int `json:"y"` Time int `json:"time"` NoteType int `json:"noteType"` // nofloat HitSound int `json:"hitSound"` // nofloat EndTime int `json:"endTime"` // optional SliderParams SliderParams // optional HitSample HitSample // optional }
func (HitObject) SliderDuration ¶
func (ho HitObject) SliderDuration(tps []TimingPoint, multiplier float64) int
TODO: need a test
type HitObjects ¶
type HitObjects []HitObject
type HitSample ¶
type HitSample struct { NormalSet int `json:"normalSet"` // nofloat AdditionSet int `json:"additionSet"` // nofloat Index int `json:"index"` // nofloat Volume int `json:"volume"` Filename string `json:"filename"` }
func (HitSample) SampleFilename ¶
TODO: test yet supposed whether normal or additional sample set is input in every call
type Metadata ¶
type Metadata struct { Title string `json:"title"` TitleUnicode string `json:"titleUnicode"` Artist string `json:"artist"` ArtistUnicode string `json:"artistUnicode"` Creator string `json:"creator"` Version string `json:"version"` Source string `json:"source"` Tags []string // delimiter(space) BeatmapID int `json:"beatmapID"` // nofloat BeatmapSetID int `json:"beatmapSetID"` // nofloat }
type SliderParams ¶
type TimingPoint ¶
type TimingPoint struct { Time int `json:"time"` BeatLength float64 `json:"beatLength"` Meter int `json:"meter"` SampleSet int `json:"sampleSet"` // nofloat SampleIndex int `json:"sampleIndex"` // nofloat Volume int `json:"volume"` Uninherited bool `json:"uninherited"` Effects int `json:"effects"` // nofloat }
func (TimingPoint) BPM ¶
func (tp TimingPoint) BPM() (bpm float64, ok bool)
func (TimingPoint) IsInherited ¶
func (tp TimingPoint) IsInherited() bool
func (TimingPoint) IsKiai ¶
func (tp TimingPoint) IsKiai() bool
func (TimingPoint) SpeedFactor ¶
func (tp TimingPoint) SpeedFactor() (speed float64, ok bool)
SpeedFactor returns a speed factor. The standard value is 1.
type TimingPoints ¶
type TimingPoints []TimingPoint
Click to show internal directories.
Click to hide internal directories.