Skip to main content
Glama

Write a row the player can hold or cast

make_item
DestructiveIdempotent

Create or rewrite an RPG Maker MZ Items, Weapons, Armors or Skills row, compiling named effects and traits into valid engine JSON and checking type ids.

Instructions

An Items, Weapons, Armors or Skills row in one call, with the effects and equipment rules spelled in words. The effect shape is the whole reason this exists: MZ stores an item effect as {code, dataId, value1, value2} — 11 recovers HP as mhp × value1 + value2, 12 MP, 13 TP, 21 and 22 add and remove a state, 31 and 32 add a buff and a debuff (dataId is the parameter, value1 the turns), 33 and 34 remove them, 41 is the special (0 = escape), 44 runs a common event — while a trait on the same row is {code, dataId, value} with one key. Send the trait's value to an effect and the engine computes mhp × undefined, floors it to NaN, and adds NaN to the actor's HP: a number the bar cannot draw and the save file now has to carry. This compiles the words into the two shapes and refuses a state, parameter or common event the project does not have. The type ids are the other quiet failure: an item whose itypeId is not 1 or 2 is never listed — MZ has no item-type name list, the menu reads those two numbers and $dataSystem.itemCategories decides whether the tab is open at all — and a weapon whose wtypeId matches no weapon type cannot be equipped by anyone, so both are checked against System.json and said out loud. Idempotent by name, like the rest of the layer: re-running a build script rewrites the same row instead of adding one.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idNoRewrite this row instead of making one
iconNoIndex into img/system/IconSet.png
nameNo
noteNo
priceNo
scopeNo0 none, 1 one enemy, 2 all enemies, 3 random, 7 self, 8 one ally, 9 all allies, 10 party, 11 dead ally
speedNoAction order bonus, the engine's own field
tableNoDefault Items
damageNo
dryRunNo
mpCostNoSkills only
paramsNoWeapons and armors: the flat parameter change when equipped
tpCostNoSkills only
tpGainNo
traitsNoWeapons and armors: the engine's own {code, dataId, value}, single value
atypeIdNoArmors: System.armorTypes
effectsNo
etypeIdNoWeapons and armors: the equipment slot, System.equipTypes
itypeIdNoItems: 1 for the Item tab, 2 for the Key Item tab. MZ keeps no item-type name list, so any other number leaves the row out of the menu
repeatsNo
stypeIdNoSkills only: the type from System.skillTypes, by name or id
wtypeIdNoWeapons: System.weaponTypes — a row nothing names cannot be equipped
copyFromNo
message1NoSkills only: the battle log line, `X uses …`
message2NoSkills only: the second battle log line
occasionNo0 any time, 1 menu only, 2 battle only, 3 never — never is not the same as unbuyable
consumableNo
animationIdNo
descriptionNo
successRateNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.4.2

TDQS

B3.4/5.0
Behavior4/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already declare idempotentHint=true and destructiveHint=true; the description reinforces idempotency ('re-running a build script rewrites the same row instead of adding one') and adds substantial extra context: validation/refusal of unknown states, parameters and common events, and the NaN failure mode from mismatching trait/effect shapes. It stops short of explaining reversibility or the destructive profile explicitly, so 4 rather than 5.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness3/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Purpose is front-loaded in the opening clause, which is good, but the body is a long single block dense with engine lore (NaN arithmetic, item-type menu behavior) that is educational yet costly for a tool-selection summary. It is not padded with filler, but it is longer than the selection decision requires.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a high-complexity 30-param, nested-object mutation tool with no output schema, the description covers the effect/trait compilation contract, validation refusals, and idempotency. It omits return/result behavior and the dryRun path, but the core failure modes an agent must avoid are addressed.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

With 30 parameters, 57% schema description coverage and nested objects, the schema does much of the work. The description adds genuine conceptual value by explaining the {code,dataId,value1,value2} effect shape versus the {code,dataId,value} trait shape and the itypeId/wtypeId validity rules, but leaves many uncovered params (dryRun, copyFrom, note, repeats) to the schema, so baseline 3 is right.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb (write/make) and resource (a row across Items/Weapons/Armors/Skills), and the framing 'Write a row the player can hold or cast' is concrete. It explains what makes it distinct (compiling effects/traits into engine shapes), but never names the generic siblings like create_database_entry or patch_database_entry it presumably supersedes, so an agent must infer the routing.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description is rich on what the tool does and why, but gives no explicit when-to-use versus when-not guidance and no alternatives. There is no mention of dryRun or when to prefer this over the generic database tools, so the agent gets no routing signal beyond implied specialism.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.