convert to sugoi web services

This commit is contained in:
josephsmendoza
2023-07-14 19:05:49 -07:00
parent a88a096af8
commit aca8b21945
17 changed files with 370 additions and 1131 deletions
+18 -59
View File
@@ -1,65 +1,24 @@
<h1 align="center">Improved Twitch Subathon Countdown</h1>
<p align="center">This is a Twitch Subathon Countdown originally by JayexDesigns.</p>
<p align="center">The CSS Code is updated by Johnnycyan. The JS Files are updated by leabdd and danilotitato to add functionalities.</p>
<br/>
# Improved Twitch Subathon Countdown
This is a Twitch Subathon Countdown originally by JayexDesigns.
<h2>Description</h2>
<p>A subathon timer that increases when someone subscribes, donates money, donates bits or purchases streamloots chests.</p>
<p>Added is a Timer that gets saved (in localStorage) and can be reset.</p>
<p>When you open the index.html you get to chose between "Reset" or "Start".</p>
<br/>
The CSS Code is updated by Johnnycyan.
<h2>Shortcuts</h2>
<p>To pause the Timer: CTRL+ALT+P</p>
<p>To enable/disable Happy Hour: CTRL+ALT+H</p>
<p>To enable/disable Random Hour: CTRL+ALT+R</p>
<p>Shortcuts can be changed in config.js</p>
<br/>
The JS Files have been re-written by SugoiDogo.
<h2>Preview</h2>
<h3 align="center"><img width="90%" src="./preview.webp"></h3>
<br/>
## Description
A subathon timer that increases when someone subscribes, donates to your charity, donates bits, follows or raids.
<h2>Usage</h2>
<p>After cloning this repository you'll have to edit the "config.js" file with any plain text editor, then change the value of the variables according to what you want:</p>
## Usage
Go to the [config page](https://sugoidogo.github.io/twitch-subathon-countdown/config.html), authorize the timer, and configure to your liking.
<h3>Twitch</h3>
<p>To get your Subs and Bits you just have to add your Channel Name.</p>
## Support
See [my github profile](https://github.com/sugoidogo)
<h3>Streamlabs Token</h3>
<p>To get the token you'll have to go to the API settings tab of your <a href="https://streamlabs.com/dashboard#/settings/api-settings">Streamlabs dashboard</a> then click on API Tokens, copy your socket API token and finally paste the code on the "streamlabs_token" variable in the "config.js" file.</p>
<img src="./auth_streamlabs.png">
<h3>StreamElements Token</h3>
<p>To get the token you'll have to go to your <a href="https://streamelements.com/dashboard/account/channels">StreamElements channels dashboard</a>, then click on show secrets, copy the Overlay token and paste the code on the "streamelements_token" variable in the "config.js" file.</p>
<img src="./auth_streamelements.png">
<h3>Streamloots Token</h3>
<p>To get the token you'll have to go to your Streamloots creator dashboard, then to alerts & widgets, then go to alerts, then copy the last part of the alerts url and finally paste the code on the "streamloots_token" variable in the "config.js" file.</p>
<img src="./auth_streamloots.png">
<h3>Initial Time</h3>
<p>You can set the initial time of the timer by setting the hours, minutes and seconds to be added when the timer is created.</p>
<h3>Random Happy Hour</h3>
<p>If this is true, you can turn enable Happy or Random Hour with the Shortcut. If it is false, the feature is disabled and cant be enabled.</p>
<p>You have to set the Happy Hour time values manually.</p>
<p>Random Hour has a bell curve which can be edited in the config. It multiplies the normal time by a random amount for each sub.</p>
<p>If enabled randHappy it can randomly activate the Happy Hour. It will last for one hour, but can be turned off manually with the Shortkey.</p>
<p>In the Config you can set a specific Date and Time. At that a Happy Hour will happen. scheduleHappy needs to be turned on.</p>
<h3>Bulk</h3>
<p>This enables that multiple Subs get added to the timer at once.</p>
<p>For Example when a user gifts 10 Subs.</p>
<h3>Full control on what to use</h3>
<p>You can enable and disable if you want to add time for Subscriptions, Bits, Donations or Chests.</p>
<h3>Other Values</h3>
<p>Change the other values to set the amount of seconds that will be added for the subscriptions, donations... And the minimum donation amounts to trigger the countdown increase.</p>
<h3>Add To OBS</h3>
<p>To add it to OBS you just have to drag the "index.html" file to the sources section or add a browser source that points to the "index.html" file.</p>
<h2>Known Problems</h2>
<p2>Only Streamelements Token in config.js does not add time for Subscriptions. Emulate with the Overlay Editor does work.</p>
## Missing Features
The original version of this overlay included support for events from StreamElements, StreamLabs, and Streamloots,
and the version this is forked from included additional features by leabdd and danilotitato,
such as Random Happy Hour and Bulk Events.
This fork is an almost total re-write of the core JS code behind the timer,
so those features will also have to be re-written to be included in this fork.
Future versions of this timer will include a plug-in loader,
allowing additional features and event sources to be added without additional forking.