Aftertouch Posted November 12, 2018 Posted November 12, 2018 Hello everybody, Is it possible to keep a snap override active during the whole command? Now i have to override it again after each click. Quote
CyberAngel Posted November 12, 2018 Posted November 12, 2018 I'll assume you don't want to keep that snap active all the time, otherwise you wouldn't be asking the question. My solution would be to write a LISP function that overrides the command you're using. For instance, if you're drawing a polyline and need the perpendicular snap, your code would do this: defun PPLINE PER snap ON PLINE PER snap OFF So instead of calling the polyline command directly, you invoke the new PPLINE function. If I've misread the situation, please provide more information. 1 1 Quote
Aftertouch Posted November 12, 2018 Author Posted November 12, 2018 Thanks for the reply... As i tought, its not possible. so i wrote a LISP for it. (defun C:MULTISNAP ( / multisnap ) (if (not hboldsnap)(setq hboldsnap (getvar "OSMODE"))) (initget "END MID CEN NOD QUA INT INS PER TAN NEA GCEN EXT PAR RESET") (setq multisnap (getkword (strcat "\nMultiple snap override [END/MID/CEN/NOD/QUA/INT/INS/PER/TAN/NEA/GCEN/EXT/PAR/RESET]: "))) (if (not multisnap)(setq multisnap "END")) (cond ((= multisnap "END")(setq multisnap 1)) ((= multisnap "MID")(setq multisnap 2)) ((= multisnap "CEN")(setq multisnap 4)) ((= multisnap "NOD")(setq multisnap 8)) ((= multisnap "QUA")(setq multisnap 16)) ((= multisnap "INT")(setq multisnap 32)) ((= multisnap "INS")(setq multisnap 64)) ((= multisnap "PER")(setq multisnap 128)) ((= multisnap "TAN")(setq multisnap 256)) ((= multisnap "NEA")(setq multisnap 512)) ((= multisnap "GCEN")(setq multisnap 1024)) ((= multisnap "EXT")(setq multisnap 4096)) ((= multisnap "PAR")(setq multisnap 8192)) ((= multisnap "RESET")(setq multisnap hboldsnap)) ) (setvar "OSMODE" multisnap) (princ) ) 1 Quote
Incognito Cube Posted November 12, 2018 Posted November 12, 2018 Alternatively, I've gotten into the habit of CTRL+Right Click while the command is active then just pressing the corresponding key for whichever snap I need for that particular function that isn't already in my OSNAP setting. Takes less than a second to override now that I've gotten it to muscle memory, but I can definitely see how it would get rough when needing to select, say, perpendicular or endpoint 25-50 times in one command. Though, keyboard macros have saved my fingers plenty in those situations... One for MID>Enter, one for PERP>Enter, one for END>Enter. I'm gonna give these LISPs a shot though. I'm always down for experimenting with a new method. Quote
BIGAL Posted November 13, 2018 Posted November 13, 2018 If its something you want to force inside a program like a point is to be perp then just change the variable Osmode to correct value in your code. Quote
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.