first tests for misc lang keys, more funny particles, extended hadron

This commit is contained in:
Bob 2020-12-02 22:33:57 +01:00
parent 6d5577573a
commit 4f8293ae0c
26 changed files with 77 additions and 21 deletions

View File

@ -274,7 +274,11 @@ hadron.analysis=Analysiere...
hadron.buttonOn=Analysekammer (falls vorhanden) ist AN
hadron.buttonOff=Analysekammer ist AUS
hadron.error=Fehler!
hadron.hopper0=§eNormalmodus:$Alle Items werden beschleunigt.
hadron.hopper1=§eTrichtermodus:$Ein Item bleibt immer übrig.
hadron.idle=Leerlauf
hadron.modeCircular=§eRingbeschleuniger:$Magnete bilden eine Schleife.$Schaltet mehr Rezepte frei.
hadron.modeLine=§eLinearbeschleuniger:$Beschleuniger ended mit Analysekammer.$Weniger Rezepte.
hadron.progress=Verarbeite...
hbmfluid.acid=Wasserstoffperoxid
@ -1437,6 +1441,11 @@ item.nuke_electric_kit.name=Kit des Elektronikingenieurs
item.nuke_starter_kit.name=Atomphysik Starterkit
item.oil_canola.name=Rohes Canola-Öl
item.oil_detector.name=Ölvorkommen-Detektor
item.oil_detector.desc1=Rechtsklick sucht nach Öl.
item.oil_detector.desc2=Detektor findet nur größere Vorkommen.
item.oil_detector.bullseye=Ölvorkommen direkt untertage!
item.oil_detector.detected=Ölvorkommen in der Nähe!
item.oil_detector.noOil=Kein Öl gefunden.
item.overfuse.name=Singularitätsschraubenzieher
item.oxy_mask.name=Sauerstoffmaske
item.paa_boots.name=PaA-"olle Latschen"
@ -1455,10 +1464,13 @@ item.part_plutonium.name=Plutoniumstaubkiste
item.particle_aelectron.name=Antielektronenkapsel
item.particle_amat.name=Antimaterienkapsel
item.particle_aproton.name=Antiprotonenkapsel
item.particle_aschrab.name=Antischrabidiumkapseö
item.particle_aschrab.name=Kupferionenkapsel
item.particle_copper.name=Copper Ion Capsule
item.particle_dark.name=Dunkle Materien Kapsel
item.particle_digamma.name=§cDas Digamma-Teilchen§r
item.particle_empty.name=Leere Partikelkapsel
item.particle_higgs.name=Higgs Bosonen Kapsel
item.particle_lead.name=Bleiionenkapsel
item.particle_muon.name=Myonenkapsel
item.particle_sparkticle.name=Sparktikelkapsel
item.particle_strange.name=Strange Quark Capsule

View File

@ -274,7 +274,11 @@ hadron.analysis=Analyzing...
hadron.buttonOn=Analysis Chamber (if present) is ON
hadron.buttonOff=Analysis Chamber is OFF
hadron.error=Error!
hadron.hopper0=§eNormal Mode:$All items will be used.
hadron.hopper1=§eHopper Mode:$One item will always remain.
hadron.idle=Idle
hadron.modeCircular=§eCircular Accelerator Mode:$Magnets must loop back into core.$Unlocks more recipes.
hadron.modeLine=§eLinear Accelerator Mode:$Accelerator ends with analysis chamber.$Fewer Recipes.
hadron.progress=In Progress...
hbmfluid.acid=Hydrogen Peroxide
@ -1437,6 +1441,11 @@ item.nuke_electric_kit.name=Electronic Engineer's Kit
item.nuke_starter_kit.name=Atomic Science Starter Kit
item.oil_canola.name=Raw Canola Oil
item.oil_detector.name=Oil Reservoir Detector
item.oil_detector.desc1=Right-click to scan for oil.
item.oil_detector.desc2=Detector will only find larger deposits.
item.oil_detector.bullseye=Oil deposit directly below!
item.oil_detector.detected=Oil detected nearby.
item.oil_detector.noOil=No oil detected.
item.overfuse.name=Singularity Screwdriver
item.oxy_mask.name=Oxygen Mask
item.paa_boots.name=PaA "good ol' shoes"
@ -1456,9 +1465,12 @@ item.particle_aelectron.name=Antielectron Capsule
item.particle_amat.name=Antimatter Capsule
item.particle_aproton.name=Antiproton Capsule
item.particle_aschrab.name=Antischrabidium Capsule
item.particle_copper.name=Copper Ion Capsule
item.particle_dark.name=Dark Matter Capsule
item.particle_digamma.name=§cThe Digamma Particle§r
item.particle_empty.name=Empty Particle Capsule
item.particle_higgs.name=Higgs Boson Capsule
item.particle_lead.name=Lead Ion Capsule
item.particle_muon.name=Muon Capsule
item.particle_sparkticle.name=Sparkticle Capsule
item.particle_strange.name=Strange Quark Capsule

Binary file not shown.

Before

Width:  |  Height:  |  Size: 724 B

After

Width:  |  Height:  |  Size: 751 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 966 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 6.0 KiB

After

Width:  |  Height:  |  Size: 6.2 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 247 B

After

Width:  |  Height:  |  Size: 309 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 255 B

After

Width:  |  Height:  |  Size: 314 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 254 B

After

Width:  |  Height:  |  Size: 340 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 242 B

After

Width:  |  Height:  |  Size: 262 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 293 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 247 B

After

Width:  |  Height:  |  Size: 326 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 247 B

After

Width:  |  Height:  |  Size: 315 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 252 B

After

Width:  |  Height:  |  Size: 312 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 250 B

After

Width:  |  Height:  |  Size: 363 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 348 B

After

Width:  |  Height:  |  Size: 376 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 305 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 247 B

After

Width:  |  Height:  |  Size: 272 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 288 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 296 B

View File

@ -18,10 +18,12 @@ public class ContainerHadron extends Container {
hadron = tedf;
//Input
this.addSlotToContainer(new Slot(tedf, 0, 26, 36));
//Output
this.addSlotToContainer(new SlotMachineOutput(tedf, 1, 134, 36));
//Inputs
this.addSlotToContainer(new Slot(tedf, 0, 17, 36));
this.addSlotToContainer(new Slot(tedf, 0, 35, 36));
//Outputs
this.addSlotToContainer(new SlotMachineOutput(tedf, 1, 125, 36));
this.addSlotToContainer(new SlotMachineOutput(tedf, 1, 143, 36));
//Battery
this.addSlotToContainer(new Slot(tedf, 2, 44, 108));

View File

@ -7,6 +7,7 @@ import com.hbm.lib.RefStrings;
import com.hbm.packet.AuxButtonPacket;
import com.hbm.packet.PacketDispatcher;
import com.hbm.tileentity.machine.TileEntityHadron;
import com.hbm.util.I18nUtil;
import net.minecraft.client.Minecraft;
import net.minecraft.client.audio.PositionedSoundRecord;
@ -33,8 +34,12 @@ public class GUIHadron extends GuiInfoContainer {
this.drawElectricityInfo(this, mouseX, mouseY, guiLeft + 71, guiTop + 108, 34, 16, hadron.power, hadron.maxPower);
//String text = "Magnets are " + ((iter.isOn && iter.power >= iter.powerReq) ? "ON" : "OFF");
//this.drawCustomInfoStat(mouseX, mouseY, guiLeft + 76, guiTop + 94, 24, 12, mouseX, mouseY, new String[] { text });
this.drawCustomInfoStat(mouseX, mouseY, guiLeft + 142, guiTop + 89, 18, 18, mouseX, mouseY, I18nUtil.resolveKeyArray("hadron.hopper0"));
if(hadron.analysisOnly)
this.drawCustomInfoStat(mouseX, mouseY, guiLeft + 142, guiTop + 107, 18, 18, mouseX, mouseY, I18nUtil.resolveKeyArray("hadron.modeLine"));
else
this.drawCustomInfoStat(mouseX, mouseY, guiLeft + 142, guiTop + 107, 18, 18, mouseX, mouseY, I18nUtil.resolveKeyArray("hadron.modeCircular"));
}
protected void mouseClicked(int x, int y, int i) {
@ -47,7 +52,7 @@ public class GUIHadron extends GuiInfoContainer {
}
//Toggle analysis chamber
if(guiLeft + 142 <= x && guiLeft + 142 + 18 > x && guiTop + 89 < y && guiTop + 89 + 18 >= y) {
if(guiLeft + 142 <= x && guiLeft + 142 + 18 > x && guiTop + 107 < y && guiTop + 107 + 18 >= y) {
mc.getSoundHandler().playSound(PositionedSoundRecord.func_147674_a(new ResourceLocation("gui.button.press"), 1.0F));
PacketDispatcher.wrapper.sendToServer(new AuxButtonPacket(hadron.xCoord, hadron.yCoord, hadron.zCoord, 0, 1));
}
@ -71,6 +76,6 @@ public class GUIHadron extends GuiInfoContainer {
drawTexturedModalRect(guiLeft + 16, guiTop + 89, 206, 0, 18, 18);
if(hadron.analysisOnly)
drawTexturedModalRect(guiLeft + 142, guiTop + 89, 206, 18, 18, 18);
drawTexturedModalRect(guiLeft + 142, guiTop + 107, 206, 18, 18, 18);
}
}

View File

@ -600,6 +600,8 @@ public class ModItems {
public static Item cell_anti_schrabidium;
public static Item particle_empty;
public static Item particle_copper;
public static Item particle_lead;
public static Item particle_aproton;
public static Item particle_aelectron;
public static Item particle_amat;
@ -609,6 +611,7 @@ public class ModItems {
public static Item particle_strange;
public static Item particle_dark;
public static Item particle_sparkticle;
public static Item particle_digamma;
public static Item pellet_antimatter;
public static Item singularity;
@ -2469,6 +2472,8 @@ public class ModItems {
cell_anti_schrabidium = new ItemDrop().setUnlocalizedName("cell_anti_schrabidium").setCreativeTab(MainRegistry.controlTab).setContainerItem(ModItems.cell_empty).setTextureName(RefStrings.MODID + ":cell_anti_schrabidium");
particle_empty = new Item().setUnlocalizedName("particle_empty").setCreativeTab(MainRegistry.controlTab).setTextureName(RefStrings.MODID + ":particle_empty");
particle_copper = new Item().setUnlocalizedName("particle_copper").setCreativeTab(MainRegistry.controlTab).setContainerItem(ModItems.particle_empty).setTextureName(RefStrings.MODID + ":particle_copper");
particle_lead = new Item().setUnlocalizedName("particle_lead").setCreativeTab(MainRegistry.controlTab).setContainerItem(ModItems.particle_empty).setTextureName(RefStrings.MODID + ":particle_lead");
particle_aproton = new Item().setUnlocalizedName("particle_aproton").setCreativeTab(MainRegistry.controlTab).setContainerItem(ModItems.particle_empty).setTextureName(RefStrings.MODID + ":particle_aproton");
particle_aelectron = new Item().setUnlocalizedName("particle_aelectron").setCreativeTab(MainRegistry.controlTab).setContainerItem(ModItems.particle_empty).setTextureName(RefStrings.MODID + ":particle_aelectron");
particle_amat = new Item().setUnlocalizedName("particle_amat").setCreativeTab(MainRegistry.controlTab).setContainerItem(ModItems.particle_empty).setTextureName(RefStrings.MODID + ":particle_amat");
@ -2478,6 +2483,7 @@ public class ModItems {
particle_strange = new Item().setUnlocalizedName("particle_strange").setCreativeTab(MainRegistry.controlTab).setContainerItem(ModItems.particle_empty).setTextureName(RefStrings.MODID + ":particle_strange");
particle_dark = new Item().setUnlocalizedName("particle_dark").setCreativeTab(MainRegistry.controlTab).setContainerItem(ModItems.particle_empty).setTextureName(RefStrings.MODID + ":particle_dark");
particle_sparkticle = new Item().setUnlocalizedName("particle_sparkticle").setCreativeTab(MainRegistry.controlTab).setContainerItem(ModItems.particle_empty).setTextureName(RefStrings.MODID + ":particle_sparkticle");
particle_digamma = new Item().setUnlocalizedName("particle_digamma").setCreativeTab(MainRegistry.controlTab).setContainerItem(ModItems.particle_empty).setTextureName(RefStrings.MODID + ":particle_digamma");
singularity = new ItemDrop().setUnlocalizedName("singularity").setMaxStackSize(1).setCreativeTab(MainRegistry.controlTab).setContainerItem(ModItems.nuclear_waste).setTextureName(RefStrings.MODID + ":singularity");
singularity_counter_resonant = new ItemDrop().setUnlocalizedName("singularity_counter_resonant").setMaxStackSize(1).setCreativeTab(MainRegistry.controlTab).setContainerItem(ModItems.nuclear_waste).setTextureName(RefStrings.MODID + ":singularity_alt");
@ -4647,6 +4653,8 @@ public class ModItems {
//Particle Containers
GameRegistry.registerItem(particle_empty, particle_empty.getUnlocalizedName());
GameRegistry.registerItem(particle_copper, particle_copper.getUnlocalizedName());
GameRegistry.registerItem(particle_lead, particle_lead.getUnlocalizedName());
GameRegistry.registerItem(particle_aproton, particle_aproton.getUnlocalizedName());
GameRegistry.registerItem(particle_aelectron, particle_aelectron.getUnlocalizedName());
GameRegistry.registerItem(particle_amat, particle_amat.getUnlocalizedName());
@ -4656,6 +4664,7 @@ public class ModItems {
GameRegistry.registerItem(particle_strange, particle_strange.getUnlocalizedName());
GameRegistry.registerItem(particle_dark, particle_dark.getUnlocalizedName());
GameRegistry.registerItem(particle_sparkticle, particle_sparkticle.getUnlocalizedName());
GameRegistry.registerItem(particle_digamma, particle_digamma.getUnlocalizedName());
//OMG how the hell is that even possible!?
GameRegistry.registerItem(singularity, singularity.getUnlocalizedName());

View File

@ -4,10 +4,13 @@ import java.util.List;
import com.hbm.blocks.ModBlocks;
import net.minecraft.client.resources.I18n;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import net.minecraft.util.ChatComponentText;
import net.minecraft.util.ChatComponentTranslation;
import net.minecraft.util.ChatStyle;
import net.minecraft.util.EnumChatFormatting;
import net.minecraft.world.World;
public class ItemOilDetector extends Item {
@ -15,8 +18,8 @@ public class ItemOilDetector extends Item {
@Override
public void addInformation(ItemStack itemstack, EntityPlayer player, List list, boolean bool)
{
list.add("Right click to scan for oil.");
list.add("Scanner can only detect larger deposits!");
list.add(I18n.format(this.getUnlocalizedName() + ".desc1"));
list.add(I18n.format(this.getUnlocalizedName() + ".desc2"));
}
@Override
@ -73,14 +76,14 @@ public class ItemOilDetector extends Item {
if(direct)
oil = true;
if(world.isRemote)
{
if(oil) {
player.addChatMessage(new ChatComponentText("Oil deposit detected!"));
if(direct)
player.addChatMessage(new ChatComponentText("Oil deposit directly below!"));
if(!world.isRemote) {
if(direct) {
player.addChatMessage(new ChatComponentTranslation(this.getUnlocalizedName() + ".bullseye").setChatStyle(new ChatStyle().setColor(EnumChatFormatting.DARK_GREEN)));
} else if(oil) {
player.addChatMessage(new ChatComponentTranslation(this.getUnlocalizedName() + ".detected").setChatStyle(new ChatStyle().setColor(EnumChatFormatting.GOLD)));
} else {
player.addChatMessage(new ChatComponentText("No oil detected."));
player.addChatMessage(new ChatComponentTranslation(this.getUnlocalizedName() + ".noOil").setChatStyle(new ChatStyle().setColor(EnumChatFormatting.RED)));
}
}

View File

@ -33,7 +33,7 @@ public class TileEntityHadron extends TileEntityMachineBase implements IConsumer
public boolean analysisOnly = true;
public TileEntityHadron() {
super(3);
super(5);
}
@Override

View File

@ -232,7 +232,6 @@ public class TileEntityMachineReactor extends TileEntityMachineBase {
charge = nbt.getShort("charge");
heat = nbt.getShort("heat");
progress = nbt.getShort("progress");
slots = new ItemStack[getSizeInventory()];
}
@Override

View File

@ -0,0 +1,14 @@
package com.hbm.util;
import net.minecraft.client.resources.I18n;
public class I18nUtil {
public static String resolveKey(String s, Object... args) {
return I18n.format(s, args);
}
public static String[] resolveKeyArray(String s, Object... args) {
return resolveKey(s, args).split("\\$");
}
}