-
Notifications
You must be signed in to change notification settings - Fork 110
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We鈥檒l occasionally send you account related emails.
Already on GitHub? Sign in to your account
Support for @Wire superclass properties to subclasses to allow game/library setup #72
Comments
Most of the time I copy the code over - like you've observed, they tend to want some custom code here and there. What about making the systems abstract so that they contain most of what's required to make them work? Or am I misunderstanding? |
That's a solution I'd like, but isn't Concrete example: In common library:
In actual game:
As far as I know |
I've reemerged(!) - my previous endeavor took much longer than expected due to lack of language familiarity; it did result in a minimal artemis c++ port however. I can think of a few approaches to solving this, not sure anyone is elegant though:
Hmm... I'm out of ideas. I think the 2nd alternative might be the cleanest and has the least amount of overhead. If you have a better idea (or just dislike the solution in general), I'm all ears. |
The user already has to explicitly register systems so they get the version they are interested in. I imagine Right now
That's fine.
I'd imagine AbstractEntityFactory would extend the artemis types, which qualifies it for
This would add the ability to have two subclasses of AbstractEntityFactory registered as system. Can't really tell if there are use-cases for that. Edit: @wire must wonder why we keep talking about him. ;) |
Correct. Also, there hasn't been an official release with
Probably not, though there might be. Can't think of any right now. Also, this might be cleaner since it doesn't introduce yet another annotation type. I have some free time for the next couple of hours, I'll try to get the
s/he has become a crucial part of our development efforts! |
Yay! And also, eek! XD I've got a halfway decent library done, just keeping it all in one template https://github.com/DaanVanYperen/libgdx-artemis-quickstart to work around the tight integration for now. Having this feature in the future will be great though! As long as it uses the reflection helper class and introduces no argumented annotations GWT should be fine. You should jam with us, promote your framework a bit! ;) |
I've been on a social hiatus while coding for the past 4w, so I'm going to try to catch up on that this weekend. I'll def partake in the next LD though. |
Looks like I won't have time to finish the improved |
Ok, during the last minute! Hope it works. Edit: And snapshot deployed to maven;s repo, |
You are making this Ludum Dare exciting, I better figure out how to refer to a specific snapshot before tomorrow if things break! ;) |
Works, close when you're ready! |
Warming up for the Ludum Dare! 馃懐 Attempting to compile a library of components and systems commonly used in Jams. Map loading, Physics, animation rendering and the like. I'm running into some issues setting up a solid design, maybe you have some insight, since you're a lot more familiar with entity systems.
My main issue seems to be
@Wired
systems being so tightly integrated I am having trouble separating them into common library and game logic.As a concrete example, assume I have a map system in my common library, that deals with map loading. During map loading it needs to instance entities, which is delegated to a second system.
Both very common systems in my games that I'd like to add them to a library, but I need to somehow be able to extend them with game specific code.
considered some options.
@Wire
and just inject systems as needed via constructor, but that gets a bit messy.@Wire
so it can wire a subclass to a superclass property, like you see in other DI packages. That way the library systems can refer to interfaces or base systems, and@Wire
to game classes.Any thoughts?
The text was updated successfully, but these errors were encountered: