This Cabin Tool was built in Houdini and brought into Unreal.
Let's take a look at the settings, then dive into the individual pieces.
Adjustable Parameters
Building Shape
The basic shape of the cabin can be set in 3 parts: the body of the cabin (X, Y, and Z), the Foundation height, and the roof height.
Materials
The stuff cabin is made of, planks and logs, can be adjusted here.
Foundation
The density of the stones can be adjusted.
Windows
The windows' size, vertical offset, as well as the percent chance of a window to appear in any window slot can be adjusted.
Here's the full SOPs network
Lets check out some of the individual pieces.
The foundation starts with a box sized from the input parameters, then follows these steps:
Taper the box so the bottom is slightly wider than the top
Double the height
Scatter points
Voronoi fracture the box using the scattered points
Return the box to its original size to get slightly flat rocks
Set the primitive normals to face away from the center to prep for extrusion
Extrude
Subdivide and remesh
Jitter points
Bevel the sharp edges
The roof starts with a peaked box from our inputs. that base is used to create the 3 parts of the roof:
Eves:
The position of the tent shape is adjusted into position, then extruded twice to give it shape then thickness
Ridge Cap
The same tent shape is scaled and positioned before being extruded for thickness.
Roof
Generate a grid based on plank size
Copy and align the grid to the tent shape
Copy planks to grid points
Rotate planks slightly during copy to ensure they overlap properly
In preparation for the cabin body, we need to determine the location of all doors and windows.
Generate a pair of boxes, independently based on X and Z cabin dimensions
Divide them based on window size
Gather the points in the center of each wall
Randomly assign one point on the front wall to be the door
Combine the other front wall points with the side wall points
Use the window chance parameter to randomly delete some of the points
Copy the window and door bounds boxes to the point locations to prepare for boolean with logs
Next we can build up the cabin shape with logs and cut the roof, door, and windows out.
Create and position the roof box
Collapse its top edges to shape it
Create and position the cabin body box
Create a new box from these bounds with 2 divisions per side giving each side a centered vertical edge
Convert these edges to curves
Resample the curve based on the input log radius
Size the source log to the length and width of the cabin, plus an extra log diameter on each end for that nice corner overlap
Move one curve up one log radius, again for the corner overlap
Copy logs to curve points
Take the starting shape and expand it slightly to completely envelope the logs
Boolean the shape, along with the windows and doors, with the logs
Finally, we make the windows and door and put them in place.
Make a simple window and door using some inputs and some static numbers
Box
Blast
Extrude
And finally, copy the doors and windows to their respective points and bring everything together.