# malunwen/jce architecture

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

- Interactive diagram: https://gitdiagram.com/malunwen/jce
- Repository: https://github.com/malunwen/jce

## Overview

JCE is a cross-platform, data-driven game engine with a C++ editor that consumes the same engine code as shipped games. The main workflow is authoring project assets and scenes in the editor, configuring rendering and other systems, then running or building the project on the engine. The README also documents scripting-language bindings and a model-agnostic AI bridge. The graph uses documented architecture and capabilities; source excerpts are partial, so internal links not directly supported by them are omitted.

Main entry points: [`engine/include/jce/application/jce_runtime.h`](https://github.com/malunwen/jce/blob/main/engine/include/jce/application/jce_runtime.h) (Game runtime), [`editor/src/ui/jce_editor_panels.cpp`](https://github.com/malunwen/jce/blob/main/editor/src/ui/jce_editor_panels.cpp) (Editor panels), [`engine/src/application/jce_engine.c`](https://github.com/malunwen/jce/blob/main/engine/src/application/jce_engine.c) (Application loop), [`editor/src/core/jce_editor.cpp`](https://github.com/malunwen/jce/blob/main/editor/src/core/jce_editor.cpp) (Editor application)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_editor["Editor authoring"]
  node_editor_app["Editor application<br/>[jce_editor.cpp]"]
  node_editor_ui["Editor panels"]
  node_asset_authoring["Asset authoring"]
  node_render_authoring["Render pipeline editor"]
end

subgraph group_project["Project pipeline"]
  node_project_state["Project settings"]
  node_build["Build and cook"]
end

subgraph group_engine["Engine runtime"]
  node_asset_manager["Asset manager"]
  node_engine_app["Application loop<br/>[jce_engine.c]"]
  node_scene["Scene systems<br/>[jce_scene.h]"]
  node_renderer["Renderer"]
  node_game["Game runtime<br/>[jce_runtime.h]"]
end

subgraph group_extensions["Language and AI"]
  node_scripting["Script bindings"]
  node_ai_panel["AI assistant panel"]
  node_llm_bridge["LLM bridge<br/>[jce_llm.h]"]
end

node_developer(("Developer"))
node_provider(("Model provider"))

node_developer -->|"authors with"| node_editor_app
node_editor_app -.->|"presents"| node_editor_ui
node_editor_ui -.->|"offers"| node_asset_authoring
node_developer -.->|"configures"| node_project_state
node_asset_authoring -.->|"prepares assets"| node_asset_manager
node_render_authoring -->|"configures"| node_renderer
node_project_state -.->|"configures"| node_build
node_build -->|"builds for"| node_game
node_game -->|"runs on"| node_engine_app
node_engine_app -->|"orchestrates"| node_renderer
node_engine_app -->|"delegates assets"| node_asset_manager
node_game -.->|"uses"| node_scene
node_game -->|"can use"| node_scripting
node_editor_ui -->|"offers"| node_ai_panel
node_ai_panel -->|"uses"| node_llm_bridge
node_llm_bridge -->|"invokes program"| node_provider

click node_editor_app "https://github.com/malunwen/jce/blob/main/editor/src/core/jce_editor.cpp"
click node_editor_ui "https://github.com/malunwen/jce/blob/main/editor/src/ui/jce_editor_panels.cpp"
click node_asset_authoring "https://github.com/malunwen/jce/blob/main/editor/src/panels/jce_panel_assets.cpp"
click node_render_authoring "https://github.com/malunwen/jce/blob/main/editor/src/panels/jce_panel_render_pipeline.cpp"
click node_project_state "https://github.com/malunwen/jce/blob/main/editor/src/core/jce_editor_project_state.cpp"
click node_build "https://github.com/malunwen/jce/blob/main/editor/src/core/jce_build_manager.cpp"
click node_asset_manager "https://github.com/malunwen/jce/blob/main/engine/src/resource/jce_asset_manager.c"
click node_engine_app "https://github.com/malunwen/jce/blob/main/engine/src/application/jce_engine.c"
click node_scene "https://github.com/malunwen/jce/blob/main/engine/include/jce/middleware/scene/jce_scene.h"
click node_renderer "https://github.com/malunwen/jce/blob/main/engine/src/renderer/jce_render_pipeline.c"
click node_game "https://github.com/malunwen/jce/blob/main/engine/include/jce/application/jce_runtime.h"
click node_scripting "https://github.com/malunwen/jce/blob/main/scripting/c_abi/src/jce_script_api.gen.c"
click node_ai_panel "https://github.com/malunwen/jce/blob/main/editor/src/panels/jce_panel_ai_assistant.cpp"
click node_llm_bridge "https://github.com/malunwen/jce/blob/main/engine/include/jce/middleware/llm/jce_llm.h"

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_app,node_editor_ui,node_asset_authoring,node_render_authoring toneBlue
class node_project_state,node_build toneAmber
class node_asset_manager,node_engine_app,node_scene,node_renderer,node_game toneMint
class node_scripting,node_ai_panel,node_llm_bridge toneRose
class node_developer,node_provider toneIndigo
```

## Components

### Editor authoring

- [Editor application](https://github.com/malunwen/jce/blob/main/editor/src/core/jce_editor.cpp): `editor/src/core/jce_editor.cpp`
- [Editor panels](https://github.com/malunwen/jce/blob/main/editor/src/ui/jce_editor_panels.cpp): `editor/src/ui/jce_editor_panels.cpp`
- [Asset authoring](https://github.com/malunwen/jce/blob/main/editor/src/panels/jce_panel_assets.cpp): `editor/src/panels/jce_panel_assets.cpp`
- [Render pipeline editor](https://github.com/malunwen/jce/blob/main/editor/src/panels/jce_panel_render_pipeline.cpp): `editor/src/panels/jce_panel_render_pipeline.cpp`

### Project pipeline

- [Project settings](https://github.com/malunwen/jce/blob/main/editor/src/core/jce_editor_project_state.cpp): `editor/src/core/jce_editor_project_state.cpp`
- [Build and cook](https://github.com/malunwen/jce/blob/main/editor/src/core/jce_build_manager.cpp): `editor/src/core/jce_build_manager.cpp`

### Engine runtime

- [Asset manager](https://github.com/malunwen/jce/blob/main/engine/src/resource/jce_asset_manager.c): `engine/src/resource/jce_asset_manager.c`
- [Application loop](https://github.com/malunwen/jce/blob/main/engine/src/application/jce_engine.c): `engine/src/application/jce_engine.c`
- [Scene systems](https://github.com/malunwen/jce/blob/main/engine/include/jce/middleware/scene/jce_scene.h): `engine/include/jce/middleware/scene/jce_scene.h`
- [Renderer](https://github.com/malunwen/jce/blob/main/engine/src/renderer/jce_render_pipeline.c): `engine/src/renderer/jce_render_pipeline.c`
- [Game runtime](https://github.com/malunwen/jce/blob/main/engine/include/jce/application/jce_runtime.h): `engine/include/jce/application/jce_runtime.h`

### Language and AI

- [Script bindings](https://github.com/malunwen/jce/blob/main/scripting/c_abi/src/jce_script_api.gen.c): `scripting/c_abi/src/jce_script_api.gen.c`
- [AI assistant panel](https://github.com/malunwen/jce/blob/main/editor/src/panels/jce_panel_ai_assistant.cpp): `editor/src/panels/jce_panel_ai_assistant.cpp`
- [LLM bridge](https://github.com/malunwen/jce/blob/main/engine/include/jce/middleware/llm/jce_llm.h): `engine/include/jce/middleware/llm/jce_llm.h`

### Other components

- **Developer**
- **Model provider**

## Connections

- Developer → Editor application: authors with (evidence: `README.md`)
- Editor application → Editor panels: presents
- Editor panels → Asset authoring: offers
- Developer → Project settings: configures
- Asset authoring → Asset manager: prepares assets
- Render pipeline editor → Renderer: configures (evidence: `editor/src/panels/jce_panel_render_pipeline.cpp`)
- Project settings → Build and cook: configures
- Build and cook → Game runtime: builds for (evidence: `README.md`)
- Game runtime → Application loop: runs on (evidence: `README.md`)
- Application loop → Renderer: orchestrates (evidence: `engine/src/application/jce_engine.c`)
- Application loop → Asset manager: delegates assets (evidence: `engine/src/application/jce_engine.c`)
- Game runtime → Scene systems: uses
- Game runtime → Script bindings: can use (evidence: `README.md`)
- Editor panels → AI assistant panel: offers
- AI assistant panel → LLM bridge: uses (evidence: `README.md`)
- LLM bridge → Model provider: invokes program (evidence: `README.md`)
