Progression Events
The Progression Events plugin emits the canonical level lifecycle events — levelStarted, levelCompleted, levelFailed, levelAbandoned, levelContinued — with one call each. It also tracks the active LevelSessionId and the user’s main-map progression and auto-attaches them to every outgoing analytics event.
Install
Add to your Packages/manifest.json dependencies (the Tactile scoped registry must already be configured):
"com.tactilegames.playops-plugins.progression": "1.1.0"Access
var progression = playOps.Analytics().Progression();Methods
| Method | Description |
|---|---|
LogLevelStarted(int levelNumber) | Emits levelStarted and starts a new level session. A fresh LevelSessionId is generated automatically. |
LogLevelCompleted(int? levelSecondsPlayed = null) | Emits levelCompleted and closes the active session. |
LogLevelFailed(int? levelSecondsPlayed = null) | Emits levelFailed. The session stays open so a follow-up LogLevelContinued reuses the same LevelSessionId. |
LogLevelAbandoned(int? levelSecondsPlayed = null) | Emits levelAbandoned and closes the active session. |
LogLevelContinued() | Emits levelContinued mid-session. The session stays open. |
SetUserProgression(int userProgression) | Updates the user’s main-map progression value. Call on boot from authoritative save data and whenever the value changes. |
levelSecondsPlayed defaults to wall-clock seconds since LogLevelStarted — pass an explicit value when the game subtracts paused or background time.
Examples
Boot
Set the user’s current main-map progression from your save data so it attaches to every event the session emits:
var progression = playOps.Analytics().Progression();progression.SetUserProgression(saveData.MainMapLevel);Happy path
progression.LogLevelStarted(levelNumber: 12);// gameplay …progression.LogLevelCompleted();progression.SetUserProgression(13);Fail and continue
progression.LogLevelStarted(12);// player runs out of movesprogression.LogLevelFailed(); // session stays open// player watches a rewarded adprogression.LogLevelContinued(); // same LevelSessionId// player winsprogression.LogLevelCompleted();Abandon
progression.LogLevelStarted(12);// player quits to the main menuprogression.LogLevelAbandoned();Explicit active gameplay seconds
Pass an explicit value when the game already tracks active-only time (excluding pause/background):
progression.LogLevelCompleted(levelSecondsPlayed: activeGameplaySeconds);