From 30e564ee47ac2593312c6733b436b7e4ea436790 Mon Sep 17 00:00:00 2001 From: Jaidyn Ann <10477760+JadedCtrl@users.noreply.github.com> Date: Sat, 15 Jul 2023 01:50:46 -0500 Subject: [PATCH] Begin nethack-factory map --- flora-search-aurora.asd | 1 + flora-search-aurora.lisp | 42 ++++++++++++++++--------- res/maps/factory.tmx | 67 ++++++++++++++++++++++++++++++++++++++++ res/maps/outdoors.tmx | 18 ++++++----- res/maps/tmx→lisp.lisp | 3 +- 5 files changed, 108 insertions(+), 23 deletions(-) create mode 100644 res/maps/factory.tmx diff --git a/flora-search-aurora.asd b/flora-search-aurora.asd index 0b48036..16242f4 100644 --- a/flora-search-aurora.asd +++ b/flora-search-aurora.asd @@ -18,6 +18,7 @@ (:file "res/clocks") (:file "res/maps/base.tmx") (:file "res/maps/casino.tmx") + (:file "res/maps/factory.tmx") (:file "res/maps/flashback-base.tmx") (:file "res/maps/flashback-casino.tmx") (:file "res/maps/flashback-school.tmx") diff --git a/flora-search-aurora.lisp b/flora-search-aurora.lisp index 621a4d2..37e4ebd 100644 --- a/flora-search-aurora.lisp +++ b/flora-search-aurora.lisp @@ -134,6 +134,14 @@ Useful for making barriers the player character refuses to traverse." map (symbol-value (read-from-string (getf trigger-plist :map))))))) +(defun avatar-change-trigger (map &optional trigger-plist) + "A somewhat weird trigger that changes the player's face or avatar." + (setf (getf-entity-data map 'player :talking-face) (getf trigger-plist :talking-face)) + (setf (getf-entity-data map 'player :face) (getf trigger-plist :face)) + (setf (getf-entity-data map 'player :avatar) (getf trigger-plist :avatar)) + (list :parameters (list :map map))) + + (defun entrance-interact (map interactee) "An interact function that can be used to move the user from one MAP to another, via the :MAP property in the INTERACTEE’s Tiled entity." @@ -212,21 +220,6 @@ run the :USE function of the nearest entity, if it has any." ;;; ——————————————————————————————————— ;;; The Outside World™ ;;; ——————————————————————————————————— - -(defun factory-window-interact (&optional map interactee-id) - (make-dialogue-state - map - (start-dialogue - (💬:face 'player "` `" "`o`") - (💬:mumble 'player :eo "(Al ĉi tiu fenesto tute mankas vitro!)" - :en "(This window's got no pane at all!)") - (💬:mumble 'player :eo "(Mi kredeble povus grimpi tien, fakte...)" - :en "(I could probably fit my way in there, actually...)") - (💬:mumble 'player :eo "(... sed ĉu vere farindas?)" - :en "(... but should I?)" - :face "`o`")))) - - ;;; ——————————————————————————————————— ;;; Random outdoors NPCs @@ -818,6 +811,24 @@ avoid triggering this." :map *flashback-base-map*)) + +;;; ——————————————————————————————————— +;;; Factory! +;;; ——————————————————————————————————— +(defun factory-window-interact (&optional map interactee-id) + (make-dialogue-state + map + (start-dialogue + (💬:face 'player "` `" "`o`") + (💬:mumble 'player :eo "(Al ĉi tiu fenesto tute mankas vitro!)" + :en "(This window's got no pane at all!)") + (💬:mumble 'player :eo "(Mi kredeble povus grimpi tien, fakte...)" + :en "(I could probably fit my way in there, actually...)") + (💬:mumble 'player :eo "(... sed ĉu vere farindas?)" + :en "(... but should I?)" + :face "`o`")))) + + ;;; ——————————————————————————————————— ;;; Casino! @@ -1204,6 +1215,7 @@ Initializes the current instance of the game, and such." (lambda (matrix) (defparameter *base-map* (🌍:plist->map (metacopy:copy-thing *base-map-plist*))) (defparameter *casino-map* (🌍:plist->map (metacopy:copy-thing *casino-map-plist*))) + (defparameter *factory-map* (🌍:plist->map (metacopy:copy-thing *factory-map-plist*))) (defparameter *flashback-base-map* (🌍:plist->map (metacopy:copy-thing *flashback-base-map-plist*))) (defparameter *flashback-casino-map* (🌍:plist->map (metacopy:copy-thing *flashback-casino-map-plist*))) (defparameter *flashback-school-map* (🌍:plist->map (metacopy:copy-thing *flashback-school-map-plist*))) diff --git a/res/maps/factory.tmx b/res/maps/factory.tmx new file mode 100644 index 0000000..7239214 --- /dev/null +++ b/res/maps/factory.tmx @@ -0,0 +1,67 @@ + + + + + + + + +0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0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,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, +0,0,0,0,0,0,0,93,0,93,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, +0,0,0,0,0,0,0,93,0,93,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, +0,0,0,0,0,0,0,93,0,93,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, +0,0,0,0,0,0,0,93,0,93,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0, +0,0,0,0,0,0,0,4,4,4,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0 + + + + + + + + + + + + + + + + + + + (Back through the window, alley-oop!) + + (Ree tra la fenestro!) + + + + + + + + + + + + + + + + + + diff --git a/res/maps/outdoors.tmx b/res/maps/outdoors.tmx index d19d418..94ee265 100644 --- a/res/maps/outdoors.tmx +++ b/res/maps/outdoors.tmx @@ -1576,13 +1576,17 @@ - (These doors are *really* locked.) -(Literally, I think they used pad-locks on padlocks...?) - (La apudmara ŝtono!) -(Mi memoras, ke la gepatroj rakontis al mi pri ĝi...) -(... ke antaŭ jarcentoj, ĝi estis akra glavo kontraŭ granda drako.) + (Al ĉi tiu fenesto tute mankas vitro!) +(Mi kredeble povus grimpi tien, fakte...) +(... sed ĉu vere farindas?) + + (This window's got no pane at all!) +(I could probably fit my way in there, actually...) +(... but should I?) + - + + @@ -1872,7 +1876,7 @@ DANĜERA LOKO - VENENA MATERIO - + diff --git a/res/maps/tmx→lisp.lisp b/res/maps/tmx→lisp.lisp index 8cb4ee9..30ee24c 100644 --- a/res/maps/tmx→lisp.lisp +++ b/res/maps/tmx→lisp.lisp @@ -16,6 +16,7 @@ (overworld.tiled:load-map (local-path (format nil "res/maps/~A.tmx" map-name))) ":FLORA-SEARCH-AURORA" (format nil "*~A-map-plist*" map-name))) - '("base" "casino" "flashback-base" "flashback-casino" "flashback-school" "outdoors")) + '("base" "casino" "factory" "flashback-base" "flashback-casino" + "flashback-school" "outdoors")) (quit)