made it so you have to do things in order.
This commit is contained in:
@@ -50,7 +50,8 @@
|
||||
:game-player "I guess I'm pretty wise."
|
||||
:game-player "And with my sharp intellect, I'm guessing you want my trophy?")
|
||||
:choices ["Yes."
|
||||
{:run #(do (actions/respond entities %
|
||||
{:run #(do (actions/update-state entities (fn [state] (assoc state :current-riddle :wool)))
|
||||
(actions/respond entities %
|
||||
:game-player "Well, if you want my trophy, you'll have to earn it."
|
||||
:game-player "There are a few riddles that even I, the wisest in all of Remington, cannot solve."
|
||||
:game-player "How about you help me?"
|
||||
@@ -81,24 +82,34 @@
|
||||
:entities {:game-player (assoc (texture "inside-castle/gameplayer.png") :x 266 :y 49 :baseline 191
|
||||
:script (actions/get-script entities (do-game-player-dialogue entities))
|
||||
:scripts {:wool (actions/get-script entities
|
||||
(actions/remove-item entities items/wool)
|
||||
(actions/do-dialogue entities
|
||||
:game-player "That's right! Now for your second riddle:"
|
||||
:game-player "Filled with air, light as a feather,"
|
||||
:game-player "If you want to keep it, best have a tether."))
|
||||
(if (= :wool (get-in @entities [:state :current-riddle]))
|
||||
(do (actions/update-state entities #(assoc % :current-riddle :balloon))
|
||||
(actions/remove-item entities items/wool)
|
||||
(actions/do-dialogue entities
|
||||
:game-player "That's right! Now for your second riddle:"
|
||||
:game-player "Filled with air, light as a feather,"
|
||||
:game-player "If you want to keep it, best have a tether."))
|
||||
(actions/talk entities :ego "He doesn't need it.")))
|
||||
:balloon (actions/get-script entities
|
||||
(actions/remove-item entities items/balloon)
|
||||
(actions/do-dialogue entities
|
||||
:game-player "That's right! Now for your third riddle:"
|
||||
:game-player "Hippity-hop, I jump really far,"
|
||||
:game-player "Now I'm dead, or at least a have a scar."))
|
||||
(if (= :balloon (get-in @entities [:state :current-riddle]))
|
||||
(do (actions/update-state entities #(assoc % :current-riddle :frog-legs))
|
||||
(actions/remove-item entities items/balloon)
|
||||
(actions/do-dialogue entities
|
||||
:game-player "That's right! Now for your third riddle:"
|
||||
:game-player "Hippity-hop, I jump really far,"
|
||||
:game-player "Now I'm dead, or at least a have a scar."))
|
||||
(actions/talk entities :ego "He doesn't need it.")))
|
||||
:frog-legs (actions/get-script entities
|
||||
(actions/remove-item entities items/frog-legs)
|
||||
(actions/do-dialogue entities
|
||||
:game-player "Wow! That's right!"
|
||||
:game-player "I guess I'm not the wisest person in Remington."
|
||||
:game-player "You have earned my trophy.")
|
||||
(actions/give entities items/trophy))}
|
||||
(if (= :frog-legs (get-in @entities [:state :current-riddle]))
|
||||
(do (actions/update-state entities #(assoc % :current-riddle :done))
|
||||
|
||||
(actions/remove-item entities items/frog-legs)
|
||||
(actions/do-dialogue entities
|
||||
:game-player "Wow! That's right!"
|
||||
:game-player "I guess I'm not the wisest person in Remington."
|
||||
:game-player "You have earned my trophy.")
|
||||
(actions/give entities items/trophy))
|
||||
(actions/talk entities :ego "He doesn't need it.")))}
|
||||
:anim nil
|
||||
:talk game-player-talk)}
|
||||
:collision "inside-castle/collision.png"
|
||||
|
||||
Reference in New Issue
Block a user