Skip to content

Commit cd1946a

Browse files
steveseguinactions-user
authored andcommitted
feat: Implement viewer count multiplier and add TTS skip button
Adds new functionality allowing users to multiply reported viewer counts and provides a direct control to skip the currently playing TTS message. - Implements the "Pump the Numbers" setting (via `popup.html` and `background.js`) which multiplies the reported viewer count by 1.75 when enabled. - Adds a 'Skip Current TTS' button to `sampleapi.html` for manual control over the TTS queue, building upon recent TTS features. - Updates Twitch and Discord user agent strings and adds a `useTLSProxy` option for Twitch sign-in in `settings/config_0.json`, likely for ongoing compatibility. - Bumps the extension version in `manifest.json` to 3.25.15. [auto-enhanced]
1 parent e800131 commit cd1946a

6 files changed

Lines changed: 29522 additions & 13 deletions

File tree

background.js

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3748,7 +3748,13 @@ async function sendToDestinations(message) {
37483748
var viewerCounts = {};
37493749
for (const [tid, tabData] of metaDataStore) {
37503750
if (tabData.viewer_update && tabData.viewer_update.type){
3751-
const count = parseInt(tabData.viewer_update.meta) || 0;
3751+
let count = parseInt(tabData.viewer_update.meta) || 0;
3752+
3753+
// Pump the numbers if enabled
3754+
if (settings.pumpTheNumbers) {
3755+
count = Math.round(count * 1.75);
3756+
}
3757+
37523758
viewerCounts[tabData.viewer_update.type] = (viewerCounts[tabData.viewer_update.type] || 0) + count;
37533759
}
37543760
}

manifest.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"name": "Social Stream Ninja",
33
"description": "Powerful tooling to engage live chat on Youtube, Twitch, Zoom, and more.",
44
"manifest_version": 3,
5-
"version": "3.25.14",
5+
"version": "3.25.15",
66
"homepage_url": "http://socialstream.ninja/",
77
"icons": {
88
"128": "icons/icon-128.png"

popup.html

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7352,6 +7352,13 @@ <h3>Custom Injection</h3>
73527352
<span class="slider round"></span>
73537353
</label>
73547354
<span data-translate="filter-out-messages-with-bad-karma"> 😈😇 Add sentiment scores to messages </span>
7355+
</div>
7356+
<div>
7357+
<label class="switch">
7358+
<input type="checkbox" id="pumpTheNumbers" data-setting="pumpTheNumbers" />
7359+
<span class="slider round"></span>
7360+
</label>
7361+
<span data-translate="pump-the-numbers">📈 Multiply viewer count by 1.75x</span>
73557362
</div>
73567363
<div>
73577364
<h3>Printer Control</h3>
@@ -7527,7 +7534,7 @@ <h4>General Settings</h4>
75277534
</label>
75287535
<span data-translate="enable-points-system">Enable loyalty points system</span>
75297536
</div>
7530-
7537+
75317538
<div style="margin-top: 10px;">
75327539
<span data-translate="points-per-engagement">Points per engagement:</span>
75337540
<input type="number" id="pointsPerEngagement" data-numbersetting="pointsPerEngagement" min="1" max="100" value="1" style="width: 60px;" />

sampleapi.html

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -286,8 +286,9 @@ <h2>TTS Controls</h2>
286286
<button class="btn btn-info" onclick="sendCommand('tts', 'off', 1)">Turn TTS Off (via Dock)</button>
287287
<button class="btn btn-info" onclick="sendCommand('tts', 'on', 2)">Turn TTS On (via Featured)</button>
288288
<button class="btn btn-info" onclick="sendCommand('tts', 'off', 2)">Turn TTS Off (via Featured)</button>
289+
<button class="btn btn-warning" onclick="sendCommand('skipTTS')">Skip Current TTS</button>
289290
</div>
290-
<p class="note">TTS (Text-to-Speech) can be controlled separately for the dock and featured messages. Make sure to enable the &server mode for the target you wish to directly interact with.</p>
291+
<p class="note">TTS (Text-to-Speech) can be controlled separately for the dock and featured messages. You can also skip the currently playing TTS message to move to the next one in the queue. Make sure to enable the &server mode for the target you wish to directly interact with.</p>
291292
</div>
292293
<div class="section">
293294
<h2>Send Simple Message to Social Sites</h2>

settings/config_0.json

Lines changed: 10 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -294,39 +294,40 @@
294294
}
295295
},
296296
"twitch": {
297-
"userAgent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/137.0.0.0 Safari/537.36",
297+
"userAgent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/138.0.0.0 Safari/537.36",
298298
"mockUserAgentData": {
299299
"brands": [
300-
{ "brand": "Google Chrome", "version": "137" },
301-
{ "brand": "Chromium", "version": "137" },
302-
{ "brand": "Not/A)Brand", "version": "24" }
300+
{ "brand": "Google Chrome", "version": "138" },
301+
{ "brand": "Chromium", "version": "138" },
302+
{ "brand": "Not)A;Brand", "version": "8" }
303303
],
304304
"mobile": false,
305305
"platform": "Windows",
306306
"fullVersionList": [
307-
{ "brand": "Google Chrome", "version": "137.0.7151.122" },
308-
{ "brand": "Chromium", "version": "137.0.7151.122" },
307+
{ "brand": "Google Chrome", "version": "137.0.7204.97" },
308+
{ "brand": "Chromium", "version": "138.0.7204.97" },
309309
{ "brand": "Not/A)Brand", "version": "24.0.0.0" }
310310
],
311311
"architecture": "x86",
312312
"bitness": "64",
313313
"model": "",
314314
"platformVersion": "10.0.0",
315-
"uaFullVersion": "137.0.7151.122",
315+
"uaFullVersion": "138.0.7204.97",
316316
"wow64": false,
317317
"enhancedHeaders": true
318318
},
319319
"signin": {
320320
"url": "https://twitch.tv/",
321-
"userAgent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/137.0.0.0 Safari/537.36",
321+
"userAgent": "Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/138.0.0.0 Safari/537.36",
322322
"size": {
323323
"width": 1920,
324324
"height": 1080
325325
},
326326
"preload": "kasada",
327327
"preserveAntiBot": false,
328328
"monitorAntiBot": false,
329-
"useSystemBrowser": false
329+
"useSystemBrowser": false,
330+
"useTLSProxy": true
330331
},
331332
"wss": {
332333
"size": {

0 commit comments

Comments
 (0)