Racing minigame! Get from point A to point B as fast as possible!
Multi-Arena or bungee support.
Achievements.
Win fireworks & effects.
Checkpoint effects.
MySQL, Flatfile or SQLite support.
Most game messages are configurable.
Custom and configurable signs.
Save and restore player inventory, levels and more.
API with Game events.
Visibility system.
NoteBlockAPI for .NBS Game sounds! Play with custom different musics per map!
1 Winner, 3 positions, 2 and 3 positions will receive half of win coins.
Win & checkpoints rewards.
MCJukeboxsupport! Play a real music with MCJukebox.
Leaderboards and Map Records!
Custom pads.
Leveling Up/Ranking System.
Bugs
I can't fix problems if I don't find them! If you have any issues, report via discussion or private message. Do not use the rating area to report bugs or request features. Please go to discussion.
Required permission:
sr.admin First of all set global spawn using
/sr setgspawn
Step by step tutorial
Create your arena - /sr create <name>.
Set arena waiting lobby - /sr setlobby <name>
Add spawn - /sr setspawn <name>
Set min players - /sr setMinPlayers <name> <amount>
Set max players - /sr setMaxPlayers <name> <amount>
Select the checkpoint area the checkpoint tool - /sr addCheckpoint <name>
Use /sr cptool to get the checkpoint tool, it work as the same way as WorldEdit.
Put the block on your hand - /sr addblock <name>
Finish the arena with - /sr finish <name>
The last checkpoint will be the win point (
if player got all of the map checkpoints)
Sign format:
[SpeedRun]
join
ArenaName
Racing Mode (BETA, NEW!)
If you don't want to have a map where players go from A to B, you can setup a map with a lap system.
Note that due limitations on how the plugin works for the normal mode, the score system will not used for racing mode for now, maybe in the future.
Player spawn should be before start and finish lines, see the layout below.
Checkpoints are still necessary so players can't cheat the race.
Checkpoint (data and checkpoint amount) will reset to 0 after completing a lap to start couting again
Racing mode uses the alternative win method where players have a few seconds to also finish the course.
Placeholders (Scoreboard):
%laps%
%laps_total%
Arena setup tutorial:
/speedrun setRacingMode <map> <true/false>
Required for the arena to be loaded as a Race map, other commands will not work on the arena without the map set to Racing mode.
With the area selected with /sr cptool /speedrun setStartLine <map>
With the area selected with /sr cptool /speedrun setFinishLine <map>
/speedrun setLaps <map> <amount>
If you are editing the arena just use the /sr finish <arena> to apply the changes, otherwise finish the setup with the other setup commands.
Arena layout example:
Checkpoint commands
To add a command to a checkpoint, you'll need the checkpoint ID. The ID system starts from 1, not 0. The first checkpoint has ID=1.
If you are not sure what is the checkpoint ID of the checkpoint you want to add the command, you can use
/sr nearbyCheckpoint
This will send you a list of nearby checkpoints in a 15 block area. Get as close as possible of the p1 of your checkpoint and use the command. Or you can just check the coords at your map file and compare.
Now that you have the ID you can just use
/sr addCheckpointCommand <game> <ID> <command>
The command does not need to have the slash (/)
Command has the %player% placeholder.
Done! To load the changes, finish your arena again (
/sr finish <game>) and you are set. Please do test your checkpoints to make sure they are executing in the correct place.
Vehicles
Players can use vehicles.
To enable this feature, set
Vehicles.Enable-Vehicles to true.
To add vehicles to your arena, you must use
/speedrun setVehicle <arena> <type>
Types: Horse, Boat, All
All will give the items for both vehicle types
Fun trick with the boat! You can gain speed and height with the boat if you click the item while looking up, you can disable this by setting the
Vehicles.Boat.Boost-When-Looking-Up to false.
You can force a player to use a certain vehicle inside a certain location, you can also force to dismount and disable vehicles.
There are 3 systems; Boat, Horse and Walk, select the area with /sr cpt and use
/sr addHorseArea <arena>
/sr addBoatArea <arena>
/sr addWalkArea <arena>
Inside those areas the player cannot dismount from the vehicle type of the area and cannot mount if the area is walk.
For this to work, check your settings
Vehicles.Check-Areas, set to true
Optionally,
Options.Mounts-Ignore-Y, true by default, ignores Y (recommended)
Leveling Up System
Disabled by default. Enable it at options.yml.
When enabled, a new file will be generated, levels.yml, with this file you will be able to add your levels, rewards and more:
Code (Text):
Levels:
Level-1: #Do not change the Level-1 section
exp: 0 #Required Exp
display-name: "&6Level 1" #Display name in level up message
prefix: "&6[1]" #Chat prefix, if enabled, hooked to PAPI
commands-to-execute: [] #Commands to execute when reaching the level
level-up-message: [] #Message to display
Level-2: #From now on you can change
exp: 10
display-name: "&6Level 2"
prefix: "&6[2]"
commands-to-execute:
- speedrun coins add %player% 100
level-up-message:
- '&7&m--------------&7[&6&lSPEEDRUN&7]&m--------------'
- ''
- '&a&lLevel Up &e&l%level%'
- ''
- '&9Next level: &b%next_level% &7(%until_next_level%/%next_level_exp% EXP)'
- ''
- '&7&m-------------------------------------'
Level-3:
exp: 20
display-name: "&6Level 3"
prefix: "&6[3]"
commands-to-execute:
- speedrun coins add %player% 100
level-up-message:
- '&7&m--------------&7[&6&lSPEEDRUN&7]&m--------------'
- ''
- '&a&lLevel Up &e&l%level%'
- ''
- '&9Next level: &b%next_level% &7(%until_next_level%/%next_level_exp% EXP)'
- ''
- '&7&m-------------------------------------'
Please do not change Level-1 as it is the default Database value, you can just use display-name to not show "Level-1" in game, the section name is just a backend thing.
Note that the reload command will not apply changes for levels.yml ATM.
How to Earn Exp
Players can earn Exp by playing, getting checkpoints and winning the game, check options.yml and you will see a new Exp section to modify.
Give Exp to old players
Set
Options.Leveling-System.Update-Levels to true in options.yml, when a player joins the server after this update, players will get exp based on wins, games played and kills/assists.
What if I don't want to use Leveling system?
Just don't enable the option. Everything will work just fine without it.
Example: {sr_wins_1} will return player with most wins.
{sr_wins_2} etc
The message can be modified at Leaderboard.Messages.Wins-Format Use the placeholders %player% for the player %wins% for the win amount and %position% for the position.
{sr_checkpoints_number}
Example: {sr_checkpoints_1} will return player with most checkpoints
{sr_checkpoints_2} etc
The message can be modified at Leaderboard.Messages.Checkpoints-Format Use the placeholders %player% for the player %checkpoints% for the checkpoint amount and %position% for the position.
{sr_records_map_position}
{sr_records_sr1_1} will return the player with the best time on the map sr1.
{sr_records_sr1_2} etc
The message can be modified at Leaderboard.Messages.Map-Record-Format. Use the placeholders %time% for time in milliseconds, %formatted_time% for mm:ss, %map% for the Map name and %position% for the position.
/sr setspawn <name> - Set the arena spawn (like a first checkpoint, where players will be teleported when game starts and if they failed and haven't a checkpoint yet.)
/sr setMinPlayers <name> <amount> - Min of players to start the game.
/sr setMaxPlayers <name> <amount> - Max of players.
/sr cptool - Area Selecting Tool.
/sr addcheckpoint <name> - Add a game checkpoint, players may not win the game without going through this checkpoint!
/sr addblock <name> - Add a block (Item in your main hand) that the player can step, if someone step in a block that isn't on this list he will be teleported to the his last checkpoint.
/sr finish <name> - Reloads the arena and finish the setup. Note: This command can be used everytime.
/sr setgspawn - Set the global spawn where players will be teleported when game ends.
/sr leaderboard - Update the Leaderboards and player data.
/sr start <arena> - Start a game.
/sr stop <arena> - Stop a game.
/sr config - Update settings.yml.
/sr coins - Edit the balance of a player.
/sr join <name> - Join in a game.
/sr quit - Left the game.
/sr stats - See your stats.
Cosmetics (Player Trails)
Players can unlock special Trail Effects on the Trails Shop. Example of a trails.yml file:
The number is the ID and will be saved in Database.
name: The display name in menu.
buyPermission: The player needs to have this permission to buy an trail/effect.
permission: The trail/effect that the player with the buyPermission will purchase.
1: #The pad ID
Material: REDSTONE_BLOCK #The block type
Data: 0 #The block data (e.g red wool you will set Material to WOOL and data to 14)
Boost-Options:
Enabled: true #If enabled this will be a boost block.
Multiply-Forward: 3.5
Multiply-Y: 0.8
Trap-Options:
Enabled: false #If enabled this will be a trap block.
Effects: #PotionEffects from the block.
Type: NONE #If "NONE" this will disable the block from giving any effect.
Duration: 0 #duration in ticks (20 = 1 sec)
Amplifier: 0 #potion effect amplifier
Custom-Action: "NONE"
Custom actions: BACK_TO_SPAWN and BACK_TO_CHECKPOINT
BACK_TO_SPAWN will send the player to the arena spawn. This will not reset the checkpoints so you can back to your last checkpoint.
BACK_TO_CHECKPOINT will force player to fail, sending back to last checkpoint.
/**
* Get player data from player.
*
* @param bukkitPlayer - The player.
* @return GamePlayer - The player data.
*
*/
public GamePlayer getPlayerData(Player bukkitPlayer);
/**
* Get player data from name.
*
* @param name - The Player name.
* @return GamePlayer - The player data.
*
*/
public GamePlayer getPlayerData(UUID uuid);
/**
* Get player data from UUID.
*
* @param uuid - The UUID.
* @return GamePlayer - The player data.
*
*/
public GamePlayer getPlayerData(String name);
/**
* Get player a game from name.
*
* @param name - The map name.
* @return Game - The game.
*
*/
public Game getGame(String name);
/**
* Get player a game from a player.
*
* @param GamePlayer - The game player.
* @return Game - The game.
*
*/
public Game getGame(GamePlayer fromPlayer);
/**
* Send a updated data to Database (MySQL, SQLite or YAML)
*
* @param players - Players to save
*
*/
public void saveData(Player... players);
/**
* Get the music from the game.
*
* @return Music - the GameMusic class
*
*/
public Music getGameMusic(Game fromGame);
/**
* Send a plugin message to a channel via BungeeCord's channel and SpeedRun's subchannels.
*
* @param player - The player sending the message -- Player must be online.
* @param server - The target server.
* @param key - Your key to listen the message.
*
*/
public boolean forwardData(Player player, String server, String key);
/**
* Get the wins leaderboard;
*
* @return The list of avaliable data.
*/
public List<Entry<String, Integer>> getWinsLeaderboard();
/**
* Get checkpoints leaderboard;
*
* @return The list of avaliable data.
*/
public List<Entry<String, Integer>> getCheckpointsLeaderboard();
/**
* Get offline player data.
*
* @param name - The player name
* @return Offline player data
*/
public OfflineGamePlayer getOfflineGamePlayer(String name);
@EventHandler
public void onGameStart(GameStartEvent event) {
event.getGame().sendGameMessage("Game started!");
}
@EventHandler
public void onGameEnd(GameEndEvent event) {
GamePlayer p = event.getPlayerFromPosition(1);
event.getPlayerFromPosition(2).getP().sendMessage(p.getName() + " is better than you!");
}
wins:
'1':
enabled: true
display-name: '&8&lIt''s my first win!'
description: '&7First speedrun win.'
commands:
- eco give %player% 150
games:
'3':
enabled: true
display-name: '&b&lI love this game!'
description: '&7Play a total of 3 speedrun games.'
commands:
- eco give %player% 250
checkpoints:
'5':
enabled: true
display-name: '&b&l/checkpoint'
description: '&7Get a total of 5 checkpoints.'
commands:
- eco give %player% 200
deaths:
'5':
enabled: true
display-name: '&b&lNever give up!'
description: '&7Get a total of 5 Fails!'
commands:
- eco give %player% 50
Code (Text):
Storage:
Database-Version: '1.1'
Type: SQLite
MySQL:
Host: localhost
Port: '3306'
User: user
Password: '123456'
Database: database
Update-Interval: '5'
Timer-Leaderboard-Delay: '3'
Leaderboard-Loading-Delay: '160'
Locations:
spawn: ''
Leaderboard:
Data-Limit: '10'
Messages:
No-Data: '&7Waiting...'
Calculating: '&7Calculating...'
Wins-Format: '&e%position%. &b%player% &7- &e%wins% &7wins'
Checkpoints-Format: '&e%position%. &b%player% &7- &e%checkpoints% &7checkpoints'
Map-Record-Format: '&e%position%. &b%player% &7- &e%formatted_time% &7seconds'
Options:
Bungee:
Enabled: 'false'
Lobby-Server: lobby
Server-Name: sr1
Join-Next-Available-Game: 'false'
Enable-Checkpoint-Particles: 'true'
Checkpoint-Particles: FIREWORKS_SPARK
Default-GameMode: SURVIVAL
Whitelisted-Commands:
- sr
- tell
- r
PreStart-Countdown: '35'
Time-After-Game: '8'
Grace-Time: '5'
Use-Vault: 'false'
Disable-WorldEdit: 'false'
Enable-Rewards: 'false'
Enable-Solo-Play: 'false'
Enable-Speed-Effect: 'true'
Enable-Jump-Effect: 'true'
Enable-Fall-Damage: 'false'
Ignore-Damage-Events: 'false'
Extra-Fall-Damage: '0.0'
Enable-PvP: 'false'
Enable-PvE: 'false'
Potion-Effects:
- 'REGENERATION : 1000 : 1'
Position-Placeholder-Limiter: '3'
Enable-Bungee-Rewards: 'false'
Use-MC-Jukebox: 'false'
Use-Musics: 'true'
Use-WinFirework-Party: 'true'
Per-Arena-Chat: 'true'
Use-Titles: 'true'
Save-Inventory: 'true'
Use-Action-Bar: 'true'
Draw-When-Timeout: 'true'
Use-Map-Records: 'true'
Use-Timer-Leaderboard: 'true'
Update-Personal-Records: 'true'
Send-All-Data-To-Database: 'false'
Disable-Block-Check: 'false'
Use-Block-Blacklist: 'false'
Use-2-Place-As-Loss: 'false'
Use-3-Place-As-Loss: 'false'
Max-Game-Length: '-1'
Checkpoint-Velocity-Booster:
Enable: 'false'
Multiply-Forward: '1.5'
Multiply-Y: '0.8'
Titles:
Fade-In: '8'
Stay: '28'
Fade-Out: '5'
Economy:
Coins-Per-Win: '250'
Coins-Per-Map-Record: '100'
Coins-Per-CheckPoint: '25'
Messages:
Join: '&7%player% &ejoined the game. (&7%players%&e/&7%maxplayers%&e)'
Left: '&7%player% &eleft the game. (&7%players%&e/&7%maxplayers%&e)'
Chat-Format: '&7%player_name%: &r%message%'
Jukebox-Command: '&e&lClick on the message below to play a music!'
Already-Started: '&cThis game already started!'
Already-InGame: '&cAlready playing!'
No-Permission: '&cNo permission!'
Game-Is-Full: '&cThis game is full!'
CannotJoin: '&cThis game already started!'
Player-Checkpoint: '&6&lYou got a checkpoint!'
Visibility-Players-Enabled: '&6&lPlayers are now visible.'
Visibility-Players-Disabled: '&6&lPlayers are now invisible.'
Teleport: '&aTeleported!'
Starting: '&eThe game starts in &b%time% &eseconds.'
Game-Started: '&e&lGame started! Run!'
Win: '&7You got the %position% position! You need to wait %count% other players
finish off the map.'
CommandFailed: '&cYou cannot use commands while playing speedrun!'
Countdown-Canceled: '&cNot enough players to start the game, countdown &lCANCELED.'
Game-Canceled: '&cGame canceled by an Administrator.'
Empty: '&7empty'
Empty-Time: '&7empty time'
Testing-Mode-Broadcast: '&eYou''ve been kicked from the game. &cReason: &eThis game
is now on testing mode.'
Testing-Mode-Game: '&c&lThis game is on testing mode!'
Grace-Time: '&eThe game starts in &c%time% &esecond(s).'
Trap: '&cYou fall into a trap!'
Boost: '&cYou stepped on a boost pad!'
Last-Checkpoint: '&b&l%player% &e&bis close to the finish line!'
Record: '&cYou broke the map record!'
Almost-Record: '&cYou were %time% seconds from breaking %player%''s map record (%record%).
Keep playing to break the record!'
Personal-Record: '&cYou broke your personal record! %record% is your new best time
on this map!'
Achievement:
- '&7&m---------------&7[&6&lACHIEVEMENT&7]&m---------------'
- ' '
- '%name% - %description%'
- ' '
- '&7&m----------------------------------'
GameStart:
- '&7&m---------------&7[&6&lSPEEDRUN&7]&m---------------'
- ' '
- '&7Run!'
- "&6&l\u266b Now playing: &e&l%song_name% &6&l\u266b"
- ' '
- '&7&m----------------------------------'
GameEnd:
- '&7&m---------------&7[&c&lSPEEDRUN&7]&m---------------'
- ' '
- '&71: &6%winner_1% &7with &6%timer_1%'
- '&72: &6%winner_2%'
- '&73: &6%winner_3%'
- ' '
- '&7&m----------------------------------'
GameEnd-Record:
- '&7&m---------------&7[&c&lSPEEDRUN&7]&m---------------'
- ' '
- '&71: &6%winner_1% &7with &6%timer_1% &c&lNEW RECORD!'
- '&72: &6%winner_2%'
- '&73: &6%winner_3%'
- ' '
- '&7&m----------------------------------'
GameEnd-Draw:
- '&7&m---------------&7[&c&lSPEEDRUN&7]&m---------------'
- ' '
- '&c&lDRAW!'
- ' '
- '&7Game ran out of time'
- ' '
- '&7&m----------------------------------'
Player-Stats:
- '&7&m---------------&7[&c&lSPEEDRUN STATS&7]&m---------------'
- ' '
- '&8Games Played: &b%games_played%'
- '&8Wins: &b%wins%'
- '&8Losses: &b%losses%'
- '&8Fails: &b%fails%'
- '&8Checkpoints: &b%checkpoints%'
- '&8Balance: &b%balance%'
- ' '
- '&7&m----------------------------------'
Enough-Money: '&cYou don''t have enough money to buy this!'
Titles:
Titles:
Join: '&eYou are playing on map:'
Left: '&eYou left the game'
Grace-Time: ''
Title:
Starting: '&eGame starts in:'
Checkpoint: '&e&lCHECKPOINT!'
Subtitle:
Starting: '&e&l%countdown%'
Subtitles:
Join: '&b%mapname%'
Left: ''
Player-Eliminated: '&7has eliminated!'
Grace-Time: '&c&l%time%'
Checkpoint: '&6&l%checkpoints%&f/&b&l%all_checkpoints%'
ActionBar:
Format: '&c&l%timer% &e&l| &c&l%score% &e&l| &c&l%checkpoints%&r/&b&l%all_checkpoints%'
Sign:
Line:
'1': '&7[&cSpeedRun&7]'
'2': '%state%'
'3': '%mapname%'
'4': '%players%/%maxplayers%'
State:
Waiting: '&aWAITING'
Starting: '&6STARTING'
InGame: '&cIN GAME'
Ending: '&4ENDING'
Motd:
State:
Waiting: '&aWAITING'
Starting: '&6STARTING'
InGame: '&cIN GAME'
Ending: '&4ENDING'
Scoreboard:
Lobby-Title: '&e&lSPEEDRUN'
Lobby-Format:
- ' '
- 'Map: &a%mapname%'
- 'Players: &b%players%/%maxplayers%'
- 'Needed: &b%minplayers%'
- ' '
- 'State: %capitalize_state%'
- ' '
- 'Balance: &a%balance%'
- ' '
- yourserver.com
Game-Title: '&e&lSPEEDRUN'
Game-Format:
- ' '
- 'Your timer: &a%timer%'
- ' '
- 'Runners: &a%players%'
- 'Checkpoints: &b%checkpoints%&r/&a%all_checkpoints%'
- ' '
- 'Fails: &b%deaths%'
- 'Score: &b%score%'
- ' '
- 'Map: &b%mapname%'
- yourserver.com
Position-Placeholder: '%player% &7- &b%score%'
Sounds:
Checkpoint: ENTITY_PLAYER_LEVELUP:0.2
Starting: UI_BUTTON_CLICK:0.2
Boost-Pad: ENTITY_ENDERDRAGON_FLAP:1
Trap-Pad: ENTITY_PLAYER_BREATH:1
Items:
Leave-Item:
Use: 'true'
Name: '&c&lLeave'
Type: BED
CheckPoint-Item:
Enabled: 'true'
Name: '&6&lCheckpoint'
Type: MAGMA_CREAM
Players-Showing-Item:
Enabled: 'true'
Name: '&eVisibility &c&l(Showing)'
Showing-Item:
Type: EYE_OF_ENDER
Players-Hidden-Item:
Name: '&eVisibility &c&l(Hidden)'
Hidden-Item:
Type: ENDER_PEARL
Rewards:
Win-Commands:
- eco give %player% 100
Record-Commands:
- eco give %player% 150
Position2-Commands:
- eco give %player% 50
Position3-Commands:
- eco give %player% 25
CheckPoint-Commands:
- eco give %player% 150