SinSong is a Minecraft plugin designed to enhance your gameplay experience by adding custom music tracks that can be played directly in the game. Whether you’re creating a custom atmosphere for your server or simply want to enjoy music while playing, SinSong provides an easy-to-use solution.
SinSong Plugin - Configuration
1. Resource Pack Folder
The resource_pack_folder is the folder where your custom music files are stored inside the assets/minecraft/sounds/ directory.
Example:
Code (YAML):
resource_pack_folder
:
"custom"
In this case, your custom music files should be placed in assets/minecraft/sounds/custom/ inside your resource pack.
2. Sound Definitions (sounds.json)
To link your custom music files with Minecraft, you need to define them in a sounds.json file. Here’s an example:
Code (json (Unknown Language)):
{
"custom.music_1": {
"sounds": [
{
"name": "custom/music_1",
"stream": true
}
]
},
"custom.music_2": {
"sounds": [
{
"name": "custom/music_2",
"stream": true
}
]
}
}
This defines two custom music tracks (music_1 and music_2) that are streamed to the player.
3. Songs List
This section defines the songs that are available to be played. Each song has the following attributes:
- name: The identifier used in the sounds.json file.
- title: The title of the song.
- duration: The duration of the song in seconds.
Example:
Code (YAML):
songs:
- name
: music_1
title
:
"Song 1"
duration
: 15
# seconds
- name
: music_2
title
:
"Song 2"
duration
: 20
# seconds
In this example, two songs are defined with different durations.
4. Auto-Play
The auto_play option defines which song will play automatically when the plugin is loaded.
Example:
Code (YAML):
auto_play
:
"music_1"
This will start music_1 automatically when the plugin is initialized.
5. Shuffle
The shuffle option determines whether the songs should be played in a random order.
Example:
Code (YAML):
shuffle
: true
If set to true, the songs will be played in a random order. If set to false, they will be played in the order defined in the songs list.
Example Full Configuration (config.yml)
resource_pack_folder: "custom" # This matches your folder inside assets/minecraft/sounds/custom/
Code (YAML):
songs:
- name
: music_1
title
:
"Song 1"
duration
: 15
# seconds
- name
: music_2
title
:
"Song 2"
duration
: 20
# seconds
auto_play
:
"music_1"
shuffle
: true
# true or false