protected override void SetFlagReactions() { Reaction neutralTowardsPlayer = new Reaction(); neutralTowardsPlayer.AddAction(new NPCEmotionUpdateAction(this, new NeturalTowardsPlayer(this, "Hi, it has been a long time since we last talked."))); neutralTowardsPlayer.AddAction(new NPCCallbackAction(MoveToOriginalLoc)); neutralTowardsPlayer.AddAction(new NPCCallbackAction(UpdateMoodToNeutral)); flagReactions.Add(FlagStrings.MusicianFriendsWithPlayer, neutralTowardsPlayer); Reaction becomesHappyBecauseSonNotCrazy = new Reaction(); becomesHappyBecauseSonNotCrazy.AddAction(new NPCEmotionUpdateAction(this, new DispleasedWithSon(this, "I am very disapointed by my son's actions, would you be a dear and make sure he stays out of trouble?"))); flagReactions.Add(FlagStrings.CSONAndCastleFriends, becomesHappyBecauseSonNotCrazy); flagReactions.Add(FlagStrings.PlayerAndCastleFriends, becomesHappyBecauseSonNotCrazy); flagReactions.Add(FlagStrings.BeachAfterConvoGood, becomesHappyBecauseSonNotCrazy); Reaction runAwayFromPlayer = new Reaction(); runAwayFromPlayer.AddAction(new NPCAddScheduleAction(this, runAway)); flagReactions.Add("Scared By Player", runAwayFromPlayer); Reaction makePlayerGoAway = new Reaction(); ShowMultipartChatAction multiChat = new ShowMultipartChatAction(this); multiChat.AddChat("Leave me alone.", 0.2f); multiChat.AddChat("Don't you have any friends? Go Away.", 0.5f); makePlayerGoAway.AddAction(multiChat); flagReactions.Add(FlagStrings.MusicianYellAtPlayer, makePlayerGoAway); }
protected void SetupReactions() { ShowMultipartChatAction castleDateOneDialogue = new ShowMultipartChatAction(this); castleDateOneDialogue.AddChat("*Out of Breath* At long last I get to try and court you my fair lady!", 5f); castleDateOne.AddAction(castleDateOneDialogue); ShowMultipartChatAction castleDateTwoDialogue = new ShowMultipartChatAction(this); castleDateTwoDialogue.AddChat("Endearing? My dear woman, I always speak this way!", 3f); castleDateTwo.AddAction(castleDateTwoDialogue); ShowMultipartChatAction castleDateThreeDialogue = new ShowMultipartChatAction(this); castleDateThreeDialogue.AddChat("You remember me!", 2f); castleDateThree.AddAction(castleDateThreeDialogue); castleDateThree.AddAction(new NPCCallbackAction(FlexMusclesDuringDate)); }
protected override void SetFlagReactions() { Reaction speakWithSiblingReactionPartOne = new Reaction(); ShowMultipartChatAction speakWithSiblingChatPartOne = new ShowMultipartChatAction(this); speakWithSiblingChatPartOne.AddChat("Patience.", 2f); speakWithSiblingReactionPartOne.AddAction(speakWithSiblingChatPartOne); flagReactions.Add(FlagStrings.FortunetellerTalkToSiblingOldPartOne, speakWithSiblingReactionPartOne); Reaction speakWithSiblingReactionPartTwo = new Reaction(); ShowMultipartChatAction speakWithSiblingChatPartTwo = new ShowMultipartChatAction(this); speakWithSiblingChatPartTwo.AddChat("I said patience!!", 2f); speakWithSiblingReactionPartTwo.AddAction(speakWithSiblingChatPartTwo); flagReactions.Add(FlagStrings.FortunetellerTalkToSiblingOldPartTwo, speakWithSiblingReactionPartTwo); Reaction speakWithSiblingReactionPartThree = new Reaction(); ShowMultipartChatAction speakWithSiblingChatPartThree = new ShowMultipartChatAction(this); speakWithSiblingChatPartThree.AddChat(".", .12f); speakWithSiblingChatPartThree.AddChat("..", .12f); speakWithSiblingChatPartThree.AddChat("...", .12f); speakWithSiblingChatPartThree.AddChat("...!", .12f); speakWithSiblingChatPartThree.AddChat("...!!", 1.5f); speakWithSiblingChatPartThree.AddChat("...!", .75f); speakWithSiblingChatPartThree.AddChat("...", .5f); speakWithSiblingChatPartThree.AddChat("..", .33f); speakWithSiblingChatPartThree.AddChat(".. F", .33f); speakWithSiblingChatPartThree.AddChat(".. Fi", .5f); speakWithSiblingChatPartThree.AddChat(".. Fin", .5f); speakWithSiblingChatPartThree.AddChat(".. Fine", 1f); speakWithSiblingChatPartThree.AddChat(".. Fine.", 1f); speakWithSiblingChatPartThree.AddChat("Let's get this over with.", 2f); speakWithSiblingChatPartThree.AddChat("What is it that you seek?", 2f); speakWithSiblingReactionPartThree.AddAction(speakWithSiblingChatPartThree); flagReactions.Add(FlagStrings.FortunetellerTalkToSiblingOldPartThree, speakWithSiblingReactionPartThree); Reaction speakWithSiblingReactionPartFour = new Reaction(); ShowMultipartChatAction speakWithSiblingChatPartFour = new ShowMultipartChatAction(this); speakWithSiblingChatPartFour.AddChat(".",.2f); speakWithSiblingChatPartFour.AddChat("..",.2f); speakWithSiblingChatPartFour.AddChat("...", 2f); speakWithSiblingChatPartFour.AddChat("Seeking a fortune with no goal in mind?", 1.5f); speakWithSiblingReactionPartFour.AddAction(speakWithSiblingChatPartFour); flagReactions.Add(FlagStrings.FortunetellerTalkToSiblingOldPartFour, speakWithSiblingReactionPartFour); Reaction speakWithSiblingReactionPartFive = new Reaction(); ShowMultipartChatAction speakWithSiblingChatPartFive = new ShowMultipartChatAction(this); speakWithSiblingChatPartFive.AddChat("I see...",1.5f); speakWithSiblingChatPartFive.AddChat("You are off your path.",3f); speakWithSiblingChatPartFive.AddChat("You should visit the sacred tree.", 3f); speakWithSiblingChatPartFive.AddChat("That is your fortune.", 1.5f); speakWithSiblingReactionPartFive.AddAction(speakWithSiblingChatPartFive); flagReactions.Add(FlagStrings.FortunetellerTalkToSiblingOldPartFive, speakWithSiblingReactionPartFive); Reaction speakWithSiblingReactionPartSix = new Reaction(); ShowMultipartChatAction speakWithSiblingChatPartSix = new ShowMultipartChatAction(this); speakWithSiblingChatPartSix.AddChat("Have a nice day.", 3f); speakWithSiblingReactionPartSix.AddAction(speakWithSiblingChatPartSix); flagReactions.Add(FlagStrings.FortunetellerTalkToSiblingOldPartSix, speakWithSiblingReactionPartSix); Reaction speakWithSiblingReactionPartSeven = new Reaction(); ShowMultipartChatAction speakWithSiblingChatPartSeven = new ShowMultipartChatAction(this); speakWithSiblingChatPartSeven.AddChat("Such a loud one she is...", 3f); speakWithSiblingChatPartSeven.AddChat("Ohh.", 1.25f); speakWithSiblingChatPartSeven.AddChat("Hello there quiet one.", 2f); //speakWithSiblingChatPartSeven.AddChat("Care for your fortune?", 1.25f); speakWithSiblingReactionPartSeven.AddAction(speakWithSiblingChatPartSeven); speakWithSiblingReactionPartSeven.AddAction(new NPCEmotionUpdateAction(this, new EnterFortuneState(this, "Decided to learn your fate?"))); speakWithSiblingReactionPartSeven.AddAction(new NPCAddScheduleAction(this, fortunetellerFortuneWithPlayer)); flagReactions.Add(FlagStrings.FortunetellerTalkToSiblingOldPartSeven, speakWithSiblingReactionPartSeven); //Reaction changeScheduleAfterSiblingFortune = new Reaction(); //changeScheduleAfterSiblingFortune.AddAction(speakWithSiblingChatPartSeven); //changeScheduleAfterSiblingFortune.AddAction(new NPCAddScheduleAction(this, fortunetellerFortuneWithPlayer)); //changeScheduleAfterSiblingFortune.AddAction(new NPCEmotionUpdateAction(this, new InitialEmotionState(this, "Line 72"))); //flagReactions.Add(FlagStrings.FortunetellerOldChangeSchedule, changeScheduleAfterSiblingFortune); }
//protected string CarpenterSonOldAngry = "CarpenterSonOldAngry"; protected override void SetFlagReactions() { Reaction reconcileReaction = new Reaction(); reconcileReaction.AddAction(new NPCAddScheduleAction(this, talkWhileFishingSchedule)); reconcileReaction.AddAction(new NPCTeleportToAction(this, MapLocations.BaseOfPierOld)); reconcileReaction.AddAction(new NPCEmotionUpdateAction(this, new InitialFishingState(this, "Best wind in years today, I think my father would be proud!"))); flagReactions.Add(FlagStrings.carpenterSonReconcile, reconcileReaction); Reaction passiveChatVictory = new Reaction(); ShowMultipartChatAction carpenterSonSatisfiedChat = new ShowMultipartChatAction(this); carpenterSonSatisfiedChat.AddChat("Hey! Came to watch me catch a big one?", 2.5f); carpenterSonSatisfiedChat.AddChat("I haven't caught anything yet, but I'm feeling lucky today!", 3f); carpenterSonSatisfiedChat.AddChat("I'm so glad I was able to be a fisherman. ", 3f); carpenterSonSatisfiedChat.AddChat("Thanks for standing up for me as a kid, it really meant a lot.", 2f); carpenterSonSatisfiedChat.AddChat("I owe a lot of great years to you.", 2.5f); carpenterSonSatisfiedChat.AddChat("I appreciate it!", 2.5f); carpenterSonSatisfiedChat.AddChat("Now, to catch the lunker!", 2f); carpenterSonSatisfiedChat.AddChat("Wish me luck!", 2f); passiveChatVictory.AddAction(carpenterSonSatisfiedChat); passiveChatVictory.AddAction(new NPCAddScheduleAction(this, fishingSchedule)); //passiveChatVictory.AddAction(new UpdateCurrentTextAction(this, "I'm going to catch the monster! I'm so excited!")); flagReactions.Add(FlagStrings.elderCarpenterSonChat, passiveChatVictory); Reaction fishingTimeReaction = new Reaction(); fishingTimeReaction.AddAction(new UpdateDefaultTextAction(this, "I'm going to catch the monster! I'm so excited!")); fishingTimeReaction.AddAction(new NPCLookInDirectionAction(this, -1)); flagReactions.Add(FlagStrings.elderCarpenterFishingTime, fishingTimeReaction); #region Carpenter Marriage Reaction carpenterMarriage = new Reaction(); carpenterMarriage.AddAction(new NPCCallbackSetStringAction(MoveForMarriage, this, "carpenter")); flagReactions.Add(FlagStrings.CastleMarriage, carpenterMarriage); #endregion #region becomes A Fisherman Reaction becomesAFisherman = new Reaction(); becomesAFisherman.AddAction(new NPCCallbackAction(TransitionToFisherman)); becomesAFisherman.AddAction(new NPCTeleportToAction (this, new Vector3(74f, (LevelManager.levelYOffSetFromCenter*2) -3.5f,transform.position.z))); flagReactions.Add(FlagStrings.carpenterSonBecomesFisherman, becomesAFisherman); #endregion #region Greet Old Sibling Reaction introductionToSiblingOld = new Reaction(); //introductionToSiblingOld.AddAction(new UpdateDefaultTextAction(this, "Best wind in years today, and with my father with me I'm sure I'll get my best catch yet.")); introductionToSiblingOld.AddAction(new NPCAddScheduleAction(this, greetSiblingOldSchedule)); flagReactions.Add(FlagStrings.siblingOldReachedCarpenterSonFlag, introductionToSiblingOld); Reaction greetSiblingPartOne = new Reaction(); ShowMultipartChatAction greetSiblingPartOneChat = new ShowMultipartChatAction(this); greetSiblingPartOneChat.AddChat("I'm fine...", 2f); greetSiblingPartOneChat.AddChat("Work as usual.", 2f); greetSiblingPartOneChat.AddChat("Brought an apple you say?", 2f); greetSiblingPartOne.AddAction(greetSiblingPartOneChat); greetSiblingPartOne.AddAction(new NPCEmotionUpdateAction(this, new WantAppleState(this, "Got an apple you say?"))); flagReactions.Add(FlagStrings.oldCarpenterGreetSiblingPartOneFlag, greetSiblingPartOne); #endregion #region Go To Beach #region Give Apple Reaction GoToBeachIntroHappy = new Reaction(); ShowMultipartChatAction goToBeachChatIntroHappy = new ShowMultipartChatAction(this); // 4 seconds goToBeachChatIntroHappy.AddChat("Thanks!", 2f); goToBeachChatIntroHappy.AddChat("Well, I'm about to take a break on the beach.", 2f); goToBeachChatIntroHappy.AddChat("You two care to join me?", 2f); GoToBeachIntroHappy.AddAction(goToBeachChatIntroHappy); GoToBeachIntroHappy.AddAction(new NPCAddScheduleAction(this, goToBeachSchedule)); flagReactions.Add(FlagStrings.oldCarpenterActivateGoToBeachHappyFlag, GoToBeachIntroHappy); #endregion #region Didn'tGiveApple Reaction GoToBeachIntroUpset = new Reaction(); ShowMultipartChatAction goToBeachChatIntroUpset = new ShowMultipartChatAction(this); // 4 seconds goToBeachChatIntroUpset.AddChat("Ohh... Ok.", 2f); goToBeachChatIntroUpset.AddChat("Well, I'm about to take a break on the beach.", 2f); goToBeachChatIntroUpset.AddChat("You two care to join me?", 2f); GoToBeachIntroUpset.AddAction(goToBeachChatIntroUpset); GoToBeachIntroUpset.AddAction(new NPCAddScheduleAction(this, goToBeachSchedule)); flagReactions.Add(FlagStrings.oldCarpenterActivateGoToBeachUpsetFlag, GoToBeachIntroUpset); #endregion Reaction GoToBeachPartOne = new Reaction(); ShowMultipartChatAction goToBeachChatPartOne = new ShowMultipartChatAction(this); goToBeachChatPartOne.AddChat("Ok.", 2f); goToBeachChatPartOne.AddChat("If you change your mind, I'll be at the beach.", 2f); GoToBeachPartOne.AddAction(goToBeachChatPartOne); GoToBeachPartOne.AddAction(new NPCAddScheduleAction(this, goToBeachSchedule)); flagReactions.Add(FlagStrings.oldCarpenterGoToBeachPartOneFlag, GoToBeachPartOne); Reaction GoToBeachPartTwo = new Reaction(); ShowMultipartChatAction goToBeachChatPartTwo = new ShowMultipartChatAction(this); GoToBeachPartTwo.AddAction(new NPCCallbackAction(SetSad)); goToBeachChatPartTwo.AddChat("Hey.", 2f); goToBeachChatPartTwo.AddChat("Glad you could join me.", 2f); goToBeachChatPartTwo.AddChat("It means a lot to have a friend like you here.", 2f); GoToBeachPartTwo.AddAction(goToBeachChatPartTwo); flagReactions.Add(FlagStrings.oldCarpenterGoToBeachPartTwoFlag, GoToBeachPartTwo); //Have discussions about his life - I'm Glad too., Everything ok?, ??? Reaction GoToBeachPartThree = new Reaction(); ShowMultipartChatAction goToBeachChatPartThree = new ShowMultipartChatAction(this); goToBeachChatPartThree.AddChat("Have you ever just looked out into the ocean", .3f); goToBeachChatPartThree.AddChat("Have you ever just looked out into the ocean.", .3f); goToBeachChatPartThree.AddChat("Have you ever just looked out into the ocean..", .3f); goToBeachChatPartThree.AddChat("Have you ever just looked out into the ocean...", 1.5f); goToBeachChatPartThree.AddChat("Have you ever just looked out into the ocean..." + "\n" + " and wondered.", .5f); goToBeachChatPartThree.AddChat("Have you ever just looked out into the ocean..." + "\n" + " and wondered..", .5f); goToBeachChatPartThree.AddChat("Have you ever just looked out into the ocean..." + "\n" + " and wondered...", 2f); goToBeachChatPartThree.AddChat("Am I following my dreams?", 2f); //goToBeachChatPartThree.AddChat("Did I make a mistake?", 2f); GoToBeachPartThree.AddAction(goToBeachChatPartThree); // Wait for 8 seconds or below GoToBeachPartThree.AddAction(new NPCEmotionUpdateAction(this, new AnswerLivedAGoodLifeState(this, "Have you ever just wondered, "+ "\n" +"am I following my dreams?"))); flagReactions.Add(FlagStrings.oldCarpenterGoToBeachPartThreeFlag, GoToBeachPartThree); #endregion }
protected void SetupReactions() { moveAway.AddAction(new NPCCallbackAction(ResetPosition)); moveAway.AddAction(new NPCEmotionUpdateAction(this, initialState)); sillyStories.AddAction(new NPCCallbackSetStringAction(ChangeDisposition, this, "-10")); yourCoward.AddAction(new NPCCallbackSetStringAction(ChangeDisposition, this, "-15")); alreadyBrave.AddAction(new NPCCallbackSetStringAction(ChangeDisposition, this, "10")); illDoIt.AddAction(new NPCCallbackSetStringAction(ChangeDisposition, this, "5")); illSellForYou.AddAction(new NPCCallbackAction(setSmile)); illSellForYou.AddAction(new NPCCallbackAction(FarmerHelped)); apple.AddAction(new NPCCallbackSetStringAction(ChangeDisposition, this, "5")); applePie.AddAction(new NPCCallbackSetStringAction(ChangeDisposition, this, "15")); shovel.AddAction(new NPCCallbackSetStringAction(ChangeDisposition, this, "5")); rope.AddAction(new NPCCallbackSetStringAction(ChangeDisposition, this, "5")); farmer.AddAction(new NPCCallbackSetStringAction(FlagToNPC, this, "farmerMotherOnBoard")); farmersBetrayed.AddAction(new NPCEmotionUpdateAction(this, new HateEmotionState(this, ""))); postDateCastle.AddAction(new NPCCallbackSetStringAction(FlagToNPC, this, "castleSuccess")); postDateCarpenter.AddAction(new NPCCallbackSetStringAction(FlagToNPC, this, "carpenterSuccess")); castleDate.AddAction(new NPCCallbackSetStringAction(FlagToNPC, this, "castle")); stoodUp.AddAction(new NPCCallbackSetStringAction(FlagToNPC, this, "stoodUp")); daughterReady.AddAction(new NPCCallbackSetStringAction(FlagToNPC, this, "daughterReady")); ShowMultipartChatAction girlEndOneDialogue = new ShowMultipartChatAction(this); girlEndOneDialogue.AddChat("So...I've been doing some thinking...and I feel like its best that we let our daughter...follow her heart...", 8f); girlEndOne.AddAction(girlEndOneDialogue); ShowMultipartChatAction girlEndTwoDialogue = new ShowMultipartChatAction(this); girlEndTwoDialogue.AddChat("...but..", 1f); girlEndTwo.AddAction(girlEndTwoDialogue); ShowMultipartChatAction girlEndThreeDialogue = new ShowMultipartChatAction(this); girlEndThreeDialogue.AddChat("I...", 1f); girlEndThreeDialogue.AddChat("HAVE HAD ENOUGH OF YOUR BULLYING!", 5f); girlEndThreeDialogue.AddChat("We did not agree to anything! you talked a lot and assumed my opinion.", 7f); girlEndThreeDialogue.AddChat("I'm drawing the line here! Our daughter can marry whomever she chooses!", 7f); girlEndThree.AddAction(girlEndThreeDialogue); }
protected void SetupReactions() { ShowMultipartChatAction introConvoOneDialogue = new ShowMultipartChatAction(this); introConvoOneDialogue.AddChat("... Look mom! I'm not going to marry the Carpenter's Son!", 4f); introConvoOne.AddAction(introConvoOneDialogue); ShowMultipartChatAction introConvoTwoDialogue = new ShowMultipartChatAction(this); introConvoTwoDialogue.AddChat("But I've chosen not to marry anyone this time!", 4f); introConvoTwo.AddAction(introConvoTwoDialogue); ShowMultipartChatAction introConvoThreeDialogue = new ShowMultipartChatAction(this); introConvoThreeDialogue.AddChat("Mom, I...", 2f); introConvoThree.AddAction(introConvoThreeDialogue); ShowMultipartChatAction introConvoFourDialogue = new ShowMultipartChatAction(this); introConvoFourDialogue.AddChat("... Fine... this isn't over...", 3f); introConvoFour.AddAction(introConvoFourDialogue); ShowMultipartChatAction castleDateOneDialogue = new ShowMultipartChatAction(this); castleDateOneDialogue.AddChat("Fair lady? Come now pretending to like the stoires my dad read to me won't make you endearing.", 7f); castleDateOne.AddAction(castleDateOneDialogue); ShowMultipartChatAction castleDateTwoDialogue = new ShowMultipartChatAction(this); castleDateTwoDialogue.AddChat("Wait... I remember you! You were the one I used to play with on the beach and build sand castles!", 6f); castleDateTwo.AddAction(castleDateTwoDialogue); ShowMultipartChatAction castleDateThreeDialogue = new ShowMultipartChatAction(this); castleDateThreeDialogue.AddChat("Of course I do! You were really sweet to me!", 4f); castleDateThree.AddAction(castleDateThreeDialogue); ShowMultipartChatAction carpenterDateOneDialogue = new ShowMultipartChatAction(this); carpenterDateOneDialogue.AddChat("Fair lady? Come now pretending to like the stoires my dad read to me won't make you endearing.", 7f); carpenterDateOne.AddAction(carpenterDateOneDialogue); ShowMultipartChatAction carpenterDateTwoDialogue = new ShowMultipartChatAction(this); carpenterDateTwoDialogue.AddChat("Wait... I remember you! You were the one I used to play with on the beach and build sand castles!", 6f); carpenterDateTwo.AddAction(carpenterDateTwoDialogue); ShowMultipartChatAction carpenterDateThreeDialogue = new ShowMultipartChatAction(this); carpenterDateThreeDialogue.AddChat("Of course I do! You were really sweet to me!", 4f); carpenterDateThree.AddAction(carpenterDateThreeDialogue); ShowMultipartChatAction castleMarriageOneDialogue = new ShowMultipartChatAction(this); castleMarriageOneDialogue.AddChat("Everything's finished! Time to put this plan into effect!", 5f); castleMarriageOneDialogue.AddChat("So Mom! I'd really like to talk about never marrying again.", 5f); castleMarriageOne.AddAction(castleMarriageOneDialogue); ShowMultipartChatAction castleMarriageTwoDialogue = new ShowMultipartChatAction(this); castleMarriageTwoDialogue.AddChat("What.. uh... yes... I mean NO!", 2f); castleMarriageTwo.AddAction(castleMarriageTwoDialogue); ShowMultipartChatAction castleMarriageThreeDialogue = new ShowMultipartChatAction(this); castleMarriageThreeDialogue.AddChat("*Hmmph* I. DON'T. LIKE. THE. CARPENTER'S. SON.", 3f); castleMarriageThree.AddAction(castleMarriageThreeDialogue); ShowMultipartChatAction castleMarriageFourDialogue = new ShowMultipartChatAction(this); castleMarriageFourDialogue.AddChat("... and you wonder why I ran away...", 3f); castleMarriageFour.AddAction(castleMarriageFourDialogue); //girl end path ShowMultipartChatAction girlEndOneDialogue = new ShowMultipartChatAction(this); girlEndOneDialogue.AddChat("See! Even dad agrees with me!", 3f); girlEndOne.AddAction(girlEndOneDialogue); ShowMultipartChatAction girlEndTwoDialogue = new ShowMultipartChatAction(this); girlEndTwoDialogue.AddChat("What do you know about what I need! You're not me!", 4f); girlEndTwo.AddAction(girlEndTwoDialogue); ShowMultipartChatAction girlEndThreeDialogue = new ShowMultipartChatAction(this); girlEndThreeDialogue.AddChat("Love? You didn't choose dad, it was arranged for you!", 4f); girlEndThree.AddAction(girlEndThreeDialogue); ShowMultipartChatAction girlEndFourDialogue = new ShowMultipartChatAction(this); girlEndFourDialogue.AddChat("...", 1f); girlEndFour.AddAction(girlEndFourDialogue); }
protected void SendDateOverToState() { Debug.Log("date over"); if (initialState.carpenterPath && successfulDate){ //date success with carpenter FlagManager.instance.SetFlag(FlagStrings.PostDatingCarpenter); marriageState.PassStringToEmotionState("carpenter"); }else if (successfulDate){ //date success with castleboy castleMarriageOne.Clear(); ShowMultipartChatAction castleMarriageOneDialogue = new ShowMultipartChatAction(this); castleMarriageOneDialogue.AddChat("Everything's finished! Time to put this plan into effect!", 5f); castleMarriageOneDialogue.AddChat("I'm marrying the Castle Man and there's nothing you can do about it!", 5f); castleMarriageOne.AddAction(castleMarriageOneDialogue); Debug.Log("castle success"); FlagManager.instance.SetFlag(FlagStrings.PostCastleDate); marriageState.PassStringToEmotionState("castleboy"); }else { Debug.Log("lighthouse girl stoodup!"); FlagManager.instance.SetFlag(FlagStrings.StoodUp); } }
protected void SetupReactions() { moveAway.AddAction(new NPCCallbackAction(ResetPosition)); moveAway.AddAction(new NPCEmotionUpdateAction(this, initialState)); notSilly.AddAction(new NPCCallbackSetStringAction(ChangeDisposition, this, "-15")); workandRead.AddAction(new NPCCallbackSetStringAction(ChangeDisposition, this, "-5")); tellOn.AddAction(new NPCCallbackSetStringAction(ChangeDisposition, this, "10")); sillyStories.AddAction(new NPCCallbackSetStringAction(ChangeDisposition, this, "5")); yourRight.AddAction(new NPCCallbackSetStringAction(ChangeDisposition, this, "10")); apple.AddAction(new NPCCallbackSetStringAction(ChangeDisposition, this, "5")); applePie.AddAction(new NPCCallbackSetStringAction(ChangeDisposition, this, "10")); shovel.AddAction(new NPCCallbackSetStringAction(ChangeDisposition, this, "15")); rope.AddAction(new NPCCallbackSetStringAction(ChangeDisposition, this, "10")); husbandOnBoard.AddAction(new NPCCallbackAction(ChangeHusbandStatus)); postDateCastle.AddAction(new NPCEmotionUpdateAction(this, new HateEmotionState(this, ""))); postDateCastle.AddAction(new NPCCallbackSetStringAction(ChangeDisposition, this, "-100")); postDateCarpenter.AddAction(new NPCCallbackSetStringAction(FlagToNPC, this, "carpenterSuccess")); castleDate.AddAction(new NPCCallbackSetStringAction(FlagToNPC, this, "castle")); stoodUp.AddAction(new NPCCallbackSetStringAction(FlagToNPC, this, "stoodUp")); //chat ShowMultipartChatAction introConvoOneDialogue = new ShowMultipartChatAction(this); introConvoOneDialogue.AddChat("And the last time ah let ya get you way, yah ran from home with that tramp.", 5f); introConvoOne.AddAction(introConvoOneDialogue); ShowMultipartChatAction introConvoTwoDialogue = new ShowMultipartChatAction(this); introConvoTwoDialogue.AddChat("What ya need is someone that can help ya settle down and tha carpenter's son will do that very nicely!", 6f); introConvoTwo.AddAction(introConvoTwoDialogue); ShowMultipartChatAction introConvoThreeDialogue = new ShowMultipartChatAction(this); introConvoThreeDialogue.AddChat("ENOUGH! What's done is done. Go back and take care of tha lighthouse, ya need ta work!", 5f); introConvoThree.AddAction(introConvoThreeDialogue); ShowMultipartChatAction castleMarriageOneDialogue = new ShowMultipartChatAction(this); castleMarriageOneDialogue.AddChat("...", 1f); castleMarriageOneDialogue.AddChat("I've just been talking to the Carpenter and he says that his tools have gone missing. Do you know anything about that?", 6f); castleMarriageOne.AddAction(castleMarriageOneDialogue); ShowMultipartChatAction castleMarriageTwoDialogue = new ShowMultipartChatAction(this); castleMarriageTwoDialogue.AddChat("I am fed up with your lies and attempts to sabotage this marriange. IT. WILL. BE. GOOD. FOR. YOU.", 5f); castleMarriageTwo.AddAction(castleMarriageTwoDialogue); ShowMultipartChatAction castleMarriageThreeDialogue = new ShowMultipartChatAction(this); castleMarriageThreeDialogue.AddChat("Enough of your childish behavior! Get back to working at the lighthouse and I fully expect an apology tomorrow morning.", 6f); castleMarriageThree.AddAction(castleMarriageThreeDialogue); ShowMultipartChatAction castleMarriageFourDialogue = new ShowMultipartChatAction(this); castleMarriageFourDialogue.AddChat("NOW!", 1f); castleMarriageFour.AddAction(castleMarriageFourDialogue); //girl end path ShowMultipartChatAction girlEndOneDialogue = new ShowMultipartChatAction(this); girlEndOneDialogue.AddChat("Really? you let her influence your thoughts? We've talked about this stuff already. Our daughter needs someone who can guide her!", 8f); girlEndOne.AddAction(girlEndOneDialogue); ShowMultipartChatAction girlEndTwoDialogue = new ShowMultipartChatAction(this); girlEndTwoDialogue.AddChat("Oh please! You are too immature to know anything about love!", 5f); girlEndTwo.AddAction(girlEndTwoDialogue); ShowMultipartChatAction girlEndThreeDialogue = new ShowMultipartChatAction(this); girlEndThreeDialogue.AddChat("And that's exactly how I know that it will provide the stability you need!", 6f); girlEndThreeDialogue.AddChat("Now enough of this nonsense!", 4f); girlEndThreeDialogue.AddChat("You girl have crossed the line far too many times. You do it once more and the punishment will be severe.", 7f); girlEndThreeDialogue.AddChat("And husband, I would have expected you above this nonsense!", 6f); girlEndThree.AddAction(girlEndThreeDialogue); ShowMultipartChatAction girlEndFourDialogue = new ShowMultipartChatAction(this); girlEndFourDialogue.AddChat("Oh don't give me those puppy dog eyes! We need to stick to what we came up with!", 4f); girlEndFour.AddAction(girlEndFourDialogue); ShowMultipartChatAction girlEndFiveDialogue = new ShowMultipartChatAction(this); girlEndFiveDialogue.AddChat("...", 1f); girlEndFive.AddAction(girlEndFiveDialogue); ShowMultipartChatAction girlEndSixDialogue = new ShowMultipartChatAction(this); girlEndSixDialogue.AddChat("Fine...have it your way but this talk isn't over.", 3f); girlEndSix.AddAction(girlEndSixDialogue); }
protected override void SetFlagReactions() { #region FirstPassiveChat Reaction gameStartPassiveChat = new Reaction(); //Emotion State shouldn't say the text: Care to talk with the Carpenter's Son?" + "\n\n" + "Let me know when you're ready to continue. gameStartPassiveChat.AddAction(new NPCEmotionUpdateAction(this, new InitialEmotionState(this, "Care to talk with the Carpenter's Son?" + "Let me know when you're ready to continue."))); #region reactivate after debugging <&^&> // ShowMultipartChatAction introMultChatPartOne = new ShowMultipartChatAction(this); introMultChatPartOne.AddChat("Hey!", 2f); introMultChatPartOne.AddChat("Feeling well today?", 2f); introMultChatPartOne.AddChat("You up for a race like old times?", 2.5f); gameStartPassiveChat.AddAction(introMultChatPartOne); // #endregion //gameStartPassiveChat.AddAction(new NPCTeleportToAction(this, new Vector3(30f, -1.6f + (LevelManager.levelYOffSetFromCenter * 2),0))); // gameStartPassiveChat.AddAction(new NPCAddScheduleAction(this, oldSiblingIntroductionSchedule)); //gameStartPassiveChat.AddAction(new NPCAddScheduleAction(this, walkToCarpenterSchedule)); //gameStartPassiveChat.AddAction(new NPCAddScheduleAction(this, siblingOldToLighthouseShedule)); // flagReactions.Add(FlagStrings.oldSiblingIntroChatFlag, gameStartPassiveChat); #endregion #region Race To Forest Reaction RaceToForestPartOne = new Reaction(); ShowMultipartChatAction beginRaceToForestPartOne = new ShowMultipartChatAction(this); beginRaceToForestPartOne.AddChat("Ready?", 2f); beginRaceToForestPartOne.AddChat("Set!", 1.5f); RaceToForestPartOne.AddAction(beginRaceToForestPartOne); flagReactions.Add(FlagStrings.siblingOldIntroRaceChatPartOneFlag, RaceToForestPartOne); Reaction RaceToForestPartTwo = new Reaction(); ShowMultipartChatAction beginRaceToForestPartTwo = new ShowMultipartChatAction(this); beginRaceToForestPartTwo.AddChat("Go!!", 3f); beginRaceToForestPartTwo.AddChat("Hurry up slowpoke!", 2f); beginRaceToForestPartTwo.AddChat("Hahahaha!", 2f); RaceToForestPartTwo.AddAction(beginRaceToForestPartTwo); flagReactions.Add(FlagStrings.siblingOldIntroRaceChatPartTwoFlag, RaceToForestPartTwo); Reaction RaceToForestPartThree = new Reaction(); ShowMultipartChatAction beginRaceToForestPartThree = new ShowMultipartChatAction(this); beginRaceToForestPartThree.AddChat("Whew!", 2f); beginRaceToForestPartThree.AddChat("Good race!", 3f); beginRaceToForestPartThree.AddChat("It's been a while, hasn't it?", 3f); //Mom's garden? //beginRaceToForestPartThree.AddChat("Aww, we never got to plant mom's garden.,2f); RaceToForestPartThree.AddAction(beginRaceToForestPartThree); flagReactions.Add(FlagStrings.siblingOldIntroRaceChatPartThreeFlag, RaceToForestPartThree); Reaction RaceToForestPartFour = new Reaction(); ShowMultipartChatAction beginRaceToForestPartFour = new ShowMultipartChatAction(this); beginRaceToForestPartFour.AddChat("Mom's garden isn't looking so good.", 3f); beginRaceToForestPartFour.AddChat("Too bad we weren't able to help before she passed.", 3f); //? beginRaceToForestPartFour.AddChat("If only we could go back, right?", 3f); RaceToForestPartFour.AddAction(beginRaceToForestPartFour); flagReactions.Add(FlagStrings.siblingOldIntroRaceChatPartFourFlag, RaceToForestPartFour); Reaction RaceToForestPartFive = new Reaction(); ShowMultipartChatAction beginRaceToForestPartFive = new ShowMultipartChatAction(this); beginRaceToForestPartFive.AddChat("Hey.", 2f); beginRaceToForestPartFive.AddChat("Want to go visit ole Carp?", 3f); beginRaceToForestPartFive.AddChat("Race you back!", 3.5f); beginRaceToForestPartFive.AddChat("Hahahaha!", 2.5f); RaceToForestPartFive.AddAction(beginRaceToForestPartFive); flagReactions.Add(FlagStrings.siblingOldIntroRaceChatPartFiveFlag, RaceToForestPartFive); Reaction RaceToForestPartSix = new Reaction(); ShowMultipartChatAction beginRaceToForestPartSix = new ShowMultipartChatAction(this); beginRaceToForestPartSix.AddChat("Let's go to the bridge!", 1.5f); RaceToForestPartSix.AddAction(beginRaceToForestPartSix); RaceToForestPartSix.AddAction(new NPCAddScheduleAction(this, walkToCarpenterSchedule)); flagReactions.Add(FlagStrings.siblingOldIntroRaceChatPartSixFlag, RaceToForestPartSix); #endregion #region To Carpenter House Reaction IntroStoryPartOne = new Reaction(); ShowMultipartChatAction walkToCarpenterPartOne = new ShowMultipartChatAction(this); walkToCarpenterPartOne.AddChat("Hey look! An apple!", 1.5f); walkToCarpenterPartOne.AddChat("Let's take it to Carp.", 2f); walkToCarpenterPartOne.AddChat("He loves apples!", 1.5f); IntroStoryPartOne.AddAction(walkToCarpenterPartOne); flagReactions.Add(FlagStrings.oldSiblingIntroStoryOnePartOneFlag, IntroStoryPartOne); //Reaction IntroStoryPartTwo = new Reaction(); //IntroStoryPartTwo.AddAction(new ShowOneOffChatAction(this, "Remember the apple trees that were once here?", 5f)); //IntroStoryPartTwo.AddAction(new ShowOneOffChatAction(this, "Remember the apple trees that once were here?", 5f)); //flagReactions.Add(FlagStrings.oldSiblingIntroStoryOnePartTwoFlag, IntroStoryPartTwo); Reaction ReachCarpenterHouse = new Reaction(); ShowMultipartChatAction reachedCarpenterDialogue = new ShowMultipartChatAction(this); reachedCarpenterDialogue.AddChat("Hey Carp!", 2f); reachedCarpenterDialogue.AddChat("Doing well today?", 2f); reachedCarpenterDialogue.AddChat("We brought you an apple!", 2f); ReachCarpenterHouse.AddAction(reachedCarpenterDialogue); flagReactions.Add(FlagStrings.siblingOldReachedCarpenterSonFlag, ReachCarpenterHouse); Reaction GreetCarpenterPartOne = new Reaction(); ShowMultipartChatAction greetCarpenterPartOneChat = new ShowMultipartChatAction(this); greetCarpenterPartOneChat.AddChat("Ya!", 1f); greetCarpenterPartOneChat.AddChat("Hey, give it to him!", 2f); GreetCarpenterPartOne.AddAction(greetCarpenterPartOneChat); flagReactions.Add(FlagStrings.siblingOldGreetCarpenterSonOldPartOneFlag, GreetCarpenterPartOne); Reaction appleGivenReaction = new Reaction(); appleGivenReaction.AddAction(new NPCAddScheduleAction(this, oldSiblingtoFortuneTellerSchedule)); flagReactions.Add(FlagStrings.oldCarpenterActivateGoToBeachHappyFlag, appleGivenReaction); Reaction appleNotGivenReaction = new Reaction(); appleNotGivenReaction.AddAction(new NPCAddScheduleAction(this, oldSiblingtoFortuneTellerSchedule)); flagReactions.Add(FlagStrings.oldCarpenterActivateGoToBeachUpsetFlag, appleNotGivenReaction); #endregion #region FortuneTeller Region Reaction goToFortuneTellerIntroReaction = new Reaction(); ShowMultipartChatAction goToFortuneTellerIntroChat = new ShowMultipartChatAction(this); goToFortuneTellerIntroChat.AddChat("Um..", 1f); goToFortuneTellerIntroChat.AddChat("I'm getting my fortune upstairs. So I'm going to pass.", 2.5f); //Add context to the going upstairs, make the choice more meaningful (can't see the conversation from both sides. //Pause goToFortuneTellerIntroChat.AddChat("Have fun though!", 2f); goToFortuneTellerIntroChat.AddChat("See you later!", 3f); goToFortuneTellerIntroReaction.AddAction(goToFortuneTellerIntroChat); flagReactions.Add(FlagStrings.siblingOldGoToFortuneTellerIntro, goToFortuneTellerIntroReaction); Reaction goToFortuneTellerPartOneReaction = new Reaction(); ShowMultipartChatAction goToFortuneTellerPartOneChat = new ShowMultipartChatAction(this); goToFortuneTellerPartOneChat.AddChat("I'm here for my fortune!", 2f); goToFortuneTellerPartOneChat.AddChat("Let's get started!", 2f); goToFortuneTellerPartOneReaction.AddAction(goToFortuneTellerPartOneChat); flagReactions.Add(FlagStrings.siblingOldTalkToFortunePartOne, goToFortuneTellerPartOneReaction); Reaction goToFortuneTellerPartTwoReaction = new Reaction(); ShowMultipartChatAction goToFortuneTellerPartTwoChat = new ShowMultipartChatAction(this); goToFortuneTellerPartTwoChat.AddChat(".", .75f); goToFortuneTellerPartTwoChat.AddChat("..", .75f); goToFortuneTellerPartTwoChat.AddChat("...", 1f); goToFortuneTellerPartTwoChat.AddChat("Now?", 1.5f); goToFortuneTellerPartTwoReaction.AddAction(goToFortuneTellerPartTwoChat); flagReactions.Add(FlagStrings.siblingOldTalkToFortunePartTwo, goToFortuneTellerPartTwoReaction); Reaction goToFortuneTellerPartThreeReaction = new Reaction(); ShowMultipartChatAction goToFortuneTellerPartThreeChat = new ShowMultipartChatAction(this); goToFortuneTellerPartThreeChat.AddChat(".", 1.5f); goToFortuneTellerPartThreeChat.AddChat("..", 1.25f); goToFortuneTellerPartThreeChat.AddChat("...", 1f); goToFortuneTellerPartThreeChat.AddChat("How about now?", 1.5f); goToFortuneTellerPartThreeReaction.AddAction(goToFortuneTellerPartThreeChat); flagReactions.Add(FlagStrings.siblingOldTalkToFortunePartThree, goToFortuneTellerPartThreeReaction); Reaction goToFortuneTellerPartFourReaction = new Reaction(); ShowMultipartChatAction goToFortuneTellerPartFourChat = new ShowMultipartChatAction(this); goToFortuneTellerPartFourChat.AddChat("Hmm", 1.5f); goToFortuneTellerPartFourChat.AddChat("Hmm.", .75f); goToFortuneTellerPartFourChat.AddChat("Hmm..", .75f); goToFortuneTellerPartFourReaction.AddAction(goToFortuneTellerPartFourChat); flagReactions.Add(FlagStrings.siblingOldTalkToFortunePartFour, goToFortuneTellerPartFourReaction); Reaction goToFortuneTellerPartFiveReaction = new Reaction(); ShowMultipartChatAction goToFortuneTellerPartFiveChat = new ShowMultipartChatAction(this); goToFortuneTellerPartFiveChat.AddChat("No..!", 1f); goToFortuneTellerPartFiveChat.AddChat("I.", .15f); goToFortuneTellerPartFiveChat.AddChat("I..", .2f); goToFortuneTellerPartFiveChat.AddChat("I...", .75f); goToFortuneTellerPartFiveChat.AddChat("I... I just wanted a fortune...", 2f); goToFortuneTellerPartFiveReaction.AddAction(goToFortuneTellerPartFiveChat); flagReactions.Add(FlagStrings.siblingOldTalkToFortunePartFive, goToFortuneTellerPartFiveReaction); Reaction goToFortuneTellerPartSixReaction = new Reaction(); ShowMultipartChatAction goToFortuneTellerPartSixChat = new ShowMultipartChatAction(this); goToFortuneTellerPartSixChat.AddChat("R", .5f); goToFortuneTellerPartSixChat.AddChat("R-", .5f); goToFortuneTellerPartSixChat.AddChat("R-Really?", 1.25f); goToFortuneTellerPartSixChat.AddChat("Thank you so much!", 1f); goToFortuneTellerPartSixReaction.AddAction(goToFortuneTellerPartSixChat); flagReactions.Add(FlagStrings.siblingOldTalkToFortunePartSix, goToFortuneTellerPartSixReaction); #endregion #region Farmer Area Reaction farmerAreaReaction = new Reaction(); ShowMultipartChatAction goToFarmerAreaChat = new ShowMultipartChatAction(this); goToFarmerAreaChat.AddChat("I'll be near the lighthouse when you're done!", 1.25f); goToFarmerAreaChat.AddChat("You should get your fortune!", 1.25f); goToFarmerAreaChat.AddChat("See ya later!", 1.25f); farmerAreaReaction.AddAction(goToFarmerAreaChat); flagReactions.Add(FlagStrings.oldSiblingGoToFarmerArea, farmerAreaReaction); Reaction farmerAreaChangeSchedule = new Reaction(); farmerAreaChangeSchedule.AddAction(new NPCAddScheduleAction(this, siblingOldToLighthouseShedule)); //FarmerAreaReaction.AddAction(new NPCEmotionUpdateAction(this, new STATE())); flagReactions.Add(FlagStrings.oldSiblingActivateFarmerSchedule, farmerAreaChangeSchedule); Reaction farmerAreaReactionPartOne = new Reaction(); ShowMultipartChatAction goToFarmerAreaChatOne = new ShowMultipartChatAction(this); goToFarmerAreaChatOne.AddChat(".", .75f); goToFarmerAreaChatOne.AddChat("..", 1f); goToFarmerAreaChatOne.AddChat("...", 1.5f); goToFarmerAreaChatOne.AddChat("Remember when the farmers used to live here?", 2f); goToFarmerAreaChatOne.AddChat("They always had the best crops.", 2.5f); goToFarmerAreaChatOne.AddChat("It's too bad they had to leave.", 2.5f); farmerAreaReactionPartOne.AddAction(goToFarmerAreaChatOne); flagReactions.Add(FlagStrings.siblingOldTalkAboutFarmerOne , farmerAreaReactionPartOne); Reaction farmerAreaReactionPartTwo = new Reaction(); ShowMultipartChatAction goToFarmerAreaChatTwo = new ShowMultipartChatAction(this); goToFarmerAreaChatTwo.AddChat("Hey.", 1.5f); goToFarmerAreaChatTwo.AddChat("Did you get your fortune done?", 1.5f); farmerAreaReactionPartTwo.AddAction(goToFarmerAreaChatTwo); flagReactions.Add(FlagStrings.siblingOldTalkAboutFarmerTwo, farmerAreaReactionPartTwo); Reaction farmerAreaReactionPartThree = new Reaction(); ShowMultipartChatAction goToFarmerAreaChatPartThree = new ShowMultipartChatAction(this); goToFarmerAreaChatPartThree.AddChat("The fortuneteller told me I should visit the sacred tree.", 2f); goToFarmerAreaChatPartThree.AddChat("Want to go with me?", 1.5f); goToFarmerAreaChatPartThree.AddChat("I'd like your company.", 3.5f); goToFarmerAreaChatPartThree.AddChat("Let's go!", 1.5f); farmerAreaReactionPartThree.AddAction(goToFarmerAreaChatPartThree); farmerAreaReactionPartThree.AddAction(new NPCAddScheduleAction(this, toReflectionTreeSchedule)); flagReactions.Add(FlagStrings.siblingOldTalkAboutFarmerThree, farmerAreaReactionPartThree); #endregion #region Reflection Tree Reaction toReflectionTreeAtFortuneteller = new Reaction(); ShowMultipartChatAction toReflectionTreeAtFortunetellerChat = new ShowMultipartChatAction(this); toReflectionTreeAtFortunetellerChat.AddChat("Hey!", 1.25f); toReflectionTreeAtFortunetellerChat.AddChat("Thanks again!", 1.25f); toReflectionTreeAtFortuneteller.AddAction(toReflectionTreeAtFortunetellerChat); flagReactions.Add(FlagStrings.oldSiblingReflectionTreeFortuneteller, toReflectionTreeAtFortuneteller); Reaction toReflectionTreeAtCastleman = new Reaction(); ShowMultipartChatAction toReflectionTreeAtCastlemanChat = new ShowMultipartChatAction(this); toReflectionTreeAtCastlemanChat.AddChat("Shh.", 1.25f); toReflectionTreeAtCastlemanChat.AddChat("Don't talk to him, he's crazy.", 2f); toReflectionTreeAtCastleman.AddAction(toReflectionTreeAtCastlemanChat); flagReactions.Add(FlagStrings.oldSiblingReflectionTreeCastleman, toReflectionTreeAtCastleman); Reaction toReflectionTreeAtPond = new Reaction(); ShowMultipartChatAction toReflectionTreeAtPondChat = new ShowMultipartChatAction(this); toReflectionTreeAtPondChat.AddChat("Mmm!", 1.5f); toReflectionTreeAtPondChat.AddChat("I love this place.", 2f); toReflectionTreeAtPondChat.AddChat("It's the best spot on the island!", 2f); toReflectionTreeAtPond.AddAction(toReflectionTreeAtPondChat); flagReactions.Add(FlagStrings.oldSiblingReflectionTreePond, toReflectionTreeAtPond); Reaction toReflectionTreePartOne = new Reaction(); ShowMultipartChatAction toReflectionTreeAtPartOneChat = new ShowMultipartChatAction(this); toReflectionTreeAtPartOneChat.AddChat("Hey.", 2f); toReflectionTreeAtPartOneChat.AddChat("Thanks for coming.", 3f); toReflectionTreeAtPartOneChat.AddChat("It's meant a lot having you around all these years.", 3f); toReflectionTreePartOne.AddAction(toReflectionTreeAtPartOneChat); flagReactions.Add(FlagStrings.oldSiblingReflectionTreePartOne, toReflectionTreePartOne); Reaction toReflectionTreeAtPartTwo = new Reaction(); ShowMultipartChatAction toReflectionTreeAtPartTwoChat = new ShowMultipartChatAction(this); toReflectionTreeAtPartTwoChat.AddChat("Sometimes I miss the old days.", 3f); toReflectionTreeAtPartTwoChat.AddChat("Mom.",2f); toReflectionTreeAtPartTwoChat.AddChat("The lighthouse girl..",2f); toReflectionTreeAtPartTwoChat.AddChat("The old bazaarman...",2f); toReflectionTreeAtPartTwoChat.AddChat("And that crazy sea captain...",3.5f); toReflectionTreeAtPartTwo.AddAction(toReflectionTreeAtPartTwoChat); flagReactions.Add(FlagStrings.oldSiblingReflectionTreePartTwo, toReflectionTreeAtPartTwo); Reaction toReflectionTreeAtPartThree = new Reaction(); ShowMultipartChatAction toReflectionTreeAtPartThreeChat = new ShowMultipartChatAction(this); toReflectionTreeAtPartThreeChat.AddChat("What if we could go back to the past?", 2f); toReflectionTreeAtPartThreeChat.AddChat(".", .75f); toReflectionTreeAtPartThreeChat.AddChat("..", .75f); toReflectionTreeAtPartThreeChat.AddChat("...", 1.5f); toReflectionTreeAtPartThreeChat.AddChat("If only we could go back.", .75f); toReflectionTreeAtPartThreeChat.AddChat("If only we could go back..", .75f); toReflectionTreeAtPartThreeChat.AddChat("If only we could go back...", 2f); toReflectionTreeAtPartThree.AddAction(toReflectionTreeAtPartThreeChat); toReflectionTreeAtPartThree.AddAction(new NPCEmotionUpdateAction(this, new AtReflectionTreeState(this, "If only we could go back to the people we used to love.."))); flagReactions.Add(FlagStrings.oldSiblingReflectionTreePartThree, toReflectionTreeAtPartThree); /* Reaction toReflectionTreeAtPartFour = new Reaction(); ShowMultipartChatAction toReflectionTreeAtPartFourChat = new ShowMultipartChatAction(this); toReflectionTreeAtPartFourChat.AddChat("Hmm.", .75f); toReflectionTreeAtPartFourChat.AddChat("Hmm..", .75f); toReflectionTreeAtPartFourChat.AddChat("Hmm...", 1.5f); toReflectionTreeAtPartFourChat.AddChat("All this thinking is making me tired.", 3f); toReflectionTreeAtPartFourChat.AddChat("I'm going to close my eyes.", .75f); toReflectionTreeAtPartFourChat.AddChat("I'm going to close my eyes..", .75f); toReflectionTreeAtPartFourChat.AddChat("I'm going to close my eyes...", 2f); toReflectionTreeAtPartFourChat.AddChat("I'm going to close my eyes... and.", .75f); toReflectionTreeAtPartFourChat.AddChat("I'm going to close my eyes... and..", .75f); toReflectionTreeAtPartFourChat.AddChat("I'm going to close my eyes... and...", 2f); toReflectionTreeAtPartFourChat.AddChat("Z", 1f); toReflectionTreeAtPartFourChat.AddChat("zZ", 1f); toReflectionTreeAtPartFourChat.AddChat("ZzZ", 2f); toReflectionTreeAtPartFourChat.AddChat("zZz", 1f); toReflectionTreeAtPartFourChat.AddChat("ZzZ", 2f); toReflectionTreeAtPartFourChat.AddChat("zZz", 1f); toReflectionTreeAtPartFour.AddAction(toReflectionTreeAtPartFourChat); flagReactions.Add(FlagStrings.oldSiblingReflectionTreePartFour, toReflectionTreeAtPartFour); */ #endregion }
protected override void SetFlagReactions() { //// Reaction stoodUpLG = new Reaction(); //// stoodUpLG.AddAction(new NPCEmotionUpdateAction(this, StoodUpState)); //// flagReactions.Add(FlagStrings.CarpenterNoShow, stoodUpLG); // startingPosition = transform.position; startingPosition.y += LevelManager.levelYOffSetFromCenter; //Schedule for the default path #region DefaultSection Reaction independentStormOffReaction = new Reaction(); independentStormOffReaction.AddAction(new NPCAddScheduleAction(this, moveToWindmill)); independentStormOffReaction.AddAction(new NPCEmotionUpdateAction(this, new StormOffToWindmill(this, "I knew I was going to screw up somewhere. I left my specialized tools someplace."))); flagReactions.Add (FlagStrings.carpenterSonTalkWithFatherMorning, independentStormOffReaction); #endregion #region FishSection //Moves the Son back to start if need be. Then triggers a flag to start the conversation with the carpenter Reaction MovePiecesForFishing = new Reaction(); //MovePiecesForFishing.AddAction MovePiecesForFishing.AddAction(new NPCTeleportToAction(this, startingPosition)); MovePiecesForFishing.AddAction(new NPCCallbackAction(AcquireFishingPole)); MovePiecesForFishing.AddAction(new NPCAddScheduleAction(this, TeleportToStartConvo)); flagReactions.Add(FlagStrings.carpenterSonEncouragedFishing, MovePiecesForFishing); //Moves the carpenter son to the pier. Reaction StartFishing = new Reaction(); StartFishing.AddAction(new NPCAddScheduleAction(this, MoveToPierToFish)); StartFishing.AddAction(new NPCEmotionUpdateAction(this, new StormOffEmotionState(this, "I need to work on the windmill."))); flagReactions.Add(FlagStrings.CarpenterSonMovesToTheBeach, StartFishing); Reaction StartWhittling = new Reaction(); StartWhittling.AddAction(new NPCAddScheduleAction(this, AfterSeaCaptainTalk)); flagReactions.Add(FlagStrings.AfterConversationAboutBuildingShip, StartWhittling); Reaction EndReaction = new Reaction(); EndReaction.AddAction(new NPCAddScheduleAction(this, EndState)); flagReactions.Add(FlagStrings.AfterProudOfSonConversation, EndReaction); /*Reaction StartTalkingToSeaCaptain = new Reaction(); //Add in NPCConvoSchedule StartTalkingToSeaCaptain.AddAction(new NPCAddScheduleAction(this, AfterSeaCaptainTalk)); flagReactions.Add(FlagStrings.StartConversationWithSeaCaptainAboutBuildingShip, StartTalkingToSeaCaptain);*/ #endregion #region Carpentry Section Reaction MovePiecesForCarpentry = new Reaction(); MovePiecesForCarpentry.AddAction(new NPCTeleportToAction(this, startingPosition)); MovePiecesForCarpentry.AddAction(new NPCAddScheduleAction(this, StartCarpentry)); flagReactions.Add(FlagStrings.carpenterSonEncouragedCarpentry, MovePiecesForCarpentry); #region Making the Harp Reaction StartMakingHarp = new Reaction(); StartMakingHarp.AddAction(new NPCAddScheduleAction(this, WhittleStuff)); flagReactions.Add (FlagStrings.carpenterSonWhittleMiddleAge, StartMakingHarp); Reaction MakingTheHarpDone = new Reaction(); MakingTheHarpDone.AddAction(new NPCGiveItemAction(this, StringsItem.Harp)); flagReactions.Add (FlagStrings.carpenterSonMakesFatherProud, MakingTheHarpDone); #endregion Reaction DoNothing = new Reaction(); DoNothing.AddAction(new NPCEmotionUpdateAction(this, carpenterState)); DoNothing.AddAction(new NPCAddScheduleAction(this, DoNothingSchedule)); flagReactions.Add(FlagStrings.IntroConvoCarpentry, DoNothing); Reaction EndOfDayConvo = new Reaction(); EndOfDayConvo.AddAction(new NPCEmotionUpdateAction(this, new BlankEmotionState(this, "It's nice to relax after a long day."))); EndOfDayConvo.AddAction(new NPCAddScheduleAction(this, AfterConversationCarpentery)); flagReactions.Add(FlagStrings.CarpenterReturnedHome, EndOfDayConvo); #endregion Reaction dating = new Reaction(); dating.AddAction(new NPCCallbackAction(setFlagDateForMe)); dating.AddAction(new NPCCallbackSetStringAction(FlagToNPC, this, "date")); flagReactions.Add(FlagStrings.CarpenterDate, dating); Reaction moveToDate = new Reaction(); moveToDate.AddAction(new NPCAddScheduleAction(this, moveToBeach)); flagReactions.Add(FlagStrings.CarpenterDating, moveToDate); Reaction endOfDate = new Reaction(); endOfDate.AddAction(new NPCCallbackAction(dateOver)); endOfDate.AddAction(new NPCAddScheduleAction(this, moveBack)); flagReactions.Add(FlagStrings.EndOfDate, endOfDate); //chat stuff Reaction carpenterDateOne = new Reaction(); ShowMultipartChatAction carpenterDateOneDialogue = new ShowMultipartChatAction(this); carpenterDateOneDialogue.AddChat("*Out of Breath* At long last I get to try and court you my fair lady!", 5f); carpenterDateOne.AddAction(carpenterDateOneDialogue); flagReactions.Add(FarmerFamilyFlagStrings.GirlCarpenterDateOne, carpenterDateOne); Reaction carpenterDateTwo = new Reaction(); ShowMultipartChatAction carpenterDateTwoDialogue = new ShowMultipartChatAction(this); carpenterDateTwoDialogue.AddChat("Endearing? My dear woman, I always speak this way!", 3f); carpenterDateTwo.AddAction(carpenterDateTwoDialogue); flagReactions.Add(FarmerFamilyFlagStrings.GirlCarpenterDateThree, carpenterDateTwo); Reaction carpenterDateThree = new Reaction(); ShowMultipartChatAction carpenterDateThreeDialogue = new ShowMultipartChatAction(this); carpenterDateThreeDialogue.AddChat("You remember me!", 2f); carpenterDateThree.AddAction(carpenterDateThreeDialogue); flagReactions.Add(FarmerFamilyFlagStrings.GirlCarpenterDateFive, carpenterDateThree); Reaction carpenterDateFour = new Reaction(); Reaction carpenterDateFive = new Reaction(); Reaction carpenterDateSix = new Reaction(); }