Inactive [MECH] Lightvote v1.73 - vote for day/night using commands, beds or items [1.1R5, 1.2.4]

Discussion in 'Inactive/Unsupported Plugins' started by Zarius, May 10, 2011.

  1. Offline

    Zarius

    Lightvote - any player can vote for day/night (based on xupwup's original Lightvote)
    Version: v1.73 (2012/03/02)

    Features:
    • Voting for both day and night
    • Sleeping in a bed starts/agrees to vote for day (optional)
    • Itemvote - vote for day/night by hitting a bed with a torch (configurable)
    • Itemvote - vote no by hitting dirt with a torch (configurable)
    • Permanent day or night (optional)
    • Reminders of vote in progress
    • Voting is disabled for a while after a vote
    • Inbuilt permission system - restrict voting to a subset of players
    • Basic multiworld support (still only world 0 for permanent time)
    Download: Download | Source (GitHub) | Bug/Feature Tracker

    Usage:
    /lvt day -- start/agree with vote for day (or vote no for a night vote)
    /lvt night -- start/agree with a vote for night (or vote no for a day vote)
    /lvt yes -- vote yes
    /lvt no -- vote no

    Configuration (open)

    The default config file looks like this:
    Code:
    # At least 'required-yes-percentage'*peopleOnServer people must vote yes, and there must be more people that voted yes than no
    # day
    required-yes-percentage-day 5
    minimum-agree-percentage-day 50
    # night
    required-yes-percentage-night 5
    minimum-agree-percentage-night 50
    vote-fail-delay 30
    vote-pass-delay 50
    vote-time 30
    reminders 2
    # enable bedvote (sleeping in a bed starts or agrees with a vote)
    bedvote yes
    # no commands - if this is enabled then all lightvote voting commands are disabled (bedvote or itemvote must be used)
    lightvote-nocommands no
    ##### Configure items for commandless voting (hitting 'itemhits' with 'iteminhand' starts/agrees/disagrees with a vote)
    # These are for starting a vote or agreeing to a vote in progress (day and night can be different if you want)
    itemVote yes
    bedvote-iteminhand-day TORCH
    bedvote-itemhits-day BED_BLOCK
    bedvote-iteminhand-night TORCH
    bedvote-itemhits-night BED_BLOCK
    # These are for disagreeing (voting no) with a vote in progress)
    bedvote-novote-iteminhand-day TORCH
    bedvote-novote-itemhits-day DIRT
    bedvote-novote-iteminhand-night TORCH
    bedvote-novote-itemhits-night DIRT
    debug-messages no
    permanent no
    use-permissions no
    The permissions file (plugins/LightVote/voteStarters.conf) consists of the names of players you wish to allow, separated by ONE space or newline. This is case insensitive. If I, for example, only want to allow myself and testuser1-3 to start votes, I could use the following config file.

    Code:
    xUpWuP testuser1 testuser2 testuser3
    If you just want everyone to be able to vote, as is the default, just use:

    Code:
    *
    Alternatively you can set "use-permissions" to yes and add the "lvt.vote.time" permission to users you want to be able to vote.

    The configuration files are in plugins/LightVote/LightVote.conf


    Changelog:

    Version 1.73 (2012/03/02)
    * updated for BukkitR5 new event system

    Version 1.72 (2011/07/27)
    * added start/join permissions (lvt.vote.time.join & lvt.vote.time.start) - start permission automatically grants join permission

    Version 1.71
    * removed debug message
    * default config includes use-permissions option now

    Older changes (open)
    Version 1.70
    * Added permissions support (enable in config and use "lvt.vote.time")
    * Added /lvt day & /lvt night commands to start or agree with a vote (or disagree as appropriate)
    * Fixed a bug with bedVote where it wouldn't work until you used a /lvt vote

    Version 1.68
    * Added option to disable itemVote.
    * Fixed bug where players could change day vote to night vote.

    Version 1.67
    * Vote message should be sent only to applicable world
    * Fixed vote start message to advise /lvt help when using lightvote-nocommands
    * Fixed count error in yes/no vote count

    Version 1.66

    * Added itemVote (hit item X with item Y in hand to vote yes/no for day/night)
    * Added lightvote-nocommands (disables /lvt start and /lvt yes/no to use only itemVote or bedVote)

    Version 1.65
    • Multiworld votes now only consider the players within the current world.
    Version 1.64
    • New feature: basic multiworld support - still only 1 vote at a time and only world 0 for permanent time.
    Version 1.63
    • New feature: bedvote. Sleeping in a bed at night starts or agrees to a vote for day. This can be turned off in the config file.
    Previous changes - see previous thread


    Todo:
    • Support for Permissions plugin. (done in 1.7)
    • Support for Bukkit SuperPerms
    • (Optional) Skip night cooldown - eg. every 5 (configurable) nights that are skipped the vote day command wont work until a full night has passed.
    • Vote /lvt day and /lvt night commands (I sometimes try these commands myself :)) (done in 1.7)
    • Bedvote: only start a vote when the player is asleep, rather than immediately upon entering the bed (if possible).
    • Weather? Both commands and gameplay (perhaps totems built to vote for rain, thunder, sun).
    • Allow simultaneous votes in different worlds (currently only one global vote at a time).
    • Voting in one world disables all voting for one minute (same issue as above) - fix this.
    • Customizable messages (thanks Hawtin)
    • Ignore NPC's
     
    Stassi, Hawtin, Linki and 1 other person like this.
  2. Offline

    Linki

    thanks for this Plugin :)
    and i've got one Question. Would it be possible to make a Plugin that works like LightVote, but is changing the weather?
    sorry for my english ;)
    Linki
     
  3. Offline

    Zarius

    I've been considering weather - bit of a tougher task though. BukkitVote does the weather but I'm trying to think of a non-command way to vote for the weather (for those that like commandless gaming).

    Thinking of requiring the player build a particular "totem" to call forth rain, thunderstorms or a sunny day and other players have to also click on the totem (or build their own and click on it) to agree to the vote.
     
  4. Offline

    Drei Gyuu

    Ah yes! exactly what I needed, since my beds apparently wont work our server.

    Thanks much for taking over the plugin!

    regards,
     
  5. Offline

    xupwup

    You might want to add [MECH] to your title, just like the original lightvote, I also doubt that your [ADMN] is correct.
     
  6. Offline

    Zarius

    Hmm, was thinking it was more administration but you're right, it's a game mechanic that's freeing up administration - will update to [MECH], thanks.
     
  7. Offline

    Plague

    Only use multiple version tags in the title if really needed.
     
  8. Offline

    Zarius

    Will do. Thanks for the move to releases.
     
  9. Offline

    rslink

    Can you add feature where they can only vote if in a bed? and not able to use the /lvt command
     
  10. Offline

    Zarius

    Good idea. Was planning on this after I worked out a good command-less way to vote for night but will put this option in early (when I get time).

    @rslink

    commandless option added - will probably need to tweak this and thinking of adding an option to require the bed for starting a vote only (ie. some servers may wish to allow the /lvt yes/no commands but disable /lvt start). Item voting added (default is to hit a bed with a torch for starting a vote or voting yes, and hitting dirt with a torch to vote no).

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: Jul 16, 2016
  11. Offline

    rslink

    @Zarius


    Thanks for that anyway to only send the messages to a certain world and/or a permissions node?
     
  12. Offline

    Zarius

    I have been wanting to send the message only to the world that the vote started in - is this what you meant? Permissions node would be trickier - I haven't worked with permissions before - not sure about this one.
     
  13. Offline

    rslink

    Yes, i have no idea either i was just asking.

    On my server there are two survival type worlds and having the message sent to both can get confusing. Great plugin non the less, thanks.
     
  14. Offline

    Zarius

    Updated - messages now only show in the world the vote takes place. Next (and harder) step is to separate the voting system so that you can have simultaneous votes (one for each world). I am aware that a successful vote in one world disables voting in all worlds for a period of time, quite a bit of source-code changes to fix this.
     
  15. Offline

    Hawtin

    @Zarius Customizable messages planned?
     
    Zarius likes this.
  16. Offline

    Zarius

    They are now :) Added to todo list.
     
  17. Offline

    Hawtin

    Thx :)
     
  18. Offline

    Legomaster98

    What is the command for Permanent day???
     
  19. THANK YOU FOR MULTI-WORLD!
    It helps sooo much.
     
  20. Offline

    xarrek

    Someone can help me disable Voteitem?
     
  21. Offline

    Rick

    even though "/lvt start" has started people can change it to "/lvt start night" during the voting process.
     
  22. Offline

    Zarius

    I haven't personally used the permanent day but I don't think there's a command. There is an option in the config file (plugins/LightVote/LightVote.conf) called "permanent" - set this to yes.

    Haven't made an option yet - will be next thing on the todo list.

    Thanks for the bug report - have located issue and next version will be fixed.

    New version out:

    Version 1.68
    * Added option to disable itemVote.
    * Fixed bug where players could change day vote to night vote.

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: Jul 16, 2016
  23. Permissions compatability would be nice, can't reload the server everytime someone donates...
     
  24. Offline

    Zarius

    Added permissions to the todo list.
     
  25. Offline

    xupwup

    You can also type /reload in the console which will reload all plugins, including this one.
     
  26. Offline

    Zarius

    Indeed, that's what I mostly use. Also, not sure when the official permissions support is due... might research that first.
     
  27. Offline

    ephesian

    what about vote to restart server?
     
  28. Offline

    Darcion

    i looked into my log and found a strange massage, the server runs fine after that:

    2011-05-25 15:15:51 [SEVERE] Exception in thread "Timer-2" 2011-05-25 15:15:51 [SEVERE] java.util.ConcurrentModificationException 2011-05-25 15:15:51 [SEVERE] at java.util.AbstractList$Itr.checkForComodification(Unknown Source) 2011-05-25 15:15:51 [SEVERE] at java.util.AbstractList$Itr.next(Unknown Source) 2011-05-25 15:15:51 [SEVERE] at org.bukkit.craftbukkit.CraftWorld.getPlayers(CraftWorld.java:538) 2011-05-25 15:15:51 [SEVERE] at org.bukkit.craftbukkit.CraftWorld.setFullTime(CraftWorld.java:437) 2011-05-25 15:15:51 [SEVERE] at org.bukkit.craftbukkit.CraftWorld.setTime(CraftWorld.java:426) 2011-05-25 15:15:51 [SEVERE] at nl.xupwup.LightVote.LVTPlayerListener.endVote(LVTPlayerListener.java:151) 2011-05-25 15:15:51 [SEVERE] at nl.xupwup.LightVote.LVTPlayerListener.access$2(LVTPlayerListener.java:119) 2011-05-25 15:15:51 [SEVERE] at nl.xupwup.LightVote.LVTPlayerListener$voteEnd.run(LVTPlayerListener.java:93) 2011-05-25 15:15:51 [SEVERE] at java.util.TimerThread.mainLoop(Unknown Source) 2011-05-25 15:15:51 [SEVERE] at java.util.TimerThread.run(Unknown Source)
     
  29. Offline

    Zarius

    Hmm... odd, I haven't seen that in mine. I'm running with a lot of plugins (see my signature) and upgraded to bukkit 803 yesterday with no problems. What plugins and bukkit version do you have? Any is there anything related happening just before this error? Has this error turned up only once?

    You mean reload plugins or restart completely? Think you can only restart if you're running a wrapper like rToolKit. Under what circumstances would you want players to be using this?

    EDIT by Moderator: merged posts, please use the edit button instead of double posting.
     
    Last edited by a moderator: Jul 16, 2016
  30. Offline

    ephesian

    say if server is lagging they can all vote to restart server.
     

Share This Page