BanSystem Pattern for Player Management
BanSystem - Player Ban Management A GameObjectSystem that manages player bans with persistent storage. Demonstrates , persistence, and RPC commands. Implementat…
Playing Sounds: SoundEvent, SoundHandle, and GameObject Audio in s&box
s&box provides several ways to play sounds in code: fire-and-forget at a world position, control via SoundHandle, attach to a GameObject, or use scene component…
s&box GamePreferences: ConVar-based user settings with attributes
GamePreferences API Reference GamePreferences is a static class for defining user preferences using ConVar attributes with automatic persistence. Type Signature…
Drag-and-drop system with static instance pattern
Drag-and-Drop System with Static Instance Pattern This example shows a drag-and-drop system using a static instance pattern for global state management and visu…
Connection Permissions: CanSpawnObjects and CanRefreshObjects
The host can change permissions for a specific in s&box multiplayer. The ideal place to set these permissions is in the network event callback when a player con…
IPlayerControllable example: ThrusterEntity
IPlayerControllable Example: ThrusterEntity ThrusterEntity demonstrates how to implement IPlayerControllable for a thruster that responds to player input while …
s&box ResourceSelectAttribute: Resource picker configuration
ResourceSelectAttribute API Reference ResourceSelectAttribute is used to configure resource selection UI for properties in the inspector. Type Signature Propert…
s&box EmitterEntity: Particle emitter entity
EmitterEntity Component API Reference EmitterEntity is a world-placed SENT that spawns and controls a particle/VFX emitter. The emitter prefab is defined by a S…
s&box Hints GameObjectSystem: UI hint queue
Hints GameObjectSystem Example Hints is a GameObjectSystem that manages the display of timed popup hints in the UI. It queues hints with delays and displays the…
Network Helper
Network Helper Pre-built component for common multiplayer scenarios. What It Does NetworkHelper handles typical multiplayer setup: Auto-creates server if enable…
Randomized Clothing for NPC Citizens using Dresser.Randomize() on Prefabs
Overview This demonstrates how to create NPC citizen prefabs with randomized clothing using the built-in component. Each time the prefab spawns or is enabled, i…
s&box ThrowType: Grenade throw distance
ThrowType Enum Documentation ThrowType is an enum that defines how a grenade is thrown by the HandGrenadeWeapon. It controls the throw distance and trajectory b…
BaseConstraintToolMode for Constraint Tools
BaseConstraintToolMode Abstract Class Base class for two-stage constraint tools (weld, rope, elastic, etc.) with selection point handling. Class Overview Contro…
s&box ICameraSetup: Camera render hooks
Interface for camera setup hooks that allow fine-grained control over camera effects. Implement to modify the camera at specific stages of the render pipeline. …
Post Processing - s&box Documentation
Official s&box documentation for Post Processing - full-screen visual effects. Post Processing applies effects to the entire rendered image. Creating PostProces…
s&box SensesLayer: NPC environmental scanning
NPC behavior layer that handles awareness and environmental scanning. Caches visible/audible objects by tag for efficient querying. Properties Methods Behavior …
Editor Shortcuts - s&box Editor Documentation
Editor Shortcuts Custom keyboard shortcuts make your editor tools more efficient. Shortcuts can be bound globally or to specific widgets. Creating a Static Shor…
Networked Objects: Spawning, Network Modes, and Interpolation
Any GameObject can become networked by calling . It will then be sent to all clients and can have Sync Properties and RPC Messages. Spawning a Networked Object …
Razor Panels: HTML/CSS UI with C# in s&box
s&box UI can be created using Razor syntax — web-like HTML/CSS combined with C#. Panels are not rendered via a HTML renderer; the syntax is a convenience layer …
Physics Triggers: Enter, Exit Events and Polling in s&box
A trigger is a collider that detects when physics objects enter or exit it without blocking movement. Useful for pickup zones, death planes, checkpoints, and ar…