Description
Introduction
Currently it adds a command that can play music from the internet.
Supports mp3 and ogg audio format.
Have special support for NetEase Cloud Music share links.
Usage
/playmusic <music_url> <sound_source> <targets>
similar to the playsound command.
/setbackgroundmusic <url> <targets> set the (looping) background music for selected targets
/stopbackgroundmusic stop the looping background music for yourself (No permission needed by default)
example:
/playmusic "https://github.com/lender544/new1.20.1/raw/refs/heads/master/src/main/resources/assets/cataclysm/sounds/music_disc/ignis_theme.ogg" music @a
This will play the song when fighting with Ignis in L_Ender's Cataclysm mod,
from its GitHub source code repo.
/playmusic "https://music.163.com/#/song?id=431855484" music @a
Play Sweet Dream (the notorious menu theme of the GTNH modpack)
using the share link of NetEase Cloud Music.
/playmusic "./kubejs/testdata.mp3" music @a
Play ./kubejs/testdata.mp3 from the clients' local file system,
with the game instance folder as the current directory
Permissions
| Node | Usage | Default Permission Level | |
|---|---|---|---|
| kuromusic.music.play | permission to use /playmusic | 2 (OP/functions) | |
| kuromusic.background_music.set | permission to use /setbackgroundmusic | 2 (OP/functions) | |
| kuromusic.background_music.stop_self | permission to use /stopbackgroundmusic | 0 (Everyone) |


