object
БесплатноБез исполняемых скриптовНе проверенInteractable things in the world — the atoms of adventure
Об этом скилле
Object
"Everything is an object. Objects have slots. Slots hold data OR behavior." — Dave Ungar, Self: The Power of Simplicity
What Is It?
An Object is anything you can interact with in the adventure world. Keys, lamps, chests, furniture, food, tools — all objects.
Objects are the atoms of the adventure. They:
- Have an identity (id, name, description)
- Advertise their actions (The Sims style)
- Contain state (lit, fuel, uses)
- Inherit from prototypes (Self style)
The Sims Architecture
From Will Wright's SimAntics:
"The intelligence is in the objects, not the characters."
Objects advertise what they can do:
advertisements:
LIGHT:
description: "Light the lamp"
score: 80
guard: "lamp has fuel"
effect: "Darkness retreats"
The character picks from what's advertised. No hardcoded behavior.
Self-Style Prototypes
An object that is a variant of another says so and states only what differs:
# examples/oil-lamp.yml
name: "Oil Lamp"
inherits: [brass-lantern.yml] # simulate, methods and advertisements come from there
state:
lit: false
fuel: 60
A lookup reads the object, then each inherits: parent depth-first, then the defaults.object
of enclosing CONTAINER.yml files, then the prototype object. A map the object states replaces
the inherited map whole, so an object with its own advertisements: gets none of its parent's.
The prototype object
OBJECT.yml in this skill is the prototype object: type: object, empty
tags, state, advertisements and methods, and false takeable, container, locked,
hidden, disabled. It is the implied parent of every OBJECT.yml and of every embedded
object in an objects: collection. A plain object file (lamp.yml) has no implied parent; it
reaches the prototype through inherits: [skills/object] or gets kind defaults from a
container's defaults.object.
Where objects live
| Size | Address | When |
|---|---|---|
| file | pub/lamp.yml |
most objects |
| directory | pub/cat-cave/OBJECT.yml |
an object with files or objects of its own |
| embedded | garden/ROOM.yml#objects.bench |
small things that belong to one room |
| catalog entry | aisle-e/PROTOTYPES.yml#prototypes.wine-rack |
many related prototypes in one file |
All four answer lookups the same way. An embedded object that grows moves into its own
directory without changing any lookup result. Worked objects are in examples/.
Object Properties
| Property | Purpose |
|---|---|
id |
Unique identifier |
name |
Display name |
type |
Category (item, furniture, tool) |
description |
What player sees |
examine |
Detailed look |
takeable |
Can be picked up |
container |
Can hold things |
contains |
What's inside |
hidden |
Invisible to players (prototypes, triggers, agents) |
state |
Mutable properties |
advertisements |
Available actions |
methods |
Named behaviors (see Methods) |
inherits |
Prototype chain |
State
Objects have mutable state:
state:
lit: false
fuel: 100
uses_remaining: 3
State changes are tracked in YAML. The adventure is the save game.
Simulate — Object Update Loops
THE SIMS INSIGHT: Objects manage their own simulation!
Every object can have a simulate property — a natural language description of what happens each turn. The compiler generates a closure that receives world.
simulate: |
if lit:
consume_fuel(1)
if fuel <= 0:
extinguish()
emit("The lamp sputters and dies!")
This compiles to:
simulate_js: (world) => {
if (world.object.state.lit) {
world.consume_fuel(1);
if (world.object.state.fuel <= 0) {
world.extinguish();
world.emit("The lamp sputters and dies!");
}
}
}
Resilience — The SimCity Zone Pattern
WILL WRIGHT INSIGHT:
"SimCity zones are self-healing. If one tile burns but the center survives, the zone will eventually rebuild."
Simulation functions should be:
1. Robust — Handle Missing Data
// BAD: crashes if state is undefined
if (world.object.state.fuel > 0) { ... }
// GOOD: defensive access
if ((world.object.state?.fuel ?? 0) > 0) { ... }
2. Self-Initializing — Create Default State
simulate: |
first ensure state.lit exists (default false)
ensure state.fuel exists (default 100)
then proceed with normal simulation
The compiled code initializes missing state:
simulate_js: (world) => {
const state = world.object.state ??= {};
state.lit ??= false;
state.fuel ??= 100;
// Now safe to proceed...
}
3. Self-Healing — Recover from Corruption
simulate: |
if fuel is somehow negative, reset to 0
if lit but fuel is 0, extinguish (inconsistent state!)
if broken flag is set but durability is full, clear broken
The c
Установить object в Claude Code и Claude Desktop
Зарегайся, чтобы установить скилл
Создай бесплатный аккаунт, чтобы открыть команду установки и сохранить скилл в библиотеку.
- Открой команду установки в одну строку
- Сохраняй скиллы в синхронизируемую библиотеку
- Уведомления, когда скиллы обновляются
Разрешённые инструменты
Инструменты, которые скиллу разрешено вызывать.
read_filewrite_fileВложенные файлы
FAQ
Что делает скилл object?
Interactable things in the world — the atoms of adventure
Как установить скилл object?
Скопируй папку скилла в ~/.claude/skills (вкладка Claude Code выше делает это одной командой), либо поставь как плагин.
Скилл object запускает скрипты?
Нет, скилл состоит только из инструкций (SKILL.md), без исполняемых скриптов.
Похожие скиллы
theme-factory
Toolkit for styling artifacts with a theme. These artifacts can be slides, docs, reportings, HTML landing pages, etc. There are 10 pre-set themes with…
от Anthropicaccess
Manage Discord channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
от Anthropicconfigure
Set up the Discord channel — save the bot token and review access policy. Use when the user pastes a Discord bot token, asks to configure Discord, asks "how…
от Anthropicaccess
Manage iMessage channel access — approve pairings, edit allowlists, set DM/group policy. Use when the user asks to pair, approve someone, check who's allowed…
от Anthropic