I’ve been meaning to document the Rapua development process. Eight major releases in, this is the first time I’ve written any of it down. If you’re curious about how games in real places can be built and studied, you’re welcome to read along.

Rapua v8 went live today!

Rapua is a platform for building and studying games that people play in real places. Think of quests and scavenger hunts for museums, zoos, cities, and class trips. Players check in with GPS, answer questions, take photos, find passwords and scan codes. I started it as a QR-code hunt during my masters, and I now build it as the research instrument for a future PhD.

Looking back over the first seven releases, the biggest decision that I overturned was using “location” as my core concept. In v8 I swapped locations with objectives and the direction of the project became much clearer. It created opportunities to fix some fundamental issues with what I am building, and the temptation to build something more powerful than I could use or check, if I wasn’t careful. This post is about the decisions and trade-offs between expressiveness and usability.

If you look at the changelog you’ll see that I took seven months of work and touched most features. At the end of it I felt like I was being The Twelve Days of Christmas’d, because swapping locations for objectives meant a new quest builder, objective editor, block editor, frontier exploration model, player view, and a partridge in a pear tree.

I stopped calling everything a location

I moved the platform away from a location being the core concept, as it was when I developed The Amazing Trace, and towards objectives.

There’s an idea in computer science that one of the hardest things to do is name things, and I felt that first-hand. In v7 a location was a place, a task, a proof, a reward and a stop on the route, all at once. It broke down when I tried to introduce things that move around (a book is transient, and so is a person) and tasks that aren’t tied to a place. “Find a red flower with blue thorns” is a different kind of thing to “Go to the pier and find the half-broken post”.

The replacement is the objective, made of a task, some proof and a reveal. Admins build these out of blocks, which are units of content shown to players, like text, a map or a photo upload. Proof is a set of interactive blocks the player completes: scanning a code, answering a question, standing in a circle. The reveal is what they get for it. An objective needs a proof, a reveal, or both.

An objective is a task, then proof, then a reveal. Completing the proof sets a key, and the key opens a hidden block and a locked objective. An objective, and how a key travels out of it.

That model took eight attempts to get right. By my count, more than 40% of v7’s Go, templ and JavaScript was deleted or rewritten along the way, and the number of test files doubled. Renaming one concept cost me most of those seven months, and it gave me a model I can reason about again.

I added keys and locks, and kept them simple

One thing that quests have that scavenger hunts don’t is choices: left or right, the red pill or the blue pill, take a clue or don’t. Rapua can now set keys when a block is completed or a choice is made, and those keys can selectively unlock other content later. At first I wanted keys to hold values like true, 4, or "The quick brown fox" and to be usable in expressions like collected_apples > 3, which would have been really cool. It would have also been stupidly difficult to build, test, and most importantly, use.

It would have made games impossible to check, too. I need to be able to tell whether a player can get stuck, which means constructing every path they can take and looking for dead ends. If keys are on or off, that’s just two things to check (for some definition of “just”). Add a collected_apples that runs from 0 to infinity and it becomes much harder to compute. So I settled on true or false, and once a key is set it can’t be unset. I gave up the expressiveness of arbitrary values and got a game that I can check and a creator can follow. Rapua’s linter already does some of this, and a reachability checker exists as a proof of concept.

The rest is a few rules. Interactive blocks set keys. Static blocks and objectives can stay hidden or closed until their keys are set. Objectives nest inside other objectives (why? because I decided to make it that way), and one with others inside it is a group: a role, not a type. Give each group a routing strategy (ordered, free roam or randomised) and a completion band (like “any two of these four”), and you get games that behave like a graph but read as a list.

Here’s a game I wanted to be able to make: a zoo hunt where every team is dealt one mammal, one bird and one reptile from separate pools and sees one list of three animals. That’s three pass-through groups, which players never see, each randomised and set to deal one animal.

Two teams playing the same zoo game, each dealt a different list Two teams, one game. Same list, different animals.

The whole game is a file you can import into your own Rapua account and change.

Secret belongs to the objective

Secret used to be a routing strategy that hid everything in a group and let players find it, which was a dumb way to do it: to hide one objective you had to wrap it in a secret group inside another group. Now it’s a flag on the objective itself. That kept the expressiveness and simplified it, making it much more usable: setting secret status is one click instead of a new group. I actually removed secrets entirely at one point and then realised they could be brought back but better.

Was the UI rewrite procrastination?

The UI had been on my list for a while, and I had to decide whether rewriting it was procrastination or actually needed. I’ve been pining over the work of an illustrator, Orely, for a while, so my plan was to leave the UI alone until Rapua was profitable enough to commission Orely.

But as the features piled in I wasn’t content with the status quo. Planned features, like history (undoing individual edits), add a new mode of editing, so the UI had to settle before I built them. I decided it was needed, and I used the chance to write out the papercuts I’d found while building the games I want to study (like starter templates on an empty page). The new block builder is easier to use than the old list, even if it asks a little more of you up front.

The same checklist block in v7 and in v8 The same checklist, word for word. The old list is on the left.

I also wanted to make the homepage player-friendly, which meant dropping the marketing copy, which meant I needed a new Creators page. The player UI then needed a refresh to match, then the block templates, the admin UI and the block forms, and here’s the partridge in a pear tree again. The public UI now uses a randomly generated topography and maps of city centres in NZ as motifs, and I like it.

The Rapua homepage in v7 and in v8 The homepage before and after. The new one is for players first.

It’s so much nicer now, but oh how I want Orely to illustrate for me.

Check-ins became events

Nesting objectives broke the old way of tracking progress. Logging a team checking in and out assumes they’re in one place at a time, but nested objectives, and routing strategies at the top level of a game, mean a team can have several open at once. So I replaced the check-in table with an event stream. It records how long an objective took while accepting that a team might be working on several, where the old system could only enforce one at a time. Whether to show one task or group at a time is a pedagogical choice that I would like to study in the future. By using frontier exploration (several groups available at once) the choice now belongs with the admin, and I can (hopefully) build a study around whether that makes a difference to player experiences and outcomes.

What the decisions are for

I originally wanted to research how Alternate Reality Games (ARGs) are designed for science communication by building one. The vision was an adventurers’ board for real places: a wooden board in a botanic garden with quest notices plastered all over it, some quests devilishly hard just for the fun of it.

A wooden display board with paper quest notices attached “Medieval Notice Board” by avelium on Sketchfab, licensed CC BY 4.0. Converted to WebP.

I abandoned that early in my masters as “Out of scope” (a favourite phrase of my supervisor) and built a QR-code hunt instead, which led to a running joke that “I invented QR codes”. v8 is a lot closer to that vision, minus community effects, which are a whole other level of complexity.

The trade-offs above all served one purpose: making Rapua something I can study games with. A game is a file, so versions can be compared and shared. Each run (one team’s playthrough) gets a timeline of events. Place-based learning is hard to study because most of it happens out of sight, and now I have a record of what teams actually did. That lets me compare what routing mechanisms do to learning and reported fun, or watch what player data does to the shape of games over time. From the events I can work out whether each team is active, stalled or abandoned, a rough indicator but better than what I had before, and plot how that changes over time. Aggregate analytics on proofs are still missing, but I have the data now.

I haven’t found an existing tool that lets you run these studies in place-based learning. If you know of one, let me know.

What’s next

History is next: it’s mocked, with a working proof of concept stashed away, and every edit and undo will be an event so you could undo a delete weeks later. After that come worlds, which are collections of quests with their own gating rules, and then the adventurers’ board itself. There are more of these decisions to write down, and now that I’ve started I intend to.