Cruise.jl game engine: A change of perspective

As you know, I’m the one building the game engine Cruise.jl and I just realized something.

Building a game engine is actually a tortuous task, there is so much to build so much to maintain, so much to learn.
It was a great experience for learning and all but I’m realizing that even myself won’t like where this project is going.
Not that it’s bad, just that it place so much responsibilities on me. And if even if one day this engine gain popularity, I will collapse one day.

So in order to correct that I totally changed my initial design.
It’s no more about my old modular game engine.
It’s now about a data flow driven game engine.

So what’s the difference :sweat_smile:
In my old modular game engine, I give you the modules and you do your stuffs, no base or guidance

In a dataflow driven game engine, I give you the base and you build on top of it.

So how does it works ?
I have build a graph that represent dependencies and execution order between systems. A subgraph of that graph is called a plugin.
The engine will manage plugins, their executions order, their dependencies and more.
This architecture seems more fundamental to me in the sense that whenever you need an ECS or scene tree or any other thing, you can make them as plugin and make them live together…

So now Cruise is all about adding plugins.
This way instead of making everything myself, I can scrap parts of othe packages into plugins and use them.
That architecture is mostly already implemented

Now the main problem is about the guidelines to make a plugins and it will all depends on you guys.

1- A plugin is a julia package: you define the dependencies of the plugin in the project.toml file, you use just Cruise to create the plugin, specify his dependencies. Then we import them

2- A plugin is a file to import: Here, you write your plugin in a file and then add it some plugin folder in Cruise then the engine will load them. It’s what I do now but I know it’s not that optimal.

3- Mix of both: A plugin is a package but that only specifies dependencies (it’s an empty module that only have a manifest and a project.toml) then in a different folder, we have the plugin to copy into Cruise’s dedicated folder

I’m not sure yet which one to choose.
And it will impact how I will build some part of the core.

6 Likes