本文整理汇总了C#中NPC.UpdateDefaultText方法的典型用法代码示例。如果您正苦于以下问题:C# NPC.UpdateDefaultText方法的具体用法?C# NPC.UpdateDefaultText怎么用?C# NPC.UpdateDefaultText使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类NPC
的用法示例。
在下文中一共展示了NPC.UpdateDefaultText方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: updateDecline
public void updateDecline(NPC toControl)
{
numDeclines++;
if (numDeclines == 1) {
_allChoiceReactions.Remove(readyChoice);
_allChoiceReactions.Remove(NotYetChoice);
GUIManager.Instance.RefreshInteraction();
NotYetChoice = new Choice ("Not yet", "Please!! I need practice!");
_allChoiceReactions.Add(NotYetChoice, new DispositionDependentReaction(declineFortuneState));
_allChoiceReactions.Add(readyChoice, new DispositionDependentReaction(acceptFortuneState));
}
if (numDeclines == 2) {
_allChoiceReactions.Remove(readyChoice);
_allChoiceReactions.Remove(NotYetChoice);
toControl.UpdateDefaultText("You're back! Ready for your fortune?");
GUIManager.Instance.RefreshInteraction();
NotYetChoice = new Choice ("Not yet", "Ok, come back soon! Predictions come and go you know!");
_allChoiceReactions.Add(NotYetChoice, new DispositionDependentReaction(declineFortuneState));
_allChoiceReactions.Add(readyChoice, new DispositionDependentReaction(acceptFortuneState));
}
if (numDeclines == 3) {
_allChoiceReactions.Remove(readyChoice);
_allChoiceReactions.Remove(NotYetChoice);
toControl.UpdateDefaultText("I promise it won't be scary!");
GUIManager.Instance.RefreshInteraction();
NotYetChoice = new Choice ("Not yet", "Ok... You win.");
_allChoiceReactions.Add(NotYetChoice, new DispositionDependentReaction(declineFortuneState));
_allChoiceReactions.Add(readyChoice, new DispositionDependentReaction(acceptFortuneState));
}
if (numDeclines == 4) {
_allChoiceReactions.Remove(readyChoice);
_allChoiceReactions.Remove(NotYetChoice);
toControl.UpdateDefaultText("Please...?");
GUIManager.Instance.RefreshInteraction();
readyChoice = new Choice ("I'm ready!", "I'm glad you finally decided to join me.");
NotYetChoice = new Choice ("Not yet", "Good catch. I thought that trick would work.");
_allChoiceReactions.Add(readyChoice, new DispositionDependentReaction(acceptFortuneState));
_allChoiceReactions.Add(NotYetChoice, new DispositionDependentReaction(declineFortuneState));
}
if (numDeclines >= 5) {
//FlagManager.instance.SetFlag(FlagStrings.MeanToFortuneteller);
_allChoiceReactions.Remove(readyChoice);
_allChoiceReactions.Remove(NotYetChoice);
toControl.UpdateDefaultText("Ok... I'll find someone else do their fortune then.");
GUIManager.Instance.RefreshInteraction();
SetOnCloseInteractionReaction(new DispositionDependentReaction(changeToGiveUpState));
}
}
示例2: updateCurrentText
public void updateCurrentText(NPC toControl)
{
toControl.UpdateDefaultText("Do you take the left path or the right path?");
GUIManager.Instance.RefreshInteraction();
}