Fix SoundEvent not being an adventure sound type

This commit is contained in:
TheMode 2021-08-12 22:08:31 +02:00
parent 70c757e8b5
commit 82602a686e

View File

@ -1,5 +1,7 @@
package net.minestom.server.sound;
import net.kyori.adventure.key.Key;
import net.kyori.adventure.sound.Sound;
import net.minestom.server.registry.ProtocolObject;
import net.minestom.server.utils.NamespaceID;
import org.jetbrains.annotations.ApiStatus;
@ -9,7 +11,7 @@ import org.jetbrains.annotations.Nullable;
import java.util.Collection;
@ApiStatus.NonExtendable
public interface SoundEvent extends ProtocolObject, SoundEventConstants {
public interface SoundEvent extends ProtocolObject, Sound.Type, SoundEventConstants {
static @NotNull Collection<@NotNull SoundEvent> values() {
return SoundEventImpl.values();
@ -26,4 +28,9 @@ public interface SoundEvent extends ProtocolObject, SoundEventConstants {
static @Nullable SoundEvent fromId(int id) {
return SoundEventImpl.getId(id);
}
@Override
default @NotNull Key key() {
return ProtocolObject.super.key();
}
}