AutoCAD Plant 3D Forum
Welcome to Autodesk’s AutoCAD Plant 3D Forums. Share your knowledge, ask questions, and explore popular AutoCAD Plant 3D topics.
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

set.Point causing Geometry can not be generated problem

2 REPLIES 2
SOLVED
Reply
Message 1 of 3
halitomi
523 Views, 2 Replies

set.Point causing Geometry can not be generated problem

Hello to All!

 

I am trying to create some custom equipment scripts that for my company would be useful but I got stuck at the point where you define the setpoints where the connection grips of the equipment should be.

 

My code is:

 

 

Spoiler

from varmain.primitiv import *
from varmain.custom import *
from math import *

@activate(Group="Vessel", TooltipShort="Skirt", TooltipLong="A skirt with base", LengthUnit="mm", Ports="1")
@group("MainDimensions")
@param(A=LENGTH, TooltipShort="Height")
@param(B=LENGTH, TooltipShort="Width")
@param(C=LENGTH, TooltipShort="Frame")
@param(C1=LENGTH, TooltipShort="Framethck")
@param(L1=LENGTH, TooltipShort="Length")
@param(L2=LENGTH, TooltipLong="HeightofLongitudeFrame")

def AIRSLIDE(s,A=500,B=300,C=40,L1=1100,C1=5,L2=100,**kw):

o4=BOX(s,L=L1,H=B+2*C,W=2*C1).translate((0,0,-(A/2)+C1+L2))
o2=BOX(s,L=C1,H=B+2*C,W=A+2*C).translate((0,-(L1/2)+C1/2,0))
o3=BOX(s,L=C1,H=B+2*C,W=A+2*C).translate((0,L1/2-C1/2,0))
o1=BOX(s,L=L1,H=B,W=A)

o1.uniteWith(o3)
o3.erase()

o1.uniteWith(o2)
o2.erase()

o1.uniteWith(o4)
o4.erase()

s=setPoint((0,0,0),(0,-1,0))

 

 

 

 

If i remove the last line I have no problem, but if I keep it there, I have a "Geometry can not be generated with the given parameters.error.

2 REPLIES 2
Message 2 of 3
jabowabo
in reply to: halitomi

Change your setPoint line to read:

 

s.setPoint((0, 0, 0), (0, -1, 0))

Message 3 of 3
halitomi
in reply to: jabowabo

AHHH

 

Thanks a lot! Documentation was in front of me and still could not see it. 🙂

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report

”Boost