How to use mazes from Maze Generator
Unity and Blender
The following summarize how to use a maze from Maze Generator in Unity with the help of Blender. Thanks to Christopher Lackey at Bradley University for putting this information together!
- Make maze and download as SVG.
- Import SVG into Blender (it will be a set of "curve" objects, which is the number of wall segments, and could be quite a few).
- Optional: Edit walls, maybe remove some if you're not concerned about a single-solution maze, or add some to make closed-off sections, etc.
- Select All and then Join, so it's one object. You can also opt to not join the walls, or only join smaller sections of them as desired. These would import as separate child objects of the main object in Unity, which allows them to be moved, rotated, scaled, disappear, etc. independently of each other. Trap doors? Revolving doors? Walls that open based on a condition? Walls that slide open and closed? etc. Some minor adjustments might need to be made on wall sizes so they don't collide with each other, but that's simple.
- Extrude a tiny amount (like 0.0001), this creates a bit of height, doesn't need much because you can stretch this in Unity, it just needs to be more than 0.
- Add a "Solidify" modifier with a tiny value (like 0.0001, just needs to be more than 0), this thickens the walls a bit or they won't render properly in Unity (only one side of each face will render because of "backface culling").
- Save as a .blend file.
- Import into Unity and scale to whatever width, depth, and height you want. So for mazes where you need a lot of space for the player, scale them way out in the X and Y dimensions.
- Add a Mesh Collider so it will act solid when objects hit it.
CNC Milling Machine
For some hints about how to use a maze as an input to a CNC milling machine check out Rob Meades' description of how he used a CNC milling machine to cut a maze in a brass plate.
Return to previous page
Copyright © 2022 Alance AB