(SysVarStore > '("CMDECHO" "BLIPMODE" "MENUECHO" "CECOLOR" > "CLAYER" "HIGHLIGHT" "LIMCHECK" "CMDDIA" > "FILEDIA" "ATTDIA" "REGENMODE" "LUNITS" > "LUPREC" > ) >) ;_ end of SysVarStore>
;;;================================================================== >;;; (SysVarStore v) >;;; Store system variables >;;;------------------------------------------------------------------ >;;; Parameters: >;;; v list of var names to store ("CMDECHO" "CLAYER") >;;;------------------------------------------------------------------ >;;; Returns: >;;; sets global var Lobot:SVARS >;;;------------------------------------------------------------------ >(defun SysVarStore (v) > (setq Lobot:SVARS '()) > (repeat (length v) > (setq Lobot:SVARS > (cons (list (car v) (getvar (car v))) > Lobot:SVARS > ) ;_ end of cons > ) ;_ end of setq > (setq v (cdr v)) > ) ;_ end of repeat >) ;_ end of defun >;;;================================================================== >;;; (SysVarReset) >;;; Reset system vars changed by SysVarStore >;;;------------------------------------------------------------------ >;;; Parameters: >;;; uses global var Lobot:SVARS >;;;------------------------------------------------------------------ >;;; Returns: >;;; always returns nil >;;;------------------------------------------------------------------ >(defun SysVarReset () > (if Lobot:SVARS > (progn > (repeat (length Lobot:SVARS) > (setvar (caar Lobot:SVARS) (cadar Lobot:SVARS)) > (setq Lobot:SVARS (cdr Lobot:SVARS)) > ) ;_ end of repeat > (setq Lobot:SVARS nil) > ) ;_ end of progn > ) ;_ end of if >) ;_ end of defun >