Ellzord / JALSE

Java Artificial Life Simulation Engine
https://ellzord.github.io/JALSE
Apache License 2.0
139 stars 24 forks source link

Consider being able to initialise an entity with multiple types #178

Open Ellzord opened 9 years ago

Ellzord commented 9 years ago

Unsure how our method signatures will look after this.

kevinzau commented 9 years ago

Hi, I'm part of a small group that wants to work on this issue. Looking through the code, it looks like it is already possible to create an entity with multiple types by marking that entity multiple times.

Is this a question of creating convenience functions or is there something more fundamental that needs to be changed that we're missing?

Ellzord commented 9 years ago

Hello! So everything you have said is correct - you can mark an entity multiple times to achieve this. I think it may be worth just adding this as a convenience function to Entities as we have a lot of method definitions for newEntity as it is.

Anything I've marked with the Question tag is entirely up for debate. Do we need it should we have it?

Happy to have you working on JALSE :)

psrivast commented 9 years ago

Hey Elizord, I am on the same group as Kevin working on this issue. I have added another implementation of the newEntity method that takes in a Collection of types as an input. I was wondering how you would want us to test this. Thanks.

Ellzord commented 8 years ago

Hello! I've added a comment to your pull request. You can move the unit test to EntitiesTest (not sure if it exists yet off the top of my head). Thanks!