alduron / JackBot

A Discord bot for hosting JackBox Party Pack 4
34 stars 5 forks source link

Inconsistent Success using SendKeys #6

Closed pseud0 closed 3 years ago

pseud0 commented 3 years ago

Hello, I noticed the SendKeys commands producing inconsistent results when attempting to Stream to Discord. After further investigation I believe you need to make the following changes in your code:

Line 668: Invoke-KeyAtTarget -CMD "^{k}" -Target $Script:Config.DiscordName CHANGE TO : Invoke-KeyAtTarget -CMD "(^k)+(^)" -Target $Script:Config.DiscordName

and

Line 669: Invoke-KeyAtTarget -CMD "+{1}" -Target $Script:Config.DiscordName CHANGE TO : Invoke-KeyAtTarget -CMD "(+1)+(+)" -Target $Script:Config.DiscordName

These changes have resulted in a 100% success rate when attempting to trigger the add to channel function.

alduron commented 3 years ago

@TheyCallMeZ added the new changes to the script. Thank you @pseud0 for identifying and submitting a fix.