@@ -205,22 +205,22 @@ def _compute_on_guided_position(
205205 child_bbox = obj .get_bounding_box ()
206206
207207 x = self ._sample_axis_position (
208- parent_bbox .min_point [0 ],
209- parent_bbox .max_point [0 ],
210- child_bbox .min_point [0 ],
211- child_bbox .max_point [0 ],
208+ parent_bbox .min_point [0 , 0 ],
209+ parent_bbox .max_point [0 , 0 ],
210+ child_bbox .min_point [0 , 0 ],
211+ child_bbox .max_point [0 , 0 ],
212212 generator ,
213213 )
214214 y = self ._sample_axis_position (
215- parent_bbox .min_point [1 ],
216- parent_bbox .max_point [1 ],
217- child_bbox .min_point [1 ],
218- child_bbox .max_point [1 ],
215+ parent_bbox .min_point [0 , 1 ],
216+ parent_bbox .max_point [0 , 1 ],
217+ child_bbox .min_point [0 , 1 ],
218+ child_bbox .max_point [0 , 1 ],
219219 generator ,
220220 )
221221
222222 # Z: place child's bottom face at parent top + clearance
223- z = parent_bbox .max_point [2 ] + on_relation .clearance_m - child_bbox .min_point [2 ]
223+ z = parent_bbox .max_point [0 , 2 ] + on_relation .clearance_m - child_bbox .min_point [0 , 2 ]
224224
225225 return (x , y , z )
226226
0 commit comments