githubEdit

Needle Core Components

Complete catalog of 100+ built-in components for audio, animation, physics, networking, XR, UI, and more - ready to use in your projects.

Built-in components that map to Unity, Blender, and three.js functionality.

:::tip Complete Reference For the full API documentation, see engine.needle.tools/docs/apiarrow-up-right :::

:::tip Custom Components You can always create your own components or add wrappers for components we haven't provided yet.

Learn scriptingarrow-up-rightFor Unity Developersarrow-up-right :::

🔊 Audio

Component
Description

Receives audio in the scene (attach to camera)

Plays audio clips with spatial audio support

🎬 Animation

Component
Description

State machine with AnimatorController, transitions, and conditions

Basic animation playback (single clip)

Timeline sequences for animation, audio, state control

📷 Camera & Controls

Component
Description

Scene rendering viewpoint (perspective/orthographic)

Rotate, zoom, and pan around target • Samplearrow-up-right

Defines visible area bounds

🎨 Rendering

Component
Description

Directional, Point, Spot lights with shadow support and baking

Renders meshes with lightmapping and instancing

Renders animated/deformable meshes

Renders 2D sprites and animations • Samplearrow-up-right

Video playback, streaming (MediaStream, M3U8) • Samplearrow-up-right

Control visibility by mode (VR/AR/Desktop)

Control visibility by device type

Project environment texture on ground • Samplearrow-up-right

Fade objects obscuring view • Samplearrow-up-right

Post-processing effects (see below) • Samplearrow-up-right

Postprocessing

Postprocessing effects use the pmndrs postprocessing libraryarrow-up-right under the hood. This means you can also easily add your own custom effects and get an automatically optimized postprocessing pass.

:::tip For Unity Users For Needle Engine Postprocessing in Unity you need to use URP (Universal Render Pipeline) :::

Add effects below

Effects

extra Unity Component

via Volume asset or separate component

via Volume asset

via Volume asset or separate component

via Volume asset or separate component

via Volume asset or separate component

via Volume asset or separate component

via Volume asset or separate component

🌐 Networking & Multiplayer

Component
Description

Enable multiplayer networking (required for all networked features)

Configure custom backend server (defaults to Needle servers)

Sync object position, rotation, scale across clients

Sync camera view to other users with custom rendering

Instantiate object per connected user (avatars, etc.)

Voice chat with spatial audio • Samplearrow-up-right

Screen sharing capabilities • Samplearrow-up-right

🖱️ Interaction

Component
Description

Drag objects in scene (requires raycaster in parent, e.g. ObjectRaycaster)

Duplicate objects by dragging (requires DragControls)

Camera orbit, zoom, and pan controls

Smooth interpolation to another object's transform

Destroys Deletable objects entering the box

Object can be deleted when entering DeleteBox

Receive file drop events for uploads

Raise events when objects enter space/area

Receive events from SpatialTrigger

Bind scroll to animations/timeline • Samplearrow-up-right

Physics

Powered by Rapierarrow-up-right physics engine.

Component
Description

Physical body with gravity, mass, drag (dynamic/kinematic/static)

Box-shaped collision volume

Sphere-shaped collision volume

Capsule-shaped collision volume

Complex collision matching mesh geometry

Physics Materials

Control friction, bounciness, and other physical properties

Attract or repel rigidbodies • Samplearrow-up-right

:::tip Colliders as Triggers Set any collider to isTrigger = true to detect overlaps without physical collision response. :::

🥽 XR / WebXR

Read the full XR documentationarrow-up-right

Component
Description

Enable VR, AR, passthrough, and avatar rendering

Enable QuickLook AR on iOS (USDZ format)

AR scene placement and scale (defines center/alignment)

Define user start position in VR

Access AR camera feed for effects/rendering

Track images and instantiate objects • Samplearrow-up-right

Create meshes/colliders for tracked planes

Render VR controllers or hand models

Default movement and teleport controls

Make objects follow hands or controllers

Control visibility by mode (VR/AR/FirstPerson/ThirdPerson)

🔧 Debugging

Component
Description

:::tip Gizmos in Code Use static Gizmos methods for drawing debug lines and shapes in your scripts. See Gizmos APIarrow-up-right :::

📁 Runtime File Input/Output

Component
Description

Export glTF from runtime (experimental)

Receive file drop events for uploads and networking

🖼️ UI

Spatial UI components map from Unity UI (Canvas, not UI Toolkit) to three-mesh-uiarrow-up-right. UI can be animated.

Component
Description

Unity UI system (World Space mode required)

Render text with custom fonts (auto-generated atlas). Use Legacy/Text, not TextMeshPro

Click events with onClick. Works in 3D and UI. Use Legacy/Text for labels

Renders sprite images

Renders textures

Text input field

:::tip HTML + Spatial UI For cross-platform projects (VR, AR, desktop), mix spatial and HTML UI:

  • HTML: 2D interfaces for best accessibility

  • Spatial UI: 3D interfaces with depth (e.g., button hover states) :::

🔀 Scene Management

Component
Description

Load/unload scenes, prefabs, glTF files with preload, swipe, keyboard, URL navigation

🛠️ Editor Only (Unity/Blender)

Component
Description

Needle Engine

Main component for managing web project(s) (install, start, deploy)

EditorSync

Sync material/component changes to runtime without reload (hot reload)


Complete API Documentation

For detailed TypeScript API documentation with all methods, properties, and types:

📖 View Complete API Reference →arrow-up-right

The API documentation includes:

  • All component classes and their methods

  • Component lifecycle hooks

  • Event handlers and callbacks

  • Type definitions and interfaces

  • Code examples and usage patterns


Learn How to Use Components

Integration Guides

Tutorials

How-To Guides

Additional Reference

Last updated