Appearance
Changelog
What changed between runtime versions. Scripts pin to the version they were written against, so older experiences keep running unchanged. See the Migration Guide when you move an experience forward.
0.2.0
A large, mostly additive release. Highlights:
New APIs
- Location – read the device location from a script via
environment.location(requestAccess,current,watch, precise-accuracy opt-in) with aGeoCoordinatetype carryingdistanceTo/bearingTohelpers. - Paths / splines –
scene.createPath({ points })builds a runtime spline; drive an object along it withentity.followPath(path, { duration, constantSpeed, alignsToTangent }). - Mesh instancing – render thousands of copies of one object with
rep.setInstances(Instances.transforms([...]))(rendering-only; far cheaper than cloning). - Compute kernels – run GPU compute from a script:
Kernel.fromSource/Kernel.fromAsset,Bufferhandles,Texture.compute, andmesh.runCompute(...). - Dynamic meshes – build and update geometry at runtime with
createMesh(...),writeVertices/writeIndices, and per-frame draw-range updates. - User interface – author panels from a script with
createPanel(...)and theUI.*builders (label, slider, stacks, …), live${var}label interpolation,findView, and property binding. (Beta.) - Materials – inline material factories:
Material.pbr(...),Material.unlit(...),Material.occlusion(...),Material.customShader(...),Material.materialX(...),Material.video(...), with web-standard property names and texture maps. - Screen gestures –
scene.on('pan' | 'pinch' | 'rotate')withvelocity(the raw input for mechanics like flick-to-launch),entity.on('doubleTap' | 'longPress'), per-object camera-claim arbitration, andenvironment.deviceCategory. iPhone / iPad / Mac only – gate withenvironment.features.has('screenGestures'). - Physics primitives –
entity.applyImpulse,applyAngularImpulse,setVelocity/setAngularVelocity, and the.physics({...})trait for giving an object a body. - Gestures trait – the typed
.gestures({...})API, includingreleaseBehavior(stay/reset/momentum) for drag-and-release mechanics. - Live value views – write through vector components directly, e.g.
entity.position.x = 2.
Changed
- Traits flattened onto the descriptor. The trait configurators are now direct chainable methods –
createSphere(0.05).physics({...}).material(...).shadow({...})– instead of the.traits(t => …)callback..traits(fn)still works but is deprecated; see the Migration Guide. - Options-object substrate for primitive factories, e.g.
createBox(w, h, d, r, { physics, material, … }).
0.1.0
Initial scripting runtime.