Class NoteBlockMusic.Sound

java.lang.Object
com.cryptomorin.xseries.NoteBlockMusic.Instruction
com.cryptomorin.xseries.NoteBlockMusic.Sound
Enclosing class:
NoteBlockMusic

public static class NoteBlockMusic.Sound extends NoteBlockMusic.Instruction
An instruction that produces a sonud which consists of a Instrument and a Note with Note.Tone, but without duration or
Since:
3.0.0
  • Field Details

    • sound

      public XSound sound
    • volume

      public float volume
      In Minecraft you have no control over note durations. A note, has a tone, and a tone is a named pitch with a specific (constant) timbre.
    • pitch

      public float pitch
      In Minecraft you have no control over note durations. A note, has a tone, and a tone is a named pitch with a specific (constant) timbre.
  • Constructor Details

    • Sound

      public Sound(org.bukkit.Instrument instrument, org.bukkit.Note note, float volume, int restatement, int restatementFermata, int fermata)
    • Sound

      public Sound(XSound sound, float pitch, float volume, int restatement, int restatementFermata, int fermata)
  • Method Details

    • setSound

      public void setSound(org.bukkit.Instrument instrument)
    • setPitch

      public void setPitch(org.bukkit.Note note)
    • play

      public void play(org.bukkit.entity.Player player, Supplier<org.bukkit.Location> location, boolean playAtLocation)
      Specified by:
      play in class NoteBlockMusic.Instruction
    • toString

      public String toString()
      Overrides:
      toString in class Object