of

@Contract(value = "_, _, _, _ -> new", pure = true)
fun of(sound: SoundEvent, minimumDelay: Int, maximumDelay: Int, replaceCurrentMusic: Boolean): Music

Creates new music with the given values.

Parameters

sound

the sound that will be played

minimumDelay

the minimum delay before starting

maximumDelay

the maximum delay before starting

replaceCurrentMusic

if the current music should be replaced