Model.bardirectionupdate#
- Model.bardirectionupdate(collection, orientation_node, y_dir)#
Updates the direction node for multiple bar and/or bar3 elements.
- Parameters:
collection (Collection) – The collection containing the bar and/or bar3 element entities to update.
orientation_node (Entity) – The orientation node ID.
y_dirspecifies whether this node defines the local y- or local z-axis.y_dir (int) – If set to 1, then orientation_node defines the local y-axis of the bar. Otherwise,
orientation_nodedefines the local z-axis.
Example#
Update bar element with ID 17 with orientation node with ID 5 as the y-axis#import hm import hm.entities as ent model = hm.Model() elem = hm.Collection(model, ent.Element, [17]) node = ent.Node(model, 5) model.bardirectionupdate( collection=elem, orientation_node=node, y_dir=1 )