Wait for speech

From UBot Studio
(Difference between revisions)
Jump to: navigation, search
(Created page with "'''wait for speech''' is a command that makes your scripting tool (UBot Studio) wait until the current speech has completely finished playing before proceeding with subsequent...")

Revision as of 03:12, 12 July 2023

wait for speech is a command that makes your scripting tool (UBot Studio) wait until the current speech has completely finished playing before proceeding with subsequent commands.

This command is especially beneficial when you need to maintain a logical sequence where an action needs to be performed only after the completion of speech playback.

Example

connect to speech synthesis("your API key")
start playing speech("Hello, UBot Studio!", "Rachel", true)
wait for speech
log("The speech has finished playing!")

Please replace "your API key" with your actual API key.

In the script provided, "Hello, UBot Studio!" is turned into speech using the "Rachel" voice and played back. The script will then wait for the speech to finish. Once the speech has finished playing, "The speech has finished playing!" is logged to the console.

Always handle your API Key carefully due to its sensitivity. An incorrect or exposed key could lead to errors or a breach of security. Also, make sure the selected voice is available in your speech synthesis API.

This command does not have a return value or parameters. It simply waits for the speech to finish playing.

Personal tools
Namespaces

Variants
Actions
Navigation
Toolbox