protected override async Task PerformInternal(CommandParametersModel parameters) { IOverlayEndpointService overlay = ChannelSession.Services.Overlay.GetOverlay(ChannelSession.Services.Overlay.DefaultOverlayName); if (overlay != null) { string message = await ReplaceStringWithSpecialModifiers(this.Text, parameters); await overlay.SendTextToSpeech(new OverlayTextToSpeech() { Text = message, Voice = this.Voice, Volume = this.Volume / 100.0, Pitch = this.Pitch / 100.0, Rate = this.Rate / 100.0 }); } }
protected override async Task PerformInternal(UserViewModel user, IEnumerable <string> arguments) { IOverlayEndpointService overlay = ChannelSession.Services.Overlay.GetOverlay(ChannelSession.Services.Overlay.DefaultOverlayName); if (overlay != null) { string message = await this.ReplaceStringWithSpecialModifiers(this.SpeechText, user, arguments); await overlay.SendTextToSpeech(new OverlayTextToSpeech() { Text = message, Voice = this.Voice, Volume = this.Volume, Pitch = this.Pitch, Rate = this.Rate }); } }