# Game assets from a coding agent on a local Ollama model

> Run a coding agent on a local Ollama model and still make game art: OpenCode takes the asset tool, while each picture is made on Tyrbo’s service.

- URL: https://tyrbo.ai/ai-game-assets-with-ollama
- Title: AI Game Assets with Ollama and a Local Model
- Language: English (en)
- Updated: 2026-11-26

Ollama runs language models on your own machine; it is not an agent and does not host MCP servers. What it does offer is `ollama launch opencode`, which starts the OpenCode agent on a model you pick, and OpenCode takes asset gen’s server. So the agent’s thinking runs locally, while each picture, sheet or model it asks for is made on Tyrbo’s service with your account’s credits, the same as from any other agent. The sprite stacks on this page are a good first job for that setup: cheap, quick and easy to check.

Send this to your agent

```
Set up Tyrbo asset gen for me so I can make my game's art, sprite sheets, animated characters, 3D models, UI and sound from here, all in one look.
1. Install the CLI: run `npm install -g @tyrbo/asset` (Node 20.11 or later).
2. Add the skill: in Claude Code, run `claude plugin marketplace add https://cdn.jsdelivr.net/npm/@tyrbo/asset/.claude-plugin/marketplace.json`, then `claude plugin install tyrbo-asset@tyrbo`. In another MCP client, add the MCP server `npx -y @tyrbo/asset mcp`. In any other agent, read `asset --help` before the first call.
3. Check it, free: in an empty scratch folder, not my game's, run `asset look grove "hand-painted fantasy forest, soft dappled light" --view top-down --mock`. It needs no key and writes stand-in files there.
4. Authenticate: ask me to make an asset key at https://app.tyrbo.ai/?from=/asset-generator#/settings/assets (Settings, Asset gen) and to run `asset login` in my own terminal, pasting the key there. Never ask me for the key in chat, and never run `asset login` yourself. Once I have, run `asset spend` to see it works.
Once that's done, let me know when it's ready.
```

[Get an asset key](https://app.tyrbo.ai/?from=/asset-generator#/settings/assets)[Read the docs](https://tyrbo.ai/asset-generator/docs)

## Set it up in Ollama

1. **Install the CLI** Install the asset command (Node 20.11 or later). `npm install -g @tyrbo/asset`
2. **Add the MCP server to Ollama** Run its own command, which writes the server into opencode.json, after ollama launch opencode starts OpenCode on a local model. `opencode mcp add tyrbo-asset -- npx -y @tyrbo/asset mcp`
3. **Try it free** In an empty scratch folder, a mock call checks the setup with no key: it writes stand-in files and spends nothing. `asset look grove "hand-painted fantasy forest, soft dappled light" --view top-down --mock`
4. **Log in in your own terminal** Make an asset key in the Tyrbo app (Settings, Asset gen) and paste it into asset login yourself. The agent never asks for the key and never runs the login. `asset login`

Ollama’s own docs, read November 25, 2026:

- [https://docs.ollama.com/integrations](https://docs.ollama.com/integrations)
- [https://docs.ollama.com/integrations/opencode](https://docs.ollama.com/integrations/opencode)

## The commands

```
asset look yard "chunky pixel art farmyard seen from above, warm greens and browns, bold outlines" --view top-down --mock
asset look yard "chunky pixel art farmyard seen from above, warm greens and browns, bold outlines" --view top-down
asset stack well "a round stone well with a little wooden roof and a bucket" --view top-down
asset stack tree "a round leafy oak tree on a short trunk" --smooth --view top-down
asset stack racecar "a red open-wheel race car with white racing stripes, a big number 7 on its nose, four fat black tyres, a driver in a yellow helmet in the cockpit and a rear wing" --view top-down
asset spend
```

## Made by the CLI, not drawn for this page

Real files the asset CLI wrote, each under the command that made it.

![The stone well’s 26 pixel slices spread apart, coming together into the well, then turning round](https://tyrbo.ai/asset-gen/yard/well-slices.webp)

### See prompt

`asset stack well "a round stone well with a little wooden roof and a bucket" --view top-down`

![The oak tree’s 90 smooth slices spread apart, coming together into the tree, then turning round](https://tyrbo.ai/asset-gen/yard/tree-slices.webp)

### See prompt

`asset stack tree "a round leafy oak tree on a short trunk" --smooth --view top-down`

![The red race car’s 12 pixel slices spread apart, coming together into the car, then turning round](https://tyrbo.ai/asset-gen/yard/racecar-slices.webp)

### See prompt

`asset stack racecar "a red open-wheel race car with white racing stripes, a big number 7 on its nose, four fat black tyres, a driver in a yellow helmet in the cockpit and a rear wing" --view top-down`

## Where each part runs

It helps to be clear about the split:

- **On your machine:** Ollama and the model, OpenCode, and the asset server OpenCode starts.
- **On Tyrbo’s service:** the image, video and 3D models each paid call uses, billed to your credits.

A local model keeps your code and your chat at home, and it costs you nothing per token. It does not make the art free. `--mock` calls are free, as are verbs such as `asset synth`, `asset clips` and `asset convert`, and a call you made before comes from your account’s cache.

## Small models and tool calls

Be honest with yourself about the model. Ollama’s OpenCode page asks for a context window of 64k or more, and the model has to support tool calling at all. Smaller local models call tools less reliably than large hosted ones: a list of words split in the wrong place, a flag invented, a call repeated.

Asset gen copes with most of that. A flag a verb does not take is refused with the reason, which the agent can read and fix. A repeat is answered from the cache. A paid call your credits cannot cover is refused before anything is spent. Still, keep the first session on `--mock` until the model calls the tool cleanly, and watch `asset spend` when you switch to real calls.

## Why sprite stacks suit a first run

`asset stack` asks a cheap model for a recipe, about a tenth of a cent, then builds the thing as slices a 2D game draws one layer at a time so it turns in place and looks solid. It writes the sheet, its atlas and `<name>.anim.json`, plus a `.glb` and a turntable to look at. The recipe is kept as `stack/<name>-recipe.json`: edit it and pass it back with `--of`, free.

That makes for short, forgiving asks. The agent says what the thing is, and you check `well-slices.png` with your own eyes. If the agent gets the words wrong, the cost of trying again is tiny.

## Questions people ask

### Does `ollama launch opencode` change my OpenCode config?

No. Ollama’s docs say it passes the model inline and leaves your own config alone. The asset server is added with OpenCode’s own command, shown above, and stays there.

### Can another agent use my Ollama model instead?

Ollama lists other agents it can launch, and several editors point at a local Ollama endpoint. Any of them that hosts MCP servers or runs shell commands can use asset gen the same way.

### Do I need credits if my model is local?

For real art, yes: pictures and models are made on Tyrbo’s service. You can wire the whole game first with `--mock`, which needs no key. See [pricing](https://tyrbo.ai/pricing) for what credits cost.

## For your coding agent

- [Game assets for Claude Code](https://tyrbo.ai/ai-game-assets-for-claude-code)
- [Game assets for Cursor](https://tyrbo.ai/ai-game-assets-for-cursor)
- [Game assets for Codex](https://tyrbo.ai/ai-game-assets-for-codex)
- [Game assets for Gemini CLI](https://tyrbo.ai/ai-game-assets-for-gemini-cli)
- [Game assets for Cline](https://tyrbo.ai/ai-game-assets-for-cline)
- [Game assets for Kilo Code](https://tyrbo.ai/ai-game-assets-for-kilo-code)
- [Game assets for Roo Code](https://tyrbo.ai/ai-game-assets-for-roo-code)
- [Game assets for OpenCode](https://tyrbo.ai/ai-game-assets-for-opencode)
- [Game assets for Windsurf](https://tyrbo.ai/ai-game-assets-for-windsurf)
- [Game assets for GitHub Copilot](https://tyrbo.ai/ai-game-assets-for-github-copilot)
- [Game assets for Zed](https://tyrbo.ai/ai-game-assets-for-zed)
- [Game assets for Aider](https://tyrbo.ai/ai-game-assets-for-aider)

## More from the asset generator

- [Asset generator](https://tyrbo.ai/asset-generator)
- [Docs](https://tyrbo.ai/asset-generator/docs)
- [Top-down RPG character sprite sheet](https://tyrbo.ai/top-down-rpg-character-sprite-sheet)
- [AI 3D model generator for games](https://tyrbo.ai/ai-3d-model-generator-for-games)
- [Auto-rig a 3D model for games](https://tyrbo.ai/auto-rig-3d-model-for-games)
- [Game UI generator](https://tyrbo.ai/game-ui-generator)
- [AI sprites for Godot](https://tyrbo.ai/ai-sprites-for-godot)
- [Pixel art asset generator](https://tyrbo.ai/pixel-art-asset-generator)

## Install it, then ask for the look.

[Get an asset key](https://app.tyrbo.ai/?from=/asset-generator#/settings/assets)

Make a key in the Tyrbo app, then run asset login. Add --mock to try any command free first.

---

This is the Markdown version of https://tyrbo.ai/ai-game-assets-with-ollama, from Tyrbo (The AI game engine). Cite and link the page itself. Every page: https://tyrbo.ai/llms.txt