Bots Home
|
Create an App
keno test kitty sinns
Author:
kittysinns
Description
Source Code
Launch Bot
Current Users
Created by:
Kittysinns
/****************************************************** ******************************************************* * Minor changes: KittySinns * Title: Keno KittySinns * Author: KittySinns * Version: 1 (08,2022) * * Based on: * Title: Token Keno Plus * Author: Adambomb01 * Version: 1.2 (12/10/15) * Token Keno v2.39 by calvin06 ******************************************************* ********** * 1.2 ********** - Doesn't send commands unless the message STARTS with a command (Allows you to show people how to use commands without annoyance) ********** * 1.1 ********** - For broadcaster and mod, use //b or //p to send the board and prizelist to the whole room - Got rid of getAdvert (Less spammy - only 2 lines when someone tips rather than 3) ********** * 1.0 ********** - Added "ignored tip amounts" feature. (Broadcaster can specify tip amounts that will NOT call Keno squares) ********** * TO DO ********** - Randomize "some skipped" (Right now it skips the last prizes) - Showvar */ // vars var VERSION = '2.39'; var total_tipped = 0; var high_tip_username = null; var high_tip_amount = 0; var last_tip_username = null; var sentwin = false; var COMMAND_BOARD_STATUS = '/b'; var COMMAND_PRIZES = '/p'; var COMMAND_LB = "/lb"; var COMMAND_VERSION = "/version"; var CONFIG_ADVERT_MINUTES = 10; var EMOTE_TITLE = ' :kenoapp1 '; var EMOTE_STARS = ' :3star '; var EMOTE_STAR = ' :1star '; var nl = '\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501\u2501'; var description = '#tokenkeno '; var firstTimeInit = true; var boardNumbers = new Array(); var boardPrizes = {}; var boardPrizesLeft = 0; var board = ''; var prizes = ''; var userPrizes = new Array(); var playerStats = {}; var gameStats = {firstplace: '',secondplace: '',thirdplace: '',firsttips: 0,secondtips: 0,thirdtips: 0}; var partialTips = {}; var ignoredTips = null; var CONFIG_PRIZENUMBER = 120; cb.settings_choices = [ /**** SETTINGS ****/ { name: 'boardnumbermin', label: 'Lowest Number on Board', type: 'int', minValue: 1, maxValue: 100, defaultValue: 1 }, { name: 'boardnumbermax', label: 'Highest Number on Board', type: 'int', minValue: 10, maxValue: CONFIG_PRIZENUMBER, defaultValue: 30 }, { name: 'prizenumbermin', label: 'No random prizes below this number', type: 'int', minValue: 1, maxValue: (CONFIG_PRIZENUMBER-1), defaultValue: 1, required: false }, { name: 'ignore_tip_amounts', label: 'Ignored Tip Amounts (ex. \'5,10,25\')', defaultValue: 'Optional - These amounts will NOT call Keno squares.', type: 'str', minLength: 1, maxLength: 255, required: false }, { name: 'goal_description', label: 'Cleared Board Goal Description', type: 'str', minLength: 1, maxLength: 255 }, { name: 'mvp_goal_description', label: 'Special prize for the MVP at game end', type: 'str', minLength: 0, maxLength: 255, required: false }, { name: 'multitip', label: "Call multiple numbers with big tips?", type: 'choice', choice1: 'yes', choice2: 'no', defaultValue: 'yes' }, { name: 'trackstats', label: "Show leader board?", type: 'choice', choice1: 'yes', choice2: 'no', defaultValue: 'no' }, { name: 'partialtips', label: "Allow group tipping? (no wasted tips - small tips add to a progress goal towards the hightest number)", type: 'choice', choice1: 'yes', choice2: 'no', defaultValue: 'yes' }, /**** PRIZES ****/ { name: 'prize1', label: 'Prize 1', type: 'str', minLength: 1, maxLength: 255, required: true }, { name: 'prize1num', label: 'Prize 1 # (leave #\'s blank for random assignment)', type: 'int', minValue: 1, maxValue: CONFIG_PRIZENUMBER, required: false }, ]; for (i = 2; i <= CONFIG_PRIZENUMBER; i++) { cb.settings_choices.push({ name: 'prize' + i, label: 'Prize ' + i, type: 'str', minLength: 1, maxLength: 255, required: false }); cb.settings_choices.push({ name: 'prize' + i + 'num', label: 'Prize ' + i + '#', type: 'int', minValue: 1, maxValue: CONFIG_PRIZENUMBER, required: false }); } cb.onTip(function (tip) { total_tipped += tip['amount']; if ((ignoredTips != null && !inArray(tip['amount'],ignoredTips)) || ignoredTips == null) { //if we aren't ignoring the tip amount last_tip_username = tip['from_user']; handleTip(tip['amount'], tip['from_user']); if (numbersRemaining() < 1) { if (!sentwin) { drawBoard(null); var s = description + ' Board Cleared!'; if (!isBlank(cb.settings.goal_description)) { s += ' Goal met [' + cb.settings.goal_description + ']'; } cb.changeRoomSubject(s) } sentwin = true } } cb.drawPanel() }); cb.onDrawPanel(function (user) { return { 'template': '3_rows_of_labels', 'row1_label': 'Board Count:', 'row1_value': '' + numbersRemaining() + ' #s / ' + prizesRemaining() + ' prizes', 'row2_label': 'Tips / On Board:', 'row2_value': '' + total_tipped + ' / ' + getTipCount(), 'row3_label': 'MVP:', 'row3_value': formatUsername(gameStats.firstplace) + ' (' + gameStats.firsttips + ')' } }); cb.onMessage(function (msg) { var msgString = msg['m'].trim(); var isCommand = msgString.charAt(0).match(/(\/|!)/gi); if (isCommand) { // Send Keno Board if (msg['m'].match(/(^|\s)(!|\/)b\b/i)) { if (msg['user'] == cb.room_slug || msg['is_mod']) { cb.sendNotice('To send the board to the entire room, use //b', msg['user'], '#FFCCCC', '#BB2222', 'bold') } if (msg['user'] == cb.room_slug || msg['is_mod'] || msg['has_tokens']) { msg['m'] = msg['m'] + " (token keno: board sent to " + msg['user'] + ")"; drawBoard(msg['user']) } else { msg['m'] = msg['m'] + " (token keno: please buy tokens to play!)"; msg['X-Spam'] = true } } if (msg['m'].match(/(^|\s)(!!|\/\/)b\b/i)) { if (msg['user'] == cb.room_slug || msg['is_mod']) { msg['m'] = msg['m'] + " (token keno: board sent to all)"; drawBoard(null) } } // Send Prize List if (msg['m'].match(/(^|\s)(!|\/)p\b/i)) { if (msg['user'] == cb.room_slug || msg['is_mod']) { cb.sendNotice('To send the prize list to the entire room, use //p', msg['user'], '#FFCCCC', '#BB2222', 'bold') } if (msg['user'] == cb.room_slug || msg['is_mod'] || msg['has_tokens']) { msg['m'] = msg['m'] + " (token keno: prize list sent to " + msg['user'] + ")"; drawPrizes(msg['user']) } else { msg['m'] = msg['m'] + " (token keno: please buy tokens to play!)"; msg['X-Spam'] = true } } if (msg['m'].match(/(^|\s)(!!|\/\/)p\b/i)) { if (msg['user'] == cb.room_slug || msg['is_mod']) { msg['m'] = msg['m'] + " (token keno: prize list sent to all)"; drawPrizes() } } // Send Leaderboard if (msg['m'].match(/(^|\s)(!|\/)lb\b/i)) { if (msg['user'] == cb.room_slug || msg['is_mod']) { cb.sendNotice('To send the leaderboard to the entire room, use //lb', msg['user'], '#FFCCCC', '#BB2222', 'bold') } if (msg['user'] == cb.room_slug || msg['is_mod'] || msg['has_tokens']) { msg['m'] = msg['m'] + " (token keno: leaderboard sent to " + msg['user'] + ")"; cb.sendNotice(getLeaderBoard(), msg['user']) } else { msg['m'] = msg['m'] + " (token keno: please buy tokens to play!)"; msg['X-Spam'] = true } } if (msg['m'].match(/(^|\s)(!!|\/\/)lb\b/i)) { if (msg['user'] == cb.room_slug || msg['is_mod']) { msg['m'] = msg['m'] + " (token keno: leaderboard sent to all)"; cb.sendNotice(getLeaderBoard()) } } // Send Version if (msg['m'].match(/(^|\s)(!|\/)version\b/i)) { cb.sendNotice(VERSION, msg['user']) } return msg } }); cb.tipOptions(function (user) { return }); function notify(message, u, bg, c, w) { if (bg == null) { bg = '#FFF'; } if (c == null) { c = '#000'; } if (w == null) { w = 'bold'; // leave at '' for normal } if (u == 'onlyMods') { cb.sendNotice(message,'',bg,c,w,'red'); } else if (u == 'roomHost') { cb.sendNotice(message,roomHost,bg,c,w); } else if (u == 'modsAndHost') { cb.sendNotice(message,'',bg,c,w,'red'); cb.sendNotice(message,roomHost,bg,c,w); } else if (u == null) { cb.sendNotice(message,'',bg,c,w); } else { cb.sendNotice(message,u,bg,c,w); } } function notifyError(message, u) { notify(message, u, '#FFCCCC', '#BB2222'); } function notifyErrorBold(message, u) { notify(message, u, '#BB2222', '#FFF'); } function isBlank(cbsetting) { var s; if(cbsetting) { s = cbsetting.trim(); } if(s == null || s == '' || s.substr(0,8) == 'Optional') { return true; } else { return false; } } function handleTip(tip, user) { var out = ''; if (!sentwin) { if (user in playerStats) { playerStats[user].totaltips += tip } else { playerStats[user] = { totaltips: tip, winstreak: 0, losestreak: 0, numberscalled: 0 } } if (boardNumbers.indexOf(tip) > -1) { if (cb.settings.partialtips == 'yes' && tip == getPartialTip()) out += (out != '' ? '\n': '') + handlePartialTip(tip, user); else out += (out != '' ? '\n': '') + drawNumberCalled(tip, user, null) } else { var closeout = getPartialTip(); if (closeout > 0) { if ((cb.settings.partialtips == 'yes' && tip == closeout) || (cb.settings.partialtips == 'yes' && cb.settings.multitip == 'yes' && tip >= closeout)) { out += (out != '' ? '\n': '') + handlePartialTip(closeout, user); tip -= closeout } } var next = getNextBestNumber(tip); if (next > 0 && cb.settings.multitip == 'yes') { tip = tip - next; while (boardNumbers.indexOf(next) > -1) { out += (out != '' ? '\n': '') + drawNumberCalled(next, user, null); next = getNextBestNumber(tip); tip -= next } } if (tip > 0 && cb.settings.partialtips == 'yes' && tip < boardNumbers[boardNumbers.length - 1]) { if (hasPartial()) { if (tip <= getPartialTip() || cb.settings.multitip == 'yes') { out += (out != '' ? '\n': '') + handlePartialTip(tip, user) } } else { out += (out != '' ? '\n': '') + createPartialTip(tip, user) } } else { if (tip > 0 && hasPartial() && boardNumbers.length == 0) { var lastamount = getPartialTip(); if (tip <= lastamount) { out += (out != '' ? '\n': '') + handlePartialTip(tip, user) } else { out += (out != '' ? '\n': '') + handlePartialTip(lastamount, user) } } } } trackTips(user, tip); if (out != '') { updateBoard(); cb.sendNotice(out); // cb.sendNotice(getAdvert(), '', '', '', 'bold') } } } function handlePartialTip(tip, user) { var out = ''; if (hasPartial()) { for (var p in partialTips) { if (!inArray(user, partialTips[p].users)) partialTips[p].users.push(user); if (tip >= getPartialTip()) { out += drawNumberCalled(p, null, partialTips[p].users); delete partialTips[p] } else { partialTips[p].tips += tip; out += '-- Added (' + tip + ') tokens to group number [ ' + p + ' ]. Remaining: ' + getPartialTip() } } } return out } function createPartialTip(tip, user) { var out = ''; var highestNum = boardNumbers[boardNumbers.length - 1]; boardNumbers.splice(boardNumbers.indexOf(highestNum), 1); var users = [user]; partialTips[highestNum] = { tips: tip, users: users }; out += '-- Group tips started for number [ ' + highestNum + ' ]. Remaining: ' + getPartialTip(); return out } function updateSubject() { var newSubject = description + ' Uncover prizes by tipping the numbers on the board.'; if (!isBlank(cb.settings.goal_description)) newSubject += ' \nGoal is: [' + cb.settings.goal_description.replace("\'", "") + '] '; newSubject += '\nType ' + COMMAND_BOARD_STATUS + ' to see the board. Type ' + COMMAND_PRIZES + ' to see prizes. '; if (!isBlank(cb.settings.mvp_goal_description)) newSubject += ' MVP wins [' + cb.settings.mvp_goal_description.replace("\'", "") + '] '; cb.changeRoomSubject(newSubject) } function getAdvert() { var advert = 'Type ' + COMMAND_BOARD_STATUS + ' for the board. Type ' + COMMAND_PRIZES + ' for prize list.'; if (cb.settings.multitip == 'yes') advert += ' Big tips call multiples!'; if (cb.settings.partialtips == 'yes') advert += ' Group tips enabled.'; return advert } function getTipCount() { var count = 0; for (var i = 0; i < boardNumbers.length; i++) { count += boardNumbers[i] } count += getPartialTip(); return count } function formatUsername(val) { if (!val || val == 'undefined') { return "--" } else { return val.substring(0, 12) } } function drawNumberCalled(n, user, users) { var out = ''; if (user) { out += '-- Number called [ ' + n + ' ]\n'; boardNumbers.splice(boardNumbers.indexOf(n), 1) } else if (users) { out += '-- GROUP Number called [ ' + n + ' ]\n' } if (n in boardPrizes) { out += EMOTE_STARS + ' ** WINNER ** - Prize won: ' + boardPrizes[n]; if (user) userPrizes.push({ prize: boardPrizes[n], user: user, number: n }); else if (users) userPrizes.push({ prize: boardPrizes[n], user: arrayToString(users), number: n }); delete boardPrizes[n]; boardPrizesLeft--; updatePrizes() } else { out += '-------- No prize won, try again' } return out } function drawBoard(user) { if (user) { cb.sendNotice(board, user) } else { cb.sendNotice(board) } } function updateBoard() { var out = 'Token Board\n'; out += nl + '\n'; if (numbersRemaining() < 1) { out += EMOTE_STARS + ' Board Cleared!!! \n' + EMOTE_STARS; if (!isBlank(cb.settings.mvp_goal_description)) { out += ' Goal met: ' + cb.settings.goal_description + '\n'; } if (!isBlank(cb.settings.mvp_goal_description)) { out += EMOTE_STAR + ' CONGRATS ' + gameStats.firstplace + '! \n' + EMOTE_STAR + ' You won MVP prize: ' + cb.settings.mvp_goal_description + '\n'; } if (cb.settings.trackstats == 'yes') out += getLeaderBoard() + '\n' } else { var mod = 10; var col = 1; if (cb.settings.boardnumbermax - cb.settings.boardnumbermin > 100) mod = 20; var gt = 0; if (cb.settings.partialtips == 'yes') gt = getPartialTipNumber(); for (var i = cb.settings.boardnumbermin; i <= cb.settings.boardnumbermax; i++) { out += ' '; if (boardNumbers.indexOf(i) > -1) { out += pad(i, 2) } else { out += (i == gt ? 'gt': 'xx') } out += ' '; if (col == mod) { out += '\n'; col = 1 } else { col++ } } } if (out.substring(out.length - 1) != '\n') out += '\n'; out += nl; for (var p in partialTips) { out += '\nGroup tipping open on [ ' + p + ' ]. Remaining: ' + getPartialTip() } board = out } function drawPrizes(user) { if (user) { cb.sendNotice(prizes, user) } else { cb.sendNotice(prizes) } } function updatePrizes() { var out = nl + '\nPrizes won (oldest to newest):\n'; if (userPrizes.length == 0) out += 'None\n'; for (var i = 0; i < userPrizes.length; i++) { out += ' ** ' + userPrizes[i].prize + ' [won by ' + userPrizes[i].user + ' on ' + userPrizes[i].number + ']\n' } out += '\nPrizes on the board (in random order):\n'; if (boardPrizesLeft == 0) out += 'None\n'; var randomizedKeys = Object.keys(boardPrizes); randomizedKeys = shuffle(randomizedKeys); for (var i = 0; i < randomizedKeys.length; i++) { out += ' ** ' + boardPrizes[randomizedKeys[i]] + '\n' } out += nl; prizes = out } function getNextBestNumber(tip) { var num = 0; for (var i = 0; i < boardNumbers.length; i++) { if (boardNumbers[i] <= tip) { num = boardNumbers[i] } } return num } function hasPartial() { var out = false; for (var p in partialTips) { out = true } return out } function getPartialTip() { var out = 0; for (var p in partialTips) { out = p - partialTips[p].tips } return out } function getPartialTipNumber() { var out = 0; for (var p in partialTips) { out = p } return out } function trackTips(user, tip) { var out = ''; var change = false; if (playerStats[user].totaltips > gameStats.firsttips) { if (gameStats.firstplace != user) { change = true; if (gameStats.secondplace != user) { gameStats.thirdplace = gameStats.secondplace; gameStats.thirdtips = gameStats.secondtips } gameStats.secondplace = gameStats.firstplace; gameStats.secondtips = gameStats.firsttips; gameStats.firstplace = user } gameStats.firsttips = playerStats[user].totaltips; if (change) out += user + ' is the new MVP! ' + getLeaderBoard() } else if (playerStats[user].totaltips > gameStats.secondtips) { if (gameStats.secondplace != user) { change = true; gameStats.thirdplace = gameStats.secondplace; gameStats.thirdtips = gameStats.secondtips; gameStats.secondplace = user } gameStats.secondtips = playerStats[user].totaltips; if (change) out += user + ' takes second! ' + getLeaderBoard() } else if (playerStats[user].totaltips > gameStats.thirdtips) { if (gameStats.thirdplace != user) { change = true; gameStats.thirdplace = user } gameStats.thirdtips = playerStats[user].totaltips; if (change) out += user + ' takes third! ' + getLeaderBoard() } if (cb.settings.trackstats == 'yes' && out != '') cb.sendNotice(out) } function getLeaderBoard() { var out = ''; if (gameStats.firstplace && gameStats.firstplace != '') out += 'Keno Tip Leaders - 1. ' + gameStats.firstplace + ' (' + gameStats.firsttips + ') '; if (gameStats.secondplace && gameStats.secondplace != '') out += ' 2. ' + gameStats.secondplace + ' (' + gameStats.secondtips + ') '; if (gameStats.thirdplace && gameStats.thirdplace != '') out += ' 3. ' + gameStats.thirdplace + ' (' + gameStats.thirdtips + ') '; if (out == '') out += 'No leaders yet. Please tip to play!'; return out } function setIgnoredTips() { var s = cb.settings.ignore_tip_amounts; if(!isBlank(s)) { //if something has been typed into "ignore tips" on startup s = s.replace(/\s/g, ''); //remove spaces s = s.replace(/\,$/g, ''); //remove comma if last character if (s.match(/^(\d+,*)+/g)) { //make sure they've given us a comma-separated list of numbers ignoredTips = s.split(',').map(function(n){return parseInt(n)}); } else { cb.sendNotice('WARNING: Invalid setting for "Ignore tip amounts" on startup screen. No tip amounts are currently being ignored.', cb.room_slug) } } } function pad(number, length) { var str = '' + number; while (str.length < length) { str = '0' + str } return str } function sanitize(str) { if (str == null) return ''; return str.replace(/[^a-zA-Z 0-9]+/g, '') } function inArray(str, arry) { if (arry) { for (var i = 0; i < arry.length; i++) { if (arry[i] === str) return true } } return false } function arrayToString(arry) { var out = ''; for (var i = 0; i < arry.length; i++) { out += arry[i]; if (i < (arry.length - 1)) out += ', ' } return out } function shuffle(o) { for (var j, x, i = o.length; i; j = Math.floor(Math.random() * i), x = o[--i], o[i] = o[j], o[j] = x); return o } function numbersRemaining() { return (hasPartial() ? boardNumbers.length + 1 : boardNumbers.length) } function prizesRemaining() { return boardPrizesLeft } function getRandomInt(min, max) { return Math.floor(Math.random() * (max - min + 1)) + min } function getRandomArrayVal(arry) { return arry[Math.floor(Math.random() * arry.length)] } function setupBoard() { var prizeTextArr = new Array(); var prizeNumberArr = new Array(); var availableSlotsArr = new Array(); var lowestPrizeNum = cb.settings.boardnumbermin; var skipped = false; if (cb.settings.prizenumbermin && cb.settings.prizenumbermin > cb.settings.boardnumbermin) lowestPrizeNum = cb.settings.prizenumbermin; for (var x = 1; x <= CONFIG_PRIZENUMBER; x++) { prizeTextArr.push(eval('cb.settings.prize' + x)); prizeNumberArr.push(eval('cb.settings.prize' + x + 'num')) } for (var y = lowestPrizeNum; y <= cb.settings.boardnumbermax; y++) { if (!inArray(y,ignoredTips)) { // if we're ignoring the number, don't make it available for prizes availableSlotsArr.push(y) } } for (var i = 0; i < prizeNumberArr.length; i++) { if (prizeNumberArr[i] != '') { if (prizeNumberArr[i] >= cb.settings.boardnumbermin && prizeNumberArr[i] <= cb.settings.boardnumbermax) { if (inArray(prizeNumberArr[i],ignoredTips)) { notifyErrorBold('\u2022 \u2022 \u2022 TOKEN KENO PLUS ERROR \u2022 Prize # set for an ignored tip amount. \u2022 \u2022 \u2022', cb.room_slug); notifyError('Please restart Token Keno Plus and ensure the field "Prize ' + prizeNumberArr[i] + ' #" is left blank\nOr, remove the number "' + prizeNumberArr[i] + '" from the "Ignored Tip Amounts" field.', cb.room_slug); crashApp(); } // cb.log('inArray(' + prizeNumberArr[i] + ',ignoredTips) = ' + inArray(prizeNumberArr[i],ignoredTips)); boardPrizes[prizeNumberArr[i]] = sanitize(prizeTextArr[i]); if (availableSlotsArr.indexOf(prizeNumberArr[i]) > -1) availableSlotsArr.splice(availableSlotsArr.indexOf(prizeNumberArr[i]), 1); prizeTextArr[i] = ''; } else { if (prizeNumberArr[i] < cb.settings.boardnumbermin || prizeNumberArr[i] > cb.settings.boardnumbermax) notifyError('', cb.room_slug) } } } for (var i = 0; i < prizeTextArr.length; i++) { if (prizeTextArr[i] != '') { if (availableSlotsArr.length > 0) { randomNum = getRandomArrayVal(availableSlotsArr); availableSlotsArr.splice(availableSlotsArr.indexOf(randomNum), 1); boardPrizes[randomNum] = sanitize(prizeTextArr[i]); } else { skipped = true; } } } if (skipped == true) { notifyError('WARNING: Board not big enough to place all the prizes. Some skipped...', cb.room_slug) } for (var j = cb.settings.boardnumbermin; j <= cb.settings.boardnumbermax; j++) { boardNumbers.push(j) } if (ignoredTips) { ignoredTips.forEach(function(a) { if (boardNumbers.indexOf(a) > -1) { boardNumbers.splice(boardNumbers.indexOf(a), 1) } }); } for (var k in boardPrizes) { if (boardPrizes.hasOwnProperty(k)) { boardPrizesLeft++ } } } function advert_gamerules() { if (!sentwin) { cb.sendNotice(EMOTE_TITLE + ' Tip a number on the board to play! Type ' + COMMAND_BOARD_STATUS + ' to see the board. Type ' + COMMAND_PRIZES + ' to see prizes remaining.', '', '', '', 'bold'); cb.setTimeout(advert_gamerules, (CONFIG_ADVERT_MINUTES * 70000)) } } function advert_mvp() { if (!sentwin) { if (!isBlank(cb.settings.mvp_goal_description)) { cb.sendNotice('MVP wins [' + cb.settings.mvp_goal_description.replace("\'", "") + '] with cleared board!'); cb.setTimeout(advert_mvp, (CONFIG_ADVERT_MINUTES * 80000)) } } } function advert_leaderboard() { if (!sentwin) { if (getLeaderBoard() != '') { cb.sendNotice(getLeaderBoard()) } cb.setTimeout(advert_leaderboard, (CONFIG_ADVERT_MINUTES * 60000)) } } function init() { if (cb.settings.boardnumbermin <= cb.settings.boardnumbermax) { setIgnoredTips(); setupBoard(); updateBoard(); updatePrizes(); updateSubject(); drawBoard(null); cb.drawPanel(); cb.sendNotice(EMOTE_TITLE, '', '', '', 'bold'); cb.setTimeout(advert_gamerules, (CONFIG_ADVERT_MINUTES * 70000)); cb.setTimeout(advert_mvp, (CONFIG_ADVERT_MINUTES * 80000)); if (cb.settings.trackstats == 'yes') cb.setTimeout(advert_leaderboard, (CONFIG_ADVERT_MINUTES * 60000)) } else { cb.sendNotice('ERROR: Min number can\'t be bigger than max, restart the app', cb.room_slug) } } init();
© Copyright Chaturbate 2011- 2024. All Rights Reserved.