사용자 지정 액션 작성 (C#)
커스텀 동작을 만드는 다양한 방법
컴포넌트로서 동작 생성하기
[System.Serializable]
class ExampleActionComponent : TypewriterActionScriptable
{
[SerializeField] float timeToWait;
// 주요 로직은 여기,
// ...무상태로
protected override IActionState CreateCustomState(ActionMarker marker, object typewriter)
=> new ExampleState(timeToWait);
// ...또는 코루틴으로
protected override IEnumerator PerformAction(TypingInfo typingInfo)
{
// yield return ...
}
}