(defun c:hammer () ; Beispiel für Animation in Bricscad ;ACAD-Beispiel von fuccaro ;siehe: ;http://www.cadtutor.net/forum/showthread.php?t=883&highlight=hammer.lsp (setvar "cmdecho" 0) (setq os (getvar "osmode") fd (getvar "filedia") ) (setvar "osmode" 0) (setvar "filedia" 0) (command "_box" '(-9 0 -5) '(9 -5 1)) (command "_color" "3") (command "_pline" '(0 0) '(1 3) '(1 13) '(2 14) '(0 14) "s") (command "_revolve" "l" "" '(0 0) '(0 1) "") (setq nail (entlast)) (command "_color" "5") (command "_pline" '(21 19) '(22 19.3) '(23 23) '(22 43) '(21 43) "s") (command "_revolve" "l" "" '(21 0) '(21 1) "") (setq handle (entlast)) (command "_color" "7") (command "_pline" '(16 38 -2.5) '(28 38) '(28 40) '(24 42) '(16 42) "s") (command "_extrude" "l" "" 5 "") (setq hammer (entlast)) (command "_viewpoint" '(-3 -9 12)) (setq i -1) ; (command "_shademode" "g") (command "_shade") (repeat 10 (command "_rotate" hammer handle "" '(21 19) 10) (command "_shade") (repeat 10000 (setq ii 1)) (if (= i 8) (command "_move" nail "" '(0 -3.9) "") ) (setq i (1+ i)) ; (command "_bmpout" (strcat "hammer" (itoa i)) "_all" "") ; (command "_bmpout" (strcat "hammer" (itoa i))) ) (setvar "osmode" os) (setvar "filedia" fd) (command "_shade") )