diff options
author | Alkalus <3060479+draknyte1@users.noreply.github.com> | 2018-07-01 19:15:47 +1000 |
---|---|---|
committer | Alkalus <3060479+draknyte1@users.noreply.github.com> | 2018-07-01 19:15:47 +1000 |
commit | 35a555fff44b6b3f0d9bb007481edeed3bc09c4e (patch) | |
tree | 0762ca8b9e47b31d6185d18553e6c926397e7950 /src/Java/gtPlusPlus/plugin/villagers/tile | |
parent | 03e72a68aee10a871b3186d141b14c76770c72fb (diff) | |
download | GT5-Unofficial-35a555fff44b6b3f0d9bb007481edeed3bc09c4e.tar.gz GT5-Unofficial-35a555fff44b6b3f0d9bb007481edeed3bc09c4e.tar.bz2 GT5-Unofficial-35a555fff44b6b3f0d9bb007481edeed3bc09c4e.zip |
% More work on Villagers.
% More work on Spawners.
Diffstat (limited to 'src/Java/gtPlusPlus/plugin/villagers/tile')
-rw-r--r-- | src/Java/gtPlusPlus/plugin/villagers/tile/TileEntityGenericSpawner.java | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/src/Java/gtPlusPlus/plugin/villagers/tile/TileEntityGenericSpawner.java b/src/Java/gtPlusPlus/plugin/villagers/tile/TileEntityGenericSpawner.java index 9f2e992d74..53c0c78a23 100644 --- a/src/Java/gtPlusPlus/plugin/villagers/tile/TileEntityGenericSpawner.java +++ b/src/Java/gtPlusPlus/plugin/villagers/tile/TileEntityGenericSpawner.java @@ -128,8 +128,14 @@ public class TileEntityGenericSpawner extends TileEntityMobSpawner { @Override public void writeToNBT(NBTTagCompound p_145841_1_) { if (hasInternalFieldBeenSet()) { - String s = (String) classToNameMap_Ex.get(mSpawners.get(this.mID)); - if (s == null){ + String s = (String) classToNameMap_Ex.get(this.getClass()); + if (s == null){ + for (Object g : classToNameMap_Ex.values()) { + if (g instanceof String) { + Logger.INFO("Found Translation for "+((Class) nameToClassMap_Ex.get(g)).getName()+": "+g); + } + } + //throw new RuntimeException(this.getClass() + " is missing a mapping! This is a bug!"); s = mSpawners.containsKey(this.mID) ? mSpawners.get(this.mID).getSimpleName() : "bad.class.name"; p_145841_1_.setString("id", s); @@ -140,7 +146,7 @@ public class TileEntityGenericSpawner extends TileEntityMobSpawner { p_145841_1_.setInteger("mID", this.mID); } else { - Logger.WARNING(this.getClass() + " is not missing a mapping! Used key: "+s); + Logger.INFO(this.getClass() + " is not missing a mapping! Used key: "+s); p_145841_1_.setString("id", s); p_145841_1_.setInteger("x", this.xCoord); p_145841_1_.setInteger("y", this.yCoord); |