Bots Home
|
Create an App
testinthings
Author:
hidden_nikki
Description
Source Code
Launch Bot
Current Users
Created by:
Hidden_Nikki
/* Title: "Tip Menu Plus" bot Author: badbadbubba Version: 1.0.0c (01/14/2016) - Changed to double dash separator 1.0.1 Use data structure for separator graphic 1.0.2 Added new heart and smiley separator 1.0.3 (09/07/16) Improved error checking and reporting for missing double dash and missing menu items 1.0.4 (09/08/16) Added text character separators */ var HEART = '\u2665'; // ♥ BDIAMOND = '\u2666'; // ♦ BSTAR = '\u2605'; // ★ var tip_amt = 0; var separator_char = "| "; var msg; var MAXITEMS=10; var tipmenuprice = []; var tipmenuitem= []; var MAXSEP = 9; 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: '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"}, {name:'item1', type:'str', label:'Item 1 (eg 10--flash tits)',}, {name:'item2', type:'str', required: false, label:'Item 2',}, {name:'item3', type:'str', required: false, label:'Item 3',}, {name:'item4', type:'str', required: false, label:'Item 4',}, {name:'item5', type:'str', required: false, label:'Item 5',}, {name:'item6', type:'str', required: false, label:'Item 6',}, {name:'item7', type:'str', required: false, label:'Item 7',}, {name:'item8', type:'str', required: false, label:'Item 8',}, {name:'item9', type:'str', required: false, label:'Item 9',}, {name:'item10', type:'str', required: false, label:'Item 10',}, {name:'noticecolor', type:'str', label:'Notice color (html code default red #FF0000)', defaultValue: '#FF0000'}, {name: 'chat_ad', type:'int', minValue: 1, maxValue: 999, defaultValue: 1, label: 'Delay in minutes between notice being displayed (minimum 1)'} ]; cb.onTip(function (tip) { tip_amt=parseInt(tip['amount']); for (var i = 1; i <= MAXITEMS; i++) { if (tip_amt == tipmenuprice[i]) { cb.sendNotice(tip['from_user'] + ' tipped for ' + tipmenuitem[i],'','',cb.settings['noticecolor'],'bold'); } } }); function chatAd() { if (msg!='Tip Menu: ') { cb.sendNotice(msg,'','',cb.settings['noticecolor'],'bold'); } cb.setTimeout(chatAd, (cb.settings.chat_ad * 60000)); } cb.setTimeout(chatAd, (cb.settings.chat_ad * 60000)); function init() { for (i=0;i<=MAXSEP-1;i++) { if (cb.settings['sepchar'] == separators[i].label) { separator_char = separators[i].shortcut + ' '; } } msg = 'Tip Menu: '; for (i=1;i<=MAXITEMS;i++) { var tmp; tmp=cb.settings['item' + i]; if (tmp) { var arr= tmp.split('--'); if (arr[1]===undefined) { cb.sendNotice('Error-You need two dashes to separate the tip amount and menu item for item no '+ i,'','',cb.settings['noticecolor'],'bold'); } else { var amt=parseInt(arr[0]); if (amt>0) { tipmenuprice[i]=amt; tipmenuitem[i]=arr[1]; if (i>=2) { msg += separator_char; } msg += arr[1] + '(' + amt + ') '; } } } } if (msg!= 'Tip Menu: ') { cb.sendNotice(msg,'','',cb.settings['noticecolor'],'bold'); } else { cb.sendNotice('Error-No menu items found','','',cb.settings['noticecolor'],'bold'); } } init(); var data = { "dad_jokes": "What time did the man go to the dentist? Tooth hurt-y.|I'm reading a book about anti-gravity. It's impossible to put down!|You're American when you go into the bathroom, and you're American when you come out, but do you know what you are while you're in there? European.|Did you know the first French fries weren't actually cooked in France? They were cooked in Greece.|Want to hear a joke about a piece of paper? Never mind... it's tearable.|I just watched a documentary about beavers. It was the best dam show I ever saw!|If you see a robbery at an Apple Store does that make you an iWitness?|Spring is here! I got so excited I wet my plants!|A ham sandwich walks into a bar and orders a beer. The bartender says, \"Sorry we don’t serve food here.\"|What’s Forrest Gump’s password? 1forrest1|Why did the Clydesdale give the pony a glass of water? Because he was a little horse!|CASHIER: \"Would you like the milk in a bag, sir?\" DAD: \"No, just leave it in the carton!’”|Did you hear about the guy who invented Lifesavers? They say he made a mint.|I bought some shoes from a drug dealer. I don't know what he laced them with, but I was tripping all day!|Why do chicken coops only have two doors? Because if they had four, they would be chicken sedans!|What do you call a factory that sells passable products? A satisfactory.|KID: \"Hey, I was thinking… \" DAD: \"I thought I smelled something burning.”|How do you make a Kleenex dance? Put a little boogie in it!|A termite walks into a bar and asks, \"Is the bar tender here?\"|When a dad drives past a graveyard: Did you know that's a popular cemetery? Yep, people are just dying to get in there!|Two peanuts were walking down the street. One was a salted.|FAST FOOD WORKER: \"Any condiments?\" DAD: \"Compliments? You look very nice today!”|Why did the invisible man turn down the job offer? He couldn't see himself doing it.|I used to have a job at a calendar factory but I got the sack because I took a couple of days off.|A woman is on trial for beating her husband to death with his guitar collection. Judge says, \"First offender?\" She says, \"No, first a Gibson! Then a Fender!”|How do you make holy water? You boil the hell out of it.|A three-legged dog walks into a bar and says to the bartender, \"I’m looking for the man who shot my paw.\"|When you ask a dad if he's alright: \"No, I’m half left.”|I had a dream that I was a muffler last night. I woke up exhausted!|GROCERY STORE CHECKER: \"Paper or plastic?\" DAD: \"Either, I’m bisacktual.”|How do you tell the difference between a frog and a horny toad? A frog says, \"Ribbit, ribbit\" and a horny toad says, \"Rub it, rub it.”|Did you hear the news? FedEx and UPS are merging. They’re going to go by the name Fed-Up from now on.|5/4 of people admit that they’re bad with fractions.|MOM: \"How do I look?\" DAD: \"With your eyes.\"|What is Beethoven’s favorite fruit? A ba-na-na-na.|What did the horse say after it tripped? \"Help! I’ve fallen and I can’t giddyup!”|Two guys walk into a bar, the third one ducks.|What do you call a masturbating cow? Beef Stroganoff.|Did you hear about the circus fire? It was in tents!|Don't trust atoms. They make up everything!|What do you call a cow with two legs? Lean beef. If the cow has no legs, then it’s ground beef.|What do you get when you cross an elephant with a rhino? Elephino.|How many tickles does it take to make an octopus laugh? Ten-tickles.|I’m only familiar with 25 letters in the English language. I don’t know why.|When an ambulance zips past with its siren blaring: \"They won’t sell much ice cream driving that fast.”|When a dad drives past a cow pasture: LOOK! That cow is OUT-STANDING in his field!|What's the best part about living in Switzerland? I don't know, but the flag is a big plus.|What do prisoners use to call each other? Cell phones.|Why couldn't the bike standup by itself? It was two tired.|What do you call a dog that can do magic? A Labracadabrador.|Why didn't the vampire attack Taylor Swift? She had bad blood.|WAITRESS: \"Soup or salad?\" DAD: \"I don’t want a SUPER salad, I want a regular salad.”|The fattest knight at King Arthur’s round table was Sir Cumference. He acquired his size from too much pi.|Did you see they made round bails of hay illegal in Wisconsin? It’s because the cows weren’t getting a square meal.|NURSE: \"Blood type?\" DAD: \"Red.\"|SERVER: \"Sorry about your wait.\" DAD: \"Are you saying I’m fat?”|KID: \"Dad, make me a sandwich!\" DAD: \"Poof, you’re a sandwich!”|What do you call a fish with two knees? A “two-knee” fish.|You know what the loudest pet you can get is? A trumpet.|I was interrogated over the theft of a cheese toastie. Man, they really grilled me.|What do you get when you cross a snowman with a vampire? Frostbite.|What do you call a deer with no eyes? No idea!|Can February March? No, but April May!|What do you call a lonely cheese? Provolone.|Why can't you hear a pterodactyl go to the bathroom? Because the pee is silent.|When you ask a dad if they got a haircut: \"No, I got them all cut!\"|What does a zombie vegetarian eat? “GRRRAAAAAIIIINNNNS!”|What does an angry pepper do? It gets jalapeño your face.|Why wasn't the woman happy with the velcro she bought? It was a total ripoff.|What did the buffalo say to his son when he dropped him off at school? Bison.|What do you call someone with no body and no nose? Nobody knows.|Where did the college-aged vampire like to shop? Forever 21.|You heard of that new band 1023MB? They're good but they haven't got a gig yet.|DAD, TO A SINGER: \"Don’t forget a bucket.\" SINGER: \"Why? \"DAD: \"To carry your tune.\"|Why did the crab never share? Because he's shellfish.", "compliments": "The next time you see someone greeting a little girl, pay attention to what they say to her. \"You’re so pretty!” \"I love your dress!” \"Look how beautiful you are!”|While these things are kind and well-intended, \"pretty” does nothing but fade and lay the foundation to keep desiring that which we first received reward and praise for.|(So here are 30 other things I hope I’ll tell my daughter one day, things I hope she’ll want to be praised and rewarded for more than what she looks like.)||1. I love that you choose to be whoever you want to be, even if I don’t always like it, even if it’s not what I’d choose, even if it isn’t my taste or aligned with my opinion, I hope you always have the guts to not only be what other people want — even if it is me.|2. You are the kindest person I know.|3. You make me so happy, just for being around.|4. I’m so proud of you for trying. I don’t care what comes out of it, what you get from things doesn’t matter much anyway. It’s doing them that’s important.|5. I consider your feelings equal to mine, not a burden to me. Feeling strongly about something is very important (even if we have to work on how you get all those feelings out sometimes…)|13. You’re a bad ass football player and I think you should try out for the team and I think you should be a linebacker and I don’t know what those ones do but I think you have what it takes to do whatever it is they do. (I’m kidding, do whatever you want.)|14. I love what you painted, I think it looks great. Next time let’s do it on paper.|15. I think you’re brave for being honest.|16. I admire how well you play pretend, I was never great at it, will you teach me how to do it better?|17. Thank you for spending time with me.|18. You were so patient with me today, even when I was taking a long time and doing boring stuff. Thank you.|19. You deserve it.|20. You’re much more capable than you give yourself credit for.|21. You taught me something new today.|22. I think you’re meant for big things, and I think \"big things” are whatever make you feel really good, and I think \"good” is whatever makes you want to jump out of bed in the morning and start doing it, even if it’s not always easy.|23. You crack me up." } cb.onTip(function(tip) { var amt = parseInt(tip['amount']) if (amt === cb.settings.joke_cost) msg_joke() if (amt === cb.settings.compliment_cost) msg_compliment() if (amt === cb.settings.clothes_cost) msg_clothes_on() }) function msg_joke() { var dad_jokes = data.dad_jokes.split('|') var rint = Math.floor(dad_jokes.length * Math.random()) var joke = dad_jokes[rint] msg(joke) } function msg_compliment() { var compliments = data.compliments.split('|') var rint = Math.floor(compliments.length * Math.random()) var compliment = compliments[rint] msg(compliment) } function msg_clothes_on() { msg('Honey, please put your clothes back on!') } function msg(m) { cb.sendNotice(m) } cb.settings_choices = [{ name: 'joke_cost', type: 'int', minValue: 1, maxValue: 99999, label: "Tokens for a Dad joke" }, { name: 'clothes_cost', type: 'int', minValue: 1, maxValue: 99999, label: "Tokens for Dad bot to request model to put her clothes back on." }, { name: 'compliment_cost', type: 'int', minValue: 1, maxValue: 99999, label: "Tokens for Dad bot to give a compliment." }]
© Copyright Chaturbate 2011- 2026. All Rights Reserved.