All work

Open source

Atlas: Avicus's XML-driven match engine

The open-source Minecraft match engine behind Avicus, where maps written in XML become modules, phases and objectives. I directed it and built much of it.

Open source · Avicus · 2017 – 2024

The problem

Every map on Avicus was its own game: teams, objectives, spawns, kits and rules that changed partway through a match. Map makers needed to describe all of that without writing Java, and the engine had to turn their description into a running match.

What I built

The Atlas README credits me with project direction, feature work and converting it into a standalone project. Some of what I built:

  1. Map XMLincludes and conditionals
  2. ModuleFactoriessorted, build modules
  3. Matchmodules registered
  4. Phase countdownboss bar near the end
  5. Applypass, retry or fail phase

How a phase applies

A sketch of the idea, not the production code.

countdown(phase.delay):
    on_tick(remaining):
        if remaining < 5 minutes: boss_bar.show(phase.message, remaining)
        else: boss_bar.clear()
        if should_broadcast(remaining): chat + sound

    on_end():
        failed = objectives.filter(o -> not phase.should_apply(o))
        if failed.empty:
            broadcast(phase.success); apply(phase.materials, objectives)
            return phase.pass_phase.map(next -> countdown(next.delay, next))
        retry = failed.filter(o -> attempts(o) < phase.retry_attempts)
        if retry and phase.retry_delay:
            return countdown(phase.retry_delay, phase, retry)
        broadcast(phase.fail)
        return phase.fail_phase.map(next -> countdown(next.delay, next))

Why it matters

Map makers could build whole new game types in XML, and a match could change itself as it went on without anyone touching code.

Stack

Links