Originally I Just used a couple of booleans to let me know if and where the player had collided.
Not very informative though, so I've added a collision enun that now tells me the state of collision
* none
* building
* roof
I can then use these accordingly to achieve other game mechanics later on.
Why not store a reference to the thing you are colliding with? That would give you more flexibility.
ReplyDelete