fixed ending.

This commit is contained in:
2015-09-05 13:56:19 -07:00
parent da00759f47
commit 641c1fb155
4 changed files with 108 additions and 141 deletions

View File

@@ -285,38 +285,6 @@ void main()
((:get-script default-interaction) (get-in entities [:cursor :current]) [x y])) entities))
(assoc-in entities [:cursor :down-target] nil)))
(defn drink-blergh [entities]
(actions/walk-straight-to entities :ego [205 45])
(sound! (sound "ego/potion.ogg") :play (utils/current-sound-volume))
(actions/play-animation entities :ego :grow :stop? false)
(actions/do-dialogue entities
:blergh "What this? A potion of strength?"
:blergh "You're still no match for me."
:blergh "Give it to me, or I'll make you regret it!")
(actions/present-choices entities {:choices ["Ok."
{:run (fn [_]
(actions/talk entities :ego "Ok." :anim :grow-talk :stop? false)
(actions/talk entities :ego "Here you go." :anim :grow-talk)
(actions/do-dialogue entities
:blergh "Yes! Now I can drink this whole thing and can become powerful enough to rule the world!"
:blergh "[#AAFFAAFF]*gulp*[]"
:blergh "What's this? What's happening?")
(actions/talk entities :ego "Uh oh." :anim :grow-talk :stop? false)
(actions/walk-straight-to entities :ego [100 45] :face :right)
(actions/play-animation entities :blergh :grow :stop? false)
(actions/do-dialogue entities :ego "'Not more than that do drink,\nOr you'll push your body to the brink.'"
:ego "Brilliant! I win!")
(actions/walk-straight-to entities :ego [800 75] :face :right)
(actions/update-state entities (fn [s] (assoc s :blergh-dead? true))))}
"No way!"
{:run (fn [_]
(actions/talk entities :ego "No way!" :anim :grow-talk)
(actions/talk entities :blergh "Then take this!")
(actions/play-animation entities :blergh :swing)
(actions/walk-straight-to entities :ego [100 45] :anim :squat :override-dir :right :speed 3.0)
(actions/do-dialogue entities :ego "Yeow!!"
:ego "Even with that potion, I'm not strong enough."))}]}))
(defn get-ego-script [cursor [x y]]
(condp = (:value cursor)
@@ -325,9 +293,9 @@ void main()
:flask-1-strength
(actions/get-script entities
(cond (and (actions/has-item? entities :magic-slingshot)
(get-in @entities [:room :blergh]))
(drink-blergh entities)
(cond (= :held
(get-in @entities [:state :last-room]))
(common/do-win entities)
(get-in @entities [:room :entities :warden])
(do