setup/Arena Config
Arena Configuration File
The arena configuration file, arenas.yml, is created when you first run the server with the HGMGS plugin. It is found in "plugins/Hunger Games Map Generator Server" folder. You can edit this file with any text editor. Check the validity of the file's contents here.
IMPORTANT: All settings described here must be under the "arenas.<arena name>" node where <arena name> is the name of the arena you want the settings to apply to.
If a setting is not specified in this file (arenas.yml), the value defined in the config.yml file will be used (except for messages, which will be taken from the language.yml whose name is defined in config.yml).
Arena-Only Settings
Name | Default | Description |
rank | empty | A number determining which arenas will be open as more players are on the server. If 0 or not given, the arena will always be open. Rank 1 arenas will be opened if all rank 0 arenas could be "arenafullpercent" full. All rank 2 arenas will be opened if all rank 1 and 0 arenas could be "arenafullpercent" full, and so on. |
autojoin | empty | When true, players will automatically join this arena when they log in. If this is set for multiple arenas, whichever one is first in the list will be joined. |
generators | empty | A list of the generator files (not including .jar) to choose from when regenerating. |
settingsfiles | empty | A list of the settings files (not including .dat) to choose from when regenerating. |
chestitemsfile | /generators/settings/chestitems.dat | The location of the chest items data file to use when regenerating. |
schematicsfolder | /generators/schematics | The location of the folder to use for schematics when regenerating. |
length | 350 | The length of the arena in blocks. |
width | 350 | The width of the arena in blocks. |
offsetX | 0 | The X-coordinate of the arena's center. |
offsetZ | 0 | The Z-coordinate of the arena's center. |
players | 12 | The number of players the arena can hold (must be 12 or 24 for the default generator). |
vip | empty | True if the arena is a VIP arena and only players with "hg.vip" permission can join. |
worldName | empty | The name of the Bukkit world that this arena should be in. Do not use a world that is already occupied. |
General Settings
Name | Default | Description |
autostart | true | When true, a game will automatically start in this arena when it is full. |
autostartidle | false | When true, this arena will automatically start if no new players have joined in the time set by "idlestarttime". |
idlestarttime | 60 | The number of seconds this arena will wait after a player joins to automatically start. Only used when "autostartidle" is true. |
autoregen | false | When true, will regenerate this arena with a new map once a game is over. |
votetostart | false | When true, allow players to vote for a game to start in this arena. |
minplayers | 5 | Defines the minimum number of players that must be in this arena for the votes to count. |
minvotepercent | 75 | Defines the percentage of players which must vote for the game to start. |
arenafullpercent | 50 | Used for calculating which arenas to open. An arena will be opened if all lower ranked arenas could potentially have "arenafullpercent" percent of their total player count join. 100 = open more arenas only if there are more players on the server than the open arenas can hold. |
countdowntime | 10 | How many seconds to count down between a game starting and the lever pull, releasing the players. |
onGameStartMessages | see config | What messages should be broadcasted to tributes after the countdown. Color codes are allowed. |
graceperiod | 0 | The amount of time after starting a game that PvP in the arena is disabled. Keep the default of 0 for no grace period. |
onGracePeriodOverMessages | '' | The messages to display when the grace period is over. Leave blank for no message. |
onDeathMessage | '' | Text to show when a player (<player>) is killed (<killer>) in an arena (<arena>)1. |
thunderondeath | true | When true, a thunder sound will be played when a player dies to imitate the cannon fire. |
autospectateondeath | false | When true, players will automatically become spectators in this arena after dying in a game. |
compassdistance | 1000 | The maximum distance a compass will be able to locate nearby players in a game. If you wish to disable the compass feature, set this to 0. |
Deathmatch Settings
Name | Default | Description |
usedeathmatch | true | When true, all players will be teleported to a random deathmatch location after "deathmatchtime" seconds. |
deathmatchwarn | 60 | How many seconds before the deathmatch should players be warned of it coming. |
onDeathmatchWarningMessages | see config | What messages to display to the tributes as a warning of the impending deathmatch. |
deathmatchtime | 600 | The number of seconds to wait after a game starts before teleporting players to the deathmatch locations. |
onDeathmatchMessages | see config | The messages to display to players once they are teleported to the deathmatch positions. |
End Game Settings
Name | Default | Description |
useendgame | true | When true, the game will be automatically ended after "endgametime" seconds. |
endgamewarn | 60 | How many seconds before the game is ended should players be warned of it coming. |
onEndgameWarningMessage | see config | What messages to display to the tributes as a warning of the impending game over. |
endgametime | 780 | The number of seconds to wait after a game starts before automatically ending it. |
onEndgameMessages | see config | The messages to display to players when a game is auto-ended in an arena (<arena>)1. |
Event Commands
Name | Default | Description | Variable Support1 |
commands.onKill | empty | Console commands to run when a player (<player>) kills another. | <player> |
commands.onDeath | empty | Console commands to run when a player (<player>) dies. | <player> |
commands.onJoinGame | empty | Console commands to run when a player (<player>) joins a game. | <player> |
commands.onLeaveGame | empty | Console commands to run when a player (<player>) leaves a game either by logging out or using /hg leave. | <player> |
commands.onVote | empty | Console commands to run when a player (<player>) voted for a game to start. | <player> |
commands.onWin | empty | Console commands to run when a player (<player>) wins a game. | <player> |
commands.onJoinSpectate | empty | Console commands to run when a player (<player>) begins spectating. | <player> |
commands.onLeaveSpectate | empty | Console commands to run when a player (<player>) stops spectating. | <player> |
commands.onStartGame | empty | Console commands to run when a game starts. | none |
commands.onStartGamePlayer | empty | Console commands to run for each player (<player>) in the arena when a game starts. | <player> |
commands.onDeathmatch | empty | Console commands to run if/when the deathmatch starts. | none |
commands.onEndGame | empty | Console commands to run when a game ends. | none |
commands.onRegenStart | empty | Console commands to run when an arena begins regenerating. | none |
commands.onRegenEnd | empty | Console commands to run when an arena is done regenerating. | none |
1Commands with variable support will replace the variable listed with the entity related to the event. For example, the "commands.onWin" will replace "<player>" (without quotes) with the name of the player that won before running the commands.
Commands with Permissions
If a command supports use of the <player> variable, it can also have a permission prefix. The syntax for a command would be:
- <permission>; <command>
where <permission> is the permission node that the player must have for the command <command> to be run. If there is no prefix, the command will be run if the player didn't have any of the other command's permissions. Here are a few examples:
- hg.vip; give <player> emerald 10 | Gives the player 10 emeralds if they have the "hg.vip" permission. |
- give <player> arrow 5 - bukkit.command.teleport; give <player> arrow 10 | Gives a player 5 arrows if they don't have the teleport permission and 10 arrows if they do. |