Skip to content

Instantly share code, notes, and snippets.

@todorok1
Last active August 16, 2025 03:25
Show Gist options
  • Select an option

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

Select an option

Save todorok1/fa0e61d267f17eeeb018149d9b0007e5 to your computer and use it in GitHub Desktop.
シンプルRPGチュートリアル第119回 メッセージウィンドウの動作を制御するクラス
/// <summary>
/// アイテムを使用した時のメッセージを生成します。
/// </summary>
public void GenerateUseItemMessage(string itemUserName, string itemName)
{
uiController.ClearMessage();
string message = $"{itemUserName}{BattleMessage.ItemUserSuffix} {itemName} {BattleMessage.ItemNameSuffix}";
StartCoroutine(ShowMessageAutoProcess(message));
}
/// <summary>
/// アイテムや魔法などの効果がない時のメッセージを生成します。
/// </summary>
public void GenerateNoEffectMessage()
{
string message = BattleMessage.NoEffect;
StartCoroutine(ShowMessageAutoProcess(message));
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment