Bots Home
|
Create an App
Gemmies Tip Timer
Author:
lil_gem
Description
Source Code
Launch Bot
Current Users
Created by:
Lil_Gem
// Chaturbate App: Tip Timer Shutdown Reminder // Description: Adds 60 seconds to a countdown timer for every tip. Sends a message when timer ends. let timerDuration = 300; // Initial time in seconds (5 minutes for example) let remainingTime = timerDuration; let intervalId = null; function startTimer() { if (intervalId !== null) return; // Prevent multiple intervals intervalId = setInterval(() => { remainingTime--; if (remainingTime <= 0) { clearInterval(intervalId); intervalId = null; cb.sendNotice("⏰ Timer ended! Please end the stream manually."); // Note: Apps cannot auto-end a stream; model must do it manually. } else if (remainingTime % 60 === 0) { cb.sendNotice("⏳ Time remaining: " + (remainingTime / 60) + " minute(s)."); } }, 1000); // Update every second } cb.onTip(function(tip) { remainingTime += 60; cb.sendNotice("💖 Thanks " + tip.from_user + "! +1 minute added. Total: " + Math.ceil(remainingTime / 60) + " minute(s)."); startTimer(); }); cb.onEnter(function(user) { if (cb.room_slug === user.username) { cb.sendNotice("⏱️ Tip timer started. Tips add time. Stream ends when timer runs out."); startTimer(); } }); // Optional: Configure panel settings cb.settings_choices = [];
© Copyright Chaturbate 2011- 2026. All Rights Reserved.