[Search tip detail and code files using keywords, tip number, author name, etc ]
 
Rotate UCS with the Number Pad
Tip# 3315 By Steve Schulz On 03-Jan-2010
3.666665
Rated By 3 users
Categories : 3D Interface
Software type : AutoCAD 2010
Rename File To : No Files to download.
Try this tool if you are performing many 3D edits.

Steve Schulz sends us a routine he made to help speed navigation inside the UCS.

"I have set up my number pad as my UCS (user coordinate system) navigator. It is the best thing I have ever done for 3D drawings. I made a LISP routine that rotates the UCS when I type numbers followed by Enter: 1 rotates the x-axis 90 degrees, 2 rotates the y-axis 90 degrees, and 3 returns to the previous setting. I have expanded the LISP to rotate -90 degrees when I enter 4, 5, or 6 (6 rotates the z-axis), and to rotate 45 degrees in response to 7, 8, or 9. It's a huge time-saver."
 

(defun C:1 ( ) (command "ucs" "x" "90") (princ))

 (defun C:2 ( ) (command "ucs" "y" "90") (princ))

 (defun C:3 ( ) (command "ucs" "p") (princ))

 (defun C:4 ( ) (command "ucs" "x" "-90") (princ))

 (defun C:5 ( ) (command "ucs" "y" "-90") (princ))

 (defun C:6 ( ) (command "ucs" "z" "-90") (princ))

 (defun C:7 ( ) (command "ucs" "x" "45") (princ))

 (defun C:8 ( ) (command "ucs" "y" "45") (princ))

 (defun C:9 ( ) (command "ucs" "z" "45") (princ))

Notes from Cadalyst Tip Patrol: This is very fast indeed! Keep in mind that you are not rotating your view, but the UCS. When you first execute this routine you might get a little lost in your drawing, unless you are accustomed to rotating your UCS. To reset your UCS once you are done editing, type UCS on the command line, then type W for World. This will reset you to World Coordinates. This is a good tool to use if you are performing many 3D edits.

  

 

Average Rating:
3.666665


User comments
Comment by Hollingsworth,Michael
Posted on 2010-01-05 08:19:37
It stands to reason that you keep UCSFollow turned on for these routines. I often have it turned off, so I would suggest adding a subroutine to check its state before executing the rest. Other than that, good job!
Comment by Anonymous
Posted on 2010-01-05 08:30:27
It seems that you could set 0 on the number pad to 'World' or to another named default UCS if you have one, in case you need to reset the UCS. Other than that, this is great


Log In