Dream Minecraft Manhunt (with optional Discord music integration)
MinecraftManhunt
Made by Eric (yoonicode.com)
Minecraft: TildeTildeTilde
Inspired by Dream on YouTube
This project is open-source! View on Github
Something wrong? Plugin broken? Check the FAQ Issues page or report the problem here!
How It Works
Three teams: Hunters, Runners, and Spectators Hunters try to kill the runners before they beat the enderdragon. Runners must beat the enderdragon before they get killed once!
Features
- Compass tracking: Right-click with your compass to choose who to track, then the compass will point to that runner!
- Portal tracking: If a runner is in the nether, the compass will track their last-used portal!
- Teams assignment: Automatically assigns in-game
/team
to distinguish between players with colors! - Discord integration: Optionally integrate with Discord for extra features!
- Auto role assignment: Automatically assign Discord roles according to teams
- Music player: Automatically (or manually) play music in your Discord voice channel that mirrors the action happening!
Instructions For Use
- Move the .jar to your plugins folder.
- Make sure your config file is up to date and has all the required options (more info down below).
- Assign roles with
/speedrunner
,/hunter
, and/spectator
. - If you want automatic music, type
/music auto
now. - Type
/start
! - After the headstart period is over, hunters should be able to start tracking runners by selecting someone to track by right-clicking with their compass.
Note: teams are not persistent between server sessions— if you shut down the server you'll have to re-assign teams and type
/start
again.
Discord Setup Instructions
-
- Create a Discord app from the Developer Portal.
- Add a Bot under the bots tab.
- Take note of your Client ID (in the General Information tab) and your Token (under the Bot tab).
- Go to the following link, replacing
123YourClientID456
with your client ID:https://discord.com/oauth2/authorize?scope=bot&client_id=123YourClientID456&permissions=8
- Select the Discord server to add your bot to.
- Add your Client ID and Token to the respective fields in the config file.
- Go to your Discord server, and add the following values to the config file, in accordance with the table above (you can
Right Click > Copy ID
if you turn on Developer Mode in Discord settings!)- the ID of your server
- the ID of the voice channel you want your music to play in
- the ID of the hunter, runner, and spectator Discord roles you want to be automatically assigned
Note: For auto-role-assignment to work, each Discord user's nickname for your Server must be set to their Minecraft username.
Commands
/speedrunner <username>
: Assign speedrunner role/hunter <username>
: Assign hunter role/spectator <username>
: Assign spectator role/start
: Start the match/end
: End the match/compass
: Give yourself a compass/music
: Controls the Discord music/music list
: Gets a list of available tracks to play./music <trackname>
: Plays a specific track by nickname and turns off auto-music./music stop
: Stops all music playing and turns off auto-music./music auto
: Turns on auto-music, which plays different tracks based on game events and hunter/runner distance./music forceupdate
: Forces the music to update to match the current hunter/runner distance. Use/music stop
first if a special event track is playing.
Configuration Options
Edit the plugins/MinecraftManhunt/config.yml
file with the following options:
Game Options
Key | Description | Type | Required? |
---|---|---|---|
headStartDuration | How long the hunters should get blindness and slowness when the match starts, in secs. | int | Required |
compassEnabledInNether | Set to true to allow the compass to work in the nether. | boolean | Optional, defaults to true |
sendUsageData | Set to true to send anonymized, aggregated usage data to help improve the plugin. | boolean | Optional, defaults to false |
uuid | Randomized id that is automatically assigned if sendUsageData is enabled. Please do not touch this field. |
string | Do not set manually |
Extra Options
Key | Description | Type | Required? |
---|---|---|---|
setRunnersToSpecOnDeath | Set to true to set runners' gamemodes to spectator when they die. | boolean | Optional, defaults to true |
huntersColor | The color to give to the hunters team. |
string | Optional |
runnersColor | The color to give to the runners team. |
string | Optional |
spectatorsColor | The color to give to the spectators team. |
string | Optional |
clearRunnerInvOnStart | Set to true to clear the runners' inventories and experience when the game starts. | boolean | Optional, defaults to false |
clearHunterInvOnStart | Set to true to clear the hunters' inventories and experience when the game starts. | boolean | Optional, defaults to false |
clearItemDropsOnStart | Set to true to clear all Item entities when the game starts. | boolean | Optional, defaults to false |
setTimeToZero | Set to true to reset the game time when the game starts. | boolean | Optional, defaults to true |
startGameByHit | Set to true to start the game when a runner hits a hunter, instead of when the /start command is used. |
boolean | Optional, defaults to false |
preGameWorldBorder | Set to true to enforce a world border before the game starts (useful to keep players from running too far). | boolean | Optional, defaults to false |
preGameBorderSize | States how big the pre-game world border would be, if enabled. | int | Optional, defaults to 100 ; ignored when preGameWorldBorder is false |
Discord Integration
Key | Description | Type | Required? |
---|---|---|---|
enableDiscord | Set to true to turn on Discord integration. Read below for more information. | boolean | Required |
discordToken | Enter the token of your Discord bot here. | string | Required if enableDiscord is true |
ip | The Discord status message portion. Will display as Playing {value} so it's recommended that you make this your server's IP. |
string | Optional |
parseDiscordCommands | Set to true if you want music commands to be run by sending a message in Discord text channels. This allows anyone in your Discord server to run music commands, however. | Optional, defaults to false |
|
discordServerId | The ID of your Discord server that the bot is on. | string | Required if enableDiscord is true |
musicChannelId | The ID of the voice channel that the bot should play music on. | string | Required if enableDiscord is true |
hunterRoleId | The ID of the role to assign to Hunters. | string | Optional |
runnnerRoleId | The ID of the role to assign to Runners. | string | Optional |
spectatorRoleId | The ID of the role to assign to Spectators. | string | Optional |
Note: if any of the role IDs are missing or invalid, no roles will be assigned.
Permissions
Permission | Description | Recommended level |
---|---|---|
minecraftmanhunt.hunter |
Allow /hunter command |
everyone |
minecraftmanhunt.speedrunner |
Allow /speedrunner command |
everyone |
minecraftmanhunt.spectator |
Allow /spectator command |
everyone |
minecraftmanhunt.clearteams |
Allow /clearteams command |
operators |
minecraftmanhunt.start |
Allow /start command |
operators |
minecraftmanhunt.end |
Allow /end command |
operators |
minecraftmanhunt.compass |
Allow /compass command |
everyone |
minecraftmanhunt.music |
Allow /music command. Note that music commands can also be typed in Discord if processDiscordCommands in config is set to true . |
everyone |
minecraftmanhunt.config |
Allow config-changing commands, such as /setheadstart . |
operators |
Music Queues
Part of the fun of this plugin is learning what each music queue means to get a competitive advantage. Here's a list of what causes each track to play.
Distance
The intensity of the music depends on the distance between the runners and the hunters. Tracks are selected at random from the following categories:
- < 50 blocks away: Chasing
- < 150 blocks away: In Sight
- < 300 blocks away: Stealth
- < 450 blocks away: Approaching
- >= 450 blocks away: Far away
Additionally, there is a set of tracks that play if the runners, but not the hunters, are in the Nether.
Special Events
Special tracks play when events related to the game occur. Some events are:
- The runners mine their first iron ore
- The runners mine a diamond ore
- The hunters craft their first piece of iron armor
- The hunters and runners damage each other
- "Chase" music plays if the fighters have a combined total of less than two pieces of armor
- "Fight" music plays if they have more than two pieces of armor
- A hunter dies
- A runner dies
- Both players are in boats
- A runner trades with a Piglin for the first time
- A runner teleports to the end
Troubleshooting
online-mode
in server.properties must be set totrue
as of version 1.2.4.- If you are using Discord integration, make sure your server's system clock is set correctly.
- Check the FAQ Issues page, or report a problem on the Issues tab!
In reply to daniel03__:
Make sure you click holding the compass to open the target select menu! Also, plugin version 1.3.3.2 does not work if your server is in offline mode. Bukkit has not published the latest version yet, so if you are using offline mode, you can download it here.
If this does not work please submit an issue on Github!
In reply to ericyoonicorn:
thanks, i will try
i got everything setup with discord integrations. should the server be online-mode. as i have cracked minecraft and running a server must be on offline mode
In reply to abdou123_damn_:
Sorry, this plugin only works with online mode enabled. I'm working on a fix— follow updates on issue #13 to know when it's implemented!
The bot is leaving and joining the channel. I gave it Administrator permissions and put the correct numbers on the config thingy
In reply to gekougaa:
Hello and thanks for using the plugin! I can't diagnose the issue without seeing your relevant server console logs. Please post the logs your server produces when the error happens here. Or, if you have a Github account, create an Issue here!
29.11 00:40:19 [Server] INFO Gekkougaa issued server command: /speedrunner Gekkougaa
29.11 00:40:20 [Server] INFO Assigning role RUNNER to Gekkougaa
29.11 00:40:21 [Server] INFO Gekkougaa issued server command: /start
29.11 00:40:21 [Server] INFO Assigning role RUNNER to Gekkougaa
29.11 00:40:23 [Server] INFO Thanks for playing!
29.11 00:40:23 [Server] INFO Made by Eric (yoonicode.com)
29.11 00:40:23 [Server] INFO Inspired by Dream (youtube.com/dream)
29.11 00:40:23 [Server] INFO MANHUNT STARTED! Good luck, have fun :D
29.11 00:40:24 [Server] INFO Gekkougaa issued server command: /music auto
29.11 00:40:27 [Server] INFO Loaded track journey
29.11 00:40:27 [Server] INFO Audio track start callback called
29.11 00:40:27 [Server] INFO Started track with a result of true
29.11 00:40:39 [Disconnect] User Gekkougaa has disconnected, reason: Disconnected
29.11 00:40:39 [Server] INFO Gekkougaa left the game
29.11 00:41:33 [Server] INFO Track ended for reason: CLEANUP
29.11 00:41:38 [Server] INFO Loaded track fun
29.11 00:41:38 [Server] INFO Audio track start callback called
29.11 00:41:38 [Server] INFO Started track with a result of true
29.11 00:42:43 [Server] INFO Track ended for reason: CLEANUP
29.11 00:42:49 [Server] INFO Loaded track gatheringresources
29.11 00:42:49 [Server] INFO Audio track start callback called
29.11 00:42:49 [Server] INFO Started track with a result of true
29.11 00:43:53 [Server] INFO Track ended for reason: CLEANUP
29.11 00:43:58 [Server] INFO Loaded track chill
29.11 00:43:58 [Server] INFO Audio track start callback called
29.11 00:43:58 [Server] INFO Started track with a result of true
In reply to gekougaa:
Sorry, I can't seem to reproduce the issue or find what's wrong from the logs you provided. Please open an issue here and paste your full logs in the issue. In the meantime, you might want to try:
I have been trying to use the integrated Music Bot feature for awhile now, but every time I attempt to run the /music auto command in Minecraft I am prompted with an error message the says "Cannot use this command when Discord is disabled" and in red text "An internal error occurred while attempting to perform this command". I have made sure enablediscord is set to true in the config file and have tried to disable and enable it again, but nothing has helped. Config file settings, excluding any sensitive info. If there's is any other information you need I will happily supply it!
Update: The issue was fixed by reinstalling the plugin and bot.
In reply to rafa_riv3ra:
Hello, and thanks for using the plugin! The first thing I can think of is checking your Discord permissions. Make sure your bot has administrator permissions (or, if you'd rather not, the Manage Roles, Send Messages, Read Message History, Connect and Speak to voice, and Use Voice Activity permissions would work). Then, make sure the bot role is above the hunter, runner, and spectator roles you created. If this doesn't work, I'm going to need recent server logs— please paste them here or open an issue on github!
My friends and I attempted to use this yesterday and we had a problem with the compasses. We attempted to do a 1 runner vs 3 hunters and it seemed like only one person at a time would have a functioning compass. We might have done something wrong but I don't think so. No matter how many times we tried selecting the runner it only ever pointed to the world spawn, for 2 of the 3 hunters.
In reply to PhoenicTwitch:
Sorry that you're having trouble with the plugin. Please fill out an issue on Github and include the requested info so I can see what the problem is!
I know how to set up as single player world so my friends can join, but I don't know how to add the plug in for the world. Where do I put the jar file?
In reply to haydnh:
This plugin only works for servers using Bukkit, including Spigot and PaperMC among others. If you're using one of these servers, just drag the .jar into your /plugins folder! Learn more here on the official Bukkit docs.
um... another question (sorry) how can I edit a file? I used notepad++ and it didn't seem to work... do you have a reccomendaition on any file editing app?
I could not understand anything about the bot thingy... can you at least make a video and show?I kinda cannot understand
ps: I'm trying this for more than 2 day... so please help me (oh and the bot thingy is the discord part)
In reply to boreasea:
Hi, and thanks for using the plugin!
To use the Discord integration, you have to create a Bot account within the Discord Developer Portal. Follow the "creating a bot account" of this guide if you need help. Then, edit your plugin config file, setting enableDiscord to true and pasting the discord Bot token in the discordToken field.
After you've done that, you will have to invite the bot to your server. Copy your client ID (DIFFERENT than your bot token— it's under the "general information" tab) from the Developer Portal, and paste it into this website. Add the bot to your server on the Discord webpage it redirects you to. Once the bot shows up in your server, make sure you give it administrator permissions.
Finally, you will need to configure your server a bit. Create a voice channel where the bot will play music in. Then, create three roles: "hunter", "runner", and "spectator" (you need all three even if you don't have any spectators).
The next step will be way easier if you enable Developer mode in Discord by following this guide. Right click on your server then go to Copy ID; paste this in the right field in your config file. Do the same with each of the roles and the voice channel you created.
Hopefully this helps! If you have any questions please reply.
In reply to ericyoonicorn:
um... another question (sorry) how can I edit a file? I used notepad++ and it didn't seem to work... do you have a reccomendaition on any file editing app?
In reply to boreasea:
.yml files are basically just text files. If you're on Windows, you can open it in normal Notepad. If you're on macOS, you can open it in TextEdit.
In reply to ericyoonicorn:
how can I find the config file? I looked at the plugin's files but I could not find a config file, if you help me again I would be more than happy... thanks!
edit: I found them, but again... thank you for your assistance!