Phased out any usage of World.getTotalWorldTime() in favor of internal tickers. SubTileEntity now has a session and packet safe internal ticker.

This commit is contained in:
Lizbeth Rika committed 2014-12-05 19:20:17 +00:00
1 parent 0a7d5ec220
commit 765e302c7e
23 files changed
+47 -46

No files matched your search

@@ -25,9 +25,11 @@ public class TilePylon extends TileEntity {
boolean activated = false;
int centerX, centerY, centerZ;
int ticks = 0;
@Override
public void updateEntity() {
++ticks;
int meta = getBlockMetadata();
if(activated && worldObj.isRemote) {
@@ -40,7 +42,7 @@ public class TilePylon extends TileEntity {
if(meta == 1) {
if(ConfigHandler.elfPortalParticlesEnabled) {
double worldTime = (int) worldObj.getTotalWorldTime();
double worldTime = ticks;
worldTime += new Random(xCoord ^ yCoord ^ zCoord).nextInt(1000);
worldTime /= 5;