Size: 1380
Comment:
|
Size: 1474
Comment:
|
Deletions are marked like this. | Additions are marked like this. |
Line 1: | Line 1: |
||<tablebgcolor="#F9F9F9" tablestyle="margin:1em 1em 1em 0px;border-style:solid;border-color:rgb(170, 170, 170);color:rgb(0, 0, 0);font-family:sans-serif;font-size:13px;line-height:19.5px;text-align:start; " tableclass="wikitable"#F2F2F2 style="border-style:solid;border-color:rgb(170, 170, 170);padding:0.2em; ">Usage: ||<style="border-style:solid;border-color:rgb(170, 170, 170);padding:0.2em;">say message<<BR>>say [language#] message || | ||<tablebgcolor="#F9F9F9" tablestyle="margin:1em 1em 1em 0px;border-style:solid;border-color:rgb(170, 170, 170);color:rgb(0, 0, 0);font-family:sans-serif;font-size:13px;line-height:19.5px;text-align:start; " tableclass="wikitable"#F2F2F2 style="border-style:solid;border-color:rgb(170, 170, 170);padding:0.2em; ">Usage: ||<style="border-style:solid;border-color:rgb(170, 170, 170);padding:0.2em;">say "message"<<BR>>say "[language#] message" || |
Line 4: | Line 4: |
Allows you to instruct the bot to say outloud a given message using the operating system's built-in text-to-speech reader. | Allows you to instruct the bot to say outloud a given message using the operating system's built-in text-to-speech reader. The say command can be used with expressions and thus requires use of quotation marks around all you want it to say, so that it can differentiate between your string and a variable. |
Line 6: | Line 6: |
An optional language value can be given to use that language by the TTS reader. In the 2nd example above, the bot would say "Tu ciudad esta siendo atacada." ("Your city is under attack") with a Spanish accent and voice as determined by the language value "es". | An optional language value can be given to use that language by the TTS reader. In the 2nd example above, the bot would say the sentence ''Tu ciudad esta siendo atacada. (Your city is under attack)'' with a Spanish accent and voice as determined by the language value ''es''. |
Line 8: | Line 8: |
The say command can be used, like other commands, with variables via the [[execute]] command. An example of a useful line for a defensive script would be: | An example of a useful line for a defensive script would be: |
Line 10: | Line 10: |
execute "say " + city.name + " has " + city.NumberOfRealAttacks + " incoming attacks" | say city.name + " has " + city.NumberOfRealAttacks + " incoming attacks" |
Usage: |
say "message" |
Example: |
say Your city is under attack. |
Allows you to instruct the bot to say outloud a given message using the operating system's built-in text-to-speech reader. The say command can be used with expressions and thus requires use of quotation marks around all you want it to say, so that it can differentiate between your string and a variable.
An optional language value can be given to use that language by the TTS reader. In the 2nd example above, the bot would say the sentence Tu ciudad esta siendo atacada. (Your city is under attack) with a Spanish accent and voice as determined by the language value es.
An example of a useful line for a defensive script would be:
say city.name + " has " + city.NumberOfRealAttacks + " incoming attacks"