Project Setup Jan 1, 2026

Lesson 2: Unreal Engine Setup & Networking Foundation

Set up Unreal Engine 5 for multiplayer development, configure networking settings, and create your first multiplayer project structure with version control.

By GamineAI Team

Lesson 2: Unreal Engine Setup & Networking Foundation

Welcome to Unreal Engine Multiplayer Development!

Congratulations on completing Lesson 1! Now it's time to get your hands dirty with Unreal Engine 5. In this lesson, you'll set up your development environment, configure networking settings, and create the foundation for your multiplayer battle royale game.

Learning Objectives

By the end of this lesson, you will:

  • βœ… Install and configure Unreal Engine 5 for multiplayer development
  • βœ… Create a new multiplayer project with proper structure
  • βœ… Understand Unreal's networking architecture
  • βœ… Configure replication settings and server/client roles
  • βœ… Set up version control with Git
  • βœ… Create your first multiplayer test scene

Part 1: Installing Unreal Engine 5

Step 1: Download Epic Games Launcher

1.1 Get the Launcher

  • Visit Epic Games Launcher
  • Download and install the Epic Games Launcher
  • Create an Epic Games account if you don't have one

1.2 Install Unreal Engine 5

  • Open Epic Games Launcher
  • Navigate to "Unreal Engine" tab
  • Click "Install Engine"
  • Select Unreal Engine 5.3 or newer (recommended: Latest stable version)
  • Choose installation location (ensure 50+ GB free space)
  • Click "Install" and wait for completion (30-60 minutes)

Step 2: Verify Installation

2.1 Launch Unreal Engine

  • Open Epic Games Launcher
  • Click "Launch" under Unreal Engine
  • Wait for the project browser to open

2.2 Check Version

  • In the project browser, verify you're using UE 5.3 or newer
  • Check that all required components are installed

Part 2: Creating Your Multiplayer Project

Step 3: Create New Project

3.1 Project Template Selection

  • In Unreal Engine project browser, click "New Project"
  • Select "Games" category
  • Choose "Third Person" template (good starting point for battle royale)
  • Select "C++" (not Blueprint-only) for full networking control
  • Click "Next"

3.2 Project Settings

  • Project Name: MultiplayerBattleRoyale
  • Location: Choose a dedicated folder (e.g., C:\Projects\ or ~/Projects/)
  • Target Platform: Desktop
  • Quality Preset: Maximum (you can optimize later)
  • Raytracing: Optional (requires RTX GPU)
  • Click "Create Project"

3.3 Wait for Project Generation

  • Unreal will generate C++ project files
  • Visual Studio or Rider will open automatically
  • First compile may take 10-20 minutes
  • Wait for compilation to complete

Step 4: Project Structure Setup

4.1 Create Folder Structure

In the Content Browser, create this structure:

Content/
β”œβ”€β”€ Maps/                    # Game levels
β”‚   β”œβ”€β”€ MainMenu/
β”‚   β”œβ”€β”€ Lobby/
β”‚   └── BattleRoyale/
β”œβ”€β”€ Blueprints/              # Blueprint classes
β”‚   β”œβ”€β”€ Characters/
β”‚   β”œβ”€β”€ Weapons/
β”‚   β”œβ”€β”€ GameModes/
β”‚   └── UI/
β”œβ”€β”€ Materials/              # Material assets
β”œβ”€β”€ Textures/              # Texture assets
β”œβ”€β”€ Meshes/                # Static meshes
β”œβ”€β”€ Audio/                 # Sound effects and music
β”œβ”€β”€ UI/                    # User interface assets
β”œβ”€β”€ Data/                  # Data tables and configs
└── Plugins/               # Custom plugins

4.2 Create Initial Maps

  • Right-click in Maps/ folder β†’ Miscellaneous β†’ Level
  • Create: MainMenu, Lobby, BattleRoyale_Main
  • Set BattleRoyale_Main as default map

Part 3: Understanding Unreal Networking

Step 5: Networking Architecture Overview

5.1 Client-Server Model

Unreal uses a dedicated server architecture:

β”Œβ”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”€β”
β”‚   Server    β”‚ ← Source of Truth (Authoritative)
β”‚  (Host)     β”‚
β””β”€β”€β”€β”€β”€β”€β”¬β”€β”€β”€β”€β”€β”€β”˜
       β”‚
       β”‚ Replication
       β”‚
   β”Œβ”€β”€β”€β”΄β”€β”€β”€β”
   β”‚Client β”‚ ← Receives updates, sends input
   β””β”€β”€β”€β”€β”€β”€β”€β”˜

Key Concepts:

  • Server: Runs game logic, validates actions, replicates state
  • Client: Sends input, receives updates, predicts locally
  • Replication: Server sends state updates to clients
  • RPCs: Remote Procedure Calls for client-server communication

5.2 Network Roles

Every actor has a network role:

  • Authority: Server has authority (source of truth)
  • Autonomous Proxy: Client controlling this actor (can send RPCs)
  • Simulated Proxy: Other clients' actors (receives replication)

Step 6: Configure Networking Settings

6.1 Project Settings - Networking

  1. Go to Edit β†’ Project Settings
  2. Navigate to Engine β†’ Network
  3. Configure these settings:
Default Network Mode: Dedicated Server
Replication Graph: Enabled (for large player counts)
Max Net Tick Rate: 60
Net Driver Definition: GameNetDriver

6.2 Enable Replication Graph

For 50-100 players, enable Replication Graph:

  • In Project Settings β†’ Engine β†’ Network
  • Check "Use Replication Graph"
  • This optimizes replication for large player counts

6.3 Configure Server Settings

Create Config/DefaultEngine.ini:

[/Script/Engine.GameNetworkManager]
TotalNetBandwidth=20000
MaxDynamicBandwidth=10000
MinDynamicBandwidth=10000

Part 4: Creating Your First Multiplayer Class

Step 7: Create Character Class

7.1 Create C++ Character Class

  1. In Content Browser, right-click β†’ New C++ Class
  2. Select "Character" as parent class
  3. Name it: BRCharacter (Battle Royale Character)
  4. Click "Create Class"

7.2 Basic Character Setup

Open BRCharacter.h and add:

UCLASS()
class MULTIPLAYERBATTLEROYALE_API ABRCharacter : public ACharacter
{
    GENERATED_BODY()

public:
    ABRCharacter(const FObjectInitializer& ObjectInitializer);

protected:
    virtual void BeginPlay() override;
    virtual void SetupPlayerInputComponent(UInputComponent* PlayerInputComponent) override;

    // Replicated properties
    UPROPERTY(Replicated)
    float Health;

    UPROPERTY(Replicated)
    float MaxHealth;

public:
    // RPC for taking damage
    UFUNCTION(Server, Reliable, WithValidation)
    void ServerTakeDamage(float DamageAmount);

    // Replication function
    virtual void GetLifetimeReplicatedProps(TArray<FLifetimeProperty>& OutLifetimeProps) const override;
};

7.3 Implement Character Class

Open BRCharacter.cpp:

#include "BRCharacter.h"
#include "Net/UnrealNetwork.h"

ABRCharacter::ABRCharacter(const FObjectInitializer& ObjectInitializer)
    : Super(ObjectInitializer)
{
    PrimaryActorTick.bCanEverTick = true;

    // Set default values
    MaxHealth = 100.0f;
    Health = MaxHealth;

    // Enable replication
    bReplicates = true;
    SetReplicatingMovement(true);
}

void ABRCharacter::BeginPlay()
{
    Super::BeginPlay();
}

void ABRCharacter::SetupPlayerInputComponent(UInputComponent* PlayerInputComponent)
{
    Super::SetupPlayerInputComponent(PlayerInputComponent);
}

void ABRCharacter::GetLifetimeReplicatedProps(TArray<FLifetimeProperty>& OutLifetimeProps) const
{
    Super::GetLifetimeReplicatedProps(OutLifetimeProps);

    // Replicate health
    DOREPLIFETIME(ABRCharacter, Health);
    DOREPLIFETIME(ABRCharacter, MaxHealth);
}

void ABRCharacter::ServerTakeDamage_Implementation(float DamageAmount)
{
    Health = FMath::Clamp(Health - DamageAmount, 0.0f, MaxHealth);

    if (Health <= 0.0f)
    {
        // Handle death
    }
}

bool ABRCharacter::ServerTakeDamage_Validate(float DamageAmount)
{
    return DamageAmount >= 0.0f && DamageAmount <= 1000.0f;
}

Step 8: Create Game Mode

8.1 Create C++ Game Mode

  1. Right-click β†’ New C++ Class
  2. Select "Game Mode" as parent class
  3. Name it: BRGameMode
  4. Click "Create Class"

8.2 Configure Game Mode

In BRGameMode.h:

UCLASS()
class MULTIPLAYERBATTLEROYALE_API ABRGameMode : public AGameMode
{
    GENERATED_BODY()

public:
    ABRGameMode();

    // Maximum players per match
    UPROPERTY(EditDefaultsOnly, Category = "Battle Royale")
    int32 MaxPlayers = 100;

    // Match duration in seconds
    UPROPERTY(EditDefaultsOnly, Category = "Battle Royale")
    float MatchDuration = 1800.0f; // 30 minutes

protected:
    virtual void BeginPlay() override;
};

Part 5: Version Control Setup

Step 9: Initialize Git Repository

9.1 Create .gitignore

Create .gitignore in project root:

# Unreal Engine
Binaries/
DerivedDataCache/
Intermediate/
Saved/
*.sln
*.xcodeproj
*.xcworkspace

# Visual Studio
.vs/
*.suo
*.user
*.userosscache

# Rider
.idea/

# OS
.DS_Store
Thumbs.db

9.2 Initialize Git

cd /path/to/MultiplayerBattleRoyale
git init
git add .
git commit -m "Initial commit: Unreal Engine 5 multiplayer project setup"

9.3 Create Remote Repository

  • Create repository on GitHub/GitLab
  • Add remote: git remote add origin <repository-url>
  • Push: git push -u origin main

Part 6: Testing Your Setup

Step 10: Create Test Scene

10.1 Set Up Test Level

  1. Open BattleRoyale_Main level
  2. Add your BRCharacter to the level
  3. Set BRGameMode as default game mode:
    • Edit β†’ World Settings
    • Set Game Mode Override to BRGameMode

10.2 Test Multiplayer

  1. Play in Editor (PIE):

    • Click "Play" button
    • Select "Number of Players": 2
    • Click "New Editor Window" for each client
    • Test that both clients can see each other
  2. Dedicated Server Test:

    • Edit β†’ Editor Preferences β†’ Play
    • Set "Run Dedicated Server": Enabled
    • Launch and connect clients

Mini Challenge: Create Basic Multiplayer Test

Task: Create a simple multiplayer test that demonstrates replication.

Requirements:

  1. Create a character that can move and jump
  2. Add a replicated health property
  3. Create an RPC to modify health
  4. Test with 2+ clients to verify replication
  5. Verify that health changes replicate to all clients

Deliverables:

  • Working multiplayer character class
  • RPC for health modification
  • Test results showing successful replication

Pro Tips:

  • Always test with multiple clients, not just single-player
  • Use GetNetMode() to check if running on server or client
  • Enable "Replay" recording to debug networking issues
  • Use Network Profiler to monitor replication bandwidth

Common Mistakes to Avoid

1. Forgetting Replication

  • ❌ Creating properties without Replicated specifier
  • βœ… Always mark networked properties with UPROPERTY(Replicated)

2. Client Authority

  • ❌ Trusting client input without server validation
  • βœ… Always validate on server, never trust client data

3. Missing GetLifetimeReplicatedProps

  • ❌ Forgetting to call DOREPLIFETIME for replicated properties
  • βœ… Always implement GetLifetimeReplicatedProps for replicated classes

4. Not Testing Multiplayer

  • ❌ Testing only in single-player mode
  • βœ… Always test with multiple clients to catch networking issues

Troubleshooting

Q: Characters don't replicate between clients A: Check that bReplicates = true and SetReplicatingMovement(true) are set in constructor.

Q: RPCs not working A: Ensure RPC functions have Server, Client, or NetMulticast specifiers and _Implementation suffix.

Q: Compilation errors after creating C++ class A: Close Unreal Editor, rebuild project in Visual Studio/Rider, then reopen editor.

Q: Can't see other players A: Verify network roles, check that characters are spawned on server, and ensure replication is enabled.

Q: High latency in multiplayer A: Check tick rate settings, optimize replication frequency, and use Replication Graph for large player counts.

Key Takeaways

βœ… Unreal Engine Setup: Install UE5 and create C++ project for full networking control βœ… Networking Architecture: Understand client-server model and replication βœ… Replication: Mark properties with Replicated and implement GetLifetimeReplicatedProps βœ… RPCs: Use Server/Client RPCs for client-server communication βœ… Testing: Always test with multiple clients to verify networking βœ… Version Control: Set up Git for collaboration and project management

What's Next?

In Lesson 3: Art Style & Asset Pipeline Planning, we'll:

  • Define your game's visual style and art direction
  • Plan asset creation pipeline and workflows
  • Set up art tools and integration processes
  • Create style guides and reference materials
  • Plan asset optimization for multiplayer performance

Get ready to bring your battle royale world to life with stunning visuals!

Additional Resources


Ready to continue? Move on to Lesson 3 to plan your art pipeline and visual style!