Deep Bot - Twitch Streamer Assistant

Deep Bot => Help/Support => Topic started by: VicPage on August 03, 2018, 05:10:43 PM

Title: command add minutes
Post by: VicPage on August 03, 2018, 05:10:43 PM
For a 24h stream, I would to create a command to let the mods add minutes to a certain string, so ppl can know how much they increased the countdown (this last part should be @getcounter@[!boostadd], it's the first command I can't figure out) . I've tried the @counter@ but ofc it adds just 1 at times, I've tried the @calc@ but apparently it doesn't work (or I am dumb). Can you help me?

Sorry for my bad english, not my native one.
Title: Re: command add minutes
Post by: ThatGirlSlays on August 07, 2018, 01:12:28 AM
Hi,

So if I am understanding you correctly this is what you are trying to do (please correct me if I am wrong):


If that's what you are trying to do then you can simply make use of @counter@ and @calc@

So for example..

This is the !extend command that people use to add time to your stream:

@user@ just added @readfile@[Extend/increment.txt] minutes to the stream. This stream has been extended by @calc@[*|@readfile@[Extend/increment.txt]|@counter@] minutes.

Then if people want to check how long the stream has been extended for later then this is your !extendcount command:
This stream has been extended @getcounter@[!extend] times for a total of @calc@[*|@readfile@[Extend/increment.txt]|@getcounter@[!extend]] extra minutes.


In your "custom logs" folder, create a new folder called "Extend" and then inside of it, create a file called "increment.txt". Inside the file, enter the number of minutes you want to extend your stream each time the !extend command is used. For example enter "30" (without the quotation marks) if you want the stream to be extended by 30 minutes each time someone uses the !extend command.

You can even do further conditional logic if you want to display minutes AND hours the stream has been extended. In might example, if the stream has been extended 5 times it will say "This stream has been extended 5 times for a total of 150 minutes. If you want this to say "2.5 hours" then you would need to divide 150 by 60. If you want to add 2.5 to 24 hour and then say "This has now become a 26.5 hour stream" then you need to use calc again to add 24 + (150 / 60).