mirror of
https://github.com/GTNewHorizons/Botania.git
synced 2026-11-13 16:54:06 +00:00
Fixed the little things that broke all flowers in the last commit.
This commit is contained in:
1 parent
765e302c7e
commit
956dc31909
3 files changed
+5
-6
No files matched your search
@@ -33,7 +33,7 @@ import cpw.mods.fml.relauncher.SideOnly;
|
||||
public class SubTileEntity {
|
||||
|
||||
protected TileEntity supertile;
|
||||
|
||||
|
||||
public int ticksExisted = 0;
|
||||
|
||||
/** The Tag items should use to store which sub tile they are. **/
|
||||
@@ -48,7 +48,7 @@ public class SubTileEntity {
|
||||
return true;
|
||||
}
|
||||
|
||||
public void onUpdate() {
|
||||
public void onUpdate() {
|
||||
ticksExisted++;
|
||||
}
|
||||
|
||||
@@ -56,13 +56,13 @@ public class SubTileEntity {
|
||||
cmp.setInteger(TAG_TICKS_EXISTED, ticksExisted);
|
||||
writeToPacketNBT(cmp);
|
||||
}
|
||||
|
||||
|
||||
public final void readFromPacketNBTInternal(NBTTagCompound cmp) {
|
||||
if(cmp.hasKey(TAG_TICKS_EXISTED))
|
||||
ticksExisted = cmp.getInteger(TAG_TICKS_EXISTED);
|
||||
readFromPacketNBT(cmp);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Writes some extra data to a network packet. This data is read
|
||||
* by readFromPacketNBT on the client that receives the packet.
|
||||
|
||||
@@ -69,7 +69,6 @@ public class SubTileGenerating extends SubTileEntity {
|
||||
}
|
||||
|
||||
if(!supertile.getWorldObj().isRemote) {
|
||||
++ticksExisted;
|
||||
int muhBalance = BotaniaAPI.internalHandler.getPassiveFlowerDecay();
|
||||
|
||||
if(isPassiveFlower() && muhBalance > 0 && ticksExisted > muhBalance) {
|
||||
|
||||
@@ -103,7 +103,7 @@ public class TileSpecialFlower extends TileMod implements IWandBindable, ISubTil
|
||||
cmp.setTag(TAG_SUBTILE_CMP, subCmp);
|
||||
|
||||
if(subTile != null)
|
||||
subTile.readFromPacketNBTInternal(subCmp);
|
||||
subTile.writeToPacketNBTInternal(subCmp);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
Reference in new issue
Block a user