X-Git-Url: https://jxself.org/git/?p=mudsync.git;a=blobdiff_plain;f=mudsync%2Fgameobj.scm;h=3957e0a4d40303898888af5828632f9e7f0525cb;hp=0ce19b6799bc2ecf2dbd168ad50507750072e177;hb=HEAD;hpb=0817a105f789bd12bd0ced0b80df8b671391f338 diff --git a/mudsync/gameobj.scm b/mudsync/gameobj.scm index 0ce19b6..fbf4a72 100644 --- a/mudsync/gameobj.scm +++ b/mudsync/gameobj.scm @@ -1,5 +1,5 @@ ;;; Mudsync --- Live hackable MUD -;;; Copyright © 2016 Christopher Allan Webber +;;; Copyright © 2016 Christine Lemmer-Webber ;;; ;;; This file is part of Mudsync. ;;; @@ -92,7 +92,7 @@ (prep-indir-command cmd-take-from '("from" "out of")))) ("put" ((prep-indir-command cmd-put-in - '("in" "inside" "on")))))) + '("in" "inside" "into" "on")))))) ;; Commands we can handle by being something's container ;; dominant version (goes before everything) @@ -241,6 +241,7 @@ Note that this doesn't do any special dyn-ref of the location." (replace-step actor occupants)) replace-steps)))) +(define %nothing (cons '*the* '*nothing*)) (define (gameobj-setup-props gameobj) (define class (class-of gameobj)) (define props (slot-ref gameobj 'props)) @@ -250,7 +251,8 @@ Note that this doesn't do any special dyn-ref of the location." ;; and use that to build up the table (hash-for-each (lambda (key value) - (when (not (hashq-ref props key value)) ; don't override init'ed instance values + (when (eq? (hashq-ref props key %nothing) ; don't override init'ed instance values + %nothing) (hashq-set! props key value))) (rmeta-slot-cache (class-slot-ref class 'initial-props)))) @@ -269,7 +271,7 @@ Note that this doesn't do any special dyn-ref of the location." (hashq-set! (slot-ref gameobj 'props) key val)) (define* (gameobj-act-get-prop actor message key #:optional dflt) - (gameobj-get-prop actor key dflt)) + (<-reply message (gameobj-get-prop actor key dflt))) (define (gameobj-goes-by gameobj) "Find the name we go by. Defaults to #:name if nothing else provided."