This project/library/demo/whatever you want to call it was created out of interest in the entity-component system game design pattern. Composition is the concept of, instead of having a class extend other classes, have an entity that is made up of individual components that describe its behavior.
As this is one of my first libraries, any comments or suggestions are much appreciated on how I can improve the implementation and/or its API. Anyone is free to use this in any project they please.
GitHub page: https://github.com/Kingdaro/love-ecs
Entity-Component Implementation/Library
Re: Entity-Component Implementation/Library
Excellent! Please, add more features. It's very useful. Thanks!
My library for easy saving Slib! Try this! Now you can encrypt your save!
- Drop of light LD#30
- OUTRANGE LD#31
(Sorry for my english. I learn it myself, and I don't have enough experience)
- Drop of light LD#30
- OUTRANGE LD#31
(Sorry for my english. I learn it myself, and I don't have enough experience)
- ejmr
- Party member
- Posts: 302
- Joined: Fri Jun 01, 2012 7:45 am
- Location: South Carolina, U.S.A.
- Contact:
Re: Entity-Component Implementation/Library
I have no major suggestions for the implementation itself; that all looks good. But to help people use the library I do suggest adding an explicit license, thorough documentation of the API, and a test suite. Middleclass is a nice example of how a test suite can also serve as a good source of self-documenting code for a library. Having such documentation, in any form, is also useful for whenever you decide to break backwards-compatibility; it’s never fun to update a library only to see it stop working because of an undocumented API change.
All that said, great-looking work!
All that said, great-looking work!
Re: Entity-Component Implementation/Library
Thank you! Were there any features you had in mind, specifically?Snuux wrote:Excellent! Please, add more features. It's very useful. Thanks!
Thanks! The main reason I said that was that I was mainly concerned with the lack of consistency in object usage, but if everyone is fine with how it works, I can consider my goal accomplished.ejmr wrote:I have no major suggestions for the implementation itself; that all looks good. But to help people use the library I do suggest adding an explicit license, thorough documentation of the API, and a test suite. Middleclass is a nice example of how a test suite can also serve as a good source of self-documenting code for a library. Having such documentation, in any form, is also useful for whenever you decide to break backwards-compatibility; it’s never fun to update a library only to see it stop working because of an undocumented API change.
All that said, great-looking work!
Also, thanks for the tips. I'll see if I can get a test pumped out for the library, and adding a license would be a good idea as well.
EDIT: Finished the licensing and tests.
Re: Entity-Component Implementation/Library
Added a StateManager object, used to emulate gamestates using engines. Because of this change, I also made it so that engines can have their own event listeners, for when you want to listen to events without acting on entities using systems.
Who is online
Users browsing this forum: No registered users and 1 guest