diff --git a/main/java/gregtech/api/metatileentity/BaseMetaTileEntity.java b/main/java/gregtech/api/metatileentity/BaseMetaTileEntity.java index ce5b3c62..9870ba9b 100644 --- a/main/java/gregtech/api/metatileentity/BaseMetaTileEntity.java +++ b/main/java/gregtech/api/metatileentity/BaseMetaTileEntity.java @@ -388,8 +388,9 @@ public class BaseMetaTileEntity extends BaseTileEntity implements IGregTechTileE || (getCoverIDAtSide((byte)4) == 0 && worldObj.getPrecipitationHeight(xCoord-1, zCoord ) - 1 < yCoord) || (getCoverIDAtSide((byte)5) == 0 && worldObj.getPrecipitationHeight(xCoord+1, zCoord ) - 1 < yCoord)) { if (GregTech_API.sMachineRainExplosions && worldObj.isRaining() && getBiome().rainfall > 0) { - if (getRandomNumber(10)==0) {doEnergyExplosion(); + if (getRandomNumber(10)==0) { try{GT_Mod.instance.achievements.issueAchievement(this.getWorldObj().getPlayerEntityByName(mOwnerName), "badweather");}catch(Exception e){} + doEnergyExplosion(); }else setOnFire(); } if (!hasValidMetaTileEntity()) { @@ -397,8 +398,8 @@ public class BaseMetaTileEntity extends BaseTileEntity implements IGregTechTileE return; } if (GregTech_API.sMachineThunderExplosions && worldObj.isThundering() && getBiome().rainfall > 0 && getRandomNumber(3) == 0) { - doEnergyExplosion(); try{GT_Mod.instance.achievements.issueAchievement(this.getWorldObj().getPlayerEntityByName(mOwnerName), "badweather");}catch(Exception e){} + doEnergyExplosion(); } } } diff --git a/main/java/gregtech/api/util/GT_ModHandler.java b/main/java/gregtech/api/util/GT_ModHandler.java index 22759cd0..b657c8ee 100644 --- a/main/java/gregtech/api/util/GT_ModHandler.java +++ b/main/java/gregtech/api/util/GT_ModHandler.java @@ -1503,7 +1503,10 @@ public class GT_ModHandler { if(isElectricItem(aStack)&&ic2.api.item.ElectricItem.manager.getCharge(aStack)>1000.0d){ for (int i = 0; i < tPlayer.inventory.mainInventory.length; i++) { if (GT_Utility.isStackInList(tPlayer.inventory.mainInventory[i], GregTech_API.sSolderingMetalList)) { - tPlayer.inventory.mainInventory[i].stackSize--; + if(tPlayer.inventory.mainInventory[i].stackSize<1)return false; + if(tPlayer.inventory.mainInventory[i].stackSize==1){tPlayer.inventory.mainInventory[i]=null;}else{ + tPlayer.inventory.mainInventory[i].stackSize--;} + if (tPlayer.inventoryContainer != null) tPlayer.inventoryContainer.detectAndSendChanges(); if (canUseElectricItem(aStack, 10000)) { return GT_ModHandler.useElectricItem(aStack, 10000, (EntityPlayer)aPlayer); diff --git a/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ProcessingArray.java b/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ProcessingArray.java index 410eea61..a3478adc 100644 --- a/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ProcessingArray.java +++ b/main/java/gregtech/common/tileentities/machines/multi/GT_MetaTileEntity_ProcessingArray.java @@ -177,18 +177,22 @@ public class GT_MetaTileEntity_ProcessingArray extends GT_MetaTileEntity_MultiBl if(tInputList.size() > 0 || tFluids.length>0){ GT_Recipe tRecipe = map.findRecipe(getBaseMetaTileEntity(), mLastRecipe, false, gregtech.api.enums.GT_Values.V[tTier], tFluids, tInputs); if (tRecipe != null) { + if(tRecipe.mFluidInputs!=null){ + + } mLastRecipe = tRecipe; this.mEUt = 0; this.mOutputItems = null; this.mOutputFluids = null; - this.mMaxProgresstime = tRecipe.mDuration; int machines = Math.min(16,mInventory[1].stackSize); - this.mEfficiency = (10000 - (getIdealStatus() - getRepairStatus()) * 1000); - this.mEfficiencyIncrease = 10000; int i = 0; for(;i> >>> < > <= >= == != ~ ( ) ?: , ; ;= ;=X; = i0 i1 i2 i3 i4 i5 o0 o1 o2 o3 o4 o5 v0 v1 v2 v3 v4 v5 v6 v7 v8 v9 m0 m1 m2 m3 m4 m5 m6 m7 m8 m9 A B C D E F", + "'0' = false, 'everything but 0' = true, '!' turns '0' into '1' and everything else into '0'", "',' is just a separator for multiple executed Codes in a row.", + "';' means that the Program waits until the next tick before continuing. ';=10' and ';=10;' both mean that it will wait 10 Ticks instead of 1. And ';=0' or anything < 0 will default to 0.", + "If the '=' Operator is used within Brackets, it returns the value the variable has been set to.", + "The Program saves the Char Index of the current Task, the 10 Variables (which reset to 0 as soon as the Program Loop stops), the 10 Member Variables and the remaining waiting Time in its NBT.", + "A = 10, B = 11, C = 12, D = 13, E = 14, F = 15, just for Hexadecimal Space saving, since Redstone has only 4 Bits.", + "For implementing Loops you just need 1 Punch Card per Loop, these Cards can restart once they are finished, depending on how many other Cards there are in the Program Loop you inserted your Card into, since it will process them procedurally.", + "A Punch Card Processor can run up to four Loops, each with the length of seven Punch Cards, parallel.", + "Why does the Punch Card need Ink to be made, you ask? Because the empty one needs to have some lines on, and the for the punched one it prints the Code to execute in a human readable format on the Card." }); - - - - - - - - - GT_Utility.getWrittenBook("Manual_Punch_Cards", "Punch Card Manual V0.0", "Gregorius Techneticies", new String[] { "This Manual will explain the Functionality of the Punch Cards, once they are fully implemented. And no, they won't be like the IRL Punch Cards. This is just a current Idea Collection.", "(i1&&i2)?o1=15:o1=0;=10", "ignore all Whitespace Characters, use Long for saving the Numbers", "&& || ^^ & | ^ ! ++ -- + - % / // * ** << >> >>> < > <= >= == != ~ ( ) ?: , ; ;= ;=X; = i0 i1 i2 i3 i4 i5 o0 o1 o2 o3 o4 o5 v0 v1 v2 v3 v4 v5 v6 v7 v8 v9 m0 m1 m2 m3 m4 m5 m6 m7 m8 m9 A B C D E F", "'0' = false, 'everything but 0' = true, '!' turns '0' into '1' and everything else into '0'", "',' is just a separator for multiple executed Codes in a row.", "';' means that the Program waits until the next tick before continuing. ';=10' and ';=10;' both mean that it will wait 10 Ticks instead of 1. And ';=0' or anything < 0 will default to 0.", "If the '=' Operator is used within Brackets, it returns the value the variable has been set to.", "The Program saves the Char Index of the current Task, the 10 Variables (which reset to 0 as soon as the Program Loop stops), the 10 Member Variables and the remaining waiting Time in its NBT.", "A = 10, B = 11, C = 12, D = 13, E = 14, F = 15, just for Hexadecimal Space saving, since Redstone has only 4 Bits.", "For implementing Loops you just need 1 Punch Card per Loop, these Cards can restart once they are finished, depending on how many other Cards there are in the Program Loop you inserted your Card into, since it will process them procedurally.", "A Punch Card Processor can run up to four Loops, each with the length of seven Punch Cards, parallel.", "Why does the Punch Card need Ink to be made, you ask? Because the empty one needs to have some lines on, and the for the punched one it prints the Code to execute in a human readable format on the Card." }); - - - - - - - - - - - - - - - - GT_Utility.getWrittenBook("Manual_Microwave", "Microwave Oven Manual", "Kitchen Industries", new String[] { "Congratulations, you inserted a random seemingly empty Book into the Microwave and these Letters appeared out of nowhere.", "You just got a Microwave Oven and asked yourself 'why do I even need it?'. It's simple, the Microwave can cook for just 128 EU and at an insane speed. Not even a normal E-furnace can do it that fast and cheap!", "This is the cheapest and fastest way to cook for you. That is why the Microwave Oven can be found in almost every Kitchen (see www.youwannabuyakitchen.ly).", "Long time exposure to Microwaves can cause Cancer, but we doubt Steve lives long enough to die because of that.", "Do not insert any Metals. It might result in an Explosion.", "Do not dry Animals with it. It will result in a Hot Dog, no matter which Animal you put into it.", "Do not insert inflammable Objects. The Oven will catch on Fire.", "Do not insert Explosives such as Eggs. Just don't." }); - - - - - - - - - - + GT_Utility.getWrittenBook("Manual_Microwave", "Microwave Oven Manual", "Kitchen Industries", new String[] { + "Congratulations, you inserted a random seemingly empty Book into the Microwave and these Letters appeared out of nowhere.", + "You just got a Microwave Oven and asked yourself 'why do I even need it?'. It's simple, the Microwave can cook for just 128 EU and at an insane speed. Not even a normal E-furnace can do it that fast and cheap!", + "This is the cheapest and fastest way to cook for you. That is why the Microwave Oven can be found in almost every Kitchen (see www.youwannabuyakitchen.ly).", + "Long time exposure to Microwaves can cause Cancer, but we doubt Steve lives long enough to die because of that.", + "Do not insert any Metals. It might result in an Explosion.", + "Do not dry Animals with it. It will result in a Hot Dog, no matter which Animal you put into it.", + "Do not insert inflammable Objects. The Oven will catch on Fire.", "Do not insert Explosives such as Eggs. Just don't." }); + GT_Log.out.println("GT_Mod: Register Items."); new GT_IntegratedCircuit_Item(); @@ -137,7 +132,6 @@ public class GT_Loader_Item_Block_And_Fluid GT_ModHandler.addCraftingRecipe(ItemList.Reactor_Coolant_NaK_6.get(1L, new Object[0]), GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE , new Object[] { "PCP", "PDP", "PCP",'C', ItemList.Reactor_Coolant_NaK_3,'P', OrePrefixes.plate.get(Materials.Tin),'D',OrePrefixes.plateDense.get(Materials.Copper) }); ItemList.ThoriumCell_1.set(new GT_RadioactiveCellIC_Item("Thoriumcell", "Fuel Rod (Thorium)", 1, 50000, 0.2F,0,0.25F)); - GT_ModHandler.addShapelessCraftingRecipe(ItemList.ThoriumCell_1.get(1L, new Object[0]), GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE , new Object[] {Ic2Items.fuelRod , OrePrefixes.dust.get(Materials.Thorium) }); ItemList.ThoriumCell_2.set(new GT_RadioactiveCellIC_Item("Double_Thoriumcell", "Double Fuel Rod (Thorium)", 2, 50000, 0.2F,0,0.25F)); GT_ModHandler.addCraftingRecipe(ItemList.ThoriumCell_2.get(1L, new Object[0]), GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE , new Object[] { "RPR", " ", " ",'R', ItemList.ThoriumCell_1 ,'P', OrePrefixes.plate.get(Materials.Iron) }); diff --git a/main/resources/assets/gregtech/lang/en_US.lang b/main/resources/assets/gregtech/lang/en_US.lang index 6a34a8e1..695cd07a 100644 --- a/main/resources/assets/gregtech/lang/en_US.lang +++ b/main/resources/assets/gregtech/lang/en_US.lang @@ -294,13 +294,13 @@ achievement.batterys.desc=Craft a Battery Buffer achievement.badweather=Bad Weather achievement.badweather.desc=Forget to build a Roof above your Machines achievement.electricproblems=Electric Problems -achievement.electricproblems.desc=Loose a Machine due to Overvoltage +achievement.electricproblems.desc=Lose a Machine due to Overvoltage achievement.ebf=Electric Blast Furnace achievement.ebf.desc=Craft an Electric Blast Furnace achievement.energyhatch=You need three of them achievement.energyhatch.desc=Craft a LV Energy Hatch -achievement.aluminium=Aluminium -achievement.aluminium.desc=Produce an Aluminium Ingot +achievement.gtaluminium=Aluminium +achievement.gtaluminium.desc=Produce an Aluminium Ingot achievement.highpowersmelt=High Power Smelter achievement.highpowersmelt.desc=Craft a Multi Furnace achievement.oilplant=Oil Plant diff --git a/main/resources/assets/gregtech/lang/zh_CN.lang b/main/resources/assets/gregtech/lang/zh_CN.lang index 3fad547f..aa7913fc 100644 --- a/main/resources/assets/gregtech/lang/zh_CN.lang +++ b/main/resources/assets/gregtech/lang/zh_CN.lang @@ -299,8 +299,8 @@ achievement.ebf=电力高炉 achievement.ebf.desc=制造一台电力高炉 achievement.energyhatch=你需要三个 achievement.energyhatch.desc=制造一个LV级能源输入舱 -achievement.aluminium=铝 -achievement.aluminium.desc=制作一块铝锭 +achievement.gtaluminium=铝 +achievement.gtaluminium.desc=制作一块铝锭 achievement.highpowersmelt=高功率冶炼厂 achievement.highpowersmelt.desc=制造一台工业熔炉 achievement.oilplant=原油工厂