[INACTIVE][FIX/MECH] properTime v1.8.9 - Control the speed of time (+multiworld) [1000]

Discussion in 'Inactive/Unsupported Plugins' started by xupwup, Jan 29, 2011.

  1. Offline

    xupwup

    properTime - Control the speed of time, for example to fix too long days/nights due to lag.
    Version: 1.8.9

    THIS PLUGIN HAS BEEN DISCONTINUED. See here for the continuation of this plugin.

    On many servers, lag causes the time to pass extremely slow, so I created a fix.

    properTime runs in a dedicated thread, so it wont really be affected by lag.
    By default this plugin makes sure that the day/night cycle lasts exactly 20 minutes.

    If desired you can change this, so that it always runs at half speed, or -10 times as fast, causing the time to go backwards really fast :). Please note that this will cause the sun/moon to jerk, this can only be fixed with a client mod.
    This plugin is also compatible with other time changing plugins, however, I advise against using it in combination with time stopping plugins. It also works fine with beds.

    Sample config file:
    Code:
    # Use 2 for double speed, 3 for triple, etc.
    # At 1x speed, the complete day-night cycle takes 20 minutes.
    
    world: "nether"
    timespeedDay: 1.0 #these settings will be ignored because perma > 0
    timespeedNight: 1.0
    timespeedDusk: 1.0
    timespeedDawn: 1.0
    perma: 15000 # the time will always be 15000, which is at night. Use a value between 0 (sunrise) and 24000.
    
    world: "world"
    timespeedDay: 5.0
    timespeedNight: 5.0
    timespeedDusk: 1.0
    timespeedDawn: 1.0
    perma: -1 # less than 0, so will be ignored
    Normally day lasts 10 minutes, dawn + dusk 1.5, and night 7.
    If you want your day to last 12 minutes, you should set timespeedDay to 10/12 = 0.833

    Also, when freezing time, if you set the time to somewhere during dusk or dawn, the light will flicker for the client. I advise against this.

    Features:
    • Configurable time speeds
    • Dedicated thread (so lag proof)
    • Separate configuration for day, night, dawn, dusk
    • Multiworld support (the plugin that creates the secondary worlds needs to load before properTime)
    • Permanent day/night
    • Ability to freeze time.

    To make sure that properTime loads after your multiworld plugin: (thanks to @tehbeard)
    Open properTime.jar with a program like winrar, and edit the plugin.yml file inside. Add the following code to it:
    Code:
    softdepend: [MultiVerse]
    In this example properTime will load after MultiVerse. Do this for any multiworld plugin you use. (note: you need the name of the multi world plugin as stated in it's own plugin.yml)

    World "foo" not found
    Make sure your plugins load in the correct order. You can also try to remove or rename your config file, so that it is regenerated with the correct worldnames and syntax.

    Troubleshooting
    First of all, carefully read all errors, as well as the last few comments on this thread. If that does not fix your problem, try adding "debug" to the top of your config file. That way the plugin will give you a lot of information, some of which may be useful for finding out what is wrong.


    Download: http://www.xupwup.nl/data/games/minecraft/properTime.jar
    Source: Inside the jar.
    Please also vote on the poll here so I have a better idea about the popularity of my plugin.

    Changelog:
    Show Spoiler

    Version 1.8.9
    • Sources are now inside the jar file. No other changes.
    Version 1.8.8
    • Open sourced!
    • Different synchronisation with the main thread, this should fix concurrentModificationException errors.
    Version 1.8.7
    • Use the bukkit scheduler to set the time from a thread. (should fix concurrentModificationException errors)
    Version 1.8.6
    • Added debugging functionality that can be enabled by putting the word "debug" somewhere in your config file, preferably at the top.
    Version 1.8.5
    • The parser now supports world names with spaces.
    • (A bit) nicer error messages.
    Version 1.8.4
    • Fixed stupid mistake where it said 2400 instead of 24000, causing a lot of weirdness when using the perma option.
    Version 1.8.3
    • Fixed a bug in the parser that caused nullpointer exceptions for some files.
    • Added the "perma" option for configuring permanent day/night.
    Version 1.8.2
    • Fixed bug that caused values below 1 to get rounded to 0, causing the time to stop for those that use a timespeed less than 1.
    Version 1.8.1
    • Fixed nullpointerexception when stopping the server when an invalid config file has been used.
    Version 1.8
    • Added multiworld support
    Version 1.7
    • Fixed compatibility with newer bukkit versions
    • The config file is now located at: plugins/properTime/properTime.conf
    Version 1.6
    • If the client would jump to for example dusk, the server will use the timespeed for dusk, so if you set your day speed to 0.25, and the dusk speed to 1, this will fix the flicker during the few seconds when the client wants to go to dusk, and the server still says day. This should not change anything if you use timespeeds >= 1.
    Version 1.5.1
    • Fixed namespace, see this.
    Version 1.5
    • Fixed compatibility with newer bukkit versions
    • You can now configure what world this plugin should work on. (only one is supported and this is not in the default config file)
    Version 1.4
    • Added the ability to configure timespeeds for dusk/dawn.
    Version 1.3
    • Fix compatibility with newer bukkit versions.
    Version 1.2
    • Added the ability to configure timespeeds for day/night independently.
    Version 1.1
    • Renamed properties file + location
    Version 1.0
    • Initial release



    I got bored with minecraft a while ago, and now I also got bored with maintaining my plugins. That means that there will be no more feature updates by me. If you want to take over this plugin, please send me a pm on this forum and I will answer your questions, put a link here to your version etc.
     
  2. Offline

    Arcwolf

    true and I have no problem holding off updating. Example, I was running pre Halloween server and client up until 1.2 Beta update. But that solution only delays the inevitable and does not resolve the issue of this plugin needing an update. Hence my post. So I patiently await an update.
     
  3. Offline

    GDorn

    This plugin will cease to work as of CraftBukkit 449 (heretofore referred to as inb4pitchforks).

    If it were open-source, I'd fork it and fix it, but I can't.
     
  4. Offline

    Ovocean

    You mean you'd contact the author, ask him if he's still maintaining it and if he is, propose him to push a patch?
    Forking is a bad thing for the community (creates confusion, divides contributors) and is not respectful to the current maintainer(s). You need a very good reason to fork.
    Unless by "forking" you meant "branching" ?

    That said, I'm entirely for freed code. It'd be a laudable move. :)
     
  5. Offline

    xupwup

    That is why properTime is not opensource. I will make it opensource when I stop maintaining it.

    I also updated properTime to v1.7, which fixes compatibility with craftbukkit 450 and up. I also moved the config file to plugins/properTime/properTime.conf
     
  6. Offline

    Arcwolf

    Awesome, one of the few plugins that I have left broken on my server. Much appreciated xupwup! ... now to go check on elevators thread ... <shuffles off to other side of forum>
     
  7. Offline

    GDorn

    I'm using the word 'fork' the way it is used on github, where forking followed by submitting pull requests is the way you contribute patches back to the original project.

    Forking is good. Forking improves code.
     
  8. I love you man !
    Greetings from the #2 french community ! 4000 members in love with your plugin ;)
     
  9. Offline

    Rhythmatic

    DESPERATELY needs multiworld support.
     
  10. Offline

    xupwup

    It has multiworld support, at least, you can select which world you want it to work on. Do you want this to work multiple worlds at the same time? If so, that is not possible. I might fix that if people want this, so if you do, please reply.

    If you just want to select the world, put this in your config file, where a is the id of the world you want it to work on, starting with 0
    Code:
    worldid: a
     
  11. Offline

    jwideman

    Can this at least affect all worlds the same?
     
  12. I tried to change client side time with addon "Daylight savings" http://www.minecraftforum.net/viewtopic.php?f=1032&t=181084 but it didn't help the case. Works for singleplayer but i think server also sends speed at which sun travels. What i did was set DaylightSavings day speed to 1/3x and propertime config all values 0.3333 and still saw it as laggy as without DaylightSavings. Sun moves normal 1x speed and then bounces back to match server time.

    So what i suspect is that this mod is forcibly setting time to constant value but is not touching the actual time speed value. Fix please? :)
     
  13. Offline

    jwideman

    Yep, that's strictly a client mod. And you probably shouldn't try to run both together. SMP day is controlled by the server, and the client just tries to keep up. So what you describe is exactly what you should expect.
     
  14. Offline

    Johannes

    I would love to have multiworld support.

    You should change the settings file to be something like the yaml files that permissions uses, so it would be set up like this:
    Code:
    times:
      world:                 # name of the world
        - Day: 2.0
        - Night: 0.5
        - Dusk: 1.0
        - Dawn: 1.0
      creative:
        - Day: -1.0          # -1 means it will always be this time.
      survival:
        - Day: 1.0
        - Night: 4.0
        - Dusk: 2.0
        - Dawn: 2.0
    
    In the above example if the user also had a world titled 'nether' its time would be the default 1.0 for everything since it's not defined in the file.
     
  15. Offline

    Kainzo

    Heres an important question - does this make the world 'lag' as well? or does it keep it actually turning nicely as if it were night -> day transition?
     
  16. Offline

    xupwup

    Saying something is important does not make it important. Also, I believe your question has already been answered in page 2 of this topic. Please read through all pages, or at least a few of them, before asking questions. And especially do not mark that message as important when it clearly isn't.

    Nice, I will see what I can do.
     
  17. Offline

    Kainzo

    English? Dear god man - What's important to me might not be 'important' to you and vice versa - take it with a grain of thought, mkay.

    This wouldnt be an issue if it was clearly stated in post 1 - i wont be skimming through pages to find what should have been posted correctly in the topic.
     
  18. Offline

    maxsteele

    I have to wonder though, if a server is lagging so much that it's unplayable because the day / night cycle isn't working properly, isn't this plugin just enabling people to run sub-standard servers that shouldn't be running in the first place? I see that as detrimental to the Minecraft server population.
     
  19. Offline

    xupwup

    Updated to v1.8
    Added multiworld support.
    Your old config file will not work anymore, so please delete it and let it be recreated by the plugin.
     
  20. A very nice plugin ..... and very much appreciated. I did have a small problem where, when loading, propertime said it couldn't find my worlds. By renaming the propertime.jar to zpropertime.jar, it loaded last after the worldwarp plugin (seems bukkit loads plugins alphabetically ), which always seemed to load my worlds, after that, the config file didn't come up with any errors. I'm assuming I am missing something about when worlds get loaded into bukkit ? ....... however, this 'fix' works fine for me. Thanks again for a very good plugin.
     
  21. Offline

    arthoz

    Bugs out here, its currently stuck at the same point of time constantly, sun moves a little bit than hops right back.

    It probably started at high loads and ~20 users, but its still stuck now with 2 users

    config:
    Code:
    world: world
    timespeedDay: 0.5
    timespeedNight: 1.0
    timespeedDusk: 1.0
    timespeedDawn: 1.0
    
    
     
  22. Offline

    CuZnDragon

    I have upgraded to the current recommended craftbukkit 493 and properTime is causing the sun to stay at the point of just after dawn in a infinite loop.

    Same config as above but for regular world and nether.
     
  23. Offline

    xupwup

    Apparently the added worlds are loaded by (in my case) nethergate, so if my plugin starts before that, those worlds will not be found. I cant really think of a way to fix this, other than how you fixed it.
    It did not have anything to do with high load, just a mistake I made. Fixed in v1.8.2.
     
  24. Offline

    Spyro

    What should I do if I want to set daytime forever?
     
  25. Offline

    xupwup

    You could wait for day and then set timespeedday to 0. If I were you though I would look for another plugin, because this one is not really meant to stop time. My other plugin, LightVote, can stop time, and allows your users to vote if they want night. I think that plugin is a bit closer to what you want.
     
  26. Offline

    Spyro

    Thanks :)
     
  27. Offline

    Legolas75893

    Wait. So how can you make it so night does seem infinite?
     
  28. Offline

    davr

    Yeah, I would like the same thing -- I want to make it permanently night in my nether world (eg black fog instead of blue fog, until there's a client fix that supports the red fog)
     
  29. Offline

    xupwup

    Mmh, so that is a feature request... I wont be implementing that this week (holiday, etc.), so you are going to have to wait for that.

    Until then, you should wait for it to turn night. When it is fully dark, stop the server, modify your propertime.conf and set your timespeednight to 0, then restart the server. That way it will remain night forever.
     
  30. Offline

    Eddiekins

    If I set timespeedDay to 0 could that make the day infinite?
     
  31. Offline

    xupwup

    Yes.
     

Share This Page