Vote system

By Chrizzy on Aug 06, 2006

This is a simple vote system, type !vote to start a vote.. Then type !yes or !no to vote.. And !stopvote to stop it if needed.
You can only vote once and only the person started the vote can stop it or you :)

Replace "OWNER NICK" with you're nick.
Type ?vote_chan #chan to set the channel the vote script will run on
Type ?reset_vote to reset the number of votes started

Im not that good with mirc scripting so go easy on me :)
Any bugs etc please let me know

Comments

Sign in to comment.
ZabuzaMomochi   -  Aug 08, 2006

Very nice.

 Respond  
Noutrious   -  Aug 07, 2006

Ofcourse, replace all the OWNER NICK with $ownerip_votechan and i think better could be results with percents too... Anyway, much to do..

 Respond  
Noutrious   -  Aug 07, 2006

reset vote:
on *:TEXT:?reset_vote:%votechan:{
if ($address($nick,2) == $ownerip_votechan) {
unset %votenr
notice $nick 12 Done 12
}
else halt
}

 Respond  
Noutrious   -  Aug 07, 2006

;For the start, this would be better for some security reasons..
alias ownerip_votechan {
;Replace YOUR_IP_ADDRESS_HERE with your IP address.
.var %OWNERIP = YOUR_IP_ADDRESS_HERE
.return %OWNERIP
}

on :TEXT:?vote_chan:#:{
if ($address(nick,2) == $ownerip_votechan) && ($2) {
set %votechan $2
unset %vote
unset %voted
unset %yesvote
unset %novote
unset %votes
unset %voteq
timer99 off
notice $nick 12 Done 12
}
elseif ($address(nick,2) != $ownerip_votechan) { /msg $nick Sorry, you dont have admin privilegies. } else { /msg $nick Sorry, you didnt tell me the vote chan. | halt }
}

 Respond  
Smokey   -  Aug 06, 2006

Make the ownersnick a variable that you can set.

 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.