Detecting when an enemy hits a wall so I can flip it?

N

Noba

Guest
I'm making an enemy that travels from one side of the room to the other, then "bounces" off the wall and flips itself to travel back to the other wall, and it keeps doing this indefinitely.

As the title says, does anyone know how I can detect it coming into contact with the wall? The room has no physical walls yet, I'm just using clamp so nothing can go off screen.
 
Top