/unreal-dev:unreal-gameplay-frameworkfrom unreal-dev
Guides placement of state across Unreal gameplay classes (GameMode, GameState, PlayerController, PlayerState, Pawn, Character, GameInstance, subsystems). Answers where variables live, why they reset, and what replicates.
Ships in unreal-dev. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them; scripts run unread.
The gameplay framework already has a home for every kind of state: rules on the server, shared state that replicates, per-player state, input, the body in the world, and what survives a level change.
Before adding a member, answer three questions about the class it goes on: on which machines does it exist, does it replicate, and how long does it live. A score on the pawn resets on respawn; a rule's result on the game mode never reaches a client; a value on the game instance is never seen by another player.
| The situation | Read |
|---|---|
| Starting the courier's class set | The class set below, templates/ |
| "Where does this variable go?" | Where state lives below, reference/framework-map.md §2 |
| "Works for the host, not for clients", "resets after respawn", "gone after the next map" | reference/framework-map.md §3 |
| Which game mode runs, default classes, the join and spawn order, possession hooks | reference/spawn-flow.md |
| Moving to the next route: seamless or not, what survives | reference/spawn-flow.md §5 |
Constructor, OnConstruction, BeginPlay, EndPlay: what runs when | reference/actor-lifecycle.md |
| A service with a managed lifetime (per world, per game instance, per local player) | reference/subsystems.md, templates/RouteSubsystem.h |
| Checking a project's classes for misplaced state | scripts/framework_check.py |
| Replicating a property, RPCs, ownership | unreal-replication |
| Input bindings on the character | unreal-enhanced-input |
| Abilities and attributes on the player state or the pawn | unreal-gas |
| Class (template) | Base | Exists on | Replicates | Lives | Courier job |
|---|---|---|---|---|---|
ACourierRunGameMode | AGameModeBase | server only | no | per level | default classes, ParcelsPerRoute, RecordDelivery |
ACourierRunGameState | AGameStateBase | server and all clients | to all | per level | ParcelsOnRoute |
ACourierPlayerState | APlayerState | server and all clients | to all | per player, outlives the pawn; copied on seamless travel | ParcelsDelivered |
ACourierPlayerController | APlayerController | server and its own client | to the owner | per connection | local set-up in BeginPlay when IsLocalController() |
ACourierCharacter | ACharacter | server and the clients it is relevant to | yes | per life | MoveOnRoute, LookAround, the possession hooks |
URouteSubsystem | UWorldSubsystem | each machine | no | per world | the map's drop points |
The game mode wires them in its constructor:
ACourierRunGameMode::ACourierRunGameMode()
{
DefaultPawnClass = ACourierCharacter::StaticClass();
PlayerControllerClass = ACourierPlayerController::StaticClass();
PlayerStateClass = ACourierPlayerState::StaticClass();
GameStateClass = ACourierRunGameState::StaticClass();
bUseSeamlessTravel = true;
}
A Blueprint child of each class (BP_CourierCharacter with the mesh and the input config) is
where content is attached; point the game mode's slots at the Blueprints in its class defaults.
The game mode runs when the project's GlobalDefaultGameMode, a map's GameMode Override or the
?game= option names it (reference/spawn-flow.md §1).
Every replicated value is written on the server and flows outwards: a client's Server RPC on
something it owns asks, the game mode decides (RecordDelivery), and the game state and player
state carry the result to everyone. The templates' SetParcelsOnRoute and AddDeliveries
return early without authority and call the Blueprint reaction on the server themselves, because
a repnotify runs on clients only.
| The state | Home |
|---|---|
| every machine sees it, about the match | game state |
| others see it, about one player, survives the pawn | player state |
| about the body, may reset on respawn | the pawn or a component on it |
| only the server may know or decide it | game mode |
| only this machine needs it (HUD, camera, menu input) | the local player controller or a local player subsystem |
| survives a map change on this machine | the game instance or a game instance subsystem |
| belongs to the loaded map, nobody else receives it | a world subsystem |
PreLogin → Login → PostLogin (OnPostLogin last) →
HandleStartingNewPlayer → RestartPlayer → FindPlayerStart / ChoosePlayerStart →
SpawnDefaultPawnFor → APawn::PossessedBy (server or standalone only) →
SetupPlayerInputComponent.OnRep_Controller,
NotifyControllerChanged (also on the server), AcknowledgePossession, PawnClientRestart,
and the player state through OnRep_PlayerState. Client-side work that needs the player state
waits for OnRep_PlayerState; server-side work that needs the controller goes in PossessedBy.OnConstruction →
PostInitializeComponents → BeginPlay; a map-placed actor goes PostLoad →
PostInitializeComponents → BeginPlay. EndPlay runs on every way out.ServerTravel with bUseSeamlessTravel keeps connections and controllers;
the game state and pawns are new; a player state's members cross only through
SeamlessTravelTo and CopyProperties. Across a non-seamless travel, data rides in the game
instance.GetAuthGameMode() is null on clients): move the
value to the game state or a player state.SeamlessTravelTo /
CopyProperties.GetPlayerState() is null in a client's BeginPlay: use OnRep_PlayerState.The full table, with causes and fixes: reference/framework-map.md §3.
python3 scripts/framework_check.py /path/to/CourierRun
python3 scripts/framework_check.py /path/to/CourierRun --strict # warnings fail too
It maps each UCLASS to its framework role through the base chain and fails on replicated
properties or RPCs on a game mode, a game instance or a subsystem, and on a default-class slot
given a class of the wrong kind; it warns on a player state whose members nothing copies on
travel and on an AGameMode paired with a base game state. Blueprint classes are invisible to it,
and 0 framework classes means nothing was judged. The replication declarations themselves are
checked by unreal-replication's rep_lint.py.
unreal-replicationunreal-enhanced-inputunreal-gasunreal-animationunreal-blueprint-boundaryunreal-cpp-reflectionreference/actor-lifecycle.md (opens in a new tab)reference/framework-map.md (opens in a new tab)reference/spawn-flow.md (opens in a new tab)reference/subsystems.md (opens in a new tab)scripts/framework_check.py (opens in a new tab)templates/CourierCharacter.cpp (opens in a new tab)templates/CourierCharacter.h (opens in a new tab)templates/CourierPlayerController.cpp (opens in a new tab)templates/CourierPlayerController.h (opens in a new tab)templates/CourierPlayerState.cpp (opens in a new tab)templates/CourierPlayerState.h (opens in a new tab)templates/CourierRunGameMode.cpp (opens in a new tab)templates/CourierRunGameMode.h (opens in a new tab)templates/CourierRunGameState.cpp (opens in a new tab)templates/CourierRunGameState.h (opens in a new tab)templates/RouteSubsystem.cpp (opens in a new tab)templates/RouteSubsystem.h (opens in a new tab)What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
unreal-engine, gameplay-framework, game-state, replication, game-mode
Other plugins' skills for the same job
npx claudepluginhub tipoli5890/game-studio --plugin unreal-dev17 skills in this plugin
/unreal-animationUnreal animation: Animation Blueprint or C++ UAnimInstance, NativeUpdateAnimation, montages, slots, sections, notifies and notify states, root motion./unreal-asset-importImport meshes, textures and animation into Unreal by script: AssetImportTask, Interchange pipelines, glTF and FBX options, static or skeletal mesh, budget check./unreal-automation-testsUnreal automation tests: IMPLEMENT_SIMPLE_AUTOMATION_TEST, Automation Spec, latent commands, Automation RunTest on the command line, the JSON report as verdict./unreal-blueprint-boundarySplit Unreal work between C++ and Blueprint: BlueprintCallable, BlueprintNativeEvent, BlueprintImplementableEvent, exposed properties, data assets, soft references./unreal-compile-loopCompile Unreal C++ from a terminal: target, platform and configuration, UnrealBuildTool and compiler errors, Live Coding or a closed-editor rebuild./unreal-config-logsUnreal config and logs: Default*.ini layering, [/Script/...] sections, console variables, UE_LOG categories and verbosity, Saved/Logs, Saved/Crashes.