Class Sound
java.lang.Object
net.darkhax.bookshelf.api.data.sound.Sound
- All Implemented Interfaces:
ISound
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanstatic SoundfromByteBuf(net.minecraft.network.FriendlyByteBuf buffer) net.minecraft.sounds.SoundSourcefloatgetPitch()net.minecraft.sounds.SoundEventgetSound()floatinthashCode()voidplaySoundAt(net.minecraft.world.level.Level level, @Nullable net.minecraft.world.entity.player.Player originator, double posX, double posY, double posZ) static voidtoString()Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, waitMethods inherited from interface net.darkhax.bookshelf.api.data.sound.ISound
playSoundAt, playSoundAt
-
Field Details
-
CODEC_SIMPLE
-
CODEC_OBJECT
-
CODEC
-
-
Constructor Details
-
Sound
public Sound(net.minecraft.sounds.SoundEvent sound) -
Sound
public Sound(net.minecraft.sounds.SoundEvent sound, net.minecraft.sounds.SoundSource category, float pitch, float volume)
-
-
Method Details
-
playSoundAt
public void playSoundAt(net.minecraft.world.level.Level level, @Nullable @Nullable net.minecraft.world.entity.player.Player originator, double posX, double posY, double posZ) - Specified by:
playSoundAtin interfaceISound
-
getSound
public net.minecraft.sounds.SoundEvent getSound() -
getCategory
public net.minecraft.sounds.SoundSource getCategory() -
getPitch
public float getPitch() -
getVolume
public float getVolume() -
toString
-
equals
-
hashCode
public int hashCode() -
fromByteBuf
-
toByteBuf
-