脚本功能
Alibre Script高级API地址为高级用户提供了一种通过C#代码从Alibre Script内部访问全部Alibre Design API的方法。请参阅安装文件夹/程序/附加组件/AlibreScript/AdvancedAPI.PDF中的PDF文件。
已添加对自定义属性的支持。新增函数Part.GetCustomProperty()、Part.SetCustomProperty()、Assembly.GetCustomProperty()、Assembly.SetCustomProperty()。
新增了对新装配约束的支持。新函数Assembly.AddGearConstraint()、Assembly.AddScrewConstraint()、Assembly.AddRackAndPinionConstraint()、Assenbly.AddFastenerConstraint()、Assembly.AddMateConstraint2()、Assembly.AddAlignConstraint2()、Assembly.AddAngleConstraint2()。
现在,Part.SaveSnapshot() 可生成指定尺寸的图像。
已添加 Part.PauseUpdating() 和 Part.ResumeUpdating()。
Part.ExportBIP() 和 Assembly.ExportBIP() 现在可以生成关键帧文件。
添加了椭圆和椭圆弧类。
Sketch.Figures 现在包括椭圆和椭圆弧。
添加了 Sketch.AddEllipse() 和 Sketch.AddEllipticalArc()。
Sketch.AddFigure() 现在支持椭圆和椭圆弧。
Sketch.AddConstraint() 现在支持椭圆和椭圆弧。
Sketch.CopyFrom() 现在支持复制椭圆和椭圆弧。
已添加对在脚本中嵌入图像的支持(还添加了图像到 Python.py 实用程序的功能)
Face.IsParallel() 和 Face.DistanceTo() 现在可用于装配体中零件的面。
使用 UtilityDialog 或 OptionsDialog 时,现在可以直接选择零件,而不必使用设计资源管理器。注:仅对启动脚本的装配体有效。
已添加文件夹来组织默认脚本库。
现在,即使在编辑过程中出现问题,也应始终关闭草图。
添加了 TwoD.GetPerpendicularVector() 和 TwoD.NormalizeVector()
已添加 BSpline.GetNormalAt()。
Part.Material 现在是定义零件材料的文本,而不是定义密度的实数。需要注意的是,这一更改并不向后兼容。
添加了部件密度。
为部件添加了文本属性:Part.Comment, Part.CostCenter, Part.CreatedBy, Part.CreatedDate, Part.CreatingApplication, Part.DocumentNumber, Part.EngineeringApprovalDate, Part.EngineeringApprovedBy, Part.EstimatedCost, Part.Keywords, Part.LastAuthor, Part.LastUpdateDate, Part.ExtendedMaterialInformation, Part.ManufacturingApprovedBy, Part.ManufacturingApprovedDate, Part.ModifiedInformation, Part.Product, Part.ReceivedFrom, Part.Revision, Part.StockSize, Part.Supplier, Part.Title, Part.Vendor and Part.WebLink.
为装配体添加了文本属性:Assembly.Comment, Assembly.CostCenter, Assembly.CreatedBy, Assembly.CreatedDate, Assembly.CreatingApplication, Assembly.DocumentNumber, Assembly.EngineeringApprovalDate, Assembly.EngineeringApprovedBy, Assembly.EstimatedCost, Assembly.Keywords, Assembly.LastAuthor, Assembly.LastUpdateDate, Assembly.ExtendedMaterialInformation、Assembly.ManufacturingApprovedBy、Assembly.ManufacturingApprovedDate、Assembly.ModifiedInformation、Assembly.Product、Assembly.ReceivedFrom、Assembly.Revision、Assembly.StockSize、Assembly.Supplier、Assembly.Title、Assembly.Vendor 和 Assembly.WebLink。
已添加装配密度、装配材料、装配描述和装配编号,以匹配零件的属性。
如果无法添加约束,Sketch.AddConstraint() 现在会返回 false。
脚本错误修复
修正了导致每次运行脚本时追加 sys.path 的错误
修正了一个 Bug,该 Bug 可导致 CurrentAssembly().Close() 和 CurrentPart().Close() 生成错误。
Sketch3D.AddBspline(Bspline3D Bspline) 现在更加精确。在以前的版本中,生成的曲线是内插曲线,可能会导致保真度降低。现在,该曲线已准确生成。