mirror of
https://github.com/IfcOpenShell/IfcOpenShell.git
synced 2026-09-26 02:07:36 +00:00
Minor fix
This commit is contained in:
@@ -236,9 +236,7 @@ class ChangeExtrusionDepth(bpy.types.Operator):
|
|||||||
extrusion = self.get_extrusion(representation)
|
extrusion = self.get_extrusion(representation)
|
||||||
if not extrusion:
|
if not extrusion:
|
||||||
return
|
return
|
||||||
print(extrusion)
|
|
||||||
extrusion.Depth = self.depth
|
extrusion.Depth = self.depth
|
||||||
print(extrusion)
|
|
||||||
DumbWallRecalculator().recalculate(context.selected_objects)
|
DumbWallRecalculator().recalculate(context.selected_objects)
|
||||||
return {"FINISHED"}
|
return {"FINISHED"}
|
||||||
|
|
||||||
@@ -941,7 +939,6 @@ class DumbWallJoiner:
|
|||||||
axis = body = self.get_wall_axis(obj)["reference"]
|
axis = body = self.get_wall_axis(obj)["reference"]
|
||||||
self.axis = copy.deepcopy(axis)
|
self.axis = copy.deepcopy(axis)
|
||||||
self.body = copy.deepcopy(body)
|
self.body = copy.deepcopy(body)
|
||||||
self.original_body = copy.deepcopy(body)
|
|
||||||
height = self.get_height(tool.Ifc.get().by_id(obj.data.BIMMeshProperties.ifc_definition_id))
|
height = self.get_height(tool.Ifc.get().by_id(obj.data.BIMMeshProperties.ifc_definition_id))
|
||||||
self.clippings = []
|
self.clippings = []
|
||||||
layers = get_material_layer_parameters(element)
|
layers = get_material_layer_parameters(element)
|
||||||
@@ -1074,14 +1071,21 @@ class DumbWallJoiner:
|
|||||||
|
|
||||||
angle = tool.Cad.angle_edges(axis1["reference"], axis2["reference"], signed=False, degrees=True)
|
angle = tool.Cad.angle_edges(axis1["reference"], axis2["reference"], signed=False, degrees=True)
|
||||||
if tool.Cad.is_x(angle, (0, 180)):
|
if tool.Cad.is_x(angle, (0, 180)):
|
||||||
return
|
return False
|
||||||
|
|
||||||
# Work out axis line
|
# Work out axis line
|
||||||
intersect = tool.Cad.intersect_edges(axis1["reference"], axis2["reference"])
|
intersect = tool.Cad.intersect_edges(axis1["reference"], axis2["reference"])
|
||||||
if intersect:
|
if intersect:
|
||||||
intersect, _ = intersect
|
intersect, _ = intersect
|
||||||
else:
|
else:
|
||||||
return
|
return False
|
||||||
|
|
||||||
|
proposed_axis = [self.axis[0], intersect] if connection == "ATEND" else [intersect, self.axis[1]]
|
||||||
|
|
||||||
|
if tool.Cad.is_x(tool.Cad.angle_edges(self.axis, proposed_axis, degrees=True), 180):
|
||||||
|
# The user has moved the wall into an invalid position that connect connect at the desired end
|
||||||
|
return False
|
||||||
|
|
||||||
self.axis[1 if connection == "ATEND" else 0] = intersect
|
self.axis[1 if connection == "ATEND" else 0] = intersect
|
||||||
|
|
||||||
# Work out body extents
|
# Work out body extents
|
||||||
@@ -1149,6 +1153,7 @@ class DumbWallJoiner:
|
|||||||
y_axis = Vector((0, 0, 1))
|
y_axis = Vector((0, 0, 1))
|
||||||
z_axis = y_axis.cross(x_axis)
|
z_axis = y_axis.cross(x_axis)
|
||||||
self.clippings.append(self.create_matrix(clip, x_axis, y_axis, z_axis))
|
self.clippings.append(self.create_matrix(clip, x_axis, y_axis, z_axis))
|
||||||
|
return True
|
||||||
|
|
||||||
|
|
||||||
def get_material_layer_parameters(element):
|
def get_material_layer_parameters(element):
|
||||||
|
|||||||
Reference in New Issue
Block a user