Build a premium pointer-driven site: (A) a real-time 3D product showcase visitors drag, turn, and customise, or (B) a click-to-explore world with hotspots and transitions. Invoke with /explore-site, or for an interactive 3D or explorable reference such as a jersey rail, a rotatable product, or a room tour. Inspect the reference, pick the mode, build the scene, and verify it with GPU screenshots. For scroll-driven pages, hand off to story-site or scroll-craft; for a page with nothing to touch,...
Installs into .claude/skills of the current project.
Sponsors
SSkills DirectorySkills Directory
Know which skills are safe — weekly.
SSkills DirectorySkills Directory
Is that skill safe to install?
Are you the author of Explore Site?
Add the live security badge to your README. It updates with every re-scan.
[](https://www.skillsdirectory.com/skills/ahmedmerza-explore-site)
---
name: explore-site
description: "Build a premium pointer-driven site: (A) a real-time 3D product showcase visitors drag, turn, and customise, or (B) a click-to-explore world with hotspots and transitions. Invoke with /explore-site, or for an interactive 3D or explorable reference such as a jersey rail, a rotatable product, or a room tour. Inspect the reference, pick the mode, build the scene, and verify it with GPU screenshots. For scroll-driven pages, hand off to story-site or scroll-craft; for a page with nothing to touch, use a static design."
---
# /explore-site — a site you play with, not scroll past
Two kinds of reference land here, and they are built differently:
| Mode | The visitor… | Built from | Reference examples |
|---|---|---|---|
| **A — Live object** | drags, swings, spins, flips, customises one thing (or a row of them) | three.js scene, procedural motion, canvas-painted textures | garuda2026.offwg.com/rail (kit rail), the Bahrain kit rail (`/srv/dev/projects/private/bahrain-kit-rail`) |
| **B — Explorable world** | clicks hotspots and travels between fixed views | stills + short transition clips (AI image-to-video or renders) driven by a state graph, HTML overlays on top | Real-estate tower → residence → cutaway floorplan → rooms → rooftop |
**Set the mode expectation before building.** If the user asks for 3D objects, a rotatable product, or a model, deliver Mode A with a usable all-angle asset. Mode B is a different experience: clickable views are not 3D. When the available assets cannot support a credible Mode A, say so before switching modes and let the user decide whether Mode B meets the goal. Never describe photos on planes, CSS perspective, or a camera zoom as a 360° object.
## Restraint gate — run first
- **Scroll is the input** (page plays as you scroll, product assembles, frame-sequence hero) →
not this skill. `story-site` plans it, `scroll-craft` builds it. Say so and hand off.
- **Nothing in the reference responds to the pointer** → a static page with good photography
beats a fake 3D gimmick. Say so.
- **Mixed** (an explorable world inside a scroll page) → build the explorable part here as a
section, and leave the scroll shell to scroll-craft.
## 0. Reverse-engineer the reference (always — never guess the stack)
- **URL:** `curl` the HTML with a browser UA into the scratchpad, list `<script src>` /
modulepreload, download the bundles, and grep them for the stack and the assets:
`THREE|WebGPURenderer|isWebGPUBackend|GLTFLoader|KTX2|Draco|Meshopt|gsap|ScrollTrigger|lenis|rive|spline|lottie`
plus `\.(glb|gltf|hdr|ktx2|mp4|webm|riv|json)`. Download one `.glb` and read its JSON chunk:
`animations`, `skins`, morph `targets`. **0 animations = the motion is procedural in code** — then
grep around words like `cloth|wind|sway|bend|flutter|spring` to see which uniforms drive it.
- **Reel / video:** run `/video-teardown` in its single-clip mode: frames, then one contact sheet per
clip (`ffmpeg … -vf "fps=2,scale=320:-1,tile=6x4"`). Describe the states and transitions, not the
thumbnail.
- Report in a few lines: stack, asset types, how the motion is made, which mode (A/B). Reproduce
the **technique**, never their code, models or brand.
## 1. Brief (keep it short — ask only what blocks the build)
What is the object/world, what assets the user already has (photos, `.glb`, renders, brand marks),
what the one "touch moment" is (swing a shirt, turn the bottle, open the apartment), and where it
should live. Build in a **new project directory**, never inside an unrelated repo. Default: a
sibling under the user's projects dir.
Plan the **arrival** alongside the touch moment. Unless the user asks for a static opening, the first view should have one short, purposeful entrance tied to the object or world: a product turns into its resting pose, a room opens, or the explorable objects arrive and settle. Let the primary assets load before starting; keep the scene usable if an asset fails. The entrance runs once, does not block a click or drag, and finishes in roughly a second. Show the complete resting scene immediately under reduced motion. Avoid a blanket fade on every UI element or a loop that never settles.
## 2A. Mode A — Live object (three.js)
Stack: **Vite + vanilla JS + three** (pin versions). `WebGLRenderer` unless the reference needs
WebGPU/TSL. React only if the user's app is already React (`@react-three/fiber` + `drei`).
**Asset ladder — choose the first route that survives an all-angle preview:**
1. An exact, usable `.glb` from the brand or owner → inspect its licence and front, side, and back;
optimise for the web if a suitable tool is available.
2. Photos but no exact model → find a **licensed base mesh of the same kind of product** (a fitted
shirt for a jersey, a pouch for coffee beans, a bottle for a drink). Check the asset's own
licence; a public repository alone does not grant reuse. Project the real product art onto its
UVs, test seams and hidden sides, and keep required credit. A good base shape can be reused with
different artwork and live canvas-painted labels. Keep a standalone textured GLB when the user
needs the model outside the site.
3. No suitable base → optionally test multi-view reconstruction from consistent front, back, and
side images. Treat its output as a candidate: reject broken openings, malformed sleeves or
sides, bad textures, and excessive mesh size. One product photo cannot establish hidden geometry.
4. No acceptable 3D shape → use the photo cutout plane and state that its side view is thin. Do
not present it as a full 360° garment or product.
5. No product imagery → request the real photos or artwork before inventing a specific product.
**Photo cutouts:** key the background out with ImageMagick (floodfill ~2% fuzz from the edges,
erode the mask 1–2 px, feather), then **fill transparent texels with the edge colour** so
mip-mapping never bleeds a white halo. Use `alphaTest`/alpha-to-coverage for the edge.
**Motion is procedural, not baked:**
- Each object has a **damped spring** state (sway/tilt/yaw + velocities), integrated with a
**fixed step (1/120 s, sub-stepped)**. A `dt` clamp alone makes a slow machine run in slow
motion.
- A **vertex shader bends the mesh** from uniforms (`bend`, `twist`, `flutter`): the far end lags
`(1−v)²`, flutter scales with speed. JS writes uniforms each frame; eased values use
`x += (target − x) * k`.
- Pointer: drag pans with momentum + rubber-band ends; pan velocity and brushing past push
neighbours; hover = small lift; click = focus (camera eases in, others dim); double-click or a
button = turn 180° with overshoot; Esc / click outside = unfocus. Pointer events, so touch works.
No tap-duration limits (a busy main thread breaks them).
- **Make the motion visible.** If a swing is not obvious in a mid-drag screenshot, it is too
stiff. Tune until it reads, then make sure neighbours never clip.
**Customisation:** paint names/numbers/text on a 2D `<canvas>` over the plain texture and use it
as a `CanvasTexture`. One asset serves every variant, and a form repaints it live. **Back faces
sample `(1−u, v)`**, or the lettering comes out mirrored.
**Look:** HDR environment (Poly Haven or PMREM of the room), ACES tone mapping, a dark room with a
spot pool per object, painted contact shadows under each object, fog or a curved backdrop so the
floor never meets the wall in a hard line, a CSS vignette. A themed loader with copy in the brand's
voice ("Hanging the shirts…"). Cap DPR at 2 and pause rendering when the tab is hidden.
**HTML overlays vs the scene:** the camera moves on focus, so check that 3D geometry never
lands behind the title/UI in any state. Hide or move the overlay per state (`body.is-focused`).
## 2B. Mode B — Explorable world (state graph)
Model it as a **graph of views**: each node is a still (or a looping clip), each edge is a short
**transition clip** (1–3 s) from node A's frame to node B's. Example: `tower` →(hotspot residence 3)→
`residence-zoom` → `cutaway` →(room chip)→ `living` ↔ `bedroom` ↔ `bath`; `tower` → `rooftop`.
- **Assets:** renders or photos per node; transitions from an image-to-video tool given the
*first and last frame* (Veo / Kling / Google Flow / kie.ai, which scroll-craft already
scripts). Prompt each edge with both frames and "locked camera path, no new objects". The user
generates them; write the per-edge prompts as a list. Encode H.264 + WebM, `playsinline muted`,
preload the neighbouring edges only.
- **Playback:** on click, play the edge clip, and on `ended` swap to the node still (same frame →
invisible cut). Reverse edges play a reversed clip (export it; don't rely on negative
`playbackRate`). Ignore clicks while a transition is running.
- **Hotspots:** absolutely positioned in **image-relative %** over an `object-fit: cover` media box
(recompute on resize), with a hover card (unit, beds, area, price, status) and a keyboard-focusable
button. The cutaway's room chips sit on the same layer.
- **Chrome:** breadcrumb/back, a room switcher, a persistent CTA (book a viewing / enquire), and
`history.pushState` per node so Back and deep links work.
- A real 3D cutaway (a three.js `.glb` dollhouse they can orbit) only if a model exists. Otherwise
a rendered orbit clip looks the same and costs nothing at runtime.
## 3. Verify — screenshots on the real GPU, every state
- Start your own server on a **free port** (`--port 5190 --strictPort --host 127.0.0.1`). Other dev
servers are usually running. Stop **only the PID you started**; never `pkill -f vite`.
- Playwright with **GPU Chrome** (`CHROME=/home/amerza/.local/bin/google-chrome`, ANGLE/EGL).
Headless SwiftShader runs at ~2 fps and makes motion look frozen. That's an artefact of the test
environment, not proof the motion is fine.
- Keep a small `tools/shots.cjs` + a `window.__app` test hook, and shoot desktop 1440×900 and phone
390×844: opening, mid-entrance, settled idle, **mid-interaction** (~140 ms after a simulated drag/click), focused, the
turned/back or each node of the graph, and after-unfocus. Log console errors to `console.log`.
- Record the entrance or inspect time-separated frames. Check that it visibly starts, settles, and can be interrupted by the first interaction; verify that reduced motion shows the complete scene without the travel.
- **Look at every shot** and read it for defects: halos, mirrored text, z-fighting, clipping,
geometry behind UI, stiff motion, hard horizons, grey rims. Fix and re-shoot. Report what you
fixed and what remains, honestly.
- `npm run build` must pass.
## Delegation
The build is visual work: per the user's rules, delegate it to a `general-purpose` agent with
`model: "fable"`, a full brief (mode, assets, the rules above, verification steps) and **"do not
spawn subagents"**. Keep the reverse-engineering inline (it's a few greps), then review its
screenshots yourself before reporting. When fixes come back, resume the same agent; it already
holds the code.
## Output
A runnable project path, the run command, the screenshot folder, what works, the known limits
(e.g. plane vs real model, user-generated clips still pending), and, for Mode B, the per-edge
generation prompts the user still has to run. Nothing is published or hosted unless asked.