
Wall Generator for table top games
thingiverse
So, I'm a huge DND player and DM, always loved having small 3D printed bits on the table to give it that real feel. Lately, I wanted a thinner (and quicker to make) version of the wall I had created before, so I tried making this. You just input the points you want the wall to go through, and it does it. Sorry if the vector thing seems complex; it didn't seem that hard when I made it. Print Settings Notes: A lot changes how you make the wall, but I advise keeping the bottom at the bottom. How I Designed This Code Explanation So, I'm still trying to figure out the best way to do this, (my GitHub might do it better once I get it set up right) but here goes nothing: I'm using a recursive module that's basically an elaborate for loop. The extent of my error handling is if it's not a valid vector point, don't make that segment. It draws a parallelogram (still working on making it sharper edges) then extrudes it wall height. Then checks to see if there are more points to be drawn and repeats. // CUSTOMIZER VARIABLES // This should be a small number relative to your wall's height width_of_wall = .05; // How tall do you want this? height_of_wall = 1; // Vector path of the wall, (wall thickness is only right angles for now), to generate a separate path make a null/blank entry in your vector of order pairs, please note these are in whatever unit you selected earlier. cords_of_wall = [[1,0],[0,0],[0,1],[-1,1],[-1,3],[0,3],[0,4],[3,4],[4,3],[4,1],[3,1],[3,0],[2,0],[2],[1,1],[1,2],[2,2],[2,1],[1,1]]; // Basically are you using American units or real units? units_entered = 25.4; // [1:mm, 10:cm, 1000:meter, 25.4:inch, 304.8:foot] // Default is mm for most printers desired_units_for_output = 1; // [1:mm, .1:cm, 0.001:meter, 0.0393701:inch, 0.00328084:foot] // This option will not appear because of the *1 // CUSTOMIZER VARIABLES END width_of_wall = width_of_wall; unit_conversion_factor = units_entered / desired_units_for_output; height_of_wall = height_of_wall * unit_conversion_factor; module make_wall_segments(cords = cords_of_wall, number_your_on, units = 25.4) { // Number_your_on works such that when it equals 1, that is the beginning. (Yes I am one of those people who believes arrays should have started with 1 instead of 0) point1 = cords[number_your_on-1] * unit_conversion_factor; point2 = cords[number_your_on] * unit_conversion_factor; point3 = [point2[0]+width_of_wall*unit_conversion_factor,point2[1]+width_of_wall*unit_conversion_factor]; point4 = [point1[0]+width_of_wall*unit_conversion_factor,point1[1]+width_of_wall*unit_conversion_factor]; linear_extrude(height = height_of_wall){ polygon([point1,point2,point3,point4]); } if(number_your_on < len(cords)){ make_wall_segments(cords = cords_of_wall,number_your_on = number_your_on+1, units = unit_conversion_factor); } } make_wall_segments(cords = cords_of_wall,number_your_on = 1, units = unit_conversion_factor);
With this file you will be able to print Wall Generator for table top games with your 3D printer. Click on the button and save the file on your computer to work, edit or customize your design. You can also find more 3D designs for printers on Wall Generator for table top games.