3
0

Some improvements in spigot timings and fix #179

This commit is contained in:
Prototik
2015-09-05 23:31:58 +07:00
parent 923b9e81a0
commit 9d56192606
8 changed files with 233 additions and 110 deletions

View File

@ -62,6 +62,24 @@
public int experienceLevel;
public int experienceTotal;
public float experience;
@@ -254,7 +281,7 @@
--this.xpCooldown;
}
- if (this.isPlayerSleeping())
+ /*if (this.isPlayerSleeping()) KCauldron - moved into EntityPlayerMP
{
++this.sleepTimer;
@@ -283,7 +310,7 @@
{
this.sleepTimer = 0;
}
- }
+ }*/
super.onUpdate();
@@ -416,6 +443,42 @@
{
this.updateItemUse(this.itemInUse, 16);
@ -485,6 +503,15 @@
if (p_70999_1_)
{
this.sleepTimer = 0;
@@ -1491,7 +1712,7 @@
}
}
- private boolean isInBed()
+ protected boolean isInBed() // KCauldron - private -> protected
{
return this.worldObj.getBlock(this.playerLocation.posX, this.playerLocation.posY, this.playerLocation.posZ).isBed(worldObj, playerLocation.posX, playerLocation.posY, playerLocation.posZ, this);
}
@@ -1606,11 +1827,13 @@
{
this.spawnChunk = new ChunkCoordinates(p_71063_1_);