1
0
mirror of https://github.com/SquidDev-CC/CC-Tweaked synced 2025-08-29 16:47:56 +00:00

Merge pull request #291 from parly/patch-1.14.x-1

Fix os.time() and os.day() behavior on 1.14
This commit is contained in:
Jonathan Coates
2019-08-19 15:34:20 +01:00
committed by GitHub

View File

@@ -311,13 +311,13 @@ public class ServerComputer extends ServerTerminal implements IComputer, IComput
@Override
public double getTimeOfDay()
{
return (m_world.getGameTime() + 6000) % 24000 / 1000.0;
return (m_world.getDayTime() + 6000) % 24000 / 1000.0;
}
@Override
public int getDay()
{
return (int) ((m_world.getGameTime() + 6000) / 24000) + 1;
return (int) ((m_world.getDayTime() + 6000) / 24000) + 1;
}
@Override