Skip to content

Instantly share code, notes, and snippets.

@todorok1
Created August 14, 2025 03:18
Show Gist options
  • Select an option

  • Save todorok1/f69d40ec9043c852437989ad11ea0556 to your computer and use it in GitHub Desktop.

Select an option

Save todorok1/f69d40ec9043c852437989ad11ea0556 to your computer and use it in GitHub Desktop.
シンプルRPGチュートリアル第117回 メッセージに関するイベントを処理するクラス
/// <summary>
/// メッセージを表示します。
/// </summary>
IEnumerator ShowMessageProcess()
{
_messageWindowController.SetUpController(this);
_messageWindowController.ShowPager();
_messageWindowController.ShowWindow();
foreach (var message in _messages)
{
_messageWindowController.ShowGeneralMessage(message, 0f);
// キー入力を待ちます。
_messageWindowController.StartKeyWait();
while (_messageWindowController.IsWaitingKeyInput)
{
yield return null;
}
// 選択時の効果音を再生します。
AudioManager.Instance.PlaySe(SeNames.OK);
}
if (!_keepWindowOpen)
{
_messageWindowController.HideWindow();
_messageWindowController.HidePager();
}
CallNextProcess();
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment