rendered paste bodyON *:TEXT:!setpoll*:#:{ if (%pollX [ $+ [ $chan ] ] == ON) { notice $nick There is already a poll... Please Wait | halt }
else {
set %maker $+ $chan $nick
set %channn $+ $chan $chan
set %poll $+ $chan $2-
set %pollX $+ $chan ON
set %yes $+ $chan 0
set %no $+ $chan 0
set %neither $+ $chan 0
unset %pollN [ $+ [ $chan ] ]
msg $chan $+ %maker [ $+ [ $chan ] ] has just set a poll for %channn [ $+ [ $chan ] ] $+ . Type !Yes to vote yes, !No to vote no, or !neither if you just dont care. The Poll: %poll [ $+ [ $chan ] ] | msg $chan $+ %j
}
}
ON *:TEXT:!finish*:#:{
if (%maker [ $+ [ $chan ] ] == $null) { notice $nick How can you end a poll that isnt there? | halt }
if ($nick == %maker [ $+ [ $chan ] ]) {
unset %maker $+ $chan
unset %channn $+ $chan
unset %poll $+ $chan
unset %pollX $+ $chan
unset %voted*
set %pollN $+ $chan OFF
msg $chan The poll for $chan $+ . Final Reasults: Yes: %yes [ $+ [ $chan ] ] No: %no [ $+ [ $chan ] ] Neither: %neither [ $+ [ $chan ] ]
unset %yes [ $+ [ $chan ] ]
unset %no [ $+ [ $chan ] ]
unset %neither [ $+ [ $chan ] ]
}
else { notice $nick Are you %maker [ $+ [ $chan ] ] $+ ? Didnt Think so
}
}
ON *:TEXT:!yes:#:{
if (%pollN [ $+ [ $chan ] ] == OFF) { notice $nick There is no poll right now. | halt }
if (%voted [ $+ [ $chan ] ] == $nick $+ Yes $+ $chan) && (%pollX [ $+ [ $chan ] ] == ON) { notice $nick Shame on you, you have already voted! | halt
if ($chan == %channn [ $+ [ $chan ] ]) && (%pollX [ $+ [ $chan ] ] == ON) }
set %yes [ $+ [ $chan ] ] $calc( %yes [ $+ [ $chan ] ] + 1 )
set %voted $+ $chan $nick $+ Yes $+ $chan
notice $nick Thank you for voting Yes $nick $+ , Total Yes votes: %yes [ $+ [ $chan ] ]
}
ON *:TEXT:!no:#:{
if (%pollN [ $+ [ $chan ] ] == OFF) { notice $nick There is no poll right now. | halt }
if (%voted [ $+ [ $chan ] ] == $nick $+ Yes $+ $chan) && (%pollX [ $+ [ $chan ] ] == ON) { notice $nick Shame on you, you have already voted! | halt
if ($chan == %channn [ $+ [ $chan ] ]) && (%pollX [ $+ [ $chan ] ] == ON) }
set %no [ $+ [ $chan ] ] $calc( %no [ $+ [ $chan ] ] + 1 )
set %voted $+ $chan $nick $+ Yes $+ $chan
notice $nick Thank you for voting No $nick $+ , Total No votes: %no [ $+ [ $chan ] ]
}
ON *:TEXT:!poll:#:{
if (%poll [ $+ [ $chan ] ] == $null) { notice $nick There is no Set poll. }
else { notice $nick The Poll is: %poll [ $+ [ $chan ] ] }
}
ON *:TEXT:!yesvotes:#:{ if (%yes [ $+ [ $chan ] ] == $null) { notice $nick There is no set poll. }
else { notice $nick There are a total of: %yes [ $+ [ $chan ] ] yes votes. }
}
ON *:TEXT:!novotes:#:{
if (%no [ $+ [ $chan ] ] == $null) { notice $nick There is no set poll. }
else { notice $nick There are a total of: %no [ $+ [ $chan ] ] no votes. }
}
ON *:TEXT:!neither:#:{
if (%pollN [ $+ [ $chan ] ] == OFF) { notice $nick There is no set poll. | halt }
if (%voted [ $+ [ $chan ] ] == $nick $+ Yes $+ $chan) && (%pollX [ $+ [ $chan ] ] == ON) { notice $nick Shame on you, you have already voted! | halt
if ($chan == %channn [ $+ [ $chan ] ]) && (%pollX [ $+ [ $chan ] ] == ON) }
set %neither [ $+ [ $chan ] ] $calc( %no [ $+ [ $chan ] ] + 1 )
set %voted $+ $chan $nick $+ Yes $+ $chan
notice $nick Thank you for voting neither $nick $+ , Total neither votes: %neither [ $+ [ $chan ] ]
}
ON *:TEXT:!neithervotes:#:{
if (%neither[ $+ [ $chan ] ] == $null) { notice $nick There is no set poll. }
else { notice $nick There are a total of: %neither [ $+ [ $chan ] ] neither votes. }
}
ON *:TEXT:!results:#:{ if (%pollX [ $+ [ $chan ] ] == ON) { notice $nick Current Reasults: Yes: %yes [ $+ [ $chan ] ] No: %no [ $+ [ $chan ] ] Neither: %neither [ $+ [ $chan ] ] }
else { if (%pollN [ $+ [ $chan ] ] == OFF) { notice $nick There is no set poll.
}
}
}