Created
March 18, 2016 11:32
-
-
Save ebith/edfa5c255dc9af9ab9b5 to your computer and use it in GitHub Desktop.
発言を読み上げるLimeChat用スクリプト
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Require: | |
// SpeechPlatformRuntime.msi - https://www.microsoft.com/en-us/download/details.aspx?id=27225 | |
// MSSpeech_TTS_ja-JP_Haruka.msi - https://www.microsoft.com/en-us/download/details.aspx?id=27224 | |
var tts; | |
function event::onLoad() { | |
tts = new ActiveXObject('Speech.SpVoice'); | |
} | |
function event::onChannelText(prefix, channel, text) { | |
if (prefix.nick == myNick) { return; } | |
text = text.replace(/(h?ttp|ftp)s?:\/\/\S+/g, 'URL省略'); | |
tts.Speak(text, 1); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment