promotional bannermobile promotional banner

RealTimeSync - Realistic Day/Night Cycles and Weather

Sync your Hytale world time and weather to real life!
Back to Files

RealTimeSync-1.0.18.jar

File nameRealTimeSync-1.0.18.jar
Uploader
HawkSlayerHawkSlayer
Uploaded
Apr 7, 2026
Downloads
174
Size
58.6 KB
File ID
7891827
Type
R
Release
Supported game versions
  • Early Access

What's new

Changelog

[1.0.18] - 2026-04-07

Changed

  • Hytale Update 4 Compatibility: Updated the mod to be fully compatible with the Hytale Update 4 stable release (2026.03.26).
  • Manifest Update: Updated manifest.json to include mandatory Dependencies and OptionalDependencies objects as required by the new Update 4 validation system.
  • Exact Version Targeting: Set ServerVersion to the exact build string 2026.03.26-89796e57b to resolve "different server version" warnings.
  • Plugin Lifecycle Migration: Moved core initialization logic from the removed start0() method to the standard start() method, ensuring the sync task correctly initializes on the new server version.
  • Midnight Tick Alignment: Updated TimeManager and HytaleWorldImpl to align with Update 4's transition to a Midnight-based tick system (0 ticks = 00:00), fixing a 6-hour time synchronization offset.
  • Java Toolchain Upgrade: Updated the build environment to Java 21 to match the modern Hytale server requirements.

Fixed

  • Fixed Config Path Detection for Dedicated Servers (Feb 2): The mod now properly detects whether it's running on a dedicated server or local/solo world and uses the correct config file location. Dedicated servers now save config to Server/universe/worlds/[WORLDNAME]/mods/RealTimeSync/config.json, while local/solo worlds save to UserData/Saves/[SAVENAME]/mods/RealTimeSync/config.json. Previously, the fallback location (mods/RealTimeSync/config.json) was being used in all cases, which prevented per-world configs from working properly on servers.

Added

  • Server Type Detection: Added automatic detection of server type with enhanced logging that displays whether the mod is running on a "Dedicated Server" or "Local/Solo" world, along with the exact config path being used for easier troubleshooting.

[1.0.17] - 2026-02-02

Fixed

  • CRITICAL: Fixed Geolocation Time Sync Race Condition: Time sync now properly initializes the geolocation UTC offset before starting. Previously, time sync would start immediately using a stale/incorrect UTC offset from config, while the weather API (which fetches the correct offset) wouldn't run until 15 seconds later. This caused incorrect time calculations, making the sun set at wrong times (e.g., 1 PM local time). The UTC offset is now fetched on startup and persisted to config for future use.
  • Fixed Client Time Sync Not Updating & Memory Corruption Crash: Fixed time synchronization to work correctly with Hytale's TimePacketSystem. When game time is paused, Hytale's automatic packet broadcasting stops. The mod now manually calls broadcastTimePacket() after each time update to ensure all connected clients receive synchronization packets. Uses safe API methods (TimeResource.setGameTime0()) and removed all dangerous direct field manipulation that caused garbage collector crashes. This ensures time syncs correctly whether playing locally, on a LAN server, or on a remote dedicated server.
  • Re-Added DST (Daylight Saving Time) Support: Geolocation time sync now automatically handles DST transitions. The UTC offset is re-fetched hourly from the Open-Meteo API to detect timezone changes. When DST begins or ends, the time offset updates within 1 hour automatically, preventing the 1-hour time drift that would previously occur twice per year.

[1.0.16] - 2026-01-31

Fixed

  • Fixed Hytale Server Time Sync: Resolved a critical issue where time synchronization failed for connected clients (displaying "normal cycle" or flickering sun).
  • Forced Pause Sync: The mod now forces isGameTimePaused=true on the server and clients. This prevents client-side interpolation from "racing" against the server's time updates, ensuring perfect synchronization.
  • Fixed setDayTime Bug: Corrected a logic error where the proper time ticks were being ignored and re-calculated incorrectly.
  • Fixed Black Screen Regression: Fixed a rendering crash caused by setting day duration overrides to 0. Default durations are now used while time remains paused.

[1.0.15] - 2026-01-30

Fixed

  • Further Console Spam Reduction: Moved "Fetching weather…" logs (every 15s) and shutdown warnings ("World no longer accepting tasks") to debugMode. The console should now be completely silent during normal operation.
  • Fixed Restore Command Flakiness: Solved a race condition where a pending background sync task would overwrite the /rts restore command, forcing the time loop back on immediately after restoration. Restorations are now queued to the main thread to ensure proper execution order.
  • Fixed/Improved Restore Behavior: /rts restore no longer blindly kills the sync scheduler. It now checks if Weather Sync is still enabled and leaves the scheduler running if so, ensuring that restoring time defaults doesn't break weather synchronization.

Added

  • Day Count Sync: The in-game "Day Count" now synchronizes with the real-world Day of the Month (e.g., Jan 30th = Day 30). This is a purely aesthetic change to enhance the "Real Time" feel and does not affect game logic. Cycle resets automatically next month (Feb 1st = Day 1).

[1.0.14] - 2026-01-30

Fixed

  • Console Spam: Moved frequent synchronization logs (e.g., "Updated _gameTimeLocalDateTime", "Set world to 24-hour cycle") to a new debugMode. These logs will no longer spam the console by default.

Added

  • Debug Mode: Added debugMode option to config.json (default: false). Set this to true to see detailed synchronization logs for troubleshooting.

[1.0.13] - 2026-01-26

Fixed

  • Fixed Timezone Display: Corrected in-game time display to show local timezone instead of UTC. Hytale displays Instant values directly as UTC, so the plugin now constructs the Instant as if the local time is UTC, ensuring correct visual display.
  • Fixed Thread Safety: Improved thread safety by using world.execute() for all time and weather updates, ensuring they run on the main world thread as recommended by Hytale's API.
  • Fixed Resource Cleanup: Added proper shutdown handling for WeatherManager's background executor to prevent resource leaks on plugin disable.
  • Fixed Geolocation Time Calculation: Improved timezone handling in geolocation time sync using OffsetDateTime for more robust timezone conversions.
  • Fixed /realtimesync restore command: Now properly disables time sync in config and prevents sync task from restarting. Previously, the command would stop the scheduler but time sync would resume because the config flag wasn't updated.
  • Fixed Weather API Error Handling: Added comprehensive error handling with retry logic (up to 3 attempts), exponential backoff, and detailed error messages for network failures, timeouts, and invalid API responses.

Added

  • Re-added /realtimesync setday <day> command: Allows manual setting of the world's day count while preserving the current time of day. Useful for correcting day counts after world resets or other issues.
  • Per-World Configuration: Configuration files are now stored per-world in UserData/Saves/[WORLDNAME]/mods/RealTimeSync/config.json, allowing unique settings for each world. Automatically migrates existing global configs to world-specific locations with full backward compatibility.

Changed

  • Removed unused onTick() method that was no longer being called after thread safety improvements.
  • Removed unused PluginConfig class.
  • Improved error handling for world shutdown scenarios with try-catch blocks around world.execute() calls.
  • Improved sync task management: startSyncTask() now checks if time sync is disabled before starting the scheduler, preventing unnecessary resource usage when sync is disabled.
  • Enhanced Weather API reliability: Weather sync now includes automatic retry with exponential backoff (5s, 10s, 20s), 10-second request timeouts, and user notifications after persistent failures.

[1.0.12] - 2026-01-26

Changed

  • Direct Time Mapping: Switched from "Offset Sync" to "Direct Real-Time Mapping" to fix desynchronization issues on long-running "Play Worlds".
  • 24-Hour Day: Hytale engine day duration is now forced to exactly 86400 seconds (24 hours) to match real life, preventing drift.
  • Aggressive Toggle/Restore: /rts toggle and /rts restore commands are now more aggressive in ensuring the sync engine is properly restarted or stopped, preventing "stuck" states.

Removed

  • Removed /rts setday command (deprecated/buggy).

[1.0.11] - 2026-01-24

Added

  • Added independent toggles for Time and Weather synchronization.
  • Added /realtimesync toggle <time/weather> <on/off> command to enable or disable sync types on the fly.
  • Integrated sync status indicators into the /rts forecast report.

Changed

  • Improved feedback when disabling time sync, automatically restoring default Hytale time cycle durations.

[1.0.10] - 2026-01-23

Added

  • Added /realtimesync restore command to manually revert world durations to Hytale defaults.
  • Added a "Manual Recovery" guide to the README for fixing worlds via in-game settings.

Fixed

  • Fixed command argument validation error for all /realtimesync subcommands.
  • Fixed a race condition where the background sync task would overwrite restoration logic.
  • Target both Base and Override fields in memory to ensure world saves capture 1.0x defaults.
  • Implemented markChanged() call to force the engine to save duration changes on command.

Changed

  • Stopped background sync task immediately upon calling /rts restore.

[1.0.9] - 2026-01-22

Fixed

  • Fixed Linux case-sensitivity issue by using lowercase mods folder for configuration.
  • Removed hardcoded Windows paths (G:/Hytale/...), making the mod fully portable.
  • Disabled file logging (RealTimeSync_Sync.log) to resolve path errors and reduce overhead.
  • Centralized path management in a new PathHelper utility.

[1.0.8] - (HOTFIX) - 2026-01-21

Fixed

  • Fixed a server hang/deadlock caused by off-thread Hytale API calls.
  • Moved time and weather synchronization to the main server thread.
  • Delayed sync task startup until the server is fully initialized (start0).
  • Optimized setForcedWeather to only trigger when weather actually changes.

[1.0.7] - 2026-01-21

✨ Geolocation Time Sync

  • Standard Time Sync: Added a new feature to synchronize in-game time with the local time of the configured Latitude and Longitude coordinates.
  • DST Support: Automatically handles Daylight Savings Time using timezone offsets from the Open-Meteo API.
  • Precision Fix: Eliminated the 4-minute discrepancy caused by raw longitude math by using API-provided UTC offsets.
  • In-Game Toggle: Added /realtimesync geoloc <on|off> command to switch between Geolocation time and Server local time instantly.
  • Offline Safety: Implemented automatic fallback to server local time if geolocation data cannot be resolved, ensuring zero crashes.

[1.0.6] - (HOTFIX) - 2026-01-20

🚨 Critical Hotfix (Stability & Rendering)

  • Fixed "Sync Death": Resolved a latent background thread crash caused by a type mismatch in reflection (sending Floats to Integer fields). Sync is now stable and won't halt silently.
  • Fixed "Black Screen" Rendering: Corrected an issue where setting time durations to 0 would break Hytale's atmospheric renderer. Skybox now renders correctly.
  • Improved Engine Compatibility: Added an automatic unpause hook to ensure time updates register visually even if the world starts in a paused state.

[1.0.5] - 2026-01-20

✨ Weather Synchronization (Phase 2)

  • Real-World Weather Sync: Actually added the Open-Meteo API to synchronize in-game weather with real-world locations. NOT A TEXT PLACEHOLDER. REAL.
  • Improved Weather Mapping: Support for Rain, Snow, Storms, and Overcast conditions using biome-optimized Hytale weather IDs.
  • Command Control: Fixed /realtimesync weather <ID> command with subcommands and proper validation.
  • Visual Weather Updates: Implemented direct WeatherResource manipulation for immediate visual changes (rain starts instantly!).
  • Global Snow Support: Confirmed and enabled Zone3_Snow support for all zones, including Zone 1.
  • Manual Override: Added 5-minute auto-sync pause when manually setting weather.
  • World-Specific Configuration: Configuration now saves to world folders, allowing unique settings per world.
  • Smooth Time Progression: Increased synchronization frequency to 20Hz (every tick) to eliminate cloud stuttering.

[1.0.4] - 2026-01-19

🚨 Critical Fixes

  • Fixed Reflection Crash: Resolved NoSuchMethodException by correctly navigating Hytale's object hierarchy (getEntityStore().getStore().getResource()).
  • Fixed Day Loop: Prevented rapid day counter increment ("time machine bug") by correcting tick calculation logic.
  • Fixed Timezone Display: Implemented local timezone offset correction so in-game time visually matches your local system time (instead of UTC).

✨ Features

  • Local Time Support: Game time now respects your PC's timezone settings automatically.
  • Robust Sync: Simplified sync architecture to "Strict Real Time" mode (1-second intervals) for maximum stability.
  • Sleep Safe: Sleeping no longer causes loops or crashes (though it does not skip night).

[1.0.3] - 2026-01-19

✨ Major Features

  • Real-Time Manual Time Sync: Now detects and corrects manual time changes using console commands
  • Sleep Cycle Synchronization: Automatically detects sleep/wake cycles and resyncs time to real-world time
  • Advanced Time Change Detection: Perfect detection of ANY time changes with 1-tick precision threshold

🔧 Technical Improvements

  • Console Command Time Control: Bypasses plugin API limitations by using Hytale's console command system for time synchronization
  • Multi-Approach Resync: Falls back through console commands → API calls → user notification for maximum reliability
  • Dynamic Real-Time Calculation: Calculates exact current real-world time for precise synchronization

🎯 Key Breakthroughs

  • Solved API Limitation: Found that plugin time APIs only work during world initialization, not during gameplay
  • Console Command Solution: Discovered that console commands work during gameplay where plugin APIs fail
  • Complete Time Coverage: Now handles world load sync + manual changes + sleep cycles

🐛 Bug Fixes

  • Fixed Manual Time Changes Being Ignored: Manual time commands now trigger immediate resync instead of being overwritten
  • Fixed Sleep Cycles Not Syncing: Sleep/wake events now properly detect time jumps and resync
  • Eliminated Stutter-Stepping: Fixed an issue where /time set would unpause the world, causing the skybox to jump. Time is now immediately re-paused after every synchronization.

[1.0.2] - 2026-01-17

🐛 Bug Fixes

  • Fixed Time Sync Not Working: Removed TIME_CHANGE_THRESHOLD that was blocking all sync commands (threshold was 3 minutes but sync interval was 30 seconds).
  • Fixed Time Stuttering: Added /time pause command to stop Hytale's natural time progression, eliminating visual stuttering.
  • Sleep Management: Pausing time now correctly disables sleeping, ensuring time remains perfectly synced without drift.

[1.0.1] - 2026-01-16

🐛 Bug Fixes & Optimization

  • Fixed Skybox Stuttering: Implemented rate-limiting to prevent visual jitters; time only updates when the sun moves significantly.
  • Sync Stability: Restored robust main-thread command hooking to ensure reliable time synchronization.

⚡ Performance

  • Zero Impact: Uses fixed sunrise/sunset times (6:00 AM / 6:00 PM) for time calculations.
  • Optimized: Zero impact on server startup time.

[1.0.0] - 2026-01-16

Initial Release

✨ Features

  • Real-time synchronization with system clock
  • Automatic daylight savings time (DST) support
  • Smooth day/night transitions
  • Configurable sync interval

🔧 Technical

  • Uses Hytale's native /time set command for reliability
  • Server-side only (no client mods required)

This mod has no additional files