### What is it?
Hey guys, I’m back with another planned plugin for Sponge!
music4minecraft (or short: m4m) is a custom music plugin for your server. You can create a playlist based on some selectors, and dependent on the in-game environment, your players will listen to awesome music perfect for what they do on your server at the moment.
### How does it work? Minecraft does not support custom music!
I know that, and there are two solutions for this, both of them can be used in m4m:
- A Minecraft mod (recommended). This makes the communication between server and client easy and will display ingame notifications about the current playing track.
- A web app. The plugin has a built-in webserver (default: http://localhost:13413/) that serves a widget you can embed in the existing server website and a simple standalone web client. You can customize everything if you want, but the default configuration should be fine for most servers.
For the web client you need to forward/allow/use a port at the server, however this is not needed if your players only use the mod.
The mod will also work in Singleplayer on custom maps as it will be completely chat-based and can be triggered by command blocks.
### What can I do with it?
You can write a playlist file (or use an existing one) where you tell the plugin: “If the player is in this situation, then play one of those tracks from youtube after the last track has ended.” This is called a selector.
You can also tell the plugin: “If the player ever comes into this exact situation, immediately stop his track and play one from this list.” - Then, this selector is called a trigger.
You can also combine multiple selectors and triggers.
This is a growing list of what will be possible:
- Music dependent on the ingame time
- Biome-dependent music
- World-dependent music
- Music for specific light levels
- Play different music if the player is in the cave
- Music in a specific area
- Music on command (trigger only)
- Other plugins can register selectors via the API
### Where does the music come from?
You will be able to use music from YouTube only at the current state.
Later I will eventually add SoundCloud and Deezer or something like that (unfortunately, Spotify got a pretty bad API…)
### How far are you with development?
I did create m4m half a year ago for our private minecraft server with only the web client, it worked pretty well with Bukkit, but it was missing an API and the code was pretty messy. This will be a complete rewrite for Sponge, and it will be awesome!
The new implementation will be Open Source, so you can help with the development! I’ll setup a GitHub repository soon.
Plan the configuration file syntax
Plan the communication between server and client
Plan the API for other plugins to hook into m4m (1/18/2015)
Code the Forge Client Mod (January)
Code the API implementation and the core plugin (January/February)
Code the main selectors (February)
Make the web app and the widget API work (February)
Release m4m (late February)
### Links to the latest updates
- The first webapp draft (1/6/2015)
- More information and documentation on my website
If you got an idea for a new selector, a better name for the plugin or just anything you want to tell me, put it down right there in the reply section.