mirror of
https://github.com/GTNewHorizons/waila.git
synced 2026-11-23 21:49:49 +00:00
Fixed the mob spawner in the Vanilla module
This commit is contained in:
1 parent
ae50c1499f
commit
2d0b325f98
3 files changed
+9
-11
No files matched your search
@@ -39,7 +39,7 @@ import cpw.mods.fml.common.registry.LanguageRegistry;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
|
||||
//@Mod(modid="Waila", name="Waila", version="1.4.5", dependencies="required-after:NotEnoughItems")
|
||||
@Mod(modid="Waila", name="Waila", version="1.5.0_EXP")
|
||||
@Mod(modid="Waila", name="Waila", version="1.7.2_1.4.5")
|
||||
|
||||
public class Waila {
|
||||
// The instance of your mod that Forge uses.
|
||||
|
||||
@@ -19,7 +19,6 @@ import mcp.mobius.waila.cbcore.LangUtil;
|
||||
|
||||
public class HUDHandlerVanilla implements IWailaDataProvider {
|
||||
|
||||
//TODO : Fix mobspawners
|
||||
//TODO : Fix records
|
||||
|
||||
static Block mobSpawner = Block.getBlockFromName("mob_spawner");
|
||||
@@ -70,13 +69,11 @@ public class HUDHandlerVanilla implements IWailaDataProvider {
|
||||
Block block = accessor.getBlock();
|
||||
|
||||
/* Mob spawner handler */
|
||||
/*
|
||||
if (block == mobSpawner && accessor.getTileEntity() instanceof TileEntityMobSpawner && config.getConfig("vanilla.spawntype")){
|
||||
String name = currenttip.get(0);
|
||||
String mobname = ((TileEntityMobSpawner)accessor.getTileEntity()).getSpawnerLogic().getEntityNameToSpawn();
|
||||
String mobname = ((TileEntityMobSpawner)accessor.getTileEntity()).func_145881_a().getEntityNameToSpawn();
|
||||
currenttip.set(0, String.format("%s (%s)", name, mobname));
|
||||
}
|
||||
*/
|
||||
|
||||
if (block == redstone){
|
||||
String name = currenttip.get(0).replaceFirst(String.format(" %s", accessor.getMetadata()), "");
|
||||
@@ -150,8 +147,8 @@ public class HUDHandlerVanilla implements IWailaDataProvider {
|
||||
currenttip.add(String.format("%s : %s" , LangUtil.translateG("hud.msg.power"), accessor.getMetadata()));
|
||||
return currenttip;
|
||||
}
|
||||
|
||||
/*
|
||||
|
||||
/*
|
||||
if (config.getConfig("vanilla.jukebox"))
|
||||
if (block == jukebox){
|
||||
NBTTagCompound tag = accessor.getNBTData();
|
||||
@@ -163,8 +160,8 @@ public class HUDHandlerVanilla implements IWailaDataProvider {
|
||||
currenttip.add(LangUtil.translateG("hud.msg.empty"));
|
||||
}
|
||||
}
|
||||
*/
|
||||
|
||||
*/
|
||||
|
||||
return currenttip;
|
||||
}
|
||||
|
||||
|
||||
@@ -29,13 +29,14 @@ import net.minecraft.item.ItemBlockWithMetadata;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.MovingObjectPosition;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.client.event.RenderGameOverlayEvent;
|
||||
|
||||
public class TickHandler {
|
||||
|
||||
//public static LangUtil lang = LangUtil.loadLangDir("waila");
|
||||
|
||||
private int ticks = 0;
|
||||
public ItemStack identifiedHighlight = new ItemStack(Blocks.dirt);
|
||||
public ItemStack identifiedHighlight;// = new ItemStack(Blocks.dirt);
|
||||
public List<String> currenttip = new ArrayList<String>();
|
||||
public MetaDataProvider handler = new MetaDataProvider();
|
||||
private Minecraft mc = Minecraft.getMinecraft();
|
||||
@@ -48,7 +49,7 @@ public class TickHandler {
|
||||
_instance = new TickHandler();
|
||||
return _instance;
|
||||
}
|
||||
|
||||
|
||||
@SubscribeEvent
|
||||
@SideOnly(Side.CLIENT)
|
||||
public void tickRender(TickEvent.RenderTickEvent event) {
|
||||
|
||||
Reference in new issue
Block a user