Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Need a better definition of Systems and components #145

Open
BenjaFriend opened this issue Mar 8, 2020 · 0 comments
Open

Need a better definition of Systems and components #145

BenjaFriend opened this issue Mar 8, 2020 · 0 comments
Labels
enhancement New feature or request PRI 2 Priority 2; Important triage This issue needs triage

Comments

@BenjaFriend
Copy link
Member

BenjaFriend commented Mar 8, 2020

Right now the engine component model is somewhat monolithic and does not provide a clear path for users to go about making a new system.

I think the best way to go about solving this problem is to actually introduce the concept of System's into our data model. The engine will manage the lifetime of these systems for you, giving you a couple options to choose from when creating one.

Definitions

  1. A WorldSystem - A world system will share the lifetime of it's owning world, being started and destroyed when the world does. By sharing the lifetime of a world this makes it easy to write gameplay systems, silar to Unreal's UWorldSubsystem and Unity's "Press Play" ideology.
  2. A PersistentSystem - A system that will share the lifetime of the engine as a whole. It will be started when the engine is launched, and shutdown when the application closes. This is what the engine itself can use to do things like rendering, input, and other systems that need to be about during the entire lifetime.
  3. EditorSystem - A system that shares the lifetime of the editor, which will make it simple to have some debug systems that you can create tools in and exclude from development builds.

Code Structure

class System
| 
|-- World System
|-- -- Any user defined gameplay subsystems
|-- -- Lua Scripting system
|-- -- Game type Definitions 
|-- PersistentSystem
|-- -- Rendering systems
|-- -- Input systems
|-- -- File IO systems
|-- EditorSystem
|-- -- Editor systems like ImGUI options or other tools
@BenjaFriend BenjaFriend added enhancement New feature or request PRI 2 Priority 2; Important triage This issue needs triage labels Mar 8, 2020
@BenjaFriend BenjaFriend pinned this issue Mar 8, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request PRI 2 Priority 2; Important triage This issue needs triage
Projects
None yet
Development

No branches or pull requests

1 participant