public void TellStory() { if (story == null) { return; } if (IsStoryEnd) { return; } if (currentStoryIndex >= story.functions.Count) { return; } ProppFunction currentFuntion = story.functions[currentStoryIndex]; //Debug.Log($"Function {currentFuntion.Number}"); foreach (var a in currentFuntion.actions) { if (a != null) { Debug.Log($"{a.Description()}"); } //Debug.Log(a.ToString()); } }
public void ProgressStory() { if (story == null) { return; } if (IsStoryEnd) { return; } currentActionIndex += 1; ProppFunction currentFuntion = story.functions[currentStoryIndex]; if (currentActionIndex >= currentFuntion.actions.Count) { currentActionIndex = 0; currentStoryIndex += 1; } if (currentStoryIndex >= story.functions.Count) { IsStoryEnd = true; } }
public void TellStory(StoryTellingSystem stSystem) { if (story == null) { return; } if (IsStoryEnd) { SceneManager.LoadScene("2_Main"); } if (currentStoryIndex >= story.functions.Count) { return; } ProppFunction currentFuntion = story.functions[currentStoryIndex]; if (currentActionIndex >= currentFuntion.actions.Count) { return; } ProppAction currentAction = currentFuntion.actions[currentActionIndex]; if (currentAction != null) { stSystem.DefaultSetting(); currentAction.ShowAction(stSystem); currentAction.TellAction(stSystem); } }
public ProppFunctionData(ProppFunction function) { functionNumber = function.Number; foreach (var a in function.actions) { actions.Add(new ProppActionData(a)); } }
protected void ReplaceFunction(ProppFunction targetFunction, ProppFunction newFunction) { targetFunction = newFunction; }
public void AddFunction(ProppFunction func) { functions.Add(func); }