Polygon.bypoints would not create 2D shape when reading from a list of coordinates in Dynamo

Hello, I am quite new to Dynamo and trying to make this work:

As shown in the picture below, I wanted Dynamo to read the list of coordinates and create 2D shapes along a line. All of the points needed for Polygon.bypoints have already been worked out by formulas and each of the list with in the list contains the four necessary coordinates to create this trapezoid shape. However, Dynamo couldn’t connect the proper shape despite the four points are correctly displayed.

I wonder if the list could be the problem, so I have shown list logic in the screenshot below.

As new users can only post one picture, I will follow this up in a comment below.

I did some research before posting on the forum and figure the problem could also be on the fact that the Polygon.bypoints function doesn’t read input like how I created the lists within lists. I was also trying to find alternatives such as Polycurve.bypoints to test out if the Polygon function is the problem, but not much luck on that end.

Any help would be greatly appreciated.

-lok


list logic for the question above.

I think you need to set your lacing to longest richt click on the node and chage the laceing.

It didn’t work, I changed lacing to longest but nothing happened to the shape. it is still unconnected…

What is the list you get out from the node polgon.bypoints?

You have the node now on cross product.

A other possible solution is to create first four lines and join them then after.

Thank you. I have tried to set lacing to be longer, and out of curiosity I tried cross product as well. Neither worked.

I used the Line.byStartPointEndPoint function to create the four sides of the shape. But I couldn’t find how to join lines together to become a cross section in dynamo…the shapes has to be cross sections so that the function Solid.byloft can be used to extrude them later, along a line.


full script.

I think you can use this one
image

The function wouldn’t read the list.


the warning message.