Jump to content

  • Log In with Google      Sign In   
  • Create Account

C++ Entity System


Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.

  • You cannot reply to this topic
6 replies to this topic

#1 pinebanana   Members   -  Reputation: 475

Like
0Likes
Like

Posted 15 December 2012 - 12:27 AM

After many hours of confusion on how I should implement my Entity System; it has finally been completed (at like 4 in the morning) Posted Image. This framework is based of the Java Entity System, Artemis, however it's a bit different with the way it is implemented, but you will find similarities. Unfortunately it is not entirely complete, I believe the only thing left to do is the SceneDirector, however, that's not really a required class in the framework, it's more of an add-on to help you manage Scene* objects.

*If you are familiar with the Artemis framework, a Scene is a World.

Features:
- Unlimited component-types
- Fast retrieval of components
- Creation of components, entity-systems and entity-managers through a string

If you are going to try this framework out, please submit ANY bugs and feel free to add suggestions. I have put issues in my BitBucket repo available for the public, so please submit bugs/suggestions there. There are no known bugs at the moment, I have resolved them.

NOTE:
If you are unsure what an Entity System is, I recommend reading this basic tutorial and preferably a blog, such as this one, before reading the tutorial, which describes what one is.

EDIT: Moved to tutorial to the public wiki on BitBucket, here.

Edited by pinebanana, 16 December 2012 - 11:58 PM.

anax - An open source C++ entity system


Sponsor:

#2 BeerNutts   Crossbones+   -  Reputation: 2945

Like
0Likes
Like

Posted 16 December 2012 - 10:47 AM

Good job, I know you enjoyed working on it. It has a lot of similarities to my Escape System Entity System, but it also has some differences, including some improvements.

The 1st thing I noticed that bothered me a little was the Macro requirement. As minor as it is, I couldn't help but frown when I saw it.

I haven't been able to look through it all, but it looks good so far. Have you used it extensively? When designing the Escape System, and using a test program, it seemed to all work fine. However, when I put it into an actual game, I found some other issues that had to be ironed out (which, honestly, I don't think I've uploaded to github)
My Gamedev Journal: 2D Game Making, the Easy Way

---(Old Blog, still has good info): 2dGameMaking
-----
"No one ever posts on that message board; it's too crowded." - Yoga Berra (sorta)

#3 superman3275   Crossbones+   -  Reputation: 2011

Like
0Likes
Like

Posted 16 December 2012 - 11:26 AM

Looks awesome! I've BookMarked this page, I'll probably use it in my next project.

I'm a game programmer and computer science ninja ph34r.png!

Here's my 2D RPG-Ish Platformer Programmed in Python + Pygame, with a Custom Level Editor and Rendering System!

 

Here's my Custom IDE / Debugger Programmed in Pure Python and Designed from the Ground Up for Programming Education!

Want to ask about Python, Flask, wxPython, Pygame, C++, HTML5, CSS3, Javascript, jQuery, C++, Vimscript, SFML 1.6 / 2.0, or anything else? Recruiting for a game development team and need a passionate programmer? Just want to talk about programming? Email me here:

hobohm.business@gmail.com

or Personal-Message me on here smile.png!


#4 pinebanana   Members   -  Reputation: 475

Like
0Likes
Like

Posted 17 December 2012 - 12:03 AM

Looks awesome! I've BookMarked this page, I'll probably use it in my next project.


Thanks, although I may have some minor changes when I get around to it :)


Good job, I know you enjoyed working on it. It has a lot of similarities to my Escape System Entity System, but it also has some differences, including some improvements.

The 1st thing I noticed that bothered me a little was the Macro requirement. As minor as it is, I couldn't help but frown when I saw it.


Thanks, and yeah... I would prefer not to use macros, but in order to have unlimited component types, it is required (without using hash-maps). Also, I placed them to serialise the components/systems/managers.

I haven't been able to look through it all, but it looks good so far. Have you used it extensively? When designing the Escape System, and using a test program, it seemed to all work fine. However, when I put it into an actual game, I found some other issues that had to be ironed out (which, honestly, I don't think I've uploaded to github)

I have tested it, but I don't believe all of it's features, and I have not tested the performance of it. There is probably a lot of optimizations I will do, but I still have yet to make a game with it, which will be soon. Currently I'm just a tad busy with other things :C. Thanks again.

anax - An open source C++ entity system


#5 wqking   Members   -  Reputation: 756

Like
0Likes
Like

Posted 17 December 2012 - 12:40 AM

Very interesting and good stuff.
One question, do we want to couple entity/component with scene?
I think an entity component system is an independent system which can be used freely without coupling to scene.

http://www.cpgf.org/
cpgf library -- free C++ open source library for reflection, serialization, script binding, callbacks, and meta data for OpenGL Box2D, SFML and Irrlicht.
v1.5.5 was released. Now supports tween and timeline for ease animation.


#6 BeerNutts   Crossbones+   -  Reputation: 2945

Like
0Likes
Like

Posted 17 December 2012 - 10:51 AM

Very interesting and good stuff.
One question, do we want to couple entity/component with scene?
I think an entity component system is an independent system which can be used freely without coupling to scene.


In this System, a Scene is a specific world where the Entity lives, it's not a Scene in the rendering sense. An Entity has to be active within a Scene, but it can be moved from Scene to Scene if you are using multiple Scene (which probably isn't common).
My Gamedev Journal: 2D Game Making, the Easy Way

---(Old Blog, still has good info): 2dGameMaking
-----
"No one ever posts on that message board; it's too crowded." - Yoga Berra (sorta)

#7 pinebanana   Members   -  Reputation: 475

Like
0Likes
Like

Posted 03 January 2013 - 01:54 AM

Very interesting and good stuff.
One question, do we want to couple entity/component with scene?
I think an entity component system is an independent system which can be used freely without coupling to scene.

A tutorial on the wiki is up (it is not entirely completed, but most of the basics are there)


anax - An open source C++ entity system





Old topic!
Guest, the last post of this topic is over 60 days old and at this point you may not reply in this topic. If you wish to continue this conversation start a new topic.



PARTNERS