阶段性完成
This commit is contained in:
@@ -3,6 +3,8 @@ using Ichni.Menu.UI;
|
||||
using Ichni.Story.UI;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
using UnityEngine.Localization;
|
||||
using UnityEngine.Localization.Tables;
|
||||
|
||||
namespace Ichni.Story
|
||||
{
|
||||
@@ -13,6 +15,9 @@ namespace Ichni.Story
|
||||
/// </summary>
|
||||
public static class TutorialFlowController
|
||||
{
|
||||
/// <summary>教程确认弹窗统一使用 Message String Table,避免业务代码内嵌可见文案。</summary>
|
||||
private static readonly TableReference MessageTable = "Message";
|
||||
|
||||
/// <summary>
|
||||
/// 由 <see cref="UI.TutorialBlockView"/> 点击时调用。配置无效或 MessageUIPage 未配置时只报错,不修改剧情进度。
|
||||
/// </summary>
|
||||
@@ -32,14 +37,18 @@ namespace Ichni.Story
|
||||
}
|
||||
|
||||
// TutorialFlowController 只描述“有哪些选择、各自触发什么效果”;
|
||||
// 具体按钮由通用 SelectionBox 在运行时生成,后续其它系统可复用同一 UI。
|
||||
messageUIPage.ShowSelectionBox(
|
||||
tutorialBlock.tutorialName,
|
||||
string.Empty,
|
||||
new List<SelectionBoxOption>
|
||||
// 具体按钮由通用 SelectionBox 在运行时生成,且按钮文案与标题均由 Message 表解析。
|
||||
messageUIPage.ShowLocalizedSelectionBox(
|
||||
new LocalizedPopupText(MessageTable, "system_tutorial_entry_title"),
|
||||
new LocalizedPopupText(MessageTable, "system_tutorial_entry_content"),
|
||||
new List<LocalizedSelectionBoxOption>
|
||||
{
|
||||
new("游玩教程", () => PlayTutorial(tutorialBlock, chapter, song, difficulty)),
|
||||
new("跳过教程", () => SkipTutorial(tutorialBlock))
|
||||
new(
|
||||
new LocalizedPopupText(MessageTable, "system_tutorial_enter"),
|
||||
() => PlayTutorial(tutorialBlock, chapter, song, difficulty)),
|
||||
new(
|
||||
new LocalizedPopupText(MessageTable, "system_tutorial_skip"),
|
||||
() => SkipTutorial(tutorialBlock))
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user