rect labyrinth class