1 decade ago by nickgravelyn
I'm working on a little game and want to have activate-able objects, such as doors and signs, that respond when the user is next to them and presses space bar. The game is a top-down tile based game, if that matters at all.
I currently have all the collisions figured out (i.e. the player can move around but doesn't pass through the activate-able entities), but I'm not sure the right approach with Impact to figure out if I'm next to another entity. I could simply get all the entities, enumerate them, and respond but I'm worried I'll be adding a lot of overhead if my levels start having more than just a few such entities.
Any ideas?
I currently have all the collisions figured out (i.e. the player can move around but doesn't pass through the activate-able entities), but I'm not sure the right approach with Impact to figure out if I'm next to another entity. I could simply get all the entities, enumerate them, and respond but I'm worried I'll be adding a lot of overhead if my levels start having more than just a few such entities.
Any ideas?