Quantcast
Channel: Scripting - McNeel Forum
Viewing all articles
Browse latest Browse all 4120

Figuring out a problem concerning: if,else,list and constructing a plane

$
0
0

So what is the case. I have the following rules that I have to follow:

And I have made a couple of lines of script. In theory It should work but this is only the theory. My target is that on the point lists that you see in the left gh component I make planes.
The points and the planes construction follow the same IF, ELIS logic. the problem is that for some reason I am unable to make the plane. The error is:

The script is that:

import Rhino.Geometry as rg
import math

len = btAx.GetLength()

if len<1200:
#var 1
a = rg.Plane(var1, hNBv, mAx)
rg.Plane.Rotate( a , math.radians(-90) , a.YAxis)

elif 1200<len<1800:
#var2a
a = rg.Plane(var2a, hNBv, mAx)
rg.Plane.Rotate( a , math.radians(-90) , a.YAxis)

elif 1800<a:
#var2b
a = rg.Plane(var2b, hNBv, mAx)
rg.Plane.Rotate( a , math.radians(-90) , a.YAxis)


Runtime error (ArgumentTypeException): expected Point3d, got NoneType

Traceback:
line 14, in script


I honestly have no idea what is going on. The lists are made of 3D points…

Thanks in advance for the help :slight_smile:
problem.3dm (679.2 KB)
problem.gh (8.8 KB)

5 posts - 3 participants

Read full topic


Viewing all articles
Browse latest Browse all 4120

Trending Articles