All day or all of the night Plugin 1.7.2

Updated: May 27, 2015 | 231 views |

http://img.niceminecraft.net/BukkitPlugin/All%20day%20or%20all%20of%20the%20night1.jpg

What it does

All day or all of the night allows servers to set worlds to only run in a specified part of the day. You can make it always day, or always night.

Features

  • Enable/disable on per world basis
  • Set the start and end times the world stays within
  • Configure how often the plugin checks the time
  • Created in response to this request: NoNight, and because I wasn’t happy with the supplied and somewhat limited solution?

I’m content to be with you in the daytime
Girl I want to be with you all of the time
The only time I feel alright is by your side
Girl I want to be with you all of the nighttime
All day or all of the night
All day or all of the night
All day or all of the night

Installation

Add the AllDayAlNight.jar file to your server’s plugins directory and start up the server. A config file will be created automatically with the default values. Use the in-game or console commands to enable worlds and change settings.

How it works

  1. Once a world is enabled in the config, time switching occurs automatically
  2. The default settings allow the day to run as normal, then at dusk (12000 ticks) it automatically sets the time to dawn (0 ticks)
  3. To make it always night, set dawn to 12500 and dusk to 23500

Commands

  • /adan toggle [world] [true|false] ? turns AllDayAlNight on or off for the specified world
  • /adan dawn [world] [time] ? sets the lower time limit in the specified world
  • /adan dusk [world] [time] ? sets the upper time limit in the specified world
  • /adan check_every [time] ? sets how often the plugin checks to see what the time is

Permissions

alldayallnight.admin ? allows a player to edit the AllDayAllNight config ? default: OP

Config

There is one main configuration section:

worlds:

Within the worlds configuration is a list of world names (these are automatically generated when the plugin starts up). A world section looks like:

worlds:
    allday:
        enabled: true
        dawn: 0
        dusk: 12000
    allnight:
        enabled: true
        dawn: 12500
        dusk: 23500

  • enabled can be true or false
  • dawn is a number between 0 and 24000, where 0 is dawn, 6000 midday, 12000 dusk, 12500 night and 18000 midnight
  • dusk is a number between 0 and 24000, where 0 is dawn, 6000 midday, 12000 dusk, 12500 night and 18000 midnight

There is also a config key for how often the plugin checks to see whether it should change the time

check_every: 1200

The default is 1200 ticks or every minute. The plugin will only change the time if the current time falls outside of the range specified in the world config settings (dawn/dusk)

Change log

v1.0.1

  • compiled against Bukkit 1.7.2

v1.0

  • Initial release

Source code

GitHub repository

All day or all of the night Plugin 1.7.2 Download Links

http://www.dl2.9minecraft.net/index.php?act=dl&id=1388990999

http://www.dl5.9minecraft.net/index.php?act=dl&id=1389016493


Credits: eccentricnz