# einxyz/editor-downgrade architecture

> Architecture diagram of the GitHub repository einxyz/editor-downgrade, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-09-27). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/einxyz/editor-downgrade
- Repository: https://github.com/einxyz/editor-downgrade

## Overview

EditorDowngrade is a Geometry Dash editor mod that adapts editing controls and object behavior to a selected target version, notably 1.9 versus 2.2. The visible workflow is editing in the editor: version-aware palettes expose legacy objects, placement is filtered and configured, and editor dialogs are adjusted for older rules. Version selection and browser integration are indicated by repository modules but their wiring is not visible in the sampled source. The README gives no product detail; relationships below are limited to sampled calls and explicit storage operations.

Main entry points: [`src/LevelEditorLayerHook.cpp`](https://github.com/einxyz/editor-downgrade/blob/main/src/LevelEditorLayerHook.cpp) (Level editor), [`src/EditorUIHook.cpp`](https://github.com/einxyz/editor-downgrade/blob/main/src/EditorUIHook.cpp) (Object palette), [`src/ColorSelectPopupHook.cpp`](https://github.com/einxyz/editor-downgrade/blob/main/src/ColorSelectPopupHook.cpp) (Color selection), [`src/VersionPopup.cpp`](https://github.com/einxyz/editor-downgrade/blob/main/src/VersionPopup.cpp) (Version selector)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_compat["Editor compatibility"]
  node_editor["Level editor"]
  node_palette["Object palette<br/>[EditorUIHook.cpp]"]
  node_versioncfg["Version catalog<br/>[data.hpp]"]
  node_legacytriggers["Legacy triggers<br/>[LegacyTriggers.hpp]"]
  node_effect["Effect objects"]
end

subgraph group_dialogs["Editor dialogs"]
  node_customize["Object customization"]
  node_colors["Color selection"]
  node_colorids["Color popup IDs"]
  node_settings["Level settings"]
  node_pause["Editor pause"]
end

subgraph group_version["Version state"]
  node_versionpopup["Version selector<br/>[VersionPopup.cpp]"]
  node_versionheaders["Version selector API<br/>[VersionPopup.hpp]"]
  node_browser["Level browser integration"]
  node_levelcell["Level cell integration<br/>[LevelCellHook.cpp]"]
end

subgraph group_integrations["External integrations"]
  node_storage[("Level storage API")]
  node_editorids["Editor ID API"]
end

node_player(("Editor user"))
node_game["Geometry Dash"]

node_player -->|"selects objects"| node_palette
node_palette -->|"reads categories"| node_versioncfg
node_palette -->|"dispatches placement"| node_editor
node_editor -->|"checks version rules"| node_versioncfg
node_editor -->|"reads/writes metadata"| node_storage
node_editor -->|"gets level ID"| node_editorids
node_editor -->|"configures legacy objects"| node_effect
node_editor -->|"creates objects"| node_game
node_effect -->|"uses legacy helpers"| node_legacytriggers
node_player -->|"edits object"| node_customize
node_customize -->|"reads target version"| node_storage
node_player -->|"edits colors"| node_colors
node_colors -->|"reads target version"| node_storage
node_colors -->|"registers node IDs"| node_colorids
node_player -->|"opens pause menu"| node_pause
node_pause -->|"reads target version"| node_storage
node_player -->|"opens settings"| node_settings
node_player -->|"chooses version"| node_versionpopup
node_browser -.->|"opens selector"| node_versionpopup
node_levelcell -.->|"opens selector"| node_versionpopup

click node_editor "https://github.com/einxyz/editor-downgrade/blob/main/src/LevelEditorLayerHook.cpp"
click node_palette "https://github.com/einxyz/editor-downgrade/blob/main/src/EditorUIHook.cpp"
click node_versioncfg "https://github.com/einxyz/editor-downgrade/blob/main/src/data.hpp"
click node_legacytriggers "https://github.com/einxyz/editor-downgrade/blob/main/src/LegacyTriggers.hpp"
click node_effect "https://github.com/einxyz/editor-downgrade/blob/main/src/EffectGameObjectHook.cpp"
click node_customize "https://github.com/einxyz/editor-downgrade/blob/main/src/CustomizeObjectLayerHook.cpp"
click node_colors "https://github.com/einxyz/editor-downgrade/blob/main/src/ColorSelectPopupHook.cpp"
click node_colorids "https://github.com/einxyz/editor-downgrade/blob/main/src/ColorSelectPopup.cpp"
click node_settings "https://github.com/einxyz/editor-downgrade/blob/main/src/LevelSettingsLayer.cpp"
click node_pause "https://github.com/einxyz/editor-downgrade/blob/main/src/EditorPauseLayerHook.cpp"
click node_versionpopup "https://github.com/einxyz/editor-downgrade/blob/main/src/VersionPopup.cpp"
click node_versionheaders "https://github.com/einxyz/editor-downgrade/blob/main/src/VersionPopup.hpp"
click node_browser "https://github.com/einxyz/editor-downgrade/blob/main/src/LevelBrowserLayerHook.cpp"
click node_levelcell "https://github.com/einxyz/editor-downgrade/blob/main/src/LevelCellHook.cpp"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_editor,node_palette,node_versioncfg,node_legacytriggers,node_effect,node_player toneBlue
class node_customize,node_colors,node_colorids,node_settings,node_pause toneAmber
class node_versionpopup,node_versionheaders,node_browser,node_levelcell toneMint
class node_storage,node_editorids toneRose
class node_game toneIndigo
```

## Components

### Editor compatibility

- [Level editor](https://github.com/einxyz/editor-downgrade/blob/main/src/LevelEditorLayerHook.cpp): `src/LevelEditorLayerHook.cpp`
- [Object palette](https://github.com/einxyz/editor-downgrade/blob/main/src/EditorUIHook.cpp): `src/EditorUIHook.cpp`
- [Version catalog](https://github.com/einxyz/editor-downgrade/blob/main/src/data.hpp): `src/data.hpp`
- [Legacy triggers](https://github.com/einxyz/editor-downgrade/blob/main/src/LegacyTriggers.hpp): `src/LegacyTriggers.hpp`
- [Effect objects](https://github.com/einxyz/editor-downgrade/blob/main/src/EffectGameObjectHook.cpp): `src/EffectGameObjectHook.cpp`

### Editor dialogs

- [Object customization](https://github.com/einxyz/editor-downgrade/blob/main/src/CustomizeObjectLayerHook.cpp): `src/CustomizeObjectLayerHook.cpp`
- [Color selection](https://github.com/einxyz/editor-downgrade/blob/main/src/ColorSelectPopupHook.cpp): `src/ColorSelectPopupHook.cpp`
- [Color popup IDs](https://github.com/einxyz/editor-downgrade/blob/main/src/ColorSelectPopup.cpp): `src/ColorSelectPopup.cpp`
- [Level settings](https://github.com/einxyz/editor-downgrade/blob/main/src/LevelSettingsLayer.cpp): `src/LevelSettingsLayer.cpp`
- [Editor pause](https://github.com/einxyz/editor-downgrade/blob/main/src/EditorPauseLayerHook.cpp): `src/EditorPauseLayerHook.cpp`

### Version state

- [Version selector](https://github.com/einxyz/editor-downgrade/blob/main/src/VersionPopup.cpp): `src/VersionPopup.cpp`
- [Version selector API](https://github.com/einxyz/editor-downgrade/blob/main/src/VersionPopup.hpp): `src/VersionPopup.hpp`
- [Level browser integration](https://github.com/einxyz/editor-downgrade/blob/main/src/LevelBrowserLayerHook.cpp): `src/LevelBrowserLayerHook.cpp`
- [Level cell integration](https://github.com/einxyz/editor-downgrade/blob/main/src/LevelCellHook.cpp): `src/LevelCellHook.cpp`

### External integrations

- **Level storage API**
- **Editor ID API**

### Other components

- **Editor user**
- **Geometry Dash**

## Connections

- Editor user → Object palette: selects objects
- Object palette → Version catalog: reads categories
- Object palette → Level editor: dispatches placement
- Level editor → Version catalog: checks version rules
- Level editor → Level storage API: reads/writes metadata
- Level editor → Editor ID API: gets level ID
- Level editor → Effect objects: configures legacy objects
- Level editor → Geometry Dash: creates objects
- Effect objects → Legacy triggers: uses legacy helpers
- Editor user → Object customization: edits object
- Object customization → Level storage API: reads target version
- Editor user → Color selection: edits colors
- Color selection → Level storage API: reads target version
- Color selection → Color popup IDs: registers node IDs
- Editor user → Editor pause: opens pause menu
- Editor pause → Level storage API: reads target version
- Editor user → Level settings: opens settings
- Editor user → Version selector: chooses version
- Level browser integration → Version selector: opens selector
- Level cell integration → Version selector: opens selector
