unreal-multiplayer
Skill4 starsChanged 3 months agoMITView on GitHub
Build Actor replication, GameMode/GameState architecture and server-authoritative gameplay. Use when building Unreal networking, actor replication, or RPCs.
In this repository47 other files it gives its agents.
- anti-cheatSkill
- blender-add-on-engineerSkill
- blender-animationSkill
- blender-modelingSkill
- blender-toolingSkill
- game-aiSkill
- game-audio-engineerSkill
- game-audioSkill
- game-build-pipelineSkill
- game-designerSkill
- game-designSkill
- game-ideationSkill
- game-monetization-designerSkill
- game-monetizationSkill
- game-performanceSkill
- game-uiSkill
- game-version-controlSkill
- godot-gameplay-scripterSkill
- godot-multiplayer-engineerSkill
- godot-shader-developerSkill
- level-designerSkill
- level-designSkill
- narrative-designerSkill
- narrative-designSkill
- playtest-feedback-analyzerSkill
- playtestingSkill
- production-planningSkill
- roblox-avatar-creatorSkill
- roblox-experience-designerSkill
- roblox-systems-scripterSkill
- tech-artSkill
- technical-artistSkill
- unity-architectSkill
- unity-architectureSkill
- unity-editor-tool-developerSkill
- unity-multiplayer-engineerSkill
- unity-multiplayerSkill
- unity-shader-graph-artistSkill
- unity-shadersSkill
- unity-toolingSkill
- unreal-multiplayer-architectSkill
- unreal-systems-engineerSkill
- unreal-systemsSkill
- unreal-tech-artSkill
- unreal-technical-artistSkill
- unreal-world-builderSkill
- unreal-worldsSkill
The file
We split this skill into the rules it gives an agent
1 rule. About 0 are common, 0 are distinctive, and 1 is very specific to this project.
≈0
Common · estimate
Many files like this have a rule of this kind.
≈0
Distinctive · estimate
This author's own choices. Worth a look.
1
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Very specific: line 49
Must implement _Validate (Security gate) and _Implementation:
≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
unreal-multiplayer
Core Philosophy
Unreal Engine was built from its inception in 1998 as a multiplayer tournament engine. Networking in Unreal is deeply opinionated: it centers around a strict Server-Authoritative Client-Server architecture orchestrated by the GameMode, GameState, PlayerState, and PlayerController classes. The server runs the definitive physical simulation; clients are visual and audio playback terminals that send player intent. Master Unreal multiplayer by understanding the Actor Replication lifecycle, property replication with DOREPLIFETIME, and the strict division between Multicast, Client, and Server RPCs.
4-Step Unreal Multiplayer Architecture
Step 1: The Core Gameplay Framework Classes
- GameMode (Server Only):
- Exists exclusively on the authoritative server. Defines match rules, win conditions, player spawning (
SpawnDefaultPawnAtTransform), and score tracking. Never replicated to clients.
- Exists exclusively on the authoritative server. Defines match rules, win conditions, player spawning (
- GameState (Server $\to$ All Clients):
- Replicated to all machines. Tracks match state (Round time, Team scores, Match phase: WaitingToStart, InProgress, PostMatch).
- PlayerState (Server $\to$ All Clients):
- Replicated to all machines. Tracks individual player attributes (Player Name, Ping, Kills, Current Score).
- PlayerController (Server $\leftrightarrow$ Owning Client):
- Exists on the server and the specific owning client. Handles input translation, UI HUD management, and secure Server RPC communication.
Step 2: Actor & Property Replication (DOREPLIFETIME)
- Actor Replication Setup:
bReplicates = truein constructor.SetReplicateMovement(true)for physical actors.
- Replicated Properties (
ReplicatedUsing):- Replicate variables using
UPROPERTY(ReplicatedUsing = OnRep_Health). - Implement
GetLifetimeReplicatedProps:void ACharacterBase::GetLifetimeReplicatedProps(TArray<FLifetimeProperty>& OutLifetimeProps) const { Super::GetLifetimeReplicatedProps(OutLifetimeProps); DOREPLIFETIME(ACharacterBase, Health); DOREPLIFETIME_CONDITION(ACharacterBase, SecretInventory, COND_OwnerOnly); }
- Replicate variables using
- RepNotify Functions:
OnRep_Health()executes automatically on clients whenever the server updatesHealth.
Step 3: Remote Procedure Call (RPC) Classification
- Server RPC (
Server, Reliable, WithValidation):- Called by Owning Client $\to$ Executed on Server.
- Must implement
_Validate(Security gate) and_Implementation:bool AWeapon::ServerFire_Validate(FVector AimDir) { return AimDir.IsNormalized(); } void AWeapon::ServerFire_Implementation(FVector AimDir) { /* Authoritative Fire */ }
- Client RPC (
Client, Reliable):- Called by Server $\to$ Executed on Owning Client only (e.g. ClientShowHitMarker).
- NetMulticast RPC (
NetMulticast, Unreliable):- Called by Server $\to$ Executed on Server and all simulated clients (e.g. MulticastPlayExplosionFX).
Step 4: Network Relevancy & Dormancy Optimization
- Network Relevancy (
IsNetRelevantFor):- Actors beyond view distance or hidden behind terrain are not replicated to distant clients, conserving network bandwidth.
- Net Dormancy (
DORM_DormantAll):- Static or rarely changing world actors (chests, switches) are set dormant until an event wakes them up, saving server tick budget.
Deliverable Format: Authoritative Server-Validated Weapon Firing (C++)
// Weapon.h
#pragma once
#include "CoreMinimal.h"
#include "GameFramework/Actor.h"
#include "Weapon.generated.h"
UCLASS()
class AWeapon : public AActor {
GENERATED_BODY()
public:
AWeapon();
UPROPERTY(ReplicatedUsing = OnRep_AmmoCount, BlueprintReadOnly)
int32 AmmoCount;
UFUNCTION()
void OnRep_AmmoCount();
UFUNCTION(Server, Reliable, WithValidation)
void ServerFire(FVector_NetQuantize TraceStart, FVector_NetQuantizeNormal AimDir);
UFUNCTION(NetMulticast, Unreliable)
void MulticastSpawnMuzzleFX();
protected:
virtual void GetLifetimeReplicatedProps(TArray<FLifetimeProperty>& OutLifetimeProps) const override;
};Worked Example: Mitigating Dedicated Server Bandwidth Saturation
- Context: A 32-player Unreal shooter was experiencing severe packet drops and server tick degradation down to 14 Hz during firefights.
- Diagnosis: Using
NetProfileandNetwork Insights, engineers discovered weapon firing was usingReliableNetMulticast RPCs and replicating unquantized 64-bit vector coordinates 30 times per second. - Optimization:
- Converted
FVectortoFVector_NetQuantize(16-bit integer compression). - Changed cosmetic FX RPCs from
ReliabletoUnreliable. - Activated Net Dormancy on 800 static interactive loot containers in the map.
- Converted
- Outcome: Server bandwidth per client decreased by 68%; server tick rate stabilized at 60 Hz.
Verification Checklist
- GameMode contains zero client-side logic and is never accessed from client HUDs.
- All Server RPCs implement
_Validate()security checks to prevent packet injection. DOREPLIFETIME_CONDITIONused to prevent sending private data (e.g. inventory) to non-owners.- Cosmetic effects transmitted via
UnreliableMulticast RPCs. - Net Relevancy distance and Net Dormancy configured for large maps.
Anti-Patterns
- Calling Server RPCs on Un-Owned Actors: Invoking a Server RPC from a client on an Actor that is not possessed or owned by that client's PlayerController (fails silently).
- Using Reliable RPCs for Frequent Ticks: Marking high-frequency weapon fire or footstep RPCs as
Reliable, causing TCP-style packet queues when latency spikes. - Accessing
AGameModeon Clients: WritingGetWorld()->GetAuthGameMode()inside client UI widgets, which returnsnullptron non-server machines.
Does it work?
Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.
No reviews yet
People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.
- It worked
- Partly
- It didn't
Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.
Your trail
Files you open will collect here, so you can find them again.
Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.
Now do this for your own.
Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.

