burning-marshmallow seems to work now with boundings.
authorChristoph Senjak <christoph@christoph-senjaks-macbook-pro.local>
Mon, 24 Aug 2009 06:58:24 +0000 (08:58 +0200)
committerChristoph Senjak <christoph@christoph-senjaks-macbook-pro.local>
Mon, 24 Aug 2009 06:58:24 +0000 (08:58 +0200)
leveleditor.lisp
room.lisp

index bf2a9f7..86a6ccc 100644 (file)
@@ -180,9 +180,6 @@ form (x y object arg1 arg2 ...)."
                       ((eq cval 'uxul-world::key)
                        (config-button-image cbtn key))
                       ((eq cval 'uxul-world::anchor)
-                       (format t "fuck")
-                       (format t (cadr cval2))
-                       (write (gethash (cadr cval2) anchors))
                        (config-button-image cbtn (gethash (cadr cval2) anchors)))
                       ((eq cval 'uxul-world::uxul)
                        (config-button-image cbtn uxul)))))
index 7e99218..f017379 100755 (executable)
--- a/room.lisp
+++ b/room.lisp
            (x (cadr item))
            (type (caddr item))
            (arg1 (cadddr item))
-           (arg2 (caddddr item)))
+           (arg2 (car (cddddr item))))
        (cond
+         ((eq type 'anchor))
          ((eq type 'uxul)
           (setf (x player) (* 128 x))
           (setf (y player) (* 128 y))
           (add-object (make-instance 'flying-nasobem
                                      :x (* 128 x)
                                      :y (* 128 y)) room))
+         ((eq type 'burning-marshmallow)
+          (add-object (make-instance 'burning-marshmallow
+                                     :x (* 128 x)
+                                     :y (* 128 y)
+                                     :inner-rectangle
+                                     (and (not (string= arg1 "")) (not (string= arg2 ""))
+                                          (list
+                                           (* 128 (car (gethash arg1 anchor-table)))
+                                           (* 128 (cdr (gethash arg1 anchor-table)))
+                                           (* 128 (1+ (car (gethash arg2 anchor-table))))
+                                           (* 128 (1+ (cdr (gethash arg2 anchor-table))))))) room))
          (T
           (add-object (make-instance type
                                      :x (* 128 x)