-
Re: revcloud lisp
You're welcome anytime .
Please notice the changes that I made to the routine and the last line which belong to the system variable "clayer". So if you run your post of codes take a look at the command line and you will see the name of created Layer appears at the end and that is not right.
Besides that your request for the sentence of the command line.
Code:
(defun c:THAR ( / i o ss x oldlay sss )
(setq oldlay (getvar "clayer"))
(setq a (getvar "cannoscalevalue"))
(COMMAND "-LAYER" "M" "EEREVISION" "C" "4" "" "S" "EEREVISION" "")
(setq sss (
cond
((= a (/ 1.0 192.0)) 50.0) ;1/16th scale sets arc length to 50
((= a (/ 1.0 128.0)) (/ 135.0 4.0)) ;3/32th scale sets arc length to 33.75
((= a (/ 1.0 96.0)) 25.0) ;1/8th scale sets arc length to 25
((= a (/ 1.0 64.0)) (/ 75.0 4.0)) ;3/16th scale sets arc length to 18.75
((= a (/ 1.0 48.0)) (* 25.0 0.5)) ;1/4 scale sets arc length to 12.5
((= a 1.0) (/ 1.0 4.0)) ;1:1 scale sets arc length to .25
((= a (/ 1.0 240.0)) 75.0) ;1:20 scale sets arc length to 75
((= a (/ 1.0 480.0)) 100.0) ;1:40 scale sets arc length to 100
((= a (/ 1.0 24.0)) (* 25 0.25)) ;1/2 scale sets arc length to 6.25
)
)
;THARWAT Nov 04.2010 [forums.augi.com/showthread.php?p=1108252#post1108252]
(if (eq "No" (progn (initget 0 "Yes No")(getkword "\n Specify start point [Yes], or object [No] : ")))
(progn
(setq i 0)
(setq o (ssget "_:L" '((0 . "CIRCLE,LWPOLYLINE"))))
(setq ss (sslength o))
(repeat ss
(setq x (ssname o (setq i (1+ i))))
(command "_.revcloud" "style" "calligraphy" "a" SSS SSS "_o" o ""))
)
(progn
(command "_.revcloud" "A" SSS SSS (while (> (getvar "CmdActive") 0) (command pause)))
)
)
(setvar "clayer" oldlay)
(princ)
)
Tharwat
-
Re: revcloud lisp
more sensible:
Code:
(initget 0 "Points Object")
(if (eq "Object" (getkword "\nSpecify points or select object? [Points/Object] <Points>: "))
(progn
(setq i 0)
(setq o (ssget "_:L" '((0 . "CIRCLE,LWPOLYLINE"))))
(setq ss (sslength o))
(repeat ss
(setq x (ssname o (setq i (1+ i))))
(command "_.revcloud" "style" "calligraphy" "a" SSS SSS "_o" o "")
)
)
(command "_.revcloud" "A" SSS SSS (while (> (getvar "CmdActive") 0) (command pause)))
)
-
Re: revcloud lisp
Nice , clearer and stright to the point .;)
Thanks you.
Tharwat