public static class NoteBlockEvent.Change extends NoteBlockEvent
NoteBlockEvent.setNote(Note, Octave)
.
Canceling this event will not change the note and also stop the Noteblock from playing it's note.NoteBlockEvent.Change, NoteBlockEvent.Note, NoteBlockEvent.Octave, NoteBlockEvent.Play
BlockEvent.BreakEvent, BlockEvent.CreateFluidSourceEvent, BlockEvent.CropGrowEvent, BlockEvent.EntityMultiPlaceEvent, BlockEvent.EntityPlaceEvent, BlockEvent.FarmlandTrampleEvent, BlockEvent.FluidPlaceBlockEvent, BlockEvent.HarvestDropsEvent, BlockEvent.NeighborNotifyEvent, BlockEvent.PortalSpawnEvent
Modifier and Type | Field and Description |
---|---|
private NoteBlockEvent.Note |
oldNote |
private NoteBlockEvent.Octave |
oldOctave |
Constructor and Description |
---|
Change(World world,
BlockPos pos,
BlockState state,
int oldNote,
int newNote) |
Modifier and Type | Method and Description |
---|---|
NoteBlockEvent.Note |
getOldNote() |
NoteBlockEvent.Octave |
getOldOctave() |
getNote, getOctave, getVanillaNoteId, setNote
getPos, getState, getWorld
private final NoteBlockEvent.Note oldNote
private final NoteBlockEvent.Octave oldOctave
public Change(World world, BlockPos pos, BlockState state, int oldNote, int newNote)
public NoteBlockEvent.Note getOldNote()
public NoteBlockEvent.Octave getOldOctave()