Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add skills/shellishack/3d-web-game-dev-skills/player-controllersnpx skills add Shellishack/3d-web-game-dev-skills --skill player-controllersgit clone --depth 1 https://github.com/Shellishack/3d-web-game-dev-skillsWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/shellishack/3d-web-game-dev-skills/player-controllers)<a href="https://agentmods.dev/skills/shellishack/3d-web-game-dev-skills/player-controllers"><img src="https://agentmods.dev/badge/skills/shellishack/3d-web-game-dev-skills/player-controllers.svg" alt="Measured on agentmods" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5.1 | $0.00000 | $0.01273 |
| Opus 5 | $0.00000 | $0.00636 |
| Sonnet 5 | $0.00000 | $0.00255 |
| Haiku 4.5 | $0.00000 | $0.00127 |
Grade A, and why
player-controllers scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 6d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 129 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Reusable First-Person and Third-Person Controllers
Use this skill when implementing interchangeable player controllers for a 3D web game.
Contract
Define a controller interface with a mode string and an update(context) method. The context should include the active camera, third-person camera when relevant, the player transform, normalized input, delta time, terrain height lookup, camera clamp helper, and world bounds.
Keep input collection outside controllers. Controllers should receive normalized axes such as { x, z, jump }, not keyboard events. This lets keyboard, gamepad, touch sticks, and AI playback use the same movement code.
import type { ArcRotateCamera, Camera, TransformNode } from '@babylonjs/core'
export interface MoveInput {
x: number
z: number
jump: boolean
}
export interface ControllerContext {
camera: Camera
orbitCamera: ArcRotateCamera
player: TransformNode
input: MoveInput
dt: number
terrainHeight: (x: number, z: number) => number
clampOrbitCamera: (camera: ArcRotateCamera) => void
worldHalfSize: number
}
export interface PlayerController {
readonly mode: 'firstPerson' | 'thirdPerson'
update(context: ControllerContext): void
}
First-Person Controller
Use the active camera forward ray to derive horizontal forward movement. Flatten the vector by zeroing Y, normalize it, then derive a right vector perpendicular to forward. Move the player transform by the weighted forward/right vector and copy the camera position to player position plus eye height.
For jumping, track vertical velocity and an air offset inside the controller. Apply gravity each frame, clamp the offset to zero, and ground the player with terrainHeight(x, z) + airOffset.
import { Vector3 } from '@babylonjs/core'
export class FirstPersonController implements PlayerController {
readonly mode = 'firstPerson' as const
private verticalVelocity = 0
private airOffset = 0
update({ camera, player, input, dt, terrainHeight, worldHalfSize }: ControllerContext) {
const forward = camera.getForwardRay().direction.clone()
forward.y = 0
if (forward.lengthSquared() > 0.0001) forward.normalize()
const right = new Vector3(forward.z, 0, -forward.x)
const move = forward.scale(input.z).add(right.scale(input.x))
if (move.lengthSquared() > 0.0001) {
move.normalize()
player.position.x = clamp(player.position.x + move.x * 0.14 * dt, -worldHalfSize, worldHalfSize)
player.position.z = clamp(player.position.z + move.z * 0.14 * dt, -worldHalfSize, worldHalfSize)
player.rotation.y = Math.atan2(move.x, move.z)
}
if (input.jump && this.airOffset <= 0.01) this.verticalVelocity = 0.08
this.verticalVelocity -= 0.0065 * dt
this.airOffset = Math.max(0, this.airOffset + this.verticalVelocity * dt)
if (this.airOffset === 0) this.verticalVelocity = 0
player.position.y = terrainHeight(player.position.x, player.position.z) + this.airOffset
camera.position.copyFrom(player.position.add(new Vector3(0, 1.3, 0)))
}
}
function clamp(value: number, min: number, max: number) {
return Math.max(min, Math.min(max, value))
}
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 6d ago First seen · 129 lines · 0 tokens per session scan A e50657bb63d4
player-controllers is a skill published in the GitHub repository Shellishack/3d-web-game-dev-skills (5 stars, last pushed 3mo ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 1,273 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other skills, from other repositories
THREE.Terrain
Use this guide when an agent must build, modify, inspect, or document a terrain scene with THREE.Terrain. The library creates heightmapped Three.js terrain and provides procedural generators, filters, material blending, decoration tools, grass, image conversion, analysis, and seeded randomness.
cesiumjs-models-particles
CesiumJS models, glTF, and particle effects - Model, KHRmeshoptcompression, CAD glTF extensions, EdgeDisplayMode, ModelAnimation, ModelNode, ParticleSystem, emitters, GPM extensions. Use when loading compressed or CAD-style glTF/GLB models, controlling edge rendering, playing model animations, positioning particles…
cesiumjs-materials-shaders
CesiumJS materials and post-processing — Material, Fabric JSON, MaterialAppearance, ImageBasedLighting, PostProcessStage, PostProcessStageLibrary, bloom, depth of field, ambient occlusion, FXAA, tonemapping, BlendingState. Use when defining Fabric materials for entities or primitives, configuring PBR image-based…
battlenet-automation
Automate Battlenet tasks via Rube MCP (Composio). Always search tools first for current schemas.
houdini-gsplat-relighting
Houdini 22 Gaussian Splat relighting skill - prepare GSplats with SideFX Labs, relight them in Solaris/Karma, and rasterize them in Copernicus. Use when an agent must relight a captured splat while retaining typed scene and parameter control. Not for training or importing a new Gaussian Splat.
houdini-kinefx
Pipeline skill — typed KineFX character animation tools. Create and configure rig skeletons, set rig poses, capture joint skinning weights, and apply motion capture data via SOP-level KineFX nodes.