aboutsummaryrefslogtreecommitdiff
path: root/src/Java/gtPlusPlus/core/block
diff options
context:
space:
mode:
Diffstat (limited to 'src/Java/gtPlusPlus/core/block')
-rw-r--r--src/Java/gtPlusPlus/core/block/base/BasicTileBlockWithTooltip.java12
1 files changed, 9 insertions, 3 deletions
diff --git a/src/Java/gtPlusPlus/core/block/base/BasicTileBlockWithTooltip.java b/src/Java/gtPlusPlus/core/block/base/BasicTileBlockWithTooltip.java
index 098b670509..6166835f31 100644
--- a/src/Java/gtPlusPlus/core/block/base/BasicTileBlockWithTooltip.java
+++ b/src/Java/gtPlusPlus/core/block/base/BasicTileBlockWithTooltip.java
@@ -33,13 +33,13 @@ public abstract class BasicTileBlockWithTooltip extends BlockContainer implement
* Each mapped object holds the data for the six sides.
*/
@SideOnly(Side.CLIENT)
- private AutoMap<CubicObject<SafeTexture>> mSidedTextureArray = new AutoMap<CubicObject<SafeTexture>>();
+ private AutoMap<CubicObject<SafeTexture>> mSidedTextureArray;
/**
* Holds the data for the six sides, each side holds an array of data for each respective meta.
*/
@SideOnly(Side.CLIENT)
- private AutoMap<CubicObject<String>> mSidedTexturePathArray = new AutoMap<CubicObject<String>>();
+ private AutoMap<CubicObject<String>> mSidedTexturePathArray;
/**
* Does this block have any meta at all?
@@ -157,7 +157,13 @@ public abstract class BasicTileBlockWithTooltip extends BlockContainer implement
@SideOnly(Side.CLIENT)
private final void handleTextures() {
- Logger.INFO("[TeTexture] Building Texture Maps for "+getTileEntityName()+".");
+ Logger.INFO("[TeTexture] Building Texture Maps for "+getTileEntityName()+".");
+
+ // Init on the Client side only, to prevent Field initialisers existing in the Server side bytecode.
+ mSidedTextureArray = new AutoMap<CubicObject<SafeTexture>>();
+ mSidedTexturePathArray = new AutoMap<CubicObject<String>>();
+
+
//Store them in forge order
//DOWN, UP, NORTH, SOUTH, WEST, EAST