Arenas and Regeneration
Building an arena, saving it as a schematic, and rebuilding it on a timer
An arena is a bounded region of the world, linked to one kit, that regenerates from a saved schematic so a fight never leaves lasting damage.
Arenas in a world manager's world
A world manager such as Multiverse loads its worlds after the plugins are enabled, so when NovaFFA reads your arena files the world an arena names often does not exist yet. That is expected and handled: the arena holds what its file says, the console names the arena and the world it is waiting for, and the arena is filled in and put on its regeneration timer the moment that world loads. Nothing is written out while it waits, so nothing can be lost.
Creating an arena
/ffa arena create <name>Then mark it out:
/ffa arena edit <arena> spawn
/ffa arena edit <arena> corners 1
/ffa arena edit <arena> corners 2spawn is where players land when they join. The two corners define the region FastAsyncWorldEdit saves and rebuilds, stand at opposite corners of the space you want covered.
Linking a kit
/ffa arena edit <arena> link <kit>See Kits. An arena with no linked kit cannot be joined.
Saving and regenerating
/ffa arena regeneration <arena> save
/ffa arena regeneration <arena> regenerate
/ffa arena regeneration <arena> start
/ffa arena regeneration <arena> stopsave takes a schematic of the arena's current state as the clean baseline. regenerate rebuilds it from that schematic immediately. start and stop control the automatic timer.
Regeneration settings
Under arenas.regeneration in config.yml:
| Key | Controls |
|---|---|
time.number, time.unit | How long between one automatic rebuild and the next |
broadcast.recipient | Who sees the rebuild message: arena, everyone, or world:<name> |
broadcast.type | Where it appears: action_bar or chat |
after.teleport_players.enabled | Whether players standing in the arena are moved once it rebuilds |
after.teleport_players.to | Where to: arena (spawn) or lobby |
after.teleport_players.give_kit_again | Whether those players are handed their kit again after being moved |
layers.enabled | Whether the arena is rebuilt a row at a time from the bottom up instead of all at once |
layers.rows | How many rows go down in one step |
layers.delay_ticks | Ticks between one step and the next, 20 ticks being a second |
protect_players.enabled | Whether the rebuild is stopped from hurting the players inside the arena |
protect_players.seconds | How long that protection is held once the blocks are back down |
protect_players.free_stuck | Whether somebody sealed inside the new blocks is lifted out of them |
Rebuilding without interrupting the fight
By default a rebuild drops the whole schematic in one paste and teleports everybody in the arena back to its spawn. That is the quickest way to do it and the surest way to leave nobody buried, but it also ends whatever fight was happening. A server that would rather the fight carried on turns the teleport off:
arenas:
regeneration:
after:
teleport_players:
enabled: falseOn its own that is dangerous. The arena is pasted back whole, air included, so the blocks come back around anybody standing in them and they suffocate. Two settings cover that, and both are read whether or not players are teleported.
Protecting the players
arenas:
regeneration:
protect_players:
enabled: true
seconds: 5
free_stuck: trueWhile a rebuild runs, and for seconds afterwards, the world cannot hurt a player inside that arena: suffocation, falling, fire, lava, drowning and the rest are all held back. Damage from another player is untouched, so a fight carries on through a rebuild rather than turning into a few seconds where nobody can die.
free_stuck then lifts anybody the new blocks sealed in up to the first open space above them, keeping the way they were facing. Somebody the arena has no room for is sent to the arena spawn, which is the only spot known to be clear.
Rebuilding row by row
arenas:
regeneration:
layers:
enabled: true
rows: 1
delay_ticks: 1Turned on, the arena grows back from its bottom row upwards, a row every delay_ticks ticks, rather than landing all at once. The floor goes back under a player before the roof goes back over them, so there is time to walk out of the way, and the rebuild is something players watch happen instead of a single frame where the world changes.
It costs one tick per row at the default settings, so an arena thirty blocks tall takes about a second and a half to come back. Raise rows to put several rows down per step on a tall arena, or delay_ticks to slow it further.
Protecting the blocks
/ffa arena edit <arena> build <on | off>Turn it off and nobody can place or break a block inside the arena. That is the whole of what a region plugin was being drawn around every arena for, and a sword or gapple arena wants it on day one, since nothing in those is meant to be built on in the first place. true and false are accepted in place of on and off.
Breaking and placing are not the only ways an arena gets changed, so the flag covers every hand a player has on the blocks: beds, doors and anything else two blocks tall, a bucket of water emptied on the floor or the arena's own water drained back out, item frames and paintings going up or coming down, and armor stands, boats, minecarts and end crystals being put down. Shooting a painting off a wall from across the arena is caught too, the arrow is followed back to whoever fired it.
What it does not cover is anything that is not a player changing a block by hand. Explosions, fire spread, liquid flow and pistons are left alone, because an arena can want its blocks left standing while explosions still do their damage. Those want flags of their own.
novaffa.arena.build.bypass, op by default, ignores the flag, so an admin can still build the arena they are standing in.
The setting is per arena and lives in that arena's file. arenas.build in config.yml is only the value a newly created arena starts with:
arenas:
build: trueAn arena made before this setting existed has no line of its own, so it falls back to that default and keeps behaving exactly as it did.
The block is what is checked, not the player. Standing a block outside the corners and reaching in is refused the same way, and a block outside the arena is never protected by it.
Both corners name a block, and the arena is every block between them, all of each of them, whatever heights the two corners are at. Corner 1 and corner 2 are meant to be opposite corners of the box, so set the second one somewhere above the height of anything you want the arena to cover, the way you would with any other region.
Premium arenas
/ffa arena edit <arena> premium <on | off>Turning this on requires the joining player to hold novaffa.arena.<arena>, on top of the general permission to use the plugin. There is no default grant for it, an owner grants it per arena, per group or player, through their permissions plugin.
Inspecting, deleting, and testing
/ffa arena info <arena>
/ffa arena delete <arena>
/ffa arena teleport <arena>teleport is an admin shortcut to the arena's spawn, without going through the fight menu or handing out a kit.