using Newtonsoft.Json; using RhythmBase.Components; using RhythmBase.Converters; namespace RhythmBase.Events { /// /// Represents an event that narrates row information. /// public class NarrateRowInfo : BaseRowAction { /// /// Initializes a new instance of the class. /// public NarrateRowInfo() { Type = EventType.NarrateRowInfo; Tab = Tabs.Actions; CustomPattern = new Patterns[6]; } /// /// Gets the type of the event. /// public override EventType Type { get; } /// /// Gets the tab associated with the event. /// public override Tabs Tab { get; } /// /// Gets or sets the type of narration information. /// public NarrateInfoType InfoType { get; set; } /// /// Gets or sets a value indicating whether the narration is sound only. /// public bool SoundOnly { get; set; } /// /// Gets or sets the beats to skip during narration. /// [JsonProperty("narrateSkipBeats")] public NarrateSkipBeats NarrateSkipBeat { get; set; } = NarrateSkipBeats.On; /// /// Gets or sets the custom pattern for the narration. /// [JsonConverter(typeof(PatternConverter))] public Patterns[] CustomPattern { get; set; } /// /// Gets or sets a value indicating whether to skip unstable beats. /// public bool SkipsUnstable { get; set; } /// /// Returns a string that represents the current object. /// /// A string that represents the current object. public override string ToString() => base.ToString() + string.Format(" {0}:{1}", InfoType, NarrateSkipBeat); /// /// Specifies the type of narration information. /// public enum NarrateInfoType { /// /// Indicates a connection event. /// Connect, /// /// Indicates an update event. /// Update, /// /// Indicates a disconnection event. /// Disconnect, /// /// Indicates an online event. /// Online, /// /// Indicates an offline event. /// Offline } /// /// Specifies the beats to skip during narration. /// public enum NarrateSkipBeats { /// /// Skip beats is on. /// On, /// /// Custom skip beats. /// Custom, /// /// Skip beats is off. /// Off, } } }