Payloads first
Define each option through payload parameters, such as tutorial steps, skipping and pacing. Read them with compiled defaults, for exampled.GetInt("steps", 5).
GetDecision always returns a result. A getter returns your default when there is no payload, the key is missing or the value has the wrong type. The same code serves every player: holdout, offline, timed out or tracking disabled.
Use GetInt, GetFloat, GetBool and GetString for scalars; GetIntArray, GetFloatArray, GetBoolArray and GetStringArray for arrays; GetJson(key, default) for nested data.
Payload fields
The model reads each option’s payload as well as which option it is. What it learns about a value then carries to every option that has that value, including options you add later.- Number and yes/no fields: PIO always learns from them.
- Choice, text, list and JSON fields: PIO learns from values that two or more options of the decision share. A value only one option has adds nothing beyond that option itself.
- Lists of numbers reach the game but PIO does not learn from them yet.
Decisions and options
A decision offers a fixed set of options:Tutorial might offer Short, Medium and Long, each with different parameter values. See the quickstart for the SDK naming. The model’s job is choosing among those options per player, using their payload fields.
Action is a label for logs and debugging. Don’t use it to pick behaviour.
Start small. A decision with three to five meaningfully different options learns faster than one with twenty near-duplicates. Add options as you learn which parameter values suit players.
Choose the decision’s default option in the dashboard. Code generation records its key in PioActions.All as the decision’s FallbackAction. Register that fallback when initialising the SDK.