Interface Music
- All Superinterfaces:
Wrapper
Wraps the Music environment attribute's music record.
- Since:
- 2.4.1
-
Nested Class Summary
Nested ClassesModifier and TypeInterfaceDescriptionstatic final classBuilder for creating music records.Nested classes/interfaces inherited from interface Wrapper
Wrapper.Context<C> -
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionstatic Music.Builderbuilder()Creates a new music record builder.intmaxDelay()Gets the maximum delay of the music.intminDelay()Gets the minimum delay of the music.static Musicof(SoundEvent sound, int minDelay, int maxDelay, boolean replaceCurrentMusic) Creates a new music record.booleanGets whether the music should replace the current music.sound()Gets the sound of the music.Methods inherited from interface Wrapper
asHandle, toMinecraft
-
Field Details
-
WIRE
-
-
Method Details
-
sound
Gets the sound of the music.- Returns:
- the sound of the music
- Since:
- 2.4.1
-
minDelay
Gets the minimum delay of the music.- Returns:
- the minimum delay of the music
- Since:
- 2.4.1
-
maxDelay
Gets the maximum delay of the music.- Returns:
- the maximum delay of the music
- Since:
- 2.4.1
-
replaceCurrentMusic
Gets whether the music should replace the current music.- Returns:
- whether the music should replace the current music
- Since:
- 2.4.1
-
of
@AsOf("2.4.1") static Music of(SoundEvent sound, int minDelay, int maxDelay, boolean replaceCurrentMusic) Creates a new music record.- Parameters:
sound- the sound of the musicminDelay- the minimum delay of the musicmaxDelay- the maximum delay of the musicreplaceCurrentMusic- whether the music should replace the current music- Returns:
- a new music record
- Since:
- 2.4.1
-
builder
Creates a new music record builder.- Returns:
- a new music record builder
- Since:
- 2.4.1
-