Photon Fusion 2.x - Setup & Configuration (1.6.0)

What this integration does

Runtime Spawner can run inside a Fusion session:

  • The authoritative peer performs spawn logic (host/server/StateAuthority)

  • Clients observe the results through Fusion replication

Runtime Spawner provides optional helpers for:

  • spawning networked prefabs via a Fusion factory

  • pooling integration via Fusion’s INetworkObjectProvider

Before you enable it

If you already have Fusion running in your project, decide which of these applies:

A) Use your existing Fusion object provider (supported)

You can run Runtime Spawner without replacing your current INetworkObjectProvider.

Runtime Spawner includes two provider options:

  • Core Provider: FusionPoolProvider

    • Construct it in your bootstrap and pass it into StartGameArgs.ObjectProvider

  • Behaviour Provider: FusionPoolObjectProviderBehaviour

    • Add it to the same GameObject as your NetworkRunner

Recommended when:

  • you want consistent pooling behavior across all spawner-created objects

  • you want prewarm support through the Runtime Spawner workflow

  • you want fewer edge-case lifecycle differences between pooled objects and spawned objects

If you use a spawner pool provider, Fusion will use that provider for all Runner.Spawn/Runner.Despawn that go through the runner.

Assembly Definition requirements (Fusion CodeGen)

Any assembly that contains Fusion NetworkBehaviour code must be weaved by Fusion.

1) Ensure Fusion defines are present

Your networking code should compile behind Fusion’s define:

  • FUSION_WEAVER

2) Add assemblies to Fusion CodeGen

Go to:

  • Tools → Fusion → Network Project Config Add all assemblies that contain NetworkBehaviour types to Assemblies to Process, including:

  • the Runtime Spawner Fusion integration assembly (if separated)

  • your gameplay/network assemblies containing your Fusion behaviours

If an assembly isn’t in this list, Fusion will not weave it.

3) Run Fusion CodeGen

After changing asmdefs or assembly lists:

  • Fusion → CodeGen → Run CodeGen

Prefab requirements

Any prefab Fusion will spawn must:

  • include a NetworkObject

  • be registered in Fusion’s Network Prefabs list (Project Settings → Fusion → Network Prefabs), or otherwise provided through your prefab table flow

Choose a bootstrap strategy

You can start Fusion however you like. The core requirement is:

  • Start a NetworkRunner

  • Ensure Runtime Spawner is configured to use a Fusion-aware object factory (FactoryAsset / FusionObjectFactory)

  • Only start spawner logic from the authoritative side

Pool provider (optional)

If you want to use Runtime Spawner’s Fusion pool provider, use either the Core Provider or Behaviour Provider approach described above.

The project-level docs stop here and link to the component driver pages:

  • WaveTrigger → FusionWaveTriggerDriver

  • LocalAreaSpawner → FusionLocalAreaSpawnerDriver

(These pages explain execution target, tag/layer filtering, authority rules, RPC behavior, etc.)

Last updated