xb-netblocks

Integrate real-time multiplayer with presence avatars and replicated NetObject transforms into XR Blocks.

455|91|Updated Sep 25, 2025
One-click install
npx skills add https://github.com/google/xrblocks --skill xb-netblocks
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: xb-netblocks
Source: https://github.com/google/xrblocks/tree/main/skills/xb-netblocks
Command: npx skills add https://github.com/google/xrblocks --skill xb-netblocks

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill solves the problem of integrating real-time multiplayer functionality into XR Blocks applications, providing presence avatars, replicated object transforms, and cooperative ownership, among other features.

Core Features & Use Cases

  • Real-time Multiplayer: Enables presence avatars, replicated NetObject transforms, and cooperative ownership for shared or co-located XR experiences.
  • Opt-in Spatial Voice: Allows for voice communication over pluggable transports like WebRTC and WebSocket.
  • Transport Flexibility: Supports local development with BroadcastChannelTransport and scalable rooms with WebSocketTransport.
  • Use Case: Ideal for building collaborative XR experiences like demos, classrooms, and co-presence sessions.

Quick Start

Enable multiplayer for your XR Blocks app by running the command: enableNet(), and join a room using joinRoom(), specifying the desired transport and display name.

Frequently Asked Questions about xb-netblocks

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I add real-time multiplayer to a WebXR app?

To add real-time multiplayer to a WebXR app, use an XR Blocks integration that enables presence avatars and replicated object transforms. By calling `enableNet()` and `joinRoom()`, your application establishes a shared cooperative environment.

Can I use WebRTC for spatial voice communication in XR applications?

Yes, WebRTC can be used for spatial voice communication in XR applications. This multiplayer integration supports pluggable voice transports, allowing WebRTC and WebSocket to handle audio presence within shared XR rooms.

Does XR Blocks support local development for multiplayer networking?

XR Blocks supports local development for multiplayer networking using `BroadcastChannelTransport` for internal browser communication. For scalable remote rooms, it switches to `WebSocketTransport` to handle distributed multiplayer sessions.

What is cooperative ownership in shared XR experiences?

Cooperative ownership in shared XR experiences is a multiplayer mechanism that allows users to interact with and manipulate the same virtual objects. It replicates NetObject transforms across the network to maintain synchronized physical states.

What is the best way to build a collaborative classroom XR environment?

The best way to build a collaborative classroom XR environment is using a real-time multiplayer integration that supports presence avatars and spatial voice. XR Blocks provides this functionality to easily create co-presence sessions.