Your code looks like it works but mine still doesn't work.
Here is the full code
(defun C:circleChanger ( / objectsset center edata eid etype translategroup minim maxim ang colorN)
; ask the user to select a set of objects
(setq objectsset (ssget))
(initget 1)
(setq center (getpoint "Center of the action :\n"))
;(initget 1)
(setq minim (getint "Minimum radius:\n"))
(setq maxim (getint "Maximum radius:\n"))
;(command "_.ChProp" objectsset "" "_C" 3 "")
; iterate over the selection set
(setq slen (sslength objectsset)
ix 0)
(setq avgN (/ (+ maxim minim) 2.))
(while (< ix slen)
(setq edata (entget (ssname objectsset ix))
eid (cdr (assoc -1 edata))
etype (cdr (assoc 0 edata))
)
(if (/= etype "CIRCLE") ; not a circle
(progn
(princ "Warning! [")
(princ eid)
(princ "] was not a [CIRCLE], but a [")
(princ etype)
(princ "]; skipped.\n")
) ; then - progn
(progn
(setq translategroup (assoc 10 edata)
edata (subst (cons 10 center) translategroup edata)
)
;(command "_.ChProp" ss "" "_C" usercol "")
;(setvar "hpscale" (cdr (assoc 41 edata))); SCALE
; (setvar "hpang" (cdr (assoc 52 edata))); ANGLE
(setq radiusN (cdr (assoc 40 edata))) ; radius
; (setq radius (cdr (assoc 39 Ent))
(cond
((<= radiusN avgN)
(princ "here! 1")
(command "_.ChProp" (cdr (assoc -1 edata)) "" "_C" 1 "")
)
((> radiusN avgN)
(princ "here! 2")
(command "_.ChProp" (cdr (assoc -1 edata)) "" "_C" 2 "")
)
)
; (princ radiusN)
; (princ avgN)
(setq ang 0)
(repeat 6
(command "PLINE"
(polar center ang (/ radiusN 2 (cos (/ pi 6))))
(polar center (+ ang (/ pi 6)) radiusN)
(polar center (+ ang (/ pi 3)) (/ radiusN 2 (cos (/ pi 6))))
""
)
(setq ang (+ ang (/ pi 3)))
)
(entmod edata)
)
)
(setq ix (1+ ix))
) ; while
(princ) ; don't return anything
)