// Last edited on DATE TIME by USER // Processed by remove-cam-lights #include "colors.inc" #include "shapes.inc" #declare component_color = texture { pigment { color rgb <0.2, 0.2, 0.2> } } #declare die = seed(91); #declare Chambers = array[10000]; #macro Make_Chamber(Index) #local Length = 0.5 + 1.3 * rand(die); #local BaseX = -7.0 + 15.0 * rand(die); #local EndX = BaseX + Length; #local BaseY = -7.0 + 15.0 * rand(die); #local EndY = BaseY + Length; #local BaseZ = 1.5 + 9.0 * rand(die); #local EndZ = BaseZ + Length; #local Center = <(BaseX + EndX)/2, (BaseY + EndY)/2, (BaseZ + EndZ)/2>; #declare Chambers[Index] = Center; box { , texture { component_color } } #end #macro Make_Chambers(ChamberCount) #local Index = 1; #for (Index, 1, ChamberCount, 1) object { Make_Chamber(Index - 1) } #end #end #macro Make_Tunnel(StartCenter, EndCenter) cylinder { EndCenter, StartCenter, 0.2 texture { component_color } } #end #macro Mine(ChamberCount, TunnelCount) Make_Chambers(ChamberCount) #local TunnelIndex = 1; #for (TunnelIndex, 1, TunnelCount, 1) #local TunnelStart = int(ChamberCount * rand(die)); #local TunnelEnd = int(ChamberCount * rand(die)); #if (TunnelStart != TunnelEnd) Make_Tunnel(Chambers[TunnelStart], Chambers[TunnelEnd]) #end #end #end background { color rgb <0.7, 0.7, 0.7> } Mine(50, 50) // Original camera parameters: // #local cam_ctr = <2,3,2> // #local cam_loc = <5,7,-8> // #local cam_vec = (<5,7,-8>-<2,3,2>) // #local cam_sky = y #include "camlight.inc" camlight(<2,3,2>,6.149,<10,10,10>,11.180,y,1.2)