using System.Collections; using System.Collections.Generic; using System.Runtime.CompilerServices; namespace Net.Project.B.Dialogue { /// /// 对话数据 /// public interface IDialogueData { /// /// 唯一对话ID /// public int Identity { get; set; } /// /// 通道ID,用于区分不同的对话 /// public int Channel { get; } /// /// 演员ID,谁是说话的人 /// public int ActorIdentity { get; } /// /// 文本 /// public string Text { get; } /// /// 语音路径 /// public string VoicePath { get; } /// /// 等待对话完成 /// /// TaskAwaiter GetAwaiter(); } /// /// 对话选择 /// public interface IDialogueChoice { /// /// 索引 /// public int Index { get; } /// /// 文本 /// public string Text { get; } /// /// 是否可选 /// public bool Enabled { get; } /// /// 备注,例如:选择这个选项会触发什么事件,不可选的原因等 /// public string Remark { get; } } public struct DialogueData:IDialogueData { public int Identity { get; set; } public int Channel { get; set; } public int ActorIdentity { get; set; } public string Text { get; set; } public string VoicePath { get; set; } public TaskAwaiter GetAwaiter() { throw new System.NotImplementedException(); } } public struct DialogueChoice:IDialogueChoice { public int Index { get; set; } public string Text { get; set; } public bool Enabled { get; set; } public string Remark { get; set; } } }