Roleplaying Bartender
mIRC Code
+ 0 likes
Please Register to submit score.
| Average Score | 4.5 |
| Scores Submitted | 2 |
| Date Added | May 16, 2008 |
| Last Updated | May 24, 2008 |
| Tags | bartender play role roleplaying |
|
|
Introduction
Hopefully somone can help me expand on the bot, such as getting some Timers for the text (Mine don't want to work) and getting a Counter for Money so i can create a Tab for people. This is really my first work, so judge lightly! ^^;
*******UPDATE********
Alright, so i have the bot working, the tab system is perfect In my opinion, and everything SHOULD work properly. Just copy the new code, and paste it in the Remote section of your script.
WHAT THIS BOT DOES: Now what this little bugger does is he greets people when they come in, giving them several options on what they can do. He not only serves people Drinks, but he also keeps track of how much they owe, and won't give them a drink if they owe too much. It has the options of Paying, Checking your tab, Making their tabs, and getting a list of drinks
The drinks in the bot are as follows: Bloodwine, Ale, Hotchocolate, Redwine, Whitewine, Water, Milk, Mead, Rum, Dragonsbreath, Angelskiss, Sake, Devilstit and Nekoblood.
Enjoy the bot, and have fun. I will make improvements from time to time, adding things like an Ice Option for each drink, things like that.
mIRC Snippet:
Roleplaying Bartender
Posted on May 16, 2008 11:33 am
Posted on May 16, 2008 11:33 am
Use describe $chan instead of msg $chan :)
Things like these are more fun when you describe them :D
Things like these are more fun when you describe them :D
mIRC Snippet:
Roleplaying Bartender
Posted on May 16, 2008 11:48 am
Posted on May 16, 2008 11:48 am
| Quote: |
Hopefully somone can help me expand on the bot, such as getting some Timers for the text (Mine don't want to work) and getting a Counter for Money so i can create a Tab for people. |
For the timers:
| Code: |
On *:TEXT:?Timer*:?: { Timer NumberOfHowManyTimesItHasToRepeat NumberOfHowFastItHasToRepeat(Seconds) } |
Example:
| Code: |
On *:TEXT:?sayhi*:?: { timer 2 5 msg $chan Hai! } |
This would repeat 2 times each 5 seconds¨
For the counter:
| Code: |
On *:TEXT:!pay*:#: { inc %Payment msg $chan Thanks for paying $nick $+ ! msg $chan The number of people who have paid me: %Payment } |
U can use anything else for ' %Payment ' But make sure % is in front of it.
Next time, try using /help. It solves like 80% of the questions :)
mIRC Snippet:
Roleplaying Bartender
Posted on May 16, 2008 2:03 pm
Posted on May 16, 2008 2:03 pm
Help solves 99% of questions, you just need to know where to look and understand the syntax :P
mIRC Snippet:
Roleplaying Bartender
Posted on May 16, 2008 2:22 pm
Posted on May 16, 2008 2:22 pm
Hehe jonesy44 ^-^
Not really 99% because i've already had problems I couldn't find in the help file :D
I used the hawkee forums <3
Not really 99% because i've already had problems I couldn't find in the help file :D
I used the hawkee forums <3
mIRC Snippet:
Roleplaying Bartender
Posted on May 16, 2008 3:21 pm
Posted on May 16, 2008 3:21 pm
yeah not bad.. :):) i agree with criminal... using describe instead of msg would make it alot better
mIRC Snippet:
Roleplaying Bartender
Posted on May 16, 2008 11:38 pm
Posted on May 16, 2008 11:38 pm
So Describe is the eqivilant of using a /me or Action type of text? Cool o.o
As for the Payment thing, what i really want to do is assign each drink with its own value, and every time someone buys a drink, it adds that much to their tab, and using !pay they get rid of their tab and reset the counter for them.
And if i do end up making this, if i wanted to restrict people's tabs from going over a certain amount of money, wouldn't it go something like
if (%tab >= 100) say Oye, your tab is to high, pay me before you ask for more!
As for the Payment thing, what i really want to do is assign each drink with its own value, and every time someone buys a drink, it adds that much to their tab, and using !pay they get rid of their tab and reset the counter for them.
And if i do end up making this, if i wanted to restrict people's tabs from going over a certain amount of money, wouldn't it go something like
if (%tab >= 100) say Oye, your tab is to high, pay me before you ask for more!
mIRC Snippet:
Roleplaying Bartender
Posted on May 17, 2008 2:33 am
Posted on May 17, 2008 2:33 am
* Snoopy whistles [/code] :P lol
mIRC Snippet:
Roleplaying Bartender
Posted on May 17, 2008 2:38 am
Posted on May 17, 2008 2:38 am
Yeah, forgot.
Can you delete the comment, Israfel? :)
Can you delete the comment, Israfel? :)
mIRC Snippet:
Roleplaying Bartender
Posted on May 17, 2008 10:43 am
Posted on May 17, 2008 10:43 am
| Code: |
On *:TEXT:!ale*:#: { if (%tab. [ $+ [ $address($nick,2) ] ] >= 100) { .notice $nick Oya, your tab is to high, pay me before you ask more! .halt } Else { .msg $chan Ohai have fun with the ale ... .inc %tab. [ $+ [ $address($nick,2) ] ] 10 .notice $nick You have $calc(100 - %tab. [ $+ [ $address($nick,2) ] ]) tabs remaining } } |
If you want to change the amount of tabs he receives, just change the 10 to a number you want ( line 8 )
mIRC Snippet:
Roleplaying Bartender
Posted on May 18, 2008 12:41 pm
Posted on May 18, 2008 12:41 pm
So what the above code should do, is create a Tab system for each person using their Nicknames/Addresses? And would i have to impliment this into EVERY one of the different options? Other then that, how exactly would i go about increasing the Tab value by more then one?
mIRC Snippet:
Roleplaying Bartender
Posted on May 18, 2008 2:41 pm
Posted on May 18, 2008 2:41 pm
If you want to increase more than one just use ' inc % number '.
(Replace number with a number of your choice ofcourse and % with the variable you want)
What the code does is uhm... How would I explain..
I'm sorry if you don't understand the following, i'm dutch.
If someone triggers the command, it'll check how many tabs he has, if it's above 100, it will notice him ' Oya, your tab is to high, pay me before you ask more ' and it'll halt.
If the tabs are under 100 it'll message the chan saying ' Ohai have fun with the ale ... ' + It increases his tabs with 10 + it calcs how many tabs he has remaining.
So in your case.. add
under each On Text event ( this checks how many tabs he has, if above 100, halts )
(Replace number with a number of your choice ofcourse and % with the variable you want)
What the code does is uhm... How would I explain..
I'm sorry if you don't understand the following, i'm dutch.
If someone triggers the command, it'll check how many tabs he has, if it's above 100, it will notice him ' Oya, your tab is to high, pay me before you ask more ' and it'll halt.
If the tabs are under 100 it'll message the chan saying ' Ohai have fun with the ale ... ' + It increases his tabs with 10 + it calcs how many tabs he has remaining.
So in your case.. add
| Code: |
if (%tab. [ $+ [ $nick ] ] >= 100) { .notice $nick Oya, your tab is to high, pay me before you ask more! .halt |
under each On Text event ( this checks how many tabs he has, if above 100, halts )
mIRC Snippet:
Roleplaying Bartender
Posted on May 19, 2008 12:18 pm
Posted on May 19, 2008 12:18 pm
Ok thanks, i'll post a Report on how it works ^^
As a side note, none of my timers work, i just get "unknown command 1" If i have the timer set as .timer 1 2 /me do this OR .timer 1 2 describe $chan Does This
Regardless, it keeps saying Unknown Command 1. I am building the script for Oasiz, so if anyone is more fammiler with their style of coding then that would be most helpful ^^
And if i wanted it to say different things based on how much they had would i write
As a side note, none of my timers work, i just get "unknown command 1" If i have the timer set as .timer 1 2 /me do this OR .timer 1 2 describe $chan Does This
Regardless, it keeps saying Unknown Command 1. I am building the script for Oasiz, so if anyone is more fammiler with their style of coding then that would be most helpful ^^
And if i wanted it to say different things based on how much they had would i write
| Code: |
| If (%tab. [ $+ [ $address($nick,2) ] ] < 33){ .notice %nick Your tab is pretty low, so don't worry about it too much } If (%tab. [ $+ [ $address($nick,2) ] ] = 34 - 66) { .notice $nick Your tab is getting up there, you might want to slow down a little } Else (%tab. [ $+ [ $address($nick,2) ] ] > 67) { .notice $nick Wow mate, your tab is getting really high, you had best pay soon so you don't embarras yourself. } |
mIRC Snippet:
Roleplaying Bartender
Posted on May 20, 2008 5:00 am
Posted on May 20, 2008 5:00 am
****Update****
Well, i finally got my timers working properly, so the bot runs MUCH smoother now, But i have a few coding problems:
Alright, so i have been trying to get the bot to give me a Tab (There seems to be come confusion about what a Tab is. A tab is essentially a Credit Card. buy your drinks now, but you pay for them later. The Tab refers to how much is owed)
now my problem is that using the %tab variable puts it as a generic variable so someone who didn't order a drink, would have a tab, and such. So how would i write an individual tab for everyone? I am not sure, but would it be something like:
And then for adding to the tab each time they buy a drink
And for paying the tab
Or am I WAY off? I checked the Help Section, and it didn't.. Well give me much help...
Well, i finally got my timers working properly, so the bot runs MUCH smoother now, But i have a few coding problems:
Alright, so i have been trying to get the bot to give me a Tab (There seems to be come confusion about what a Tab is. A tab is essentially a Credit Card. buy your drinks now, but you pay for them later. The Tab refers to how much is owed)
now my problem is that using the %tab variable puts it as a generic variable so someone who didn't order a drink, would have a tab, and such. So how would i write an individual tab for everyone? I am not sure, but would it be something like:
| Code: |
On *:JOIN:#: .Write $nick %tab 0 |
And then for adding to the tab each time they buy a drink
| Code: |
On *:TEXT:!Ale:#: .describe $chan Here you go, some fresh Ale .Read $nick .inc %tab 5 .notice $nick your tab has reached (.Read $nick(%tab)) |
And for paying the tab
| Code: |
.describe $chan Takes the money happily .write $nick %tab 0 .notice $nick Your tab has been erased, Thank you! |
Or am I WAY off? I checked the Help Section, and it didn't.. Well give me much help...
mIRC Snippet:
Roleplaying Bartender
Posted on May 20, 2008 6:06 am
Posted on May 20, 2008 6:06 am
ive been working on the sale sort of thing so i thought id post so you can see the timers i use. i had to post in the forum
mIRC Snippet:
Roleplaying Bartender
Posted on May 20, 2008 11:51 am
Posted on May 20, 2008 11:51 am
*****Update 2!*****
alright, i have almost everything working. The bot .Notice's people when they come in and tells them about the system, the commands to use the like. i have the Drink list set up, the drinks themselves set up, even the Tabs and Payment system! I have to give PunkTuReD the credit for being able to keep the Tabs system, so i greatly thank you :P
the only thing that ISN't working right now is my "Limit" system, ergo if someone reaches a certain limit in money (100 silver) then it cuts them off until they pay the bill. I can show you the code
So the part that i am having trouble with is the
Part. Even if these people have a tab of 642 it still lets them buy drinks! Its maddening! I mean, whats the point of having a payment system if you can't force people to use it!!
So i will break down parts of it so you get the general idea of whats going on
Ok, so when someone types !bloodwine it checks their tab to see if its over 100, if it is, it denies them the drink until they pay for their other drinks. If they have a tab under 100 (Even 99 works) then it gives them the drink, and adds money to their tab (in this case 7 silver) then it adds a 1 to a Total's value, which will tell people the total number of drinks ever served on this script. It then .Notice's them and tells them what their tab is currently at (Something i will embellish later)
So here is my delema one more time. The bot gives people drinks even though i tell it not to, any tips or tricks on what i may need done?
alright, i have almost everything working. The bot .Notice's people when they come in and tells them about the system, the commands to use the like. i have the Drink list set up, the drinks themselves set up, even the Tabs and Payment system! I have to give PunkTuReD the credit for being able to keep the Tabs system, so i greatly thank you :P
the only thing that ISN't working right now is my "Limit" system, ergo if someone reaches a certain limit in money (100 silver) then it cuts them off until they pay the bill. I can show you the code
| Code: |
On *:TEXT:!Bloodwine:#: { if (% $+ $nick > = 100) { .Describe $chan ~The bartender shakes his head and continues wiping down his glasses, "Sorry there $nick you have racked up too high of a tab. I can't serve you anymore untill you pay me." } Else { describe $Chan ~ He grasps a large glass from under the counter, a large flat base pointing into a long thin stem, branching out in an elegant pattern to support a large bowel. kneeling down he then lifted a large bottle, wrapped in cord to the bar top, drilling a>> .timer 1 2 describe $Chan ~ Corkscrew inside the bottle. Lifting the bottle off the counter, he began pouring the crimson liquid into the glass, letting it settle before sliding it over to the drinker, "Hope that satisfies ya. I'll put it on your tab."<D> .inc % $+ $nick 7 .Inc %total .timer 1 3 .notice $nick you have a % $+ $nick silver tab running } } |
So the part that i am having trouble with is the
| Code: |
if (% $+ $nick > = 100) { .Describe $chan ~The bartender shakes his head and continues wiping down his glasses, "Sorry there $nick you have racked up too high of a tab. I can't serve you anymore until you pay me." } |
Part. Even if these people have a tab of 642 it still lets them buy drinks! Its maddening! I mean, whats the point of having a payment system if you can't force people to use it!!
So i will break down parts of it so you get the general idea of whats going on
Ok, so when someone types !bloodwine it checks their tab to see if its over 100, if it is, it denies them the drink until they pay for their other drinks. If they have a tab under 100 (Even 99 works) then it gives them the drink, and adds money to their tab (in this case 7 silver) then it adds a 1 to a Total's value, which will tell people the total number of drinks ever served on this script. It then .Notice's them and tells them what their tab is currently at (Something i will embellish later)
So here is my delema one more time. The bot gives people drinks even though i tell it not to, any tips or tricks on what i may need done?
mIRC Snippet:
Roleplaying Bartender
Posted on May 20, 2008 11:47 pm
Posted on May 20, 2008 11:47 pm
Lol? You can't be serious
That's exactly the same what I said ... lame
Make a menu? why should I help if you don't even try to listen
That's exactly the same what I said ... lame
| Quote: |
So here is my delema one more time. The bot gives people drinks even though i tell it not to, any tips or tricks on what i may need done? |
Make a menu? why should I help if you don't even try to listen
mIRC Snippet:
Roleplaying Bartender
Posted on May 21, 2008 5:49 am
Posted on May 21, 2008 5:49 am
try this
russelb helped me with something similar
the 2 there in $($+(%,$nick),2)
checks the setting of the variable
if u replace it with a 1
it checks the name of the variable
| Code: |
if (!bloodwine isin $$1) && ($($+(%,$nick),2) >= 100 ) { msg $chan The bartender shakes his head and continues wiping down his glasses, "Sorry there $nick you have racked up too high of a tab. I can't serve you anymore until you pay me." } |
russelb helped me with something similar
the 2 there in $($+(%,$nick),2)
checks the setting of the variable
if u replace it with a 1
it checks the name of the variable
mIRC Snippet:
Roleplaying Bartender
Posted on May 21, 2008 12:12 pm
Posted on May 21, 2008 12:12 pm
Criminal, i ment based on the Tab system. I am using a different system then the one you were showing me, so it won't work the same.
mIRC Snippet:
Roleplaying Bartender
Posted on May 21, 2008 1:44 pm
Posted on May 21, 2008 1:44 pm
You want something like a ... Creditcard or so?
Try the following
| Quote: |
if (% $+ $nick > = 100) { .Describe $chan ~The bartender shakes his head and continues wiping down his glasses, "Sorry there $nick you have racked up too high of a tab. I can't serve you anymore until you pay me." } |
Try the following
| Quote: |
if (% [ $+ [ $nick ] ] > = 100) { .Describe $chan ~The bartender shakes his head and continues wiping down his glasses, "Sorry there $nick you have racked up too high of a tab. I can't serve you anymore until you pay me." } |
mIRC Snippet:
Roleplaying Bartender
Posted on May 22, 2008 11:47 am
Posted on May 22, 2008 11:47 am
Yeah, thats almost identical to what i am using now.
sorry if i seem like an idiot.. I literally know nothing about Scripting x.x
That and i am going through a major breakup, sooo life aint on my side atm <<
sorry if i seem like an idiot.. I literally know nothing about Scripting x.x
That and i am going through a major breakup, sooo life aint on my side atm <<
mIRC Snippet:
Roleplaying Bartender
Posted on May 26, 2008 3:16 am
Posted on May 26, 2008 3:16 am
try
| Code: |
if ($($+(%,$nick),2) > = 100) { .Describe $chan ~The bartender shakes his head and continues wiping down his glasses, "Sorry there $nick you have racked up too high of a tab. I can't serve you anymore until you pay me." } |








