Create Railways Navigator

Create Railways Navigator

2M Downloads

Departure and arrival times not correct (incompatibility with Hourglass?)

Urkaz opened this issue ยท 2 comments

commented

Version:

  • Minecraft Version: 1.20.1
  • Forge Version 47.4.0
  • Mod Version beta-0.8.3-C6

Describe the bug
All times displayed for departures and arrivals are incorrect. It seems like they are calculated using the vanilla minecraft time, so when using mods like Hourglass that change the day and night length, those times are not valid and all calculations broke.

To Reproduce
Steps to reproduce the behavior:

  1. Install Hourglass mod and set "daySpeed" and "nightSpeed" to 0.5.
  2. Create a train line with multiple stations and create a schedule.
  3. Wait until the Navigator calculates everything.
  4. Do a search between 2 stations of that line.
  5. Notice that all times are incorrect, and are constantly updated as if the train were ahead of it's schedule.

Expected behavior
Departure and arrival (and other) times should be displayed correctly.

A "simple" solution may be adding an extra config to tell this mod the day and day length, and when it stats so it can calculate things correctly when using multiple day/night speeds. If multiple day/night speeds increases the complexity too much, then limit it to a single global speed.

Screenshots
https://www.youtube.com/watch?v=eUDe6_jhbwc
At the beginning you can see how it displays an incorrect departure time. After that it keeps updating down the arrival time, not matching with the used world time.
(I had to upload the video to YT, GitHub was not accepting it for some reason as an attachment).

commented

It think it is a duplicate of #60, you need to use DragonLib (see here for detailed explaination: #60 (comment))

commented

I'm trying to configure it, but without any result...
I also tried using Time Control, which has a better way to manage the time than Hourglass, and using this config:

[arbitrary_time]
	#Specifies the duration in seconds for an in-game day, spanning from the 0th tick to the 12000th
	#Range: 4 ~ 10737360
	day_length_seconds = 1200
	#Specifies the duration in seconds for an in-game night, spanning from the 12000th tick to the 0th
	#Range: 4 ~ 10737360
	night_length_seconds = 1200

and this for DragonLib:

[dragonlib_common_config]

	[dragonlib_common_config.time]
		#The number of ticks for one Minecraft day. If in doubt, leave it unchanged! (Default: 24000)
		#Range: > 0
		ticks_per_day = 48000
		#The scale of the tick length. 1 means that a tick has normal duration (0.05 seconds). 20 would therefore result in a length of 1 second per tick. If in doubt, leave it unchanged! (Default: 1)
		#Range: 0.0 ~ 1.7976931348623157E308
		time_multiplier = 1
		#The number of ticks by which the time of day is shifted to match the real daytime. By default, 0 ticks is 6 AM, but 0 ticks should represent 12 AM (midnight). If in doubt, leave it unchanged! (Default: 6000)
		#Range: > 0
		daytime_shift = 12000

still displays the same behaviour as the one seen in the video.

Based on that linked explanation and the variable comments, that should be correct?