s&box
RustCounter-Strike 2s&boxDeadlock
Wiki
Get s&box on Steam
Browse
OverviewGetting StartedCreating GamesEngine & ToolsDocumentationCommunity GamesResources
s&boxDocumentationSceneMapsNetworking
SOURCE 2 · C#
Build and play games with s&box.

Facepunch's game engine and creation platform — make games in C#, or jump straight into community games.

Get s&box on Steam

s&box Wiki

  • Overview
  • Getting Started
  • Creating Games
  • Engine & Tools
  • Documentation
  • Community Games
  • Resources

Tools & Community

  • Getting Started
  • Creating Games
  • Engine & Tools
  • Resources

Platforms

  • RustBattle
  • CSBattle
  • Rust Game Wiki
  • CS2 Skins Wiki
  • Deadlock Wiki

About

  • Official Site
  • Developer Wiki
  • GitHub
  • Get on Steam
NOT AFFILIATED WITH FACEPUNCH STUDIOS · © 2026 s&box Wiki (community)
Docs/Scene
Scene

Networking

Maps and networking work together automatically. Most of the map's content does not need to be networked because it is loaded identically on every client from the same map file.

Physics props (prop_physics) are the main exception. When the map loads, each physics prop is spawned as a fully networked object.

prop.GameObject.Network.SetOrphanedMode( NetworkOrphaned.ClearOwner );
prop.GameObject.Network.SetOwnerTransfer( OwnerTransfer.Takeover );
prop.GameObject.NetworkSpawn();

This means any client can interact with physics props - pushing, shooting, or destroying them - and the changes replicate to everyone.

Everything else in the map is loaded locally and does not go through the network system:

  • World geometry and collision
  • Lights and light probes
  • Fog volumes
  • Skyboxes
  • Soundscapes
  • Static props and func_brush entities
  • Cubemap probes

These are all deterministic - they produce the same result on every client because they come from the same map file.

When a client joins a game, the MapInstance is part of the scene snapshot. The map loads on the client and all its entities are created locally.

The MapInstance is careful not to duplicate objects that already exist from the network. If a child GameObject was already received via the network snapshot, the map loader will skip creating it again. This prevents doubled props or conflicting state.

Maps can also contain GameObjects embedded in a scene file (world.scene). These are deserialized and added as children of the MapInstance. Any of these GameObjects that have NetworkMode.Object set will be network spawned automatically by the host.

On the client side, GameObjects that arrive via the network are not re-created from the map file - the networked version takes precedence.

Source: Facepunch/sbox-docs (CC-BY-4.0) · updated 2026-04-11. Read it rendered on the official docs.

More in Scene

Advanced Topics
Async
Camera Effects
Component Interfaces
Component Methods
Component Versioning
Components
Events
← All documentation

Community wiki — not affiliated with Facepunch Studios. For the latest and most authoritative information, see the official developer wiki.