X-Git-Url: https://jxself.org/git/?a=blobdiff_plain;f=if.lisp;h=447f69787db91d9ae9364c3290072654903bc4ec;hb=0b54e760a0bb4044372a2407ee959b37952d3e4d;hp=5664a60d9a1eddba65200111c3cf5a758c1b9481;hpb=f590c554e7d2e0eaf32377427416a29f69a74034;p=lifp.git diff --git a/if.lisp b/if.lisp index 5664a60..447f697 100644 --- a/if.lisp +++ b/if.lisp @@ -483,14 +483,14 @@ word in dictionary, add it." (defun read-property- (method self property &rest args) "read-property using specific method. method is one of keywords: - :string :number :object :integer :" + :string :number :object :integer :execute :list" (case method (:string (apply #'read-property-string (slot-value self property) args)) - (:number (apply #'read-property-string (slot-value self property) args)) - (:integer (apply #'read-property-string (slot-value self property) args)) - (:object (apply #'read-property-string (slot-value self property) args)) - (:execute (apply #'read-property-string (slot-value self property) args)) - (:list (apply #'read-property-string (slot-value self property) args)) + (:number (apply #'read-property-number (slot-value self property) args)) + (:integer (apply #'read-property-integer (slot-value self property) args)) + (:object (apply #'read-property-object (slot-value self property) args)) + (:execute (apply #'read-property-execute (slot-value self property) args)) + (:list (apply #'read-property-list (slot-value self property) args)) (t (slot-value self property)))) ;;SECTION 7: IfClass macro and its hairy surroundings @@ -958,14 +958,15 @@ word in dictionary, add it." ;;React after? t) -(defun run-action (action args &key (time 0)) +(defun run-action (action args &key (time 0) no-output) "Run an action with a given args" (unless (listp args) (setf args (list args))) (setf *after* nil) (let ((*action* action) (*args* args) (*noun* (first args)) - (*second* (second args))) + (*second* (second args)) + (*no-output* no-output)) (when *debug* (format t "[running action: ~a ~a]~%" *action* *args*)) (when *meta* ;;Just do the darn thing!