cancel
Showing results for 
Search instead for 
Did you mean: 
EN
cancel
Showing results for 
Search instead for 
Did you mean: 
Daniella1985
Contributor

These are floor tiles. I want to cut the holes correctly. Which command should I use? It seems like

Daniella1985_0-1778226995825.png

Daniella1985_1-1778227298602.png

 

Operating system used: Windows

1 Solution

Accepted Solutions
AllanP
Expert

if you are just wanting to cut the hole, you can use 

SOLID GEOMETRY COMMANDS  

 

2D Script

Project2 2,270,3
unid = 1
hotspot2 0,0,unid:unid = unid + 1
hotspot2 A,0,unid:unid = unid + 1
hotspot2 0,B,unid:unid = unid + 1
hotspot2 A,B,unid:unid = unid + 1

HOTSPOT2 	0, 						start_hole_Y,	unid, 	start_hole_X, 1+128 : unid=unid+1
HOTSPOT2	-1, 				 	start_hole_Y,	unid, 	start_hole_X, 3 : unid=unid+1
HOTSPOT2	start_hole_X,			start_hole_Y, 	unid, 	start_hole_X, 2 : unid=unid+1
HOTSPOT2	start_hole_X,			0, 				unid, 	start_hole_Y, 1+128  : unid=unid+1
HOTSPOT2	start_hole_X,			-1, 			unid, 	start_hole_Y, 3 : unid=unid+1
HOTSPOT2	start_hole_X,			start_hole_Y, 	unid, 	start_hole_Y, 2 : unid=unid+1

HOTSPOT2 	0, 						end_hole_Y,	unid, 	end_hole_X, 1+128 : unid=unid+1
HOTSPOT2	-1, 				 	end_hole_Y,	unid, 	end_hole_X, 3 : unid=unid+1
HOTSPOT2	end_hole_X,			end_hole_Y, 	unid, 	end_hole_X, 2 : unid=unid+1
HOTSPOT2	end_hole_X,			0, 				unid, 	end_hole_Y, 1+128  : unid=unid+1
HOTSPOT2	end_hole_X,			-1, 			unid, 	end_hole_Y, 3 : unid=unid+1
HOTSPOT2	end_hole_X,			end_hole_Y, 	unid, 	end_hole_Y, 2 : unid=unid+1

 

 

 

 

 

3D script

tile_wide = 0.300
tile_deep = 0.300
Tile_Gap = 0.010
Tile_thickness = 0.008
unid = 1
hotspot 0,0,0,unid:unid = unid + 1
hotspot A,0,0,unid:unid = unid + 1
hotspot 0,B,0,unid:unid = unid + 1
hotspot A,B,0,unid:unid = unid + 1



HOTSPOT 	0, 				start_hole_Y,0,	unid, 	start_hole_X, 1+128 : unid=unid+1
HOTSPOT	-1, 				start_hole_Y,0,	unid, 	start_hole_X, 3 : unid=unid+1
HOTSPOT	start_hole_X,		start_hole_Y, 0,	unid, 	start_hole_X, 2 : unid=unid+1
HOTSPOT	start_hole_X,		0, 			0,	unid, 	start_hole_Y, 1+128  : unid=unid+1
HOTSPOT	start_hole_X,		-1, 		0,	unid, 	start_hole_Y, 3 : unid=unid+1
HOTSPOT	start_hole_X,		start_hole_Y, 0,	unid, 	start_hole_Y, 2 : unid=unid+1

HOTSPOT 	0, 				end_hole_Y,0,	unid, 	end_hole_X, 1+128 : unid=unid+1
HOTSPOT	-1, 				end_hole_Y,0,	unid, 	end_hole_X, 3 : unid=unid+1
HOTSPOT	end_hole_X,			end_hole_Y, 0,	unid, 	end_hole_X, 2 : unid=unid+1
HOTSPOT	end_hole_X,			0, 			0,	unid, 	end_hole_Y, 1+128  : unid=unid+1
HOTSPOT	end_hole_X,			-1, 		0,	unid, 	end_hole_Y, 3 : unid=unid+1
HOTSPOT	end_hole_X,			end_hole_Y, 0,	unid, 	end_hole_Y, 2 : unid=unid+1

group "My tiles to be cut"
     Material My_Mat
     !!Draw my tiles here
     x_number = CEIL(a/(tile_wide+Tile_Gap))
     y_number = CEIL(b/(tile_deep+Tile_Gap))
      for x_loop = 1 to x_number
         for y_loop = 1 to y_number
                  add (tile_wide+Tile_Gap)*(x_loop-1),(tile_deep+Tile_Gap)*(y_loop-1), 0 
                  tile_wide_A = min(tile_wide,a-(tile_wide+Tile_Gap)*(x_loop-1))
                  tile_deep_B = min(tile_deep,b-(tile_deep+Tile_Gap)*(y_loop-1))
                   Prism_ 5,Tile_thickness,
                            0,0, 15,
                            tile_wide_A,0, 15,
                            tile_wide_A,tile_deep_B, 15,
                            0,tile_deep_B, 15,
                            0,0, -1
			del 1
         next y_loop
     next x_loop
endgroup

group "Cutting object"
     Prism_ 5,10,
           start_hole_X,  start_hole_Y, 15,
           start_hole_X,  end_hole_Y, 15,
           end_hole_X,  end_hole_Y, 15,
           end_hole_X,  start_hole_Y, 15,
           start_hole_X,  start_hole_Y, -1
endgroup

placegroup subgroup("My tiles to be cut","Cutting object")

killgroup "My tiles to be cut"
killgroup "Cutting object"
 

 

this will just take the tile and do a big "Solid element operation" cut from them

 

AllanP_0-1778473619091.png

AllanP_1-1778473634419.png

Is this the sort of thing you are after?

 

I have been using ArchiCAD continually since ArchiCAD 4.5
Member of Architalk since 2003, but missed the migration from Architalk to Graphisoft Communities. Melbourne, Australia

Go to post

6 Replies 6
Lingwisyer
Guru

You will need to clarify your question a bit. How is it coded? What type of GDL element is it (ie. is it a generic object, window, etc)? What do you mean by "correctly"?

AC22-29 AUS 3200Help Those Help You - Add a Signature
Self-taught, bend it till it breaksCreating a Thread
Win11 | i9 10850K | 64GB | RX6600 Win11 | 5900X | 32GB | GTX2080TI
Daniella1985
Contributor

3D-PRISM_ How to define tiles and holes? To avoid excessive clipping? I am a GDL beginner. GDL treats the entire outer frame as a hole, causing the whole piece to disappear 

runxel
Moderator

You'll need to provide some more info than that.

What object is this? Did you code it? What's the goal? 

Do you have any specific question? It's all very open ended right now and thus hard to give clear, constructive answers.

And depending on all the info you will provide the solutions can actually vary a lot.

Lucas Becker | AC 29 on Mac (Sequoia) | Graphisoft Insider Panelist | Akroter.io – high-end GDL objects | Author of Runxel's Archicad Wiki | Editor at SelfGDL | Developer of the GDL plugin for Sublime Text

My List of AC shortcomings & bugs | I Will Piledrive You If You Mention AI Again |

POSIWID – The Purpose Of a System Is What It Does /// «Furthermore, I consider that Carth... yearly releases must be destroyed»
jl_lt
Ace

Why not use the curtain wall tool?

AllanP
Expert

if you are just wanting to cut the hole, you can use 

SOLID GEOMETRY COMMANDS  

 

2D Script

Project2 2,270,3
unid = 1
hotspot2 0,0,unid:unid = unid + 1
hotspot2 A,0,unid:unid = unid + 1
hotspot2 0,B,unid:unid = unid + 1
hotspot2 A,B,unid:unid = unid + 1

HOTSPOT2 	0, 						start_hole_Y,	unid, 	start_hole_X, 1+128 : unid=unid+1
HOTSPOT2	-1, 				 	start_hole_Y,	unid, 	start_hole_X, 3 : unid=unid+1
HOTSPOT2	start_hole_X,			start_hole_Y, 	unid, 	start_hole_X, 2 : unid=unid+1
HOTSPOT2	start_hole_X,			0, 				unid, 	start_hole_Y, 1+128  : unid=unid+1
HOTSPOT2	start_hole_X,			-1, 			unid, 	start_hole_Y, 3 : unid=unid+1
HOTSPOT2	start_hole_X,			start_hole_Y, 	unid, 	start_hole_Y, 2 : unid=unid+1

HOTSPOT2 	0, 						end_hole_Y,	unid, 	end_hole_X, 1+128 : unid=unid+1
HOTSPOT2	-1, 				 	end_hole_Y,	unid, 	end_hole_X, 3 : unid=unid+1
HOTSPOT2	end_hole_X,			end_hole_Y, 	unid, 	end_hole_X, 2 : unid=unid+1
HOTSPOT2	end_hole_X,			0, 				unid, 	end_hole_Y, 1+128  : unid=unid+1
HOTSPOT2	end_hole_X,			-1, 			unid, 	end_hole_Y, 3 : unid=unid+1
HOTSPOT2	end_hole_X,			end_hole_Y, 	unid, 	end_hole_Y, 2 : unid=unid+1

 

 

 

 

 

3D script

tile_wide = 0.300
tile_deep = 0.300
Tile_Gap = 0.010
Tile_thickness = 0.008
unid = 1
hotspot 0,0,0,unid:unid = unid + 1
hotspot A,0,0,unid:unid = unid + 1
hotspot 0,B,0,unid:unid = unid + 1
hotspot A,B,0,unid:unid = unid + 1



HOTSPOT 	0, 				start_hole_Y,0,	unid, 	start_hole_X, 1+128 : unid=unid+1
HOTSPOT	-1, 				start_hole_Y,0,	unid, 	start_hole_X, 3 : unid=unid+1
HOTSPOT	start_hole_X,		start_hole_Y, 0,	unid, 	start_hole_X, 2 : unid=unid+1
HOTSPOT	start_hole_X,		0, 			0,	unid, 	start_hole_Y, 1+128  : unid=unid+1
HOTSPOT	start_hole_X,		-1, 		0,	unid, 	start_hole_Y, 3 : unid=unid+1
HOTSPOT	start_hole_X,		start_hole_Y, 0,	unid, 	start_hole_Y, 2 : unid=unid+1

HOTSPOT 	0, 				end_hole_Y,0,	unid, 	end_hole_X, 1+128 : unid=unid+1
HOTSPOT	-1, 				end_hole_Y,0,	unid, 	end_hole_X, 3 : unid=unid+1
HOTSPOT	end_hole_X,			end_hole_Y, 0,	unid, 	end_hole_X, 2 : unid=unid+1
HOTSPOT	end_hole_X,			0, 			0,	unid, 	end_hole_Y, 1+128  : unid=unid+1
HOTSPOT	end_hole_X,			-1, 		0,	unid, 	end_hole_Y, 3 : unid=unid+1
HOTSPOT	end_hole_X,			end_hole_Y, 0,	unid, 	end_hole_Y, 2 : unid=unid+1

group "My tiles to be cut"
     Material My_Mat
     !!Draw my tiles here
     x_number = CEIL(a/(tile_wide+Tile_Gap))
     y_number = CEIL(b/(tile_deep+Tile_Gap))
      for x_loop = 1 to x_number
         for y_loop = 1 to y_number
                  add (tile_wide+Tile_Gap)*(x_loop-1),(tile_deep+Tile_Gap)*(y_loop-1), 0 
                  tile_wide_A = min(tile_wide,a-(tile_wide+Tile_Gap)*(x_loop-1))
                  tile_deep_B = min(tile_deep,b-(tile_deep+Tile_Gap)*(y_loop-1))
                   Prism_ 5,Tile_thickness,
                            0,0, 15,
                            tile_wide_A,0, 15,
                            tile_wide_A,tile_deep_B, 15,
                            0,tile_deep_B, 15,
                            0,0, -1
			del 1
         next y_loop
     next x_loop
endgroup

group "Cutting object"
     Prism_ 5,10,
           start_hole_X,  start_hole_Y, 15,
           start_hole_X,  end_hole_Y, 15,
           end_hole_X,  end_hole_Y, 15,
           end_hole_X,  start_hole_Y, 15,
           start_hole_X,  start_hole_Y, -1
endgroup

placegroup subgroup("My tiles to be cut","Cutting object")

killgroup "My tiles to be cut"
killgroup "Cutting object"
 

 

this will just take the tile and do a big "Solid element operation" cut from them

 

AllanP_0-1778473619091.png

AllanP_1-1778473634419.png

Is this the sort of thing you are after?

 

I have been using ArchiCAD continually since ArchiCAD 4.5
Member of Architalk since 2003, but missed the migration from Architalk to Graphisoft Communities. Melbourne, Australia
Daniella1985
Contributor

I'm very sorry it took me almost four weeks to reply. The 2D and 3D code you provided was very helpful and gave me a lot of direction; it was invaluable because I couldn't achieve the compensation effect when cutting blocks and tiles. Thank you so much!

You understand what I'm trying to express!

Didn't find the answer?

Check other topics in this Forum

Back to Forum

Read the latest accepted solutions!

Accepted Solutions

Start a new conversation!