用UF函数创建块体,下图为NXOpen Python的参考指南:
以下是实现的代码:
import NXOpen.UF
sign=NXOpen.UF.Modl.FeatureSigns.ValueOf(0) #这里为相应布尔类型,目标体为就近的其他实体
feat_tag_of_block=NXOpen.UF.UFSession.GetUFSession().ModlFeatures.CreateBlock1(sign,[0.0,0.0,0.0],['20','20','20'])
最终实现的效果如下图: