RealVotes
RealVotes
Voting system that allow users to execute commands using simple votes.
Server admin can configure votes for any command that can be typed in server console !
Sample votes :
- /vote sun to vote for sun
- /vote day to vote for day
- /vote ban player to vote for ban of a player when moderators are away
- /vote op to vote for the asking player to become op
- /vote anything : server admin can configure any wanted vote
Installation
- Download the RealVotes.jar file
- Create your plugins/RealVotes/config.txt file
- If you want to translate or customize your messages, create your plugins/RealVotes/messages.txt file
Permissions
generic permissions
- vote.list : can /vote (without args, for listing)
- vote.yes : player can /yes
- vote.no : player can /no
- vote.reload : player can /votereload your customized permissions :
- vote.votename : replace votename with vote id as defined into the configuration file
Configuration file
You MUST create this file in plugins/RealVotes/config.txt
day/night/sun votes of this default configuration files need Essentials to be installed !
Sample file :
time=15 reminders=2 ban: command=/ban $1 answer=3 answer=51% yes=3 yes=80% time=30 reminders=5 day: command=/time day $world answer=1% yes=100% night: command=/time night $world answer=33% yes=100% op: command=/op $player answer=10 answer=100% yes=100% sun: command=/weather $world sun answer=1% yes=100%
What does this example configuration ?
- day : Vote for day in current world
Vote is valid if at least 1% of players answer to the vote and 100% of voting players vote "yes".
Result is that if 1 player says "no", then the day will not come.
Default time players have to give their answer is 15 seconds, and 2 reminders will be displayed during the vote.
- sun : Vote for sun in current world
Same as for day.
- night : Vote for night in current world
Vote is valid if at least 33% of players answer to the vote and 100% of voting players vote "yes".
- ban : Vote for banning a player
First voter must use this command like this : /vote ban player.
Vote is valid if at least 3 players answer to the vote AND at least 51% of players answer AND at least 3 players vote "yes" AND at least 80% vote "yes".
Time players have to give their answer is 30 seconds, and 5 reminders will be displayed during the vote.
- op : Vote for a player becomming admin of the server
Vote is valid if at least 10 players answer to the vote AND 100% of the connected players answer yes.
Messages file
You may create this file in plugins/RealVotes/messages.txt
Sample file (french translation) :
+player votes for +vote: +remain seconds left=+player vote pour +vote: +remain secondes pour voter Only players can vote=Seuls les joueurs peuvent voter Unknown vote +vote=Vote inconnu +vote Vote for +vote: +remain seconds left=Vote pour +vote: +remain secondes pour voter Vote for +vote had no enough answers: only +count / +total=Vote pour +vote n'a pas assez de réponses: +count / +total Vote for +vote had no enough yes: only +count / +total=Vote pour +vote n'a pas assez de votes pour: +count / +total Vote for +vote in progress. You can't start another vote=Vote +vote en cours. Impossible de démarrer un autre vote Vote for +vote result is yes=Vote pour +vote accepté You can vote for +votes=Vous pouvez voter pour +votes You can vote with /yes or /no=Vous pouvez voter avec /yes ou /no You have nothing to vote for=Aucun vote en cours You vote no for +vote=Vous votez non pour +vote You vote yes for +vote=Vous votez oui pour +vote
What is missing (TODO)
- capability to configure multi-worlds votes (all are currently for player's current world only, even if effect is multi-worlds !)
- conditions for accepting a vote : no players on a worlds list, no players on a WorldGuard regions list. This to avoid setting day if you have DreamLands installed for example, or players on a roleplay region of your world where you don't allow votes to work, and you don't want the day to come out at the wrong time.
- anything else ?
-
View User Profile
-
Send Message
Posted Jun 21, 2012@Jason733i
That might be if they type /yes when there is no vote going.
-
View User Profile
-
Send Message
Posted Jun 17, 2012I'm seeing this error in my server.log file. I'm not sure what exactly caused it... I hope this helps!
2012-06-17 13:14:18 [SEVERE] null
org.bukkit.command.CommandException Unhandled exception executing command 'yes' in plugin RealVotes v0.04
at org.bukkit.command.PluginCommand.execute(PluginCommand.java:42)
at org.bukkit.command.SimpleCommandMap.dispatch(SimpleCommandMap.java:166)
at org.bukkit.craftbukkit.CraftServer.dispatchCommand(CraftServer.java:479)
at net.minecraft.server.NetServerHandler.handleCommand(NetServerHandler.java:821)
at net.minecraft.server.NetServerHandler.chat(NetServerHandler.java:781)
at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:764)
at net.minecraft.server.Packet3Chat.handle(Packet3Chat.java:34)
at net.minecraft.server.NetworkManager.b(NetworkManager.java:229)
at net.minecraft.server.NetServerHandler.a(NetServerHandler.java:113)
at net.minecraft.server.NetworkListenThread.a(NetworkListenThread.java:78)
at net.minecraft.server.MinecraftServer.w(MinecraftServer.java:567)
at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:459)
at net.minecraft.server.ThreadServerApplication.run(SourceFile:492)
Caused by: java.lang.NullPointerException
at fr.crafter.tickleman.realvotes.RealVotes.voteYes(RealVotes.java:363)
at fr.crafter.tickleman.realvotes.RealVotes.onCommand(RealVotes.java:215)
at org.bukkit.command.PluginCommand.execute(PluginCommand.java:40)
... 12 more
-
View User Profile
-
Send Message
Posted Jun 17, 2012@zestybaby
Without any error logs it's hard to say what your crash could be caused by.
-
View User Profile
-
Send Message
Posted Jun 15, 2012Really tiny and useful plugin to the server which the op didn't show up for the most time. And I have downloaded it and translate it to Simplified Chinese, you can see it at here:http://pastebin.com/AzTTrDhd Here's a bug report: when I just type /yes and the server will just got some crash in it, but the server can still running. Please check that problem. Thanks for your time.
-
View User Profile
-
Send Message
Posted Jun 14, 2012Don't going to update?...
-
View User Profile
-
Send Message
Posted Jun 5, 2012@dropposite
vote is the global one. It just isn't hidden properly from the results in the code.
$player is the player who casted the vote. If you want to pass an arguement for a player name use $1
@Mayhem777
I don't think I had this problem but I never used the $world parameter. I just get them to pass the world name to the plugin using a $1 parameter. So maybe it could have something to do with the $world parameter.
-
View User Profile
-
Send Message
Posted Jun 2, 2012I'm just using the default config, any vote launches the error, /vote day, works 1 time and then get buged (for example).
-
View User Profile
-
Send Message
Posted Jun 2, 2012i keep seeing 'vote' as one of the votes. so i removed all the votes from the config, and did a /vote, and its says "You can vote for Vote'...and of course /vote vote, does nothing....
Next issue is i took your sample config from the website and did a '/vote op playersname', and when the 100% vote was cast, it made me op instead....
-
View User Profile
-
Send Message
Posted Jun 1, 2012@Mayhem777
What did you put in your config file for the command that causes that and what plugin are you trying to issue the command for?
-
View User Profile
-
Send Message
Posted May 28, 2012No help? :(
-
View User Profile
-
Send Message
Posted May 27, 2012I use MC 1.2.5 and CBR.1.0 --->
27.05 18:18:37 [Server] INFO at net.minecraft.server.ThreadServerApplication.run(SourceFile:492)
27.05 18:18:37 [Server] INFO at net.minecraft.server.MinecraftServer.run(MinecraftServer.java:449)
27.05 18:18:37 [Server] INFO at net.minecraft.server.MinecraftServer.w(MinecraftServer.java:517)
27.05 18:18:37 [Server] INFO at org.bukkit.craftbukkit.scheduler.CraftScheduler.mainThreadHeartbeat(CraftScheduler.java:126)
27.05 18:18:37 [Server] INFO at fr.crafter.tickleman.realvotes.RealVotes$1.run(RealVotes.java:270)
27.05 18:18:37 [Server] INFO at fr.crafter.tickleman.realvotes.RealVotes.access$0(RealVotes.java:240)
27.05 18:18:37 [Server] INFO at fr.crafter.tickleman.realvotes.RealVotes.reminder(RealVotes.java:251)
27.05 18:18:37 [Server] INFO at fr.crafter.tickleman.realvotes.RealVotes.endVote(RealVotes.java:73)
27.05 18:18:37 [Server] INFO java.lang.ArithmeticException: / by zero
27.05 18:18:37 [Server] WARNING Task of 'RealVotes' generated an exception
27.05 18:18:35 [Server] INFO Jugadores conectados:Goty
27.05 18:18:22 [Server] INFO day null /time day $world : ans=null|1% yes=null|51% (nulls/null)
When i use any command i get this.
-
View User Profile
-
Send Message
Posted May 27, 2012Add iconomy support for votes please, this prevents players to spam votes :) thanks!
-
View User Profile
-
Send Message
Posted May 11, 2012@cutsogreen1
Use Command Helper http://wiki.sk89q.com/wiki/CommandHelper
-
View User Profile
-
Send Message
Posted May 10, 2012We've had problems with 3min - 2hr rollbacks if we don't save beforehand. If its easy to add I would be forever grateful if you added pauses and multiple command support.
I also think adding a whitelist option (use a whitelist.txt in the plugin folder) so only trusted players could use it would be good (seems easier then using permissions that's all :P)
-
View User Profile
-
Send Message
Posted May 9, 2012@cutsogreen1 Server is automatically saved, when you use /stop, no need for /save-all and /f save.
-
View User Profile
-
Send Message
Posted May 9, 2012Can this execute a list of commands in a specific order and with pauses?
I want to allow people to vote to restart the server. So it'd need to execute these commands in this order:
-
View User Profile
-
Send Message
Posted May 8, 2012Best voting plugin around!
But when somebody uses /yes or /no when there is no vote started, I get this error in console: http://paste2.org/p/2013730 and "An internal error occurred while attempting to perform this command" ingame.
-
View User Profile
-
Send Message
Posted Apr 29, 2012@CaptainSeasick
Maybe you should read the instructions above more carefully then. You have to create that file. It works perfectly fine.
-
View User Profile
-
Send Message
Posted Apr 29, 2012This thing ain't working for me. Says it can't load the "config.txt" in the console when trying to do a first-time start-up with the plugin. Kinda BS if you ask me, tbh...
-
View User Profile
-
Send Message
Posted Apr 25, 2012@tickleman1
You are welcome =) I love this plugin. I think it's simple enough to learn how to use to code plugins for me. I have been messing with it a little. I added in descriptions and detection of the proper number of arguments based on how many $ are in the command. I don't know if that's the best way. I doubt you would want my code though since I have somewhat mangled yours a bit and changed some things around.
Sorry to be a pain but is the current version what you have on github already?
Also, I think you are referring to their other plugin: http://wiki.sk89q.com/wiki/CommandHelper