Planes are directional, so the simple answer is to flip your plane the other way around:
wNode.addSolid(CollisionPlane(Plane(Vec3(-1, 0, 0), Point3(5, 0, 0))))
But since Planes are also infinite, I doubt this will be very useful to construct the walls of a maze, since your maze walls have to be finite so you can walk around them.
So, use CollisionPolygons. As you have observed, these have a directional property: they’re only solid from the front side. If you want to have a wall that’s solid from both directions, you will need to use two CollisionPolygons, one facing each direction.
But you will have some problems with back-to-back CollisionPolygons. If your avatar intersects two walls at once, the collision system won’t be sure which direction your avatar came from, and might yank it all the way through the wall.
One way to reduce this problem is to put a little bit of space between your back-to-back walls, so that you will never intersect both of them at once. The right amount of space is a little bit more than the minimum distance your avatar might penetrate within the span of a single frame.
Another way to reduce this problem is to turn on the fluid movement detection, as described in the manual. Then the collision system will know the direction your avatar is moving, and will know to ignore walls that are facing in the wrong direction.
I recommend using both of the above solutions together.
A third solution, which requires a bit more work in the Python code, is to selectively enable or disable walls according to where your avatar is standing within the grid. For instance, you could examine your avatar’s X, Y position and know that he’s standing at block (4, 5), and therefore there should be a north wall and an east wall here. All of the other walls can be disabled (for instance, by stashing them). This will not only avoid problems from inappropriate collisions with backfacing walls, but it will also improve performance by reducing the number of walls the collision system will have to test against. Of course, you’ll have to figure out how to write the algorithm that determines which walls should be active based on your avatar’s position.
David