Camera Pan & Zoom Controls
SkillMonitoring & opsUse when adding pan, zoom, and clamping to an isometric camera so the world stays crisp and within bounds across screen sizes.
Use Camera Pan & Zoom Controls in Claude, ChatGPT or Ahel Desktop
Free. Sign in, add Camera Pan & Zoom Controls and connect your AI. About a minute.
Also: Claude Code · Cursor · Codex
Then ask your AI: use the Camera Pan & Zoom Controls skill
Details
Instructions available. Your AI can read the instructions. Execution depends on the setup they require.
Account requirements not reviewed. Check the skill instructions before use; Ahel provides instructions and does not run this skill.
No other account needed.
Add Ahel to your AI once: Claude, ChatGPT, Cursor, Claude Code or Codex. Then ask it to use this.
What this skill tells your AI
The instructions your AI receives, as published by 0xheycat/isometric-game-skills in skills/camera-pan-zoom-controls/SKILL.md and read by Ahel’s review.
Overview
A camera is a single transform applied before drawing. This skill implements pan (drag), zoom (toward cursor), and clamping to map bounds, keeping tiles pixel-aligned to avoid shimmer.
When to Use
- The world is bigger than the screen.
- You need drag-to-pan and scroll-to-zoom.
- Tiles shimmer or the camera leaves the map.
Process
- Represent the camera as offset (x, y) and scale (zoom).
- Apply it once per frame before drawing (translate then scale).
- Pan by adding drag delta to the offset.
- Zoom toward the cursor: adjust offset so the point under the cursor stays put.
- Clamp offset and zoom so the view never leaves the map bounds.
- Snap the final transform to whole pixels to avoid tile shimmer.
- Feed the inverse transform into
tile-picking-interaction.
ctx.setTransform(zoom,0,0,zoom, -cam.x*zoom, -cam.y*zoom);
Rationalizations (Stop Lying to Yourself)
| Excuse | Reality |
|---|---|
| "Zoom toward center is fine" | Users expect zoom toward the cursor. Anchor the zoom point. |
| "Clamping is optional" | Without clamps the player pans into the void. Clamp to bounds. |
Red Flags - STOP if you catch yourself:
- Zoom anchored to screen center, not cursor.
- No bounds clamping.
- Sub-pixel camera offsets causing shimmer.
Verification
You are NOT done until every box is checked:
- Drag pans and scroll zooms toward the cursor.
- Camera is clamped within map bounds at all zooms.
- Transform snaps to whole pixels (no shimmer).
Signals
- GitHub stars
- 25
- Forks
- 3
- Last commit
- Aug 2026
Advanced
- Item type
- skill
- Key
camera-pan-zoom-controls- Source
- github.com/0xheycat/isometric-game-skills
github.com/0xheycat/isometric-game-skills
More in Monitoring & ops
Skill · anthropics
More in Monitoring & opsagent-eval
Skill · affaan-m
More in Monitoring & opspricing
Skill · coreyhaines31
More in Monitoring & opslark-okr
Skill · larksuite
More in Monitoring & opsdashboard-builder
Skill · affaan-m
More in Monitoring & opsbabysit
Skill · thedotmack
More in Monitoring & ops