mirror of
https://github.com/GTNewHorizons/Binnie.git
synced 2026-11-21 12:42:53 +00:00
Fix problem in PlankType with "getName", which conflicts during obfuscation.
This commit is contained in:
1 parent
6c3eaca546
commit
34d57cda35
10 files changed
+20
-15
No files matched your search
@@ -39,7 +39,7 @@ public class CeramicColor implements IDesignMaterial {
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getName() {
|
||||
public String getDesignMaterialName() {
|
||||
return this.color.getName();
|
||||
}
|
||||
|
||||
|
||||
@@ -7,7 +7,7 @@ public interface IDesignMaterial {
|
||||
|
||||
ItemStack getStack(boolean fireproof);
|
||||
|
||||
String getName();
|
||||
String getDesignMaterialName();
|
||||
|
||||
int getColour();
|
||||
}
|
||||
@@ -231,7 +231,7 @@ public class BlockETDoor extends BlockDoor implements IBlockMetadata, ITileEntit
|
||||
public String getDisplayName(ItemStack itemStack) {
|
||||
final int meta = TileEntityMetadata.getItemDamage(itemStack);
|
||||
final String typeName = getDoorType(meta).getName();
|
||||
final String woodName = WoodManager.getPlankType(meta & 0xFF).getName();
|
||||
final String woodName = WoodManager.getPlankType(meta & 0xFF).getDesignMaterialName();
|
||||
if (typeName.equals("")) {
|
||||
return Binnie.LANGUAGE.localise(ExtraTrees.instance, "block.door.name", woodName);
|
||||
}
|
||||
|
||||
@@ -132,6 +132,11 @@ public class PlankType {
|
||||
|
||||
@Override
|
||||
public String getName() {
|
||||
return "block.planks." + this.toString().toLowerCase();
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getDesignMaterialName() {
|
||||
return ExtraTrees.proxy.localise("block.planks." + this.toString().toLowerCase());
|
||||
}
|
||||
|
||||
@@ -197,7 +202,7 @@ public class PlankType {
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getName() {
|
||||
public String getDesignMaterialName() {
|
||||
return ExtraTrees.proxy.localise("block.planks.vanilla." + this.toString().toLowerCase());
|
||||
}
|
||||
|
||||
@@ -301,7 +306,7 @@ public class PlankType {
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getName() {
|
||||
public String getDesignMaterialName() {
|
||||
return ExtraTrees.proxy.localise("block.planks.forestry." + this.toString().toLowerCase());
|
||||
}
|
||||
|
||||
|
||||
@@ -198,8 +198,8 @@ public class BlockMultiFence extends BlockFence implements IBlockMetadata, IStat
|
||||
String woodGrammar = ExtraTrees.proxy.localise("block.multifence" + (twoTypes ? "2" : "") + ".grammar");
|
||||
|
||||
woodGrammar = woodGrammar.replaceAll("%PREFIX", fenceType.getPrefix());
|
||||
woodGrammar = woodGrammar.replaceAll("%TYPE", typeSecond.getName());
|
||||
woodGrammar = woodGrammar.replaceAll("%WOOD", typeFirst.getName());
|
||||
woodGrammar = woodGrammar.replaceAll("%TYPE", typeSecond.getDesignMaterialName());
|
||||
woodGrammar = woodGrammar.replaceAll("%WOOD", typeFirst.getDesignMaterialName());
|
||||
return woodGrammar;
|
||||
}
|
||||
|
||||
|
||||
@@ -139,9 +139,9 @@ public abstract class BlockDesign extends BlockMetadata implements IMultipassBlo
|
||||
public void addInformation(ItemStack stack, EntityPlayer player, List<String> tooltip, boolean advanced) {
|
||||
DesignBlock block = ModuleCarpentry.getDesignBlock(this.getDesignSystem(), TileEntityMetadata.getItemDamage(stack));
|
||||
if (block.getPrimaryMaterial() != block.getSecondaryMaterial()) {
|
||||
tooltip.add(block.getPrimaryMaterial().getName() + " and " + block.getSecondaryMaterial().getName());
|
||||
tooltip.add(block.getPrimaryMaterial().getDesignMaterialName() + " and " + block.getSecondaryMaterial().getDesignMaterialName());
|
||||
} else {
|
||||
tooltip.add(block.getPrimaryMaterial().getName());
|
||||
tooltip.add(block.getPrimaryMaterial().getDesignMaterialName());
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -469,9 +469,9 @@ public class DesignBlock {
|
||||
public String getString() {
|
||||
String type = "";
|
||||
if (this.getPrimaryMaterial() != this.getSecondaryMaterial()) {
|
||||
type = this.getPrimaryMaterial().getName() + " and " + this.getSecondaryMaterial().getName();
|
||||
type = this.getPrimaryMaterial().getDesignMaterialName() + " and " + this.getSecondaryMaterial().getDesignMaterialName();
|
||||
} else {
|
||||
type = this.getPrimaryMaterial().getName();
|
||||
type = this.getPrimaryMaterial().getDesignMaterialName();
|
||||
}
|
||||
return super.toString() + " " + "{" + type + " " + this.getDesign().getName() + " " + (this.panel ? "Panel" : "Tile") + ", Facing:" + this.getFacing() + ", Rotation:" + this.getRotation() + "}";
|
||||
}
|
||||
|
||||
@@ -71,7 +71,7 @@ public class GlassType implements IDesignMaterial {
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getName() {
|
||||
public String getDesignMaterialName() {
|
||||
return this.name;
|
||||
}
|
||||
|
||||
|
||||
@@ -83,8 +83,8 @@ public class ModuleCore implements IInitializable {
|
||||
if (wood2 == null) {
|
||||
outputPlanks.println("<td></td>");
|
||||
} else {
|
||||
final String img = "<img alt=\"" + wood2.getName() + "\" src=\"images/planks/" + wood2.getName() + ".png\">";
|
||||
outputPlanks.println("<td>" + img + " " + wood2.getName() + "</td>");
|
||||
final String img = "<img alt=\"" + wood2.getDesignMaterialName() + "\" src=\"images/planks/" + wood2.getDesignMaterialName() + ".png\">";
|
||||
outputPlanks.println("<td>" + img + " " + wood2.getDesignMaterialName() + "</td>");
|
||||
}
|
||||
}
|
||||
outputPlanks.println("</tr>");
|
||||
|
||||
@@ -36,7 +36,7 @@ public class ExtraTreesJeiPlugin extends BlankModPlugin {
|
||||
FenceDescription desc = WoodManager.getFenceDescription(itemStack);
|
||||
if (desc != null) {
|
||||
FenceType type = WoodManager.getFenceType(itemStack);
|
||||
return type + ":" + desc.getPlankType().getName().toLowerCase() + ":" + desc.getSecondaryPlankType().getName().toLowerCase();
|
||||
return type + ":" + desc.getPlankType().getDesignMaterialName().toLowerCase() + ":" + desc.getSecondaryPlankType().getDesignMaterialName().toLowerCase();
|
||||
}
|
||||
return Integer.toString(itemStack.getItemDamage());
|
||||
});
|
||||
|
||||
Reference in new issue
Block a user