diff options
author | md_5 <md_5@bigpond.com> | 2012-11-02 18:55:42 +1100 |
---|---|---|
committer | EvilSeph <evilseph@gmail.com> | 2012-11-02 16:36:43 -0400 |
commit | 53d24e2b22c29b2ae0ab96af4855d932b8428454 (patch) | |
tree | 766a41e8500c0f36e261e4e4eb50a0868d74e209 /src/main/java/net | |
parent | 3dd0580d50fe05afce8dba20cf9e383624f56ae4 (diff) | |
download | craftbukkit-53d24e2b22c29b2ae0ab96af4855d932b8428454.tar craftbukkit-53d24e2b22c29b2ae0ab96af4855d932b8428454.tar.gz craftbukkit-53d24e2b22c29b2ae0ab96af4855d932b8428454.tar.lz craftbukkit-53d24e2b22c29b2ae0ab96af4855d932b8428454.tar.xz craftbukkit-53d24e2b22c29b2ae0ab96af4855d932b8428454.zip |
[Bleeding] Fix mistranslation affecting time of the server vs time of day.
Fixes BUKKIT-2797
Diffstat (limited to 'src/main/java/net')
-rw-r--r-- | src/main/java/net/minecraft/server/EntityPlayer.java | 4 | ||||
-rw-r--r-- | src/main/java/net/minecraft/server/MinecraftServer.java | 2 |
2 files changed, 3 insertions, 3 deletions
diff --git a/src/main/java/net/minecraft/server/EntityPlayer.java b/src/main/java/net/minecraft/server/EntityPlayer.java index 2ceeac08..6130cd64 100644 --- a/src/main/java/net/minecraft/server/EntityPlayer.java +++ b/src/main/java/net/minecraft/server/EntityPlayer.java @@ -739,10 +739,10 @@ public class EntityPlayer extends EntityHuman implements ICrafting { public long getPlayerTime() { if (this.relativeTime) { // Adds timeOffset to the current server time. - return this.world.getTime() + this.timeOffset; + return this.world.F() + this.timeOffset; } else { // Adds timeOffset to the beginning of this day. - return this.world.getTime() - (this.world.getTime() % 24000) + this.timeOffset; + return this.world.F() - (this.world.F() % 24000) + this.timeOffset; } } diff --git a/src/main/java/net/minecraft/server/MinecraftServer.java b/src/main/java/net/minecraft/server/MinecraftServer.java index 349458bb..dd2d741d 100644 --- a/src/main/java/net/minecraft/server/MinecraftServer.java +++ b/src/main/java/net/minecraft/server/MinecraftServer.java @@ -530,7 +530,7 @@ public abstract class MinecraftServer implements Runnable, IMojangStatistics, IC if (this.ticks % 20 == 0) { for (int i = 0; i < this.getServerConfigurationManager().players.size(); ++i) { EntityPlayer entityplayer = (EntityPlayer) this.getServerConfigurationManager().players.get(i); - entityplayer.netServerHandler.sendPacket(new Packet4UpdateTime(entityplayer.getPlayerTime(), entityplayer.world.F())); // Add support for per player time + entityplayer.netServerHandler.sendPacket(new Packet4UpdateTime(entityplayer.world.getTime(), entityplayer.getPlayerTime())); // Add support for per player time } } |