A small repair with a clear finish line

How to Prompt an AI Game Maker to Fix One Bug

To fix one bug with an AI game maker, send a repeatable failure, the result you expected, the current project context, and a clear boundary for the change. Ask for a diagnosis before a patch. Save the working version, apply the smallest justified repair, and replay the same failure before accepting it.

A small repair with a clear finish line
A small repair with a clear finish line.

Write the failure before requesting the repair

Start with the player action that exposes the problem. Include the level, object, control, and starting state needed to repeat it. Separate what you saw from your guess about the cause. A character that does not move is an observation; a broken movement script is still a hypothesis.

Keep the current project attached to that description. A fresh conversation can narrow the task, but it needs the relevant files or project context and a short account of the last accepted behavior. It cannot repair an unspecified version of the game.

Choose the kind of repair before choosing the wording

Separate a successful generation from a successful repair. A broad request can produce a playable starting point, while a later local defect still survives a round of improvements. A narrow task with its own test gives you a different finish line: the named failure no longer occurs. Do not carry the freedom of the initial build into a repair prompt. State what must remain stable, then ask the assistant to explain why its proposed edit is sufficient. A larger response is not stronger evidence that the original fault has gone away.

A delayed response may belong to the asset rather than the interaction code. An audio file can contain silence before its audible content, making a correctly triggered effect seem late. Before asking for a new sound system, compare the moment of the trigger with the beginning of the actual sound. Ask the assistant to inspect that boundary and report what it can establish. If trimming the asset is the chosen repair, keep the trigger behavior unchanged so that you can tell whether the timing problem came from the file.

Name the owner of the behavior. A weapon script that works for an enemy is not automatically a player weapon, even when the objects look alike. The repair request should identify who supplies the input, which object holds the script, and which actor receives the result. Asking for another weapon can conceal that mismatch under replacement code. Asking how the current script depends on its owner makes the missing relationship inspectable. Preserve the enemy version while checking the player version, so a local correction does not silently remove the behavior that already worked.

A clean conversation and a persistent project solve different problems. Narrow sessions keep unrelated tasks out of the repair, while shared files and a written project state preserve the decisions that the repair depends on. Combine them deliberately: start a focused task with the existing project, the failing route, and the last accepted behavior. Avoid treating a blank chat as a reset of the game itself. If you change assistants, carry the same record across instead of asking the next one to reconstruct every earlier decision from the opening idea.

A claim that a camera is fixed can fail during the next movement. Likewise, an enemy that feels too fast may require a design decision rather than a missing feature. Keep those requests separate. For the camera, specify the viewpoint and route that must remain inside the intended boundary. For difficulty, state the behavior you want to change and preserve a version for comparison. Do not bundle either request with new artwork or a new level. Otherwise an attractive revision can distract you from whether the boundary or chase behavior actually changed.

Use this bounded repair prompt

The following is an illustrative prompt, not a report of a tested game or a guarantee that a provider can access your files. Replace its details with your actual reproduction.

In the current project, the player can collect the key, but the exit door stays closed. Reproduce it from a fresh start: collect the key, approach the marked door, and use the interaction control. Expected: that door opens after the key is collected. Actual: it remains closed. Inspect the key state and the door's access to that state before editing. Explain the suspected cause and the files or objects you need to change. Preserve movement, enemy behavior, artwork, and scoring. After the repair, check the door both without and with the key. Report any check you could not run.

If you have a visible error, include the exact message alongside the reproduction. In Godot, the Debugger panel has an Errors tab for runtime errors and warnings. Use the official debugger reference to find the relevant diagnostic output; do not substitute an unrelated error from an earlier run.

Check sound timing, behavior ownership, and project context
Inspect the boundary before asking for replacement code.

Accept or reject the patch against the same failure

Keep the original reproduction beside the patched build. Run it again, then check the neighboring behavior you explicitly asked to preserve. If the repair succeeds only after changing the rules, it has answered a different request. Save the result as a separate version until you accept it.

Questions that change the next prompt

Should I open a new chat for every bug?

A fresh chat is useful when it removes unrelated work while preserving the current files, intended behavior, and reproduction. If those details disappear, restore the context before requesting another patch.

What if the AI says it fixed the bug but I can still reproduce it?

Return the failing action and result, not another general request to improve the game. Identify the version you tested and ask which assumption differs from the observed behavior. Keep the old reproduction until it passes.

Should I switch tools immediately?

Before switching, preserve the current project and write a handoff note describing the unresolved failure. A replacement assistant still needs that context. Its name does not establish that it has understood the bug.

Finish with a repair record: the accepted behavior, the changed files or objects, the replay result, and anything still unverified. If the original failure remains, keep the patch out of your accepted version and continue from that record.

Use the pre-publish gameplay testing guide to find failures, and check which project or output you are actually editing before handing the repair to another tool.