-
Notifications
You must be signed in to change notification settings - Fork 89
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Signed-off-by: Pablo Herrera <[email protected]>
- Loading branch information
1 parent
50c2bc3
commit 0443673
Showing
5 changed files
with
45 additions
and
9 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
package tc.oc.pgm.util.bukkit; | ||
|
||
import static net.kyori.adventure.sound.Sound.sound; | ||
import static tc.oc.pgm.util.bukkit.MiscUtils.MISC_UTILS; | ||
|
||
import net.kyori.adventure.sound.Sound; | ||
|
||
public interface Sounds { | ||
Sound WARNING = sound("NOTE_BASS", "BLOCK_NOTE_BLOCK_BASS", 1f, 0.75f); | ||
|
||
static Sound sound(String legacyConstant, String modernConstant, float volume, float pitch) { | ||
return sound( | ||
MISC_UTILS.getSound( | ||
BukkitUtils.parse(org.bukkit.Sound::valueOf, legacyConstant, modernConstant)), | ||
Sound.Source.MASTER, | ||
volume, | ||
pitch); | ||
} | ||
} |