Sub topic 10
Hints That Arrive When They Are Needed
Assume you understand a game's core loop and can read basic TypeScript. This chapter focuses on hint timing, escalation, and player control. A hint should help the player continue playing. It should not replace the discovery that makes the mechanic memorable.
Use player behavior as the trigger
A fixed tutorial timer is a weak signal. Players read at different speeds, pause, explore, or already know the mechanic. Instead, watch for evidence that the player needs help:
- They remain near the goal without making progress.
- They repeat the same failed action.
- They look at an interactive object but do not use it.
- They attempt an action that cannot work.
- They stop providing meaningful input.
These signals should be combined with context. A player who is idle while safely exploring may not need help. A player who is idle beside a locked door after several failed attempts probably does.
A useful hint system has three stages:
- Subtle: draw attention to the relevant object or path.
- Specific: describe the useful action without naming every control.
- Explicit: provide the exact input or solution.
Escalate without taking control
The first hint should preserve the player's opportunity to notice a relationship. For example, make a climbable ledge glow briefly before saying, “Jump toward the ledge.” If the player remains blocked, show the required button.
Reset the hint level when the player succeeds, changes objectives, or leaves the relevant context. Do not count every frame as progress. Count meaningful actions and elapsed time only while the player is in a state where the hint applies.
type GameEvent = { type: string; [key: string]: unknown };
type TutorialStep = {
id: string;
isComplete: (event: GameEvent) => boolean;
hints: string[];
};
class TutorialRunner {
private index = 0;
private hintLevel = 0;
private idleMs = 0;
constructor(
private readonly steps: TutorialStep[],
private readonly hintAfterMs = 8000
) {}
onEvent(event: GameEvent): void {
const step = this.steps[this.index];
if (step?.isComplete(event)) {
this.index++;
this.hintLevel = 0;
this.idleMs = 0;
}
}
tick(dtMs: number): string | null {
const step = this.steps[this.index];
if (!step) return null;
this.idleMs += dtMs;
if (this.idleMs < this.hintAfterMs || step.hints.length === 0) {
return null;
}
this.idleMs = 0;
const hint = step.hints[Math.min(this.hintLevel, step.hints.length - 1)];
this.hintLevel++;
return hint;
}
}
const runner = new TutorialRunner([{
id: "jump",
isComplete: event => event.type === "jumped",
hints: [
"Something is blocking the path.",
"Try jumping over the gap.",
"Press Space to jump."
]
}]);
console.log(runner.tick(8000));
runner.onEvent({ type: "jumped" });
console.log(runner.tick(8000));Avoid common hint failures
| Failure | Why it hurts | Better approach |
|---|---|---|
| Hint appears immediately | It prevents discovery | Wait for meaningful struggle |
| Same message repeats forever | It becomes visual noise | Escalate, then stop |
| Hint describes controls only | It teaches buttons without purpose | Explain the goal and action |
| Hint ignores context | It may suggest an impossible action | Check location and game state |
| Hint disappears too quickly | Players may not read it | Keep it visible or repeat safely |
Hints also need accessibility support. Do not communicate essential information through color or a brief animation alone. Pair visual cues with readable text, sound options, and sufficient display time. Let players adjust text size, contrast, timing, and hint frequency where the game permits.
Exercise
A player has stood beside a locked gate for ten seconds but has not tried any action. What should the first hint do?
Show answer
It should draw attention to the gate or a nearby interactive object without immediately stating the exact button. If the player remains blocked, escalate to the action and then the control.