Advertisement
Guest User

Untitled

a guest
Feb 26th, 2019
76
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
mIRC 1.17 KB | None | 0 0
  1.   if ($1-2 == !set vote ) && ($nick isop $chan) && (%vote. [ $+ [ $chan ] ] == on) {
  2.     set -g %voteoptions. [ $+ [ $chan ] ] $lower($3-)
  3.     msg $chan your voting options are %voteoptions. [ $+ [ $chan ] ]
  4.   }
  5.   if ( $1 == !vote ) {
  6.     if ( $2 == on ) && ( $nick isop $chan ) {
  7.       msg $chan Voting has been turned on. !set vote option1 option2 option3 etc to set options. !vote to vote.
  8.       set -u7200 %vote. [ $+ [ $chan ] ] on
  9.     }
  10.     elseif ( $2 == off ) && ($nick isop $chan) {
  11.       msg $chan Voting has been turned off. Result:
  12.       unset %vote. [ $+ [ $chan ] ]
  13.     }
  14.     elseif ($2 == results) && ($3 == $null) {
  15.       ;code to find results and output
  16.     }
  17.     elseif ($2 != $null) {
  18.       ;checks to see if what they typed was an option, if it is, check to see if it exists. if no, make it and inc it. If it does, inc it
  19.       if ($istok(%voteoptions. [ $+ [ $chan ] ],$lower($2),32)) {
  20.         if (%votechoice. [ $+ [ $lower($2) ] == $null) {
  21.           set -g %votechoice. [ $+ [ $lower($2) ] ]
  22.           inc %votechoice. [ $+ [ $lower($2) ] ]
  23.         }
  24.         else {
  25.           inc %votechoice. [ $+ [ $lower($2) ] ]
  26.         }
  27.       }
  28.     }
  29.   }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement