editor-undo-redo-contract

Manage deterministic undo/redo operations for Godot editor plugins.

2|Updated Feb 22, 2026
One-click install
npx skills add https://github.com/DubDev720/gdref --skill editor-undo-redo-contract
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: editor-undo-redo-contract
Source: https://github.com/DubDev720/gdref/tree/main/godot-skills/godot-tertiary/editor-undo-redo-contract
Command: npx skills add https://github.com/DubDev720/gdref --skill editor-undo-redo-contract

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill ensures that changes made by Godot editor plugins to the scene or resource state are safely and correctly handled by the editor's undo/redo system, preventing data corruption and ensuring a stable editing experience.

Core Features & Use Cases

  • Deterministic Undo/Redo: Wraps editor mutations in explicit undo actions with matching do/undo operations.
  • Scene History Correctness: Maintains accurate scene history, especially in multi-scene editor contexts.
  • Use Case: When developing a plugin that automatically refactors node properties, this Skill guarantees that the refactoring can be undone precisely, preserving the integrity of the scene file.

Quick Start

Use the editor-undo-redo-contract skill to safely apply a batch of changes to the current scene.

Frequently Asked Questions about editor-undo-redo-contract

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I make Godot editor plugin changes reversible without corrupting the scene?

To ensure safe Godot editor mutations, you must wrap plugin changes in explicit undo actions using EditorUndoRedoManager. This requires matching do and undo operations to maintain deterministic scene history and prevent file corruption during automated refactoring.

What is EditorUndoRedoManager and when do I need it for Godot plugin development?

EditorUndoRedoManager is Godot's built-in system for tracking scene and resource state changes. You need it when developing editor plugins that modify nodes or resources, ensuring that batch edits, autofixes, and tool actions can be safely undone.

How do I handle undo and redo operations for batch edits in a Godot editor tool?

Handling undo and redo for batch edits in a Godot editor tool requires grouping all property changes into a single EditorUndoRedoManager action. You must provide explicit do/undo parity for every mutated node to guarantee the batch reverts cleanly.

Does Godot undo redo work correctly when modifying multiple scenes simultaneously?

Godot undo redo works correctly across multiple scenes only when provided with a custom context. Managing multi-scene editor contexts requires explicit context assignment to keep scene history accurate and prevent cross-scene state corruption.

Why do my Godot plugin undo actions cause scene history errors?

Godot plugin undo actions cause scene history errors when there is a mismatch between do and undo operations. Ensuring deterministic undo requires exact do/undo parity for every modified property, preventing broken history entries during automated refactoring.