
bonus if I can make it happen in Java.
Also killing panda is bad =)
|
|
|||||||||||
|
|
These gameplay features can be broken into several domains: Collision checking How do you know that the panda's have met? How do you know the evil hero has slain a panda? Scene management How do you keep track of all the entities in a scene? How do you destroy entities? How do you create new ones? First, scene management. An easy way to keep track of everything in your scene is just to make a list. Then, when you want to make a new entity or destroy one, it either adds or deletes it from the list. Simple. Then, because you have your list of entities, you can have very basic collision checking by simply checking every item in your list with the other items. Just calculate the distances and see if they're close enough to collide. And that should give you a general idea of how to solve these problems. :) |
|||
|
|
|
This is honestly kind of ridiculous. You've gone and created an object hierarchy without even considering how instances of the object interact. Where's your infrastructure? Where are the object containers? How do you handle locality? Et cetera. Get yourself to interacting non-ojects in the world, then do your abstractions after that. You don't make a car by styling the interior then filling in the mechanics afterwards. |
|||||||
|