mirror of
https://github.com/HbmMods/Hbm-s-Nuclear-Tech-GIT.git
synced 2026-08-10 17:55:44 +00:00
even more ROR integration
This commit is contained in:
parent
2412283b5d
commit
07eff2a32a
@ -1,5 +1,12 @@
|
||||
## Changed
|
||||
* Removed the euphemium and DNT compound plate recipes from the anvil, they are now plasma forge exclusive
|
||||
* More RoR integration
|
||||
* PWRs can now output the control rod position
|
||||
* Industrial turbines and leviathans can now output their current energy production
|
||||
* Industrial turbines can output their current flywheel speed in %
|
||||
* The ZIRNOX now outputs its heat and pressure
|
||||
* The CCGT can output the turbine setting in percent, the turbine's RPM and the produced energy
|
||||
* The fusion reactor plasma vessel can output its output plasma energy and fuel consumption in percent
|
||||
|
||||
## Fixed
|
||||
* Fixed euphemium compound plate recipe not yielding four items as it should in the plasma forge
|
||||
@ -257,4 +257,17 @@ public class TileEntityChungus extends TileEntityTurbineBase implements SimpleCo
|
||||
}
|
||||
throw new NoSuchMethodException();
|
||||
}
|
||||
|
||||
@Override
|
||||
public String[] getFunctionInfo() {
|
||||
return new String[] {
|
||||
PREFIX_VALUE + "output"
|
||||
};
|
||||
}
|
||||
|
||||
@Override
|
||||
public String provideRORValue(String name) {
|
||||
if((PREFIX_VALUE + "output").equals(name)) return "" + (int) this.powerBuffer;
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
@ -236,4 +236,19 @@ public class TileEntityMachineIndustrialTurbine extends TileEntityTurbineBase im
|
||||
|
||||
return bb;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String[] getFunctionInfo() {
|
||||
return new String[] {
|
||||
PREFIX_VALUE + "output",
|
||||
PREFIX_VALUE + "flywheel"
|
||||
};
|
||||
}
|
||||
|
||||
@Override
|
||||
public String provideRORValue(String name) {
|
||||
if((PREFIX_VALUE + "output").equals(name)) return "" + (int) this.powerBuffer;
|
||||
if((PREFIX_VALUE + "flywheel").equals(name)) return "" + (int) (spin * 100);
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
@ -26,6 +26,7 @@ import com.hbm.util.CompatEnergyControl;
|
||||
|
||||
import api.hbm.energymk2.IEnergyProviderMK2;
|
||||
import api.hbm.fluid.IFluidStandardTransceiver;
|
||||
import api.hbm.redstoneoverradio.IRORValueProvider;
|
||||
import api.hbm.tile.IInfoProviderEC;
|
||||
import cpw.mods.fml.common.Optional;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
@ -44,7 +45,7 @@ import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.util.ForgeDirection;
|
||||
|
||||
@Optional.InterfaceList({@Optional.Interface(iface = "li.cil.oc.api.network.SimpleComponent", modid = "OpenComputers")})
|
||||
public class TileEntityMachineTurbineGas extends TileEntityMachineBase implements IFluidStandardTransceiver, IEnergyProviderMK2, IControlReceiver, IGUIProvider, SimpleComponent, IInfoProviderEC, CompatHandler.OCComponent, IFluidCopiable {
|
||||
public class TileEntityMachineTurbineGas extends TileEntityMachineBase implements IFluidStandardTransceiver, IEnergyProviderMK2, IControlReceiver, IGUIProvider, SimpleComponent, IInfoProviderEC, CompatHandler.OCComponent, IFluidCopiable, IRORValueProvider {
|
||||
|
||||
public long power;
|
||||
public static final long maxPower = 1000000L;
|
||||
@ -727,4 +728,21 @@ public class TileEntityMachineTurbineGas extends TileEntityMachineBase implement
|
||||
data.setDouble(CompatEnergyControl.D_CONSUMPTION_MB, this.waterToBoil);
|
||||
data.setDouble(CompatEnergyControl.D_OUTPUT_MB, this.waterToBoil * 10);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String[] getFunctionInfo() {
|
||||
return new String[] {
|
||||
PREFIX_VALUE + "turbinepercent",
|
||||
PREFIX_VALUE + "turbinespeed",
|
||||
PREFIX_VALUE + "output"
|
||||
};
|
||||
}
|
||||
|
||||
@Override
|
||||
public String provideRORValue(String name) {
|
||||
if((PREFIX_VALUE + "turbinepercent").equals(name)) return "" + (int) (this.powerSliderPos * 100D / 60D);
|
||||
if((PREFIX_VALUE + "turbinespeed").equals(name)) return "" + this.rpm;
|
||||
if((PREFIX_VALUE + "output").equals(name)) return "" + (int) this.instantPowerOutput;
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
@ -642,6 +642,7 @@ public class TileEntityPWRController extends TileEntityMachineBase implements IG
|
||||
@Override
|
||||
public String[] getFunctionInfo() {
|
||||
return new String[] {
|
||||
PREFIX_VALUE + "rods",
|
||||
PREFIX_VALUE + "coreheat",
|
||||
PREFIX_VALUE + "hullheat",
|
||||
PREFIX_VALUE + "flux",
|
||||
@ -653,6 +654,7 @@ public class TileEntityPWRController extends TileEntityMachineBase implements IG
|
||||
|
||||
@Override
|
||||
public String provideRORValue(String name) {
|
||||
if((PREFIX_VALUE + "rods").equals(name)) return "" + (int) this.rodLevel;
|
||||
if((PREFIX_VALUE + "coreheat").equals(name)) return "" + this.coreHeat;
|
||||
if((PREFIX_VALUE + "hullheat").equals(name)) return "" + this.hullHeat;
|
||||
if((PREFIX_VALUE + "flux").equals(name)) return "" + (int) this.flux;
|
||||
|
||||
@ -29,6 +29,7 @@ import com.hbm.util.EnumUtil;
|
||||
import com.hbm.util.fauxpointtwelve.DirPos;
|
||||
|
||||
import api.hbm.fluid.IFluidStandardTransceiver;
|
||||
import api.hbm.redstoneoverradio.IRORValueProvider;
|
||||
import api.hbm.tile.IInfoProviderEC;
|
||||
import cpw.mods.fml.common.Optional;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
@ -49,7 +50,7 @@ import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.util.ForgeDirection;
|
||||
|
||||
@Optional.InterfaceList({@Optional.Interface(iface = "li.cil.oc.api.network.SimpleComponent", modid = "OpenComputers")})
|
||||
public class TileEntityReactorZirnox extends TileEntityMachineBase implements IControlReceiver, IFluidStandardTransceiver, SimpleComponent, IGUIProvider, IInfoProviderEC, CompatHandler.OCComponent {
|
||||
public class TileEntityReactorZirnox extends TileEntityMachineBase implements IControlReceiver, IFluidStandardTransceiver, SimpleComponent, IGUIProvider, IInfoProviderEC, CompatHandler.OCComponent, IRORValueProvider {
|
||||
|
||||
public int heat;
|
||||
public static final int maxHeat = 100000;
|
||||
@ -597,4 +598,19 @@ public class TileEntityReactorZirnox extends TileEntityMachineBase implements IC
|
||||
data.setDouble(CompatEnergyControl.D_CONSUMPTION_MB, output);
|
||||
data.setDouble(CompatEnergyControl.D_OUTPUT_MB, output);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String[] getFunctionInfo() {
|
||||
return new String[] {
|
||||
PREFIX_VALUE + "heat",
|
||||
PREFIX_VALUE + "pressure"
|
||||
};
|
||||
}
|
||||
|
||||
@Override
|
||||
public String provideRORValue(String name) {
|
||||
if((PREFIX_VALUE + "heat").equals(name)) return "" + (int) Math.round(heat * 1.0E-5D * 780.0D + 20.0D);
|
||||
if((PREFIX_VALUE + "pressure").equals(name)) return "" + (int) Math.round(pressure * 1.0E-5D * 30.0D);
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
@ -13,6 +13,7 @@ import com.hbm.util.fauxpointtwelve.DirPos;
|
||||
|
||||
import api.hbm.energymk2.IEnergyProviderMK2;
|
||||
import api.hbm.fluidmk2.IFluidStandardTransceiverMK2;
|
||||
import api.hbm.redstoneoverradio.IRORValueProvider;
|
||||
import api.hbm.tile.IInfoProviderEC;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
@ -20,7 +21,7 @@ import io.netty.buffer.ByteBuf;
|
||||
import io.netty.buffer.Unpooled;
|
||||
import net.minecraft.nbt.NBTTagCompound;
|
||||
|
||||
public abstract class TileEntityTurbineBase extends TileEntityLoadedBase implements IEnergyProviderMK2, IFluidStandardTransceiverMK2, IInfoProviderEC, IBufPacketReceiver, IFluidCopiable {
|
||||
public abstract class TileEntityTurbineBase extends TileEntityLoadedBase implements IEnergyProviderMK2, IFluidStandardTransceiverMK2, IInfoProviderEC, IBufPacketReceiver, IFluidCopiable, IRORValueProvider {
|
||||
|
||||
protected ByteBuf buf;
|
||||
public long powerBuffer;
|
||||
|
||||
@ -27,6 +27,7 @@ import com.hbm.util.BobMathUtil;
|
||||
import com.hbm.util.fauxpointtwelve.BlockPos;
|
||||
import com.hbm.util.fauxpointtwelve.DirPos;
|
||||
|
||||
import api.hbm.redstoneoverradio.IRORValueProvider;
|
||||
import cpw.mods.fml.common.Optional;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
@ -45,7 +46,7 @@ import net.minecraft.world.World;
|
||||
import net.minecraftforge.common.util.ForgeDirection;
|
||||
|
||||
@Optional.InterfaceList({@Optional.Interface(iface = "li.cil.oc.api.network.SimpleComponent", modid = "OpenComputers")})
|
||||
public class TileEntityFusionTorus extends TileEntityCooledBase implements IGUIProvider, IControlReceiver, SimpleComponent, CompatHandler.OCComponent {
|
||||
public class TileEntityFusionTorus extends TileEntityCooledBase implements IGUIProvider, IControlReceiver, SimpleComponent, CompatHandler.OCComponent, IRORValueProvider {
|
||||
|
||||
public boolean didProcess = false;
|
||||
|
||||
@ -573,4 +574,19 @@ public class TileEntityFusionTorus extends TileEntityCooledBase implements IGUIP
|
||||
}
|
||||
throw new NoSuchMethodException();
|
||||
}
|
||||
|
||||
@Override
|
||||
public String[] getFunctionInfo() {
|
||||
return new String[] {
|
||||
PREFIX_VALUE + "plasma",
|
||||
PREFIX_VALUE + "consumption"
|
||||
};
|
||||
}
|
||||
|
||||
@Override
|
||||
public String provideRORValue(String name) {
|
||||
if((PREFIX_VALUE + "plasma").equals(name)) return "" + this.plasmaEnergy;
|
||||
if((PREFIX_VALUE + "consumption").equals(name)) return "" + (int) (this.fuelConsumption * 100);
|
||||
return null;
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user