Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- if ($1-2 == !set vote ) && ($nick isop $chan) && (%vote. [ $+ [ $chan ] ] == on) {
- set -g %voteoptions. [ $+ [ $chan ] ] $lower($3-)
- msg $chan your voting options are %voteoptions. [ $+ [ $chan ] ]
- }
- if ( $1 == !vote ) {
- if ( $2 == on ) && ( $nick isop $chan ) {
- msg $chan Voting has been turned on. !set vote option1 option2 option3 etc to set options. !vote to vote.
- set -u7200 %vote. [ $+ [ $chan ] ] on
- }
- elseif ( $2 == off ) && ($nick isop $chan) {
- msg $chan Voting has been turned off. Result:
- unset %vote. [ $+ [ $chan ] ]
- }
- elseif ($2 == results) && ($3 == $null) {
- ;code to find results and output
- }
- elseif ($2 != $null) {
- ;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
- if ($istok(%voteoptions. [ $+ [ $chan ] ],$lower($2),32)) {
- if (%votechoice. [ $+ [ $lower($2) ] == $null) {
- set -g %votechoice. [ $+ [ $lower($2) ] ]
- inc %votechoice. [ $+ [ $lower($2) ] ]
- }
- else {
- inc %votechoice. [ $+ [ $lower($2) ] ]
- }
- }
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement