You can’t snap “to” selected verts, in this context, trying to move linked object’s vertex to another instance lead to other one vertex being also selected and kept out from snap target.
The logic behind this is you don’t want to snap a vertex to itself while moving.
Ah i see i think i thought i could always do this. i sometimes use sketchup which you can do this sort of thing so i think i confused it with that
So i just got this error trying to move an object
Error: Python: Traceback (most recent call last):
File “C:\Users\speak\Desktop\blender-3.0.0\3.0\scripts\addons\slcad_transform\slcad_transform.py”, line 2488, in modal self._free_move(context, event)
File “C:\Users\speak\Desktop\blender-3.0.0\3.0\scripts\addons\slcad_transform\slcad_transform.py”, line 2536, in free_move
slcadsnap.snap(context, event, grid_matrix)
File “C:\Users\speak\Desktop\blender-3.0.0\3.0\scripts\addons\slcad_transform\slcad_snap.py”, line 836, in snap
target, ret = self.gl_stack.snap(center)
File "C:\Users\speak\Desktop\blender-3.0.0\3.0\scripts\addons\slcad_transform\snap_context_init.py", line 484, in snap
ret = self.get_loc(snap_obj, index)
File "C:\Users\speak\Desktop\blender-3.0.0\3.0\scripts\addons\slcad_transform\snap_context_init.py", line 190, in _get_loc
co = Vector(gpu_data.get_origin_co(index))
File “C:\Users\speak\Desktop\blender-3.0.0\3.0\scripts\addons\slcad_transform\snap_context\drawing.py”, line 394, in get_origin_co
return self._arrays.origin_co[index]
IndexError: list index out of range
location: :-1
which crashes the cad tool, this consistently happens with the same object i attempt to move
I did some tests, it dosnt crash if i try to rotate or scale the same object but if i try to move the crash happens just highlighting a vert after pressing g to enter grab mode causes the crash
Other noteworthy thing is im trying to mover several objects at once i have 7 objects selected
i can move each object separately but just selecting two of the objects and trying to move them causes the same crash
So im guessing this is related to the raycast between several objects where as single objects is fine
I can as i say rotate and scale the several objects fine
Looks like an issue with a wrong index found while snapping to object’s origin / cursor.
May be related to precision issue in the draw buffer either while drawing / getting value back from pixels.
So your updated snap.py defiantly stops the freezing, but the crash issue with moving makes the tool intermittent with working in this scale
Scale and rotate are unaffected by this issue and work without crashes
Having tested the last few days not had a single crash using rotate or scale just move
Is there an easy way to scale to zero? I see that if you manage to finagle it super close to the center it snaps to zero but its tricky to get right. Is there a hotkey I can hold to stop the scaling from going to negative or make the snapping zone bigger?
In order to scale to 0, i would recommand to go with regular blender’s scale operator.
When you scale, at every step, the tool store new scale, remove last and apply new one, however when scale goes to 0, it is no more possible to revert, as multiply anything with 0 remains 0.
Scale will never be negative, it is bound to absolute values (so always positive) as negative scaling along 1 or 3 axis does actually flip normals.
If one has questions about CAD Transforms and how to achieve certains things with it…where should one post? Here or open a new thread in the forum?
CAD Transforms is amazing and I understand how to use it. But how do I do things like this:
How to best do the following tasks:
two objects. Align an edge of one of the objects with an edge of the other object. I don’t mean move there, I mean the two edges should not only touch but have the same rotation (be parallel).
two objects. Align the polygon (position and rotation) of the first object with a polygon of the second object. Both polygons should at the end be in the same plane.
I’m encounter the problem while I’m using emulate 3 mouse button setting.
I want to rotate an object with snap angle, when I want to click to apply the transformation while holding Alt it activated viewport rotation instead, there should be other way to apply the transformation like an enter or space button?