Engineering
component-workflow avatar

component-workflow

Guidance for creating and integrating new ECS components, including class design, JSON serialization, custom editor UI implementation, and DI registration.

Introduction

This skill provides a structured workflow for developers adding new Entity Component System (ECS) components to the GameEngine repository. It serves as an authoritative guide for maintaining architectural consistency within the engine's data-driven model. The skill is specifically designed for developers extending the engine's core functionality, whether they are implementing new behavior-data containers or integrating complex custom editor interfaces for the properties panel. By following these established patterns, developers ensure their components remain performant, properly serializable via the SceneSerializer, and seamlessly integrated with the editor's UI infrastructure.

  • Step-by-step implementation guide covering C# class creation, serialization logic, and custom IComponentEditor development.

  • Best practices for utilizing engine-specific UI utilities such as UIPropertyRenderer, VectorPanel, LayoutDrawer, and drag-drop target systems for optimized inspector workflows.

  • Mandatory dependency injection (DI) registration steps using the DryIoc container to ensure proper lifecycle management within the Editor application.

  • Standardization of naming conventions and component structural patterns, including the use of record structs for data-heavy components and class-based structures for larger components.

  • Integration instructions for the ComponentEditorRegistry to allow new components to be discoverable and editable within the engine's visual environment.

  • Use this skill whenever you add, modify, or extend ECS components within the Engine/Scene/Components/ path.

  • Always implement IComponentEditor for any new component to ensure it appears in the editor inspection panels.

  • Utilize constructor injection for all editor dependencies rather than relying on static accessors to maintain code testability and clean architecture.

  • Ensure all custom serialization logic is handled through the SceneSerializer configuration to support persistent state across scene saves and loads.

  • Performance note: keep components focused and data-only to maintain cache efficiency and effective separation of concerns between ECS systems and data containers.

Repository Stats

Stars
12
Forks
1
Open Issues
2
Language
C#
Default Branch
main
Sync Status
Idle
Last Synced
May 4, 2026, 01:13 AM
View on GitHub