Bots Home
|
Create an App
test1234kjhfkjsadhfsdf
Author:
chopper_daddy
Description
Source Code
Launch Bot
Current Users
Created by:
Chopper_Daddy
// ====================================================== // // ================ Roxie's Tip Menu ==================== // // ====================================================== // // ============ Written By chopper_daddy ================ // // ====================================================== // let HEART = '\u2665'; // ♥ let BDIAMOND = '\u2666'; // ♦ let BSTAR = '\u2605'; // ★ let separator_char = " | "; let messageIntro; let messageMenu; let messageOutro; let MAXITEMS = 25; let mip = []; let mi = []; let MAXSEP = 9; const gradient = 'linear-gradient(#410078, #B00099)'; let menuItemPrice; let menuItem; let fappyHour = false; separators = [ { label: 'Hearts', shortcut: ':heart2' }, { label: 'Glitter', shortcut: ':pixelglitter' }, { label: 'Flowers', shortcut: ':tinyflower2' }, { label: 'Bow', shortcut: ':bluebow' }, { label: 'Hearts2', shortcut: ':pixelheart' }, { label: 'Smiley', shortcut: ':smile' }, { label: 'Text Heart', shortcut: HEART }, { label: 'Text Diamond', shortcut: BDIAMOND }, { label: 'Text Star', shortcut: BSTAR } ] cb.settings_choices = [ { name: 'modelName', type: 'str', label: 'Performer Name', required: false }, { name: 'thanksM', type: 'str', label: 'Thank You Message', required: false }, { name: 'fappyHour', type: 'choice', choice1: 'yes', choice2: 'no', defaultValue: 'no', label: 'Start with Fappy Hour turned on?', required: false }, { name: 'sepchar', type: 'choice', choice1: 'Vertical Bar', choice2: 'Hearts', choice3: 'Glitter', choice4: 'Flowers', choice5: 'Bow', choice6: 'Hearts2', choice7: 'Smiley', choice8: 'Text Heart', choice9: 'Text Diamond', choice10: 'Text Star', defaultValue: 'Vertical Bar', label: 'Separator character', required: false }, { name: 'customsep', type: 'str', label: 'Custom Separator', required: false }, { name: 'item1', type: 'str', label: 'Item 1' }, { name: 'item1price', type: 'int', minValue: 0, maxValue: 99999999, label: 'Item 1 Price' }, { name: 'item2', type: 'str', required: false, label: 'Item 2' }, { name: 'item2price', type: 'int', minValue: 0, maxValue: 99999999, required: false, label: 'Item 2 Price' }, { name: 'item3', type: 'str', required: false, label: 'Item 3' }, { name: 'item3price', type: 'int', minValue: 0, maxValue: 99999999, required: false, label: 'Item 3 Price' }, { name: 'item4', type: 'str', required: false, label: 'Item 4' }, { name: 'item4price', type: 'int', minValue: 0, maxValue: 99999999, required: false, label: 'Item 4 Price' }, { name: 'item5', type: 'str', required: false, label: 'Item 5' }, { name: 'item5price', type: 'int', minValue: 0, maxValue: 99999999, required: false, label: 'Item 5 Price' }, { name: 'item6', type: 'str', required: false, label: 'Item 6' }, { name: 'item6price', type: 'int', minValue: 0, maxValue: 99999999, required: false, label: 'Item 6 Price' }, { name: 'item7', type: 'str', required: false, label: 'Item 7' }, { name: 'item7price', type: 'int', minValue: 0, maxValue: 99999999, required: false, label: 'Item 7 Price' }, { name: 'item8', type: 'str', required: false, label: 'Item 8' }, { name: 'item8price', type: 'int', minValue: 0, maxValue: 99999999, required: false, label: 'Item 8 Price' }, { name: 'item9', type: 'str', required: false, label: 'Item 9' }, { name: 'item9price', type: 'int', minValue: 0, maxValue: 99999999, required: false, label: 'Item 9 Price' }, { name: 'item10', type: 'str', required: false, label: 'Item 10' }, { name: 'item10price', type: 'int', minValue: 0, maxValue: 99999999, required: false, label: 'Item 10 Price' }, { name: 'item11', type: 'str', required: false, label: 'Item 11' }, { name: 'item11price', type: 'int', minValue: 0, maxValue: 99999999, required: false, label: 'Item 11 Price' }, { name: 'item12', type: 'str', required: false, label: 'Item 12' }, { name: 'item12price', type: 'int', minValue: 0, maxValue: 99999999, required: false, label: 'Item 12 Price' }, { name: 'item13', type: 'str', required: false, label: 'Item 13' }, { name: 'item13price', type: 'int', minValue: 0, maxValue: 99999999, required: false, label: 'Item 13 Price' }, { name: 'item14', type: 'str', required: false, label: 'Item 14' }, { name: 'item14price', type: 'int', minValue: 0, maxValue: 99999999, required: false, label: 'Item 14 Price' }, { name: 'item15', type: 'str', required: false, label: 'Item 15' }, { name: 'item15price', type: 'int', minValue: 0, maxValue: 99999999, required: false, label: 'Item 15 Price' }, { name: 'item16', type: 'str', required: false, label: 'Item 16' }, { name: 'item16price', type: 'int', minValue: 0, maxValue: 99999999, required: false, label: 'Item 16 Price' }, { name: 'item17', type: 'str', required: false, label: 'Item 17' }, { name: 'item17price', type: 'int', minValue: 0, maxValue: 99999999, required: false, label: 'Item 17 Price' }, { name: 'item18', type: 'str', required: false, label: 'Item 18' }, { name: 'item18price', type: 'int', minValue: 0, maxValue: 99999999, required: false, label: 'Item 18 Price' }, { name: 'item19', type: 'str', required: false, label: 'Item 19' }, { name: 'item19price', type: 'int', minValue: 0, maxValue: 99999999, required: false, label: 'Item 19 Price' }, { name: 'item20', type: 'str', required: false, label: 'Item 20' }, { name: 'item20price', type: 'int', minValue: 0, maxValue: 99999999, required: false, label: 'Item 20 Price' }, { name: 'item21', type: 'str', required: false, label: 'Item 21' }, { name: 'item21price', type: 'int', minValue: 0, maxValue: 99999999, required: false, label: 'Item 21 Price' }, { name: 'item22', type: 'str', required: false, label: 'Item 22' }, { name: 'item22price', type: 'int', minValue: 0, maxValue: 99999999, required: false, label: 'Item 22 Price' }, { name: 'item23', type: 'str', required: false, label: 'Item 23' }, { name: 'item23price', type: 'int', minValue: 0, maxValue: 99999999, required: false, label: 'Item 23 Price' }, { name: 'item24', type: 'str', required: false, label: 'Item 24' }, { name: 'item24price', type: 'int', minValue: 0, maxValue: 99999999, required: false, label: 'Item 24 Price' }, { name: 'item25', type: 'str', required: false, label: 'Item 25' }, { name: 'item25price', type: 'int', minValue: 0, maxValue: 99999999, required: false, label: 'Item 25 Price' }, { name: 'noticecolor', type: 'str', label: 'Notice Color (default: red)', defaultValue: '#9013FE' }, { name: 'noticebg', type: 'str', label: 'Notice Background Color (default: white)', defaultValue: '#ffffff' }, { name: 'chat_ad', type: 'int', minValue: 1, maxValue: 999, defaultValue: 1, label: 'Delay in minutes between notice being displayed (min 1)' } ]; cb.onEnter(user => { if (user['has_tokens'] && !user['in_fanclub'] && !user['is_mod'] && !fappyHour) { menuNotice(user['user'], 'menu'); } else if ((user['in_fanclub'] || user['is_mod'])) { menuNotice(user['user'], 'fanmenu'); } else if (fappyHour) { menuNotice(user['user'], 'fappymenu'); cb.setTimeout(() => { let fappyMessage = `***\n******\n*********\n************\n***************\nWelcome to FAPPY HOUR!\u00a0\u00a0\u00a0\nEnjoy my Fan Club tip menu until 9:30pm (Pacific Time)\u00a0\u00a0\u00a0\n***************\n************\n*********\n******\n***`; cb.sendNotice(fappyMessage, user['user'], gradient, '#ffffff', 'bold', ''); }, 1000); } }); cb.onTip(tip => { const fromUser = tip['from_user']; const isFanclub = tip['from_user_in_fanclub']; const isMod = tip['from_user_is_mod']; const tipAmount = parseInt(tip['amount']); if (isFanclub || isMod || fappyHour) { for (let i = 1; i <= MAXITEMS; i++) { if (tipAmount == Math.round(mip[i] * .6)) { cb.sendNotice(`${fromUser} tipped for ${mi[i]}\u00A0`, '', cb.settings['noticecolor'], cb.settings['noticebg'], 'bold', ''); } } } else { for (let i = 1; i <= MAXITEMS; i++) { if (tipAmount == mip[i]) { cb.sendNotice(`${fromUser} tipped for ${mi[i]}\u00A0`, '', cb.settings['noticecolor'], cb.settings['noticebg'], 'bold', ''); } } } cb.setTimeout(() => { cb.sendNotice(`${HEART} ${cb.settings.thanksM} ${HEART}\u00A0`, fromUser, cb.settings['noticebg'], cb.settings['noticecolor'], 'bold', ''); }, 500); }); cb.onMessage(msg => { const isMod = msg['is_mod']; const isModel = msg['user'] === cb.room_slug; const model = cb.settings['modelName']; const message = msg['m']; const user = msg['user']; if ((isMod || isModel) && message === '/fappyhour') { msg['X-Spam'] = true; fappyHourOnOff(); } if (message === '/fappyhourstatus') { msg['X-Spam'] = true; let fappyMessage = fappyHour ? `***************\nFappy Hour is currently in play\u00a0\u00a0\u00a0\n***************` : `***************\nFappy Hour has finished. Ask ${model} for details on the next Fappy Hour\u00a0\u00a0\u00a0\n***************`; cb.sendNotice(fappyMessage, user, gradient, '#ffffff', 'bold', ''); } if (message === '/fanmenu') { msg['X-Spam'] = true; menuNotice(user, 'fanmenu'); } if (message === '/menu') { msg['X-Spam'] = true; menuNotice(user, 'menu'); } return msg; }); // function chatAd() { // noticeFan(null, 'green'); // cb.setTimeout(chatAd, (cb.settings.chat_ad * 60000)); // } // cb.setTimeout(chatAd, (cb.settings.chat_ad * 60000)); function fappyHourOnOff() { let message = `***\n******\n*********\n************\n***************\n${fappyHour ? `Thanks for cumming to Fappy Hour!\nCum again, every Monday @ 8:30pm (Pacific Time)\u00a0\u00a0\u00a0` : `It’s FAPPY HOUR!\nEveryone gets a taste of my FanClub Tip Menu!\u00a0\u00a0\u00a0\nType /menu to view XO`}\n***************\n************\n*********\n******\n***`; cb.sendNotice(message, '', gradient, '#ffffff', 'bold', ''); fappyHour ? fappyHour = false : fappyHour = true; } function menuNotice(usr, type) { const fanMenu = type === 'fanmenu' ? true : false; const fappyMenu = type === 'fappymenu' ? true : false; cb.setTimeout(() => { cb.sendNotice( fanMenu ? messageIntroFan : fappyMenu ? messageIntroFappy : messageIntro, usr, fappyMenu ? '#410078' : cb.settings['noticecolor'], fappyMenu ? '#ffffff' : cb.settings['noticebg'], 'normal', '' ); }, 0); cb.setTimeout(() => { cb.sendNotice( fanMenu ? messageMenuFan : messageMenu, usr, fappyMenu ? gradient : cb.settings['noticebg'], fappyMenu ? '#ffffff' : cb.settings['noticecolor'], 'normal', '' ); }, 150); cb.setTimeout(() => { cb.sendNotice( messageOutro, usr, fappyMenu ? '#B00099' : cb.settings['noticecolor'], fappyMenu ? '#ffffff' : cb.settings['noticebg'], 'normal', '' ); }, 300); } function init() { let modelName; messageMenu = ''; messageMenuFan = ''; modelName = cb.settings['modelName'] ? cb.settings['modelName'] : cb.room_slug; fappyHour = cb.settings['fappyHour'] === 'yes' ? true : false; for (i = 0; i <= MAXSEP - 1; i++) { if (cb.settings['customsep']) { separator_char = `${cb.settings['customsep']}`; } else if (cb.settings['sepchar'] == separators[i].label) { separator_char = ` ${separators[i].shortcut} `; } } for (i = 1; i <= MAXITEMS; i++) { menuItem = cb.settings['item' + i]; menuItemPrice = cb.settings['item' + i + 'price']; mip[i] = menuItemPrice; mi[i] = menuItem; if (menuItem != '' && menuItem != null) { messageMenu += `${menuItem} (${menuItemPrice}) ${separator_char}\u00A0`; messageMenuFan += `${menuItem} (${Math.round(menuItemPrice * .6)}) ${separator_char}\u00A0`; } } messageIntro = `${separator_char} ${modelName}'s tip menu ${separator_char}\u00A0`; messageIntroFan = `${separator_char} ${modelName}'s FANS ONLY tip menu ${separator_char}\u00A0`; messageIntroFappy = `${separator_char} ${modelName}'s FAPPY HOUR tip menu ${separator_char}\u00A0`; messageOutro = `${separator_char} ${cb.settings.thanksM} ${separator_char}\u00A0`; } init();
© Copyright Chaturbate 2011- 2024. All Rights Reserved.