TimeControl [1.13.X - 1.20.X] icon

TimeControl [1.13.X - 1.20.X] -----

Control the length of day and night separately for each world! How much players have to sleep?



Big Update: Overhall/Enhancement of Sleeping Mechanics, Storm Behavior Changes
Changelog v4.0.0:

#Added: several options to inform players within a world of sleeping.
#Added: permission timecontrol.sleep.actionbar (default true) to receive sleep notifications via actionBar.
#Added: permission timecontrol.sleep.chat (default true) to receive sleep notifications via chat.

#Changed: storm duration will now be speed up by multiplying just like time in respect of the speed value to be more consistent.
#Changed: storms will no longer clear if night sleeping happened anytime but not till morning.
#Changed: storms will now be speed up also during night time.
#Changed: set command now shows valid range if an invalid value was tried to be set.
#Changed: renamed storm-time-subtrahend to sleeping-storm-time-multiplier.
#Changed: renamed sleeping-time-multiplier to sleeping-night-time-multiplier.
#Changed: renamed permission timecontrol.edit to timecontrol.set.
#Changed: renamed permissions timecontrol.change.[option] to timecontrol.set.[option].
#Changed: all existing entries of messages section were moved to section.cmd.
#Changed: default value of (now) sleeping-night-time-multiplier to 20.
#Changed: default value of (now) sleeping-storm-time-multiplier to 60.
#Changed: updated Essentials dependency to v2.18.0.
#Changed: updated commons code to v1.8.0.
#Changed: the credits (aka. my name) is now clickable and will open my profile page on spigot.
#Changed: sent messages make now use of the BaseComponent API which allows click events (like above) or hover events.
#Changed: commands are now easier to maintain.
#Changed: every (sub-)command will now generate its own help command.
#Changed: every (sub-)command will now generate its own usage message.

#Fixed: main config was not properly reloaded by command.

#Removed: messages.help.reload.
#Removed: messages.help.set.
#Removed: messages.help.debug.
#Removed: messages.help.uninstall.
#Removed: messages.setCmd.
#Removed: messages.wrongCmdUsage.

IMPORTANT: This update needs quite heavy editing of your current configurations.

In the default_world_settings section rename
- "sleeping-time-multiplier" to "sleeping-night-time-multiplier" and
- "storm-time-subtrahend" to "sleeping-storm-time-multiplier"

These renamings will result in a lose of those values for every world.

Edit your messages section to look like this:
Code (YAML):
messages:
  cmd
:
    credits
: "Use /timecontrol help for all available commands."
    help_header
: "List of all available commands:"
    noPerm
: "&4You do not have permission."
    wrongCmdUsagePrefix
: "&CUsage:"

  # Messages regarding the sleeping mechanics.
  # Available placeholders:
  ## %sleep_needed% - Amount of needed sleeping players. (not available for sleeping.actionBar.msg.success)
  ## %sleep_sleeping% - Amount of actual sleeping players. (not sleeping ignored in any way) (not available for sleeping.actionBar.msg.success)
  ## %player% - the player's displayed name. (only available in sleeping.chat.msg)
  sleeping
:
    actionBar
:
      enable
: true
      msg
:
        success
: "&eSweet dreams everyone!"
        progress
: "&e%sleep_sleeping% of %sleep_needed% players are sleeping."
    chat
:
      enable
: true
      msg
:
        enterBed
: "%player% is now sleeping. (%sleep_sleeping%/%sleep_needed%)"
        leaveBed
: "%player% left bed. (%sleep_sleeping%/%sleep_needed%)"


As you can see a lot of work was done before publishing this update. Let me give you some closing words:

Because I had to rewrite all commands I decided to not support changing the messages of all commands which I categorized as operator commands. If you really feel like you need one of the removed options, feel free to contact me.

This update is quite a monster I will admit and I am very glad to finally be able to publish it. However such large updates come with various different bug possibilities. I think I tested everything but you never know so please report bugs as soon as possible in the discussion section.

After finishing coding I felt like doing a proper wiki on github before editing the whole plugin's main page on spigot. I hope you like it - feel free to make any suggestions! TimeControl Wiki on GitHub

Best regards
Alex_qp

PS: @TheNutsOfRambo Sorry it took my so long but I had a whole code cleanup in mind before publishing the next update. I hope the changes suit your interests.
----------, Aug 12, 2020
Resource Information
Author:
----------
Total Downloads: 97
First Release: Sep 22, 2019
Last Update: May 30, 2024
Category: ---------------
All-Time Rating:
4 ratings
Version -----
Released: --------------------
Downloads: ------
Version Rating:
----------------------
-- ratings