▶️ ЗАБЕРИ СВОИ 8 ПОДАРКОВ 🎁 ПРИ СОЗДАНИИ СВОЕГО МАЙНКРАФТ СЕРВЕРА
Моды/Login Music
Login Music

Login Music

A simple Minecraft mod that can play music when players join in the world.

Оцените первым
287
2

A simple Minecraft mod that can play music when players join in the world.

This mod uses AI to assist in development.

Inspired by TartaricAcid's Net Music !

MilestoneBig changes
1.1.0javafx has given place to com.googlecode.soundlibs:mp3spi, which provides MP3 support now.
1.2.0the music config has changed to JSON type.
1.2.1Music can be played directly through the Internet without downloading; lyrics support!
1.2.2Audio backend loading, Players can receive audio from other players on the server.

The logo comes from here, designed by juicy_fish.

Functions

  • Play music
  • Supported file types: mp3, wav
  • Music Downloading screen
  • Allow download switch
  • Play different musics based on the player's name (uuid)
  • Show lyrics while playing music

File Structure

Destructive changes:

Since mod version 1.2.5, the config file's storage has been changed! If you upgrade from previous version, please move them to the new place!

All music files are stored in the /data/login_music folder.

{version folder}
├── config
│   ├── login_music-music.json      # Specific musics
│   └── login_music-client.toml     # Client config    
│
├── data/login_music        # Store music files
│   ├── MusicsCache
│   │   ├── music_1.mp3
│   │   ├── music_2.wav
│   │   └── ...
│   └── LyricsCache   
│       ├── music_1.lrc
│       ├── music_2.lrc
│       └── ...
└── ...

Configuration

Music Config JSON

Since mod version 1.2.0, the music config has changed to JSON type, just as shown below.

If you enter a server with this mod, the config file on the server has higher priority, which will cover your custom settings.

{
    "musics": [
        {
            "id": "Default",
            "music": "Default.mp3",
            "musicUrl": "https://www.example.com/example.mp3",
            "lyric": "Default.lrc",
            "lyricUrl": "https://www.example.com/example.lrc" 
        }, {
            "id": "Steve",
            "music": "login_music.mp3",
            "musicUrl": "https://www.example.com/login_music.mp3",
            "lyric": "login_music.lrc",
            "lyricUrl": "https://www.example.com/login_music.lrc"
        }
    ]
}

The music will be downloaded if InternetAccess is set true (the default setting is false), otherwise, the music is played through network audio streams, which may cause a short pause when entering a world.

For example, When a player named Steve enters the world, the mod will try to find the music matched the name Steve (in this case it's login_music.mp3 ) in the folder /LoginMusic first. Then try to download it from its related url if it has failed before.

Tips: If there is a file with the same name in the folder, it will skip the download even if the file does not match the URL.

If more entries need to be configured, please follow the JSON's rule.

Since mod version 1.2.4, you can open Login Music Config from the main menu if Cloth Config API has been installed.

Client Side

login_music-client.toml is effective only for the client:

[Lyrics]
    #Whether to show lyrics while playing music
    ShowLyrics = true
    #Defines the position of the lyrics
    #Allowed Values: UP, MIDDLE, DOWN
    LyricsPosition = "DOWN"
    #Defines the color of the lyrics you want to use
    LyricsColor = 16777215

[Music]
    #Range of music play (a non negative integer)
    # Default: 3
    # Range: 0 ~ 100
    range = 3
    #Whether to allow downloading music from the internet
    InternetAccess = false
    #Whether to play musics from other players
    AllowOthersMusic = true

Server Side

login_music-server.toml:

[Selection]
    #Keywords for music selection (name/uuid)
    #Allowed Values: NAME, UUID
    type = "NAME"

Command

All the commands need permission level 2.

CommandFunction
/loginmusic reloadreload config
/loginmusic listshow music config available currently
/loginmusic show <targetPlayer>show targetPlayer's music config
/loginmusic playreplay your login music

Часто задаваемые вопросы

Совместимость

Minecraft: Java Edition

1.21.x1.20.x

Платформы

Поддерживаемые окружения

Клиент и сервер

Зависимости

Ссылки

Детали

Лицензия:
Опубликован:4 месяца назад
Обновлён:3 недели назад
Главная