Rules

A rule is how you say what you mean in the dashboard, without writing any code. It is built from two things: what a player has done, and what is true about them.

You pick the events and attributes, the amounts and the stretch of time, and the dashboard reads it back as a sentence:

How many times Lesson completed happened is at least 3, in the last 7 days and the player's Plan is “premium”

One thing they did, one thing that is true about them.

Rules do two jobs, and the difference matters:

  • What finishes something. A mission's objectives, and what keeps a streak alive.
  • Who it is for. Everyone, or the players you choose with a rule. The rest either never see it, or see it locked, whichever you choose.

A rule you expect to use more than once is worth saving as a segment instead of writing it again.

Who gets in stays in

A rule that says who something is for is checked once, when the player first joins it:

  • A mission, the first time they qualify for it.
  • A streak, on the first day that counts for them.
  • A leaderboard, the first time they score in a period. The next period checks again.

After that they are in, and they stay in even if they stop matching. A player who leaves a segment keeps the mission they already started.

The shop is the exception. A listing checks the rule at every purchase, so a player who stops matching stops being able to buy.

Re-checking a rule after the fact is not possible today. It is planned.

On this page