Skip to main content
skill CX Codex

canvas2d-isometric-renderer — Claude Code skill: isometric Canvas 2D

Builds the draw loop for an isometric tilemap on Canvas 2D: ground tiles first, depth-sorted sprites after.

Install into Claude Code · Skills CLI (Vercel) All methods and platforms ↓
npx skills add 0xheycat/isometric-game-skills --skill canvas2d-isometric-renderer -a claude-code
Open on GitHub

What canvas2d-isometric-renderer does

This skill lays out the render backbone for an isometric world. Ground tiles go back-to-front by row and column, then objects and characters follow in depth order. Coordinate work comes from isometric-grid-math, images from the atlas packed by spritesheet-atlas-packing, and the camera transform is applied once per frame.

What you get is a seven-step process, a short JavaScript loop example, and a table of excuses it refuses to accept — drawing the whole map every frame being the first one. A red-flags list names the usual failure points: no viewport culling, fresh arrays allocated inside the draw loop, tile pass and object pass tangled together.

The skill leans on its neighbours. Skip depth-sorting-occlusion and sprites end up behind walls; skip camera-pan-zoom-controls and there is no transform to apply. Verification asks for three checks: tiles drawn back-to-front, objects drawn after tiles in depth order, and nothing drawn outside the visible area.

What it helps with

  • draw an isometric tilemap on Canvas 2D
  • fix sprite order when objects hide behind walls
  • wire grid math and a sprite atlas into one draw loop
  • cull tiles outside the visible viewport
  • stop allocating arrays inside the draw loop

Example prompts for the agent

  • Build the isometric draw loop: ground tiles first, then objects sorted by depth
  • Sprites render in the wrong order — trace the draw loop and fix it
  • Add viewport culling to the current tile pass

How to install canvas2d-isometric-renderer

1Skills CLI (Vercel)

npx skills add 0xheycat/isometric-game-skills --skill canvas2d-isometric-renderer -a claude-code

2Manually: put the files in place

~/.claude/skills/canvas2d-isometric-renderer/SKILL.md

Copy the whole skill folder; for one project use .claude/skills/canvas2d-isometric-renderer/

Step by step, with commands for each platform: How to install skills in Claude Code: five ways

Questions about canvas2d-isometric-renderer

How do I install canvas2d-isometric-renderer in Claude Code?

Run npx skills add 0xheycat/isometric-game-skills --skill canvas2d-isometric-renderer -a claude-code. The skill lands at ~/.claude/skills/canvas2d-isometric-renderer/SKILL.md.

What does canvas2d-isometric-renderer do?

It defines how an isometric scene gets drawn: ground tiles back-to-front, then objects and characters sorted by depth. Coordinates come from isometric-grid-math and images from the atlas.

Which skills does it work with?

The process points to isometric-grid-math for coordinate conversion, depth-sorting-occlusion for sorting, spritesheet-atlas-packing for the atlas, and camera-pan-zoom-controls for the camera transform.

Source text

SKILL.md · MIT
---
name: canvas2d-isometric-renderer
description: Use when building a Canvas 2D renderer that draws an isometric tilemap and sprites efficiently with correct ordering.
license: MIT
---

# Canvas2D Isometric Renderer

## Overview

This skill builds the core render loop: draw ground tiles back-to-front, then depth-sorted objects, using the grid math transform and the atlas. It is the backbone every gameplay skill plugs into.

## When to Use

- You need to actually draw the isometric world.
- Tiles or sprites render in the wrong order.
- You are wiring grid math + atlas into a render loop.

## Process

1. Use `isometric-grid-math` for all coordinate conversions.
2. Draw ground tiles in back-to-front order (by row+col).
3. Draw objects/characters AFTER tiles, sorted by depth (see `depth-sorting-occlusion`).
4. Source every image from the atlas (see `spritesheet-atlas-packing`).
5. Apply the camera transform once per frame (see `camera-pan-zoom-controls`).
6. Only draw tiles within the visible viewport (culling).
7. Keep the draw loop pure - no allocations per frame.

```js
for (const tile of tilesInView) drawTile(tile);
for (const obj of sortByDepth(objectsInView)) drawSprite(obj);
```

## Rationalizations (Stop Lying to Yourself)

| Excuse | Reality |
|---|---|
| "I will draw everything every frame" | Drawing off-screen tiles wastes the frame budget. Cull. |
| "Order does not matter much" | Wrong order = objects behind walls. Sort every frame. |

## Red Flags - STOP if you catch yourself:

- Drawing the entire map instead of the viewport.
- Allocating arrays/objects inside the draw loop.
- No separation between tile pass and object pass.

## Verification

You are NOT done until every box is checked:

- [ ] Ground tiles draw back-to-front correctly.
- [ ] Objects draw after tiles in depth order.
- [ ] Only visible tiles are drawn (culling works).

© 0xheycat · MIT · 0xheycat/isometric-game-skills

Similar skills

All skills for Game dev and 3D: Unity, Unreal, Godot, Blender →

From the same set7

Project sponsors

Companies that keep this analytics open
Gold sponsor

Impressions, clicks and code copies — open statistics. We keep the numbers public for the same reason NeBlask itself is public. Become a sponsor