Handled Room Bounds

I can tell when a collision occurs with the map. But i need you guys to
find the actual points that are on the room so that the collision is
accurate. Also need to handle the collision.