1
votes

First, I am building a little 3D engine in c++, just for fun. This is said to me quite often:

You should have your game use the engine as a library. But I thought it would be better the other way around, like here. Thus have the engine being the executable, and have it just call the game classes loop functions in order(classes either compiled with the engine exe, or loaded from a dll/so).

This because in my game engine, the engine has an editor, and you create game classes(eg. a player controller) by creating a class derived from GameObject. And have the engine being the game executable, and have it call the Loop function of that class every frame.

This seems better to me, as it only needs an engine that calls the game classes.

So what would you recommend based on what I said and the link?

Thanks!

1

1 Answers

-1
votes

Both have their pros & cons:

LIBRARY:

  • You can have things and size compact use the part of engines you want
  • You can make high end compatible games a bit ported to the low end ones.

GAME ENGINE:

  • Things will get easier.

  • Less time consuming