mirror of
https://github.com/SPAWNRYS-ban/FUCK-CustomDiscs.git
synced 2025-12-17 16:59:38 +05:00
Permissions
The permission customdiscs.command is now required to run /customdisc .
This commit is contained in:
@@ -35,7 +35,7 @@ public class CustomDisc implements CommandExecutor {
|
||||
Player p = (Player) sender;
|
||||
|
||||
// /customdisc wewontbealone "We wont be alone"
|
||||
if (command.getName().equalsIgnoreCase("customdisc")) {
|
||||
if (command.getName().equalsIgnoreCase("customdisc") && p.hasPermission("customdiscs.command")) {
|
||||
if (isMusicDisc(p)) {
|
||||
if (args.length >= 2) {
|
||||
|
||||
|
||||
@@ -65,9 +65,6 @@ public class JukeBox implements Listener {
|
||||
LocationalAudioChannel audioChannel = VoicePlugin.voicechatServerApi.createLocationalAudioChannel(id, VoicePlugin.voicechatApi.fromServerLevel(block.getLocation().getWorld()), VoicePlugin.voicechatApi.createPosition(block.getLocation().getX() + 0.5d, block.getLocation().getY() + 0.5d, block.getLocation().getZ() + 0.5d));
|
||||
|
||||
try {
|
||||
|
||||
|
||||
|
||||
AudioPlayer audioPlayer = VoicePlugin.voicechatServerApi.createAudioPlayer((AudioChannel) audioChannel, VoicePlugin.voicechatApi.createEncoder(), readSoundFile(soundFilePath));
|
||||
playerMap.put(id, audioPlayer);
|
||||
audioPlayer.startPlaying();
|
||||
|
||||
Reference in New Issue
Block a user