I have been using entityx https://github.com/alecthomas/entityx as an ECS framework. I have been following the Examples and looking at some sample projects, and applying what they do to my own engine.
I realize now that I am doing a lot of stuff that I really have no idea whats going on behind the scenes. I also have no clue as to what this stuff is called in c++, so I am asking if you guys can give me a quick rundown on 'keywords' I should be looking up.
class Game : public entityx::Receiver<Game>
Now I would understand if this was class Game : public entityx::Receiver
as Game inheriting from Receiver class, but in this case they use the so called "Curiously recurring template pattern" of which I cant fully understand the Point?
m_systemManager.update<MovementSystem>(frameTime); <-- What is code like this called in c++?
Somehow this updates everything in my class MovementSystem : public entityx::System<MovementSystem> update function. The update function reads as so:
void update(entityx::EntityManager &entities, entityx::EventManager &events, double dt);
But I only need to pass in my time step (frameTime), so how does it get the other two parameters?
Similarly the first thing I do is add all the systems using
I am just wondering what I can read to understand what is going on behind the scenes.
Edit: One more thing I am not sure of, I see this code:
SplashViewCreator().create(); <-- What is code like this called in c++?
where SplashViewCreator is a class.
I have never seen a class initiated and used without an object of it first being created... e.g. I would expect
Are those two things equivalent?
Thanks for your time.