Control Minecraft’s day-night cycle using a simple config file, choosing either to set length for day and night in minutes (can be configured independently), or synchronize with system clock.
No base classes are modified, no ASM/mixin transformations and no touching tick lengths.
For years when playing the game I yearned for a way to make days longer, without breaking other mods, dimensions and who else knows what.
No other mod that tried to implement a similar feature satisfied me.
This is my extremely simplistic attempt, without modifying any mechanics, the one exception being reliance on the vanilla "doDaylightCycle" rule being off.
/time command works, sleeping works (the mod lets vanilla handle sleep)
Note: Quark's "Improved Sleeping" feature breaks sleeping with this mod because Quark does it's own shenanigans. (the feature can be safely disabled in it's config)
Check out Morpheus, it seems to work https://www.curseforge.com/minecraft/mc-mods/morpheus
There is also compatibility with Comforts and Vampirism's day sleeping
There is an operator/cheats-enabled command to update cycle lengths in-game
/timecontrol get < sync_to_system_time | night_length_minutes | day_length_minutes >
/timecontrol set < night_length_minutes | day_length_minutes > <value>
At this time it works with both multiplayer and singleplayer (must be installed on both), but on Dedicated Servers due to possible ping and ticks per second discrepancies slight skybox jitter may be noticeable.
The mod relies on a custom gamerule (the mod will take care of this - the vanilla way of course), "doDaylightCycle_tc". It is possible to set it to false and the vanilla rule to true to stop the mod from doing anything! System clock sync option will operate regardless, so turn it off in the config if you want to do anything with time. Forge's config reloading on a live instance is supported in 1.15.2+ (can be finicky, but that's just how it detects live filesystem changes), except for system sync - this requires a restart.
FAQ
Q: Forge?
A: Forge.
Q: Can I include your mod in a video?
A: As long as you include a link to the mod/modpack (if it happens to be in one), absolutely
Q: Can I add your mod to a modpack?
A: As long as it's on CurseForge, yes.
P.S.
If you don't feel confident enough about my mod and may have also been "hurt" by all the previously existing mods attempting to give control to daylight cycle length:
I've been playing with this mod I made since 1.12.2, always in heavily modded packs (200+ mods) on a multiplayer server. This should be a vanilla feature in my opinion.
Thank you for this! I tried many other mods, and all of them broke my game in various unwanted ways. From hidden timers to glitchy time stopping, I thought that all mods that try this were broken. Thank you for proving me wrong!
In reply to project_aleph:
Heck yes. This needed to be a thing!
Hello, my sun/moon stays on default time and then every 20 ticks it twitches to system time, i want it to stay on system time, am i doing something wrong?
In reply to xjeroen_slx:
Are you using it on a server? It needs to have the same settings in both config files, on client and server.
How to reverse effects? i removed the mod but time is acting weird and sometimes it freezes
In reply to iobiarg:
The only thing the mod changes when it's installed is the vanilla doDaylightCycle rule, as long as you remove the jar file, you can simply toggle the gamerule to your desired value and it'll be back to vanilla!
has anybody tryed this with Survive Mod?
Lovely.
Hi! I think this mod may be exactly what I have been looking for, but I have ran into a slight problem. I installed it, set my times in the config, & I can still sleep, but when I wake up it's not day, it's still night. None of the mods I have should be interfering. Any suggestions? Thanks!
Edit: Ignore that last post. Lol. It was me. I forgot to unsync it from the system clock. Lol. Thanks so much for this mod! It is great. May I use it in a modpack?
In reply to mandycmoore:
Hi there!
You're welcome to use it in any modpack as long as you leave a link back here if it's a public one and it's otherwise appropriate.
In reply to Unixkitty:
I will absolutely do that. Again, thanks so much for this mod!
Is it possible to update the length of the day/night in-game with commands without restarting?
In reply to Murdermancer:
Hmm, since I don't believe forge ever fixed their live config updates that worked in 1.15.2, this may be useful.
In reply to Unixkitty:
Would love to see that feature! I wanted to integrate something like this with quest rewards, or game stages. (Though, maybe I'm missing a cleverer way to do it, but I think this would make it really flexible.)
How does it affect growth speed of plants and animals?
Is the growth speed in minecraft expressed in "minecraft minutes" or "real minutes"?
So if I make my day longer, will I wait longer until my cow goes mature or always fixed time, say, 15 real-life minutes?
In reply to mipe1996:
growth in Minecraft is determined by tick rate, which this mod does not affect. so 15 minutes stays 15 minutes in terms of animal maturity
This is exactly the type of mod I been looking for!!! One that not only makes day/nights longer, but one that is highly configurable, doesn't screw with ticks, have the sun jerk back and forth, or screw with the skybox!! No annoyingly infinite days either. Thank you!
.
1.16.4 please?
In reply to honest_dragoness:
Pretty sure it already works!