您最多选择25个主题
主题必须以中文或者字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符
24 行
607 B
24 行
607 B
using UnityEngine;
|
|
|
|
namespace GameplayIngredients.Actions
|
|
{
|
|
[AddComponentMenu(ComponentMenu.actionsPath + "Send Message Action")]
|
|
[HelpURL(Help.URL + "messager")]
|
|
[Callable("Game", "Actions/ic-action-message.png")]
|
|
public class SendMessageAction : ActionBase
|
|
{
|
|
public string MessageToSend = "Message";
|
|
|
|
public override void Execute(GameObject instigator = null)
|
|
{
|
|
Messager.Send(MessageToSend, instigator);
|
|
}
|
|
|
|
public override string GetDefaultName()
|
|
{
|
|
return $"Send Message : '{MessageToSend}'";
|
|
}
|
|
}
|
|
}
|
|
|
|
|