Rock Paper Scissors Game
mIRC Code
+ 0 likes
Please Register to submit score.
| Average Score | 0.0 (of 0 scores) |
| Date Added | Nov 05, 2008 |
| Last Updated | Nov 05, 2008 |
| Tags | game paper rock rps scissors |
Introduction
Update 11/05/08:
- Bug fixed: In his older version, he used "isin $1" which allowed people to type something like"!rockpaperscissors i" and actually have "i" recognized as a legitimate choice. I've fixed this problem by changing the isin to regex.
- Shortened command: The previous command was "!rockpaperscissors". With my new regex update, I can shorten the command to "!rps" or whatever you like.
Update 2 11/05/08:
- Added score tracking
mIRC Snippet:
Rock Paper Scissors Game
Posted on Nov 5, 2008 11:09 pm
Posted on Nov 5, 2008 11:09 pm
you could just use $istok
or for the regex this will work
| Code: |
| if (!$istok(rock paper scissors,$2,32)) { |
or for the regex this will work
| Code: |
| if (!$regex($2,/^(rock|paper|scissors)$/i)) { |
mIRC Snippet:
Rock Paper Scissors Game
Posted on Nov 5, 2008 11:15 pm
Posted on Nov 5, 2008 11:15 pm
I am not sure if that will work, but thanks for the comment anyways.
Edit: Does not seem to work.
Edit: Does not seem to work.
mIRC Snippet:
Rock Paper Scissors Game
Posted on Nov 5, 2008 11:36 pm
Posted on Nov 5, 2008 11:36 pm
it works fine for me
instead of this line
you can use
or
they both work just fine.
instead of this line
| Code: |
| if ($calc( $regex( $2 ,rock) + $regex( $2 ,paper) + $regex( $2 ,scissors) ) != 1) { msg $chan [4 $+ $nick $+ ] You've got to choose Rock, Paper or Scissors! | halt } |
you can use
| Code: |
| if (!$regex($2,/^(rock|paper|scissors)$/i)) { msg $chan [4 $+ $nick $+ ] You've got to choose Rock, Paper or Scissors! | halt } |
or
| Code: |
| if (!$istok(rock paper scissors,$2,32)) { msg $chan [4 $+ $nick $+ ] You've got to choose Rock, Paper or Scissors! | halt } |
they both work just fine.
mIRC Snippet:
Rock Paper Scissors Game
Posted on Nov 6, 2008 7:00 am
Posted on Nov 6, 2008 7:00 am
can you put this game with a timer?60 seconds?the player picks and 60 seconds after the scipt give the answer
thanks
thanks





