功能如题所说的。
TTS取巧用的Google Translate的。
感谢QQSpy
感谢踏雪流云
感谢Translate.google.com
.....
代码:
def Speaker(): while True: if MsgCookies: TinyTTS.SPEECH(MsgCookies.pop()) else: time.sleep(1) @HOOKDecorator('KernelUtil.?SaveMsg@Msg@Util@@YAHPB_WKKKPAUITXMsgPack@@PAUITXData@@@Z', ctypes.CFUNCTYPE) def SaveMsg(str, toQQNum, fromQQNum, data3, pmsg, pdata): xmsg = ctypes.c_long() AbstractMsg(ctypes.pointer(xmsg), pmsg) msg = ctypes.wstring_at(xmsg.value) MsgCookies.insert(0, '%d说: %s' % (fromQQNum, msg.encode('gb2312'))) global IsSpeakerRunning if not IsSpeakerRunning: IsSpeakerRunning = True thread.start_new(Speaker, ()) return OriginFuncion(str, toQQNum, fromQQNum, data3, pmsg, pdata)