Card Dealing Script

By vaseline28 on May 03, 2008

This randomly gives a selection of cards to the user prompting the script. E.g.:

!deal 12

**[GameMoglin ]** < No. of Cards Dealt:12 > < Cards:8 **King**10 8 10 4 **Queen** **Queen**4 6 8 7 > ```mirc on *:text:!Deal*:#: { if (($2 == $null) || ($2 <= 0)) { /msg $chan [4 $nick ] You need some cards to be dealt! | /halt } var -s %CardsDealt 0 while (%CardsDealt < $2) { inc %CardsDealt var %Cards $instok(%Cards,$rand(2,14),%CardsDealt,32) } var -s %Cards $replace(%Cards,11,Jack,12,Queen,13,King,14,Ace) msg $chan [4 $nick ] < No. of Cards Dealt:4 $2 > < Cards:4 %Cards > } ```

Comments

Sign in to comment.
tzar469   -  May 03, 2008

An idea is to message the suit of the cards as well. There are 4 Queens in a deck; which one do you have?

 Respond  
Are you sure you want to unfollow this person?
Are you sure you want to delete this?
Click "Unsubscribe" to stop receiving notices pertaining to this post.
Click "Subscribe" to resume notices pertaining to this post.