mIRC Homepage
Posted By: pauls74462 onjoin bartender script - 03/12/09 02:38 AM
I'm needing help on making a onjoin script where ti will serve a drink upon welcuming a nick to the channel.

Drinks in a text file will be great.

Drinks will be randomly served to the nick.

Please help. mIRC scripts is not my specialty.

Pauls74462
Posted By: Riamus2 Re: onjoin bartender script - 03/12/09 02:53 AM
Code:
on *:join:#yourchannel: {
  if ($nick != $me) { msg $chan Here $nick $+ ! Have a $read(Drinks.txt) $+ . }
}


Put Drinks.txt with drinks (one per line) in your mIRC dir alone with the script and you're set.
Posted By: pauls74462 Re: onjoin bartender script - 03/12/09 04:23 AM
Originally Posted By: Riamus2
Code:
on *:join:#yourchannel: {
  if ($nick != $me) { msg $chan Here $nick $+ ! Have a $read(Drinks.txt) $+ . }
}


Put Drinks.txt with drinks (one per line) in your mIRC dir alone with the script and you're set.


Thanks it works great.

It shows up as:

[22:14] <Pauls74462> Here Grult! Have a Jade Isle.

I like it to show up as:

* Pauls74462 offers Johnl8374 a Jade Isle & and toasts #Channel IRC!
Posted By: RusselB Re: onjoin bartender script - 03/12/09 05:15 AM
replace msg with describe
Posted By: pauls74462 Re: onjoin bartender script - 03/12/09 05:51 AM
Thanks all who had input, it's working.

BTW: when I go out I'm the designated drinker! hehehe


Pauls74462
Posted By: 5618 Re: onjoin bartender script - 03/12/09 06:48 AM
Originally Posted By: Riamus2
Code:
on *:join:#yourchannel: {
  if ($nick != $me) { msg $chan Here $nick $+ ! Have a $read(Drinks.txt) $+ . }
}

Maybe some constructive criticism, as found in /help Event Prefixes ?
Code:
on !*:JOIN:#yourchannel: describe $chan Here $nick $+ ! Have a $read(Drinks.txt) $+ .
Posted By: Tomao Re: onjoin bartender script - 03/12/09 07:58 AM
They're the same difference, except an if statement is omitted.
Posted By: 5618 Re: onjoin bartender script - 03/12/09 11:01 AM
Originally Posted By: Tomao
They're the same difference, except an if statement is omitted.

That's my whole point. ;-)
A shorter script is a happy script.
Posted By: Riamus2 Re: onjoin bartender script - 03/12/09 01:27 PM
Thanks. I knew there was a prefix, but I'm at work and don't have access to the help file to remember it and it's not a check I normally have to do in my scripts, so I never remember what it is. smile
© mIRC Discussion Forums