just working on this tree.

This commit is contained in:
Bryce Covert
2015-08-01 00:53:45 -07:00
parent bb9b7b82de
commit 8bf776030b

View File

@@ -146,6 +146,26 @@
(actions/get-script entities
(actions/talk entities :ego "I don't want to put something in there unless I'm sure I need to."))))
(defn do-frog [entities]
(actions/talk entities :wizard "Grenouille KALA!!!" :anim :talk-angry :stop? false)
(particle-effect! (get-in @entities [:room :entities :magic-frog-particle]) :reset)
(particle-effect! (get-in @entities [:room :entities :magic-frog-particle]) :start)
(actions/begin-animation entities :ego :frog)
(Thread/sleep 2000)
(actions/begin-animation entities :wizard :stand)
(Thread/sleep 1000)
(actions/do-dialogue entities
:wizard "I warned you, Tick."
:wizard "Now, I will return you to your true state if you leave me in peace."
:wizard "Do you promise?")
(actions/play-animation entities :ego :frog-nod :stop? false)
(actions/talk entities :wizard "Frustatium DISPOSIUM!!!" :anim :talk-angry :stop? false)
(particle-effect! (get-in @entities [:room :entities :magic-frog-particle]) :reset)
(particle-effect! (get-in @entities [:room :entities :magic-frog-particle]) :start)
(Thread/sleep 1500)
(actions/transition-background entities :outside-house [257 90] :face :left))
(defn wizard-dialogue [entities]
(if (get-in @entities [:state :has-met-gandarf?])
(do (actions/do-dialogue entities :ego "Hello again Gandarf!"
@@ -166,22 +186,26 @@
(actions/begin-animation entities :wizard :magic-hands)))
(actions/update-state entities (fn [s] (assoc s :has-met-gandarf? true)))
(actions/present-choices entities
{:choices ["What do you mean, \"Not you again?\""
{:run #(actions/respond entities % :wizard "I mean, you've wrecked my life and I never want to see you again.")
{:choices ["Surely you can't still be angry with me!"
{:run #(actions/respond entities % :wizard "I can't?"
:wizard "Do you even remember what you did?")
:choices ["You mean the time I set your house on fire with a fire mint?"
{:run #(do
(actions/respond entities %
:wizard "That was you!?"
:wizard "My house was nearly destroyed!"
:wizard "I spent weeks rebuilding my home!"
)
:wizard "No, of course n...")
(Thread/sleep 500)
(actions/do-dialogue entities :wizard "Wait... that was you!?" :wizard "My house was completely destroyed!")
(Thread/sleep 500)
(actions/talk entities :wizard "I had to move out of town into this shack!" :anim :talk-angry :stop? false)
(actions/talk entities :wizard "Leave, now, or I'll turn you into a ..." :anim :talk-angry :stop? false)
(actions/talk entities :wizard "... a ..." :anim :talk-angry :stop? false)
(actions/talk entities :wizard "... a frog!" :anim :talk-angry)
(actions/talk entities :wizard "... a pack of matches!" :anim :talk-angry)
(actions/begin-animation entities :wizard :magic-hands)
(actions/talk entities :ego "Okay, okay, I'm leaving!")
(actions/transition-background entities :outside-house [257 90] :face :left)
(actions/do-dialogue entities :ego "I guess he's really upset with me."
:ego "I wonder if I can convince him to let me stay..."))}
(actions/play-animation entities :ego :sigh)
(actions/do-dialogue entities :ego "It seems like his temper is on fire."
:ego "Sort of like his house was."))}
"You're still cross about my stealing your magic cowboy hat?"
{:run #(do (actions/respond entities %
:wizard "Of course I'm cross! It's irreplaceable!"
@@ -189,12 +213,36 @@
:wizard "And complemented my skin color."
:wizard "And you little pipsqueak stole it from me!"
:wizard "That's why I bought my Magi-Safe 5000, to keep out intruders like you."
:wizard "Now leave, before I get really angry!.")
)
(actions/talk entities :wizard "Now leave, before I force you out!" :anim :talk-angry :stop? false)
(actions/begin-animation entities :wizard :magic-hands)
(actions/transition-background entities :outside-house [257 90] :face :left)
(actions/do-dialogue entities :ego "I guess he's really upset with me."
:ego "I wonder if I can convince him to let me stay..."))}
"Even an old hoot like you needs a kick in the pants every now and again."
{:run #(actions/respond entities % :wizard "What gives you the right to try to teach me a lesson?")
(actions/do-dialogue entities :ego "I guess he's really upset about that cowboy hat!"))}
"Maybe the time I freed your pet dragon?"
{:run #(do (actions/respond entities %
:wizard "Of course I mean that!"
:wizard "I've raised Snaggletooth from the day he was born."
:wizard "Raised him as my own, I did."
:wizard "47 long years."
:wizard "All for nothing!")
(actions/talk entities :wizard "Give me one reason I shouldn't turn you into a replacement dragon right now!"
:anim :talk-angry :stop? false)
(actions/begin-animation entities :wizard :magic-hands))
:choices ["Frankie Rockfist and his gang made me do it!"
{:run #(do (actions/respond entities %
:wizard "Frankie Rockfist, eh?"
:wizard "What kind of dumb name is Frankie Rockfist?!"
)
(Thread/sleep 1000)
(actions/talk entities :wizard "You think I'm stupid enough to fall for that?!" :anim :talk-angry :stop? false)
(actions/talk entities :wizard "It's time to teach you a lesson." :anim :talk-angry :stop? false)
(do-frog entities)
(actions/do-dialogue entities :ego "Phew!"
:ego "I thought I had nearly croaked!"))}
"I'm on an important quest!"
{:run #(actions/respond entities % :wizard "Eh?"
:wizard "Pray tell, what kind of quest?")
:choices ["My good looks?"
{:run #(do (actions/respond entities %
:wizard "You know, handsome looks aren't all they're chocked up to be."
@@ -249,9 +297,24 @@
:wizard "While your goal sounds noble, no amount of bizarre conversation tree searching will earn my respect."
:wizard "Now please leave.")
(actions/transition-background entities :outside-house [257 90] :face :left)
(actions/talk entities :ego "If only Gandarf could be tricked into seeing the valiant side of me..."))}]}]}]}
"You're not happy to see me, Gandarf?"
{:run #(actions/respond entities % :wizard "Of course not, you little brat. You've made my life a living hell!")
(actions/talk entities :ego "If only Gandarf could be tricked into seeing the valiant side of me..."))}]}]}
"Snaggletooth deserved a free life, you old gheezer!"
{:run #(do (actions/respond entities % :wizard "Why, you..."
:wizard "Snaggletooth was my friend!")
(Thread/sleep 1000)
(do-frog entities)
(actions/talk entities :ego "Phew!")
(actions/talk entities :ego "I thought I had ribbit the dust!"))}
]}
]}
"But I'm your friend, Gandarf!"
{:run #(do (actions/respond entities % :wizard "Friend? "
:wizard "What kind of friend would do what you did to me?")
(Thread/sleep 500)
(actions/talk entities :wizard "You don't even remember what you did, do you?")
)
:choices #(-> % zip/left)}
"Or else what?"
{:run #(do (actions/talk entities :ego %)
@@ -262,23 +325,11 @@
#(do
(actions/talk entities :ego %)
(actions/talk entities :wizard "You asked for it, boy." :anim :talk-angry :stop? false)
(actions/talk entities :wizard "Grenouille KALA!!!" :anim :talk-angry :stop? false)
(particle-effect! (get-in @entities [:room :entities :magic-frog-particle]) :reset)
(particle-effect! (get-in @entities [:room :entities :magic-frog-particle]) :start)
(actions/begin-animation entities :ego :frog)
(Thread/sleep 2000)
(actions/begin-animation entities :wizard :stand)
(Thread/sleep 1000)
(actions/do-dialogue entities
:wizard "I warned you, Tick."
:wizard "Now, I will return you to your true state if you leave me in peace."
:wizard "Do you promise?")
(actions/play-animation entities :ego :frog-nod :stop? false)
(actions/talk entities :wizard "Frustatium DISPOSIUM!!!" :anim :talk-angry :stop? false)
(particle-effect! (get-in @entities [:room :entities :magic-frog-particle]) :reset)
(particle-effect! (get-in @entities [:room :entities :magic-frog-particle]) :start)
(Thread/sleep 1500)
(actions/transition-background entities :outside-house [257 90] :face :left))}
(do-frog entities))
}
"On second thought..."
{:run #(actions/do-dialogue entities :ego %)
:choices actions/something-else}
"Okay, okay, I'm leaving."
{:run
#(do
@@ -287,7 +338,7 @@
"Okay, okay, I'm leaving."
{:run #(do
(actions/talk entities :ego %)
(actions/talk entities :wizard "Okay, okay, I'm leaving." :anim :talk-angry)
(actions/talk entities :wizard "Good riddance!" :anim :talk-angry)
(actions/transition-background entities :outside-house [257 90] :face :left))}]}))