mirror of
https://github.com/GTNewHorizons/EnderIO.git
synced 2026-11-15 09:34:50 +00:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
87e5a32b89 | ||
|
|
c232ea8534 | ||
|
|
d27f30951a | ||
|
|
8dcda4e822 | ||
|
|
e337597a3c |
No files matched your search
+1
-1
@@ -28,7 +28,7 @@ dependencies {
|
||||
compileOnly(rfg.deobf('curse.maven:computercraft-67504:2269339')) // https://www.curseforge.com/minecraft/mc-mods/computercraft/files/2269339
|
||||
compileOnly(rfg.deobf('curse.maven:mekanism-268560:2475797')) // https://www.curseforge.com/minecraft/mc-mods/mekanism/files/2475797
|
||||
compileOnly(rfg.deobf('maven.modrinth:immibis-microblocks:59.1.2')) // https://modrinth.com/mod/immibis-microblocks/version/59.1.2
|
||||
|
||||
compileOnly('com.github.GTNewHorizons:BetterBuildersWands:0.13.12-GTNH:dev@jar')
|
||||
compileOnlyApi('com.github.GTNewHorizons:Angelica:2.2.10:api') {transitive = false}
|
||||
compileOnly("com.github.GTNewHorizons:Hodgepodge:2.7.196:dev")
|
||||
compileOnly('curse.maven:automagy-222153:2285272')
|
||||
|
||||
@@ -47,6 +47,7 @@ import cpw.mods.fml.common.registry.EntityRegistry;
|
||||
import cpw.mods.fml.common.registry.GameRegistry;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import crazypants.enderio.api.IMC;
|
||||
import crazypants.enderio.betterbuilderswands.PaintedCustomMapping;
|
||||
import crazypants.enderio.block.BlockDarkSteelAnvil;
|
||||
import crazypants.enderio.block.BlockDarkSteelLadder;
|
||||
import crazypants.enderio.block.BlockDarkSteelPressurePlate;
|
||||
@@ -190,7 +191,8 @@ import crazypants.util.EE3Util;
|
||||
after:Waila@[1.5.8,);\
|
||||
after:Thaumcraft;\
|
||||
after:appliedenergistics2@[rv2-beta-8,);\
|
||||
after:Railcraft@[9.16.7,)\
|
||||
after:Railcraft@[9.16.7,);\
|
||||
after:betterbuilderswands@[0.13.12,)\
|
||||
""", guiFactory = "crazypants.enderio.config.ConfigFactoryEIO")
|
||||
public class EnderIO {
|
||||
|
||||
@@ -839,6 +841,9 @@ public class EnderIO {
|
||||
Log.info("Failed to registered Capacitor Banks as Tinkers Construct Flux Upgrades");
|
||||
}
|
||||
}
|
||||
if (Loader.isModLoaded("betterbuilderswands")) {
|
||||
PaintedCustomMapping.registerMappings();
|
||||
}
|
||||
|
||||
ThaumcraftCompat.load();
|
||||
}
|
||||
|
||||
@@ -0,0 +1,101 @@
|
||||
package crazypants.enderio.betterbuilderswands;
|
||||
|
||||
import java.util.function.BiFunction;
|
||||
import java.util.function.IntFunction;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.item.ItemStack;
|
||||
|
||||
import com.github.bsideup.jabel.Desugar;
|
||||
|
||||
import crazypants.enderio.EnderIO;
|
||||
import crazypants.enderio.machine.painter.BlockPaintedCarpet;
|
||||
import crazypants.enderio.machine.painter.BlockPaintedFence;
|
||||
import crazypants.enderio.machine.painter.BlockPaintedFenceGate;
|
||||
import crazypants.enderio.machine.painter.BlockPaintedGlowstone;
|
||||
import crazypants.enderio.machine.painter.BlockPaintedSlab;
|
||||
import crazypants.enderio.machine.painter.BlockPaintedStair;
|
||||
import crazypants.enderio.machine.painter.BlockPaintedWall;
|
||||
import crazypants.enderio.machine.painter.TileEntityPaintedBlock;
|
||||
import portablejim.bbw.BetterBuildersWandsMod;
|
||||
import portablejim.bbw.basics.Point3d;
|
||||
import portablejim.bbw.core.conversion.ICustomMapping;
|
||||
import portablejim.bbw.shims.IPlayerShim;
|
||||
import portablejim.bbw.shims.IWorldShim;
|
||||
|
||||
@Desugar
|
||||
public record PaintedCustomMapping(Block lookBlock, BiFunction<Block, Integer, ItemStack> itemStackGetter, int meta)
|
||||
implements ICustomMapping {
|
||||
|
||||
@Override
|
||||
public Block getLookBlock() {
|
||||
return lookBlock;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getMeta() {
|
||||
return meta;
|
||||
}
|
||||
|
||||
@Override
|
||||
public ItemStack getItems(IWorldShim world, IPlayerShim player, Point3d point) {
|
||||
if (world.getTile(point) instanceof TileEntityPaintedBlock painted) {
|
||||
return itemStackGetter.apply(painted.getSourceBlock(), painted.getSourceBlockMetadata());
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean shouldCopyTileNBT() {
|
||||
return true;
|
||||
}
|
||||
|
||||
public static void registerMappings() {
|
||||
register(
|
||||
i -> new PaintedCustomMapping(
|
||||
EnderIO.blockPaintedGlowstone,
|
||||
BlockPaintedGlowstone::createItemStackForSourceBlock,
|
||||
i));
|
||||
register(
|
||||
i -> new PaintedCustomMapping(
|
||||
EnderIO.blockPaintedStair,
|
||||
BlockPaintedStair::createItemStackForSourceBlock,
|
||||
i));
|
||||
register(
|
||||
i -> new PaintedCustomMapping(
|
||||
EnderIO.blockPaintedFence,
|
||||
BlockPaintedFence::createItemStackForSourceBlock,
|
||||
i));
|
||||
register(
|
||||
i -> new PaintedCustomMapping(
|
||||
EnderIO.blockPaintedFenceGate,
|
||||
BlockPaintedFenceGate::createItemStackForSourceBlock,
|
||||
i));
|
||||
register(
|
||||
i -> new PaintedCustomMapping(
|
||||
EnderIO.blockPaintedCarpet,
|
||||
BlockPaintedCarpet::createItemStackForSourceBlock,
|
||||
i));
|
||||
register(
|
||||
i -> new PaintedCustomMapping(
|
||||
EnderIO.blockPaintedSlab,
|
||||
BlockPaintedSlab::createItemStackForSourceBlock,
|
||||
i));
|
||||
register(
|
||||
i -> new PaintedCustomMapping(
|
||||
EnderIO.blockPaintedWall,
|
||||
BlockPaintedWall::createItemStackForSourceBlock,
|
||||
i));
|
||||
register(
|
||||
i -> new PaintedCustomMapping(
|
||||
EnderIO.blockPaintedDoubleSlab,
|
||||
BlockPaintedSlab::createItemStackForSourceBlock,
|
||||
i));
|
||||
}
|
||||
|
||||
private static void register(IntFunction<ICustomMapping> mapping) {
|
||||
for (int i = 0; i < 16; i++) {
|
||||
BetterBuildersWandsMod.instance.mappingManager.setMapping(mapping.apply(i));
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -320,7 +320,7 @@ public class ConduitUtil {
|
||||
}
|
||||
|
||||
int signalStrength = getInternalSignalForColor(bundle, col);
|
||||
if (signalStrength < 15 && DyeColor.RED == col && bundle != null && bundle.getEntity() != null) {
|
||||
if (signalStrength < 15 && bundle != null && bundle.getEntity() != null) {
|
||||
TileEntity te = bundle.getEntity();
|
||||
signalStrength = Math
|
||||
.max(signalStrength, te.getWorldObj().getStrongestIndirectPower(te.xCoord, te.yCoord, te.zCoord));
|
||||
|
||||
@@ -175,6 +175,7 @@ public class ItemSettings extends BaseSettingsPanel {
|
||||
private void updateButtons() {
|
||||
rsB.onGuiInit();
|
||||
rsB.setMode(itemConduit.getExtractionRedstoneMode(gui.getDir()));
|
||||
colorB.onGuiInit();
|
||||
|
||||
loopB.onGuiInit();
|
||||
loopB.setSelected(itemConduit.isSelfFeedEnabled(gui.getDir()));
|
||||
|
||||
@@ -47,8 +47,8 @@ public class ExistingItemFilter implements IItemFilter {
|
||||
|
||||
private boolean isStackInInventory(NetworkedInventory ni, ItemStack item) {
|
||||
int[] slots = ni.getInventory().getAccessibleSlotsFromSide(ni.getInventorySide());
|
||||
for (int i = 0; i < slots.length; i++) {
|
||||
ItemStack stack = ni.getInventory().getStackInSlot(i);
|
||||
for (int slot : slots) {
|
||||
ItemStack stack = ni.getInventory().getStackInSlot(slot);
|
||||
if (stackEqual(item, stack)) {
|
||||
return true;
|
||||
}
|
||||
@@ -116,8 +116,8 @@ public class ExistingItemFilter implements IItemFilter {
|
||||
snapshot = new ArrayList<>();
|
||||
}
|
||||
int[] slots = ni.getInventory().getAccessibleSlotsFromSide(ni.getInventorySide());
|
||||
for (int i = 0; i < slots.length; i++) {
|
||||
ItemStack stack = ni.getInventory().getStackInSlot(i);
|
||||
for (int slot : slots) {
|
||||
ItemStack stack = ni.getInventory().getStackInSlot(slot);
|
||||
if (stack != null && !isStackInSnapshot(stack)) {
|
||||
snapshot.add(stack);
|
||||
}
|
||||
|
||||
@@ -15,8 +15,14 @@ public class SoulBinderEnderCystalRecipe extends AbstractSoulBinderRecipe {
|
||||
Config.soulBinderEnderCystalRF,
|
||||
Config.soulBinderEnderCystalLevels,
|
||||
"SoulBinderEnderCystalRecipe",
|
||||
"SpecialMobs.SpecialEnderman",
|
||||
"Enderman");
|
||||
"Enderman",
|
||||
"SpecialMobs.BlindingEnderman",
|
||||
"SpecialMobs.CursedEnderman",
|
||||
"SpecialMobs.IcyEnderman",
|
||||
"SpecialMobs.LightningEnderman",
|
||||
"SpecialMobs.MiniEnderman",
|
||||
"SpecialMobs.MirageEnderman",
|
||||
"SpecialMobs.ThiefEnderman");
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -15,8 +15,14 @@ public class SoulBinderPrecientCystalRecipe extends AbstractSoulBinderRecipe {
|
||||
Config.soulBinderPrecientCystalRF,
|
||||
Config.soulBinderPrecientCystalLevels,
|
||||
"SoulBinderPrecientCystalRecipe",
|
||||
"SpecialMobs.SpecialEnderman",
|
||||
"Enderman");
|
||||
"Enderman",
|
||||
"SpecialMobs.BlindingEnderman",
|
||||
"SpecialMobs.CursedEnderman",
|
||||
"SpecialMobs.IcyEnderman",
|
||||
"SpecialMobs.LightningEnderman",
|
||||
"SpecialMobs.MiniEnderman",
|
||||
"SpecialMobs.MirageEnderman",
|
||||
"SpecialMobs.ThiefEnderman");
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -16,7 +16,12 @@ public class SoulBinderReanimationRecipe extends AbstractSoulBinderRecipe {
|
||||
Config.soulBinderReanimationLevels,
|
||||
"SoulBinderReanimationRecipe",
|
||||
"Zombie",
|
||||
"SpecialMobs.SpecialZombie");
|
||||
"SpecialMobs.BrutishZombie",
|
||||
"SpecialMobs.FireZombie",
|
||||
"SpecialMobs.FishingZombie",
|
||||
"SpecialMobs.GiantZombie",
|
||||
"SpecialMobs.HungryZombie",
|
||||
"SpecialMobs.PlagueZombie");
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -16,7 +16,13 @@ public class SoulBinderSentientRecipe extends AbstractSoulBinderRecipe {
|
||||
Config.soulBinderReanimationLevels,
|
||||
"SoulBinderSentientRecipe",
|
||||
"Witch",
|
||||
"enderzoo.WitherWitch");
|
||||
"enderzoo.WitherWitch",
|
||||
"SpecialMobs.DominationWitch",
|
||||
"SpecialMobs.RageWitch",
|
||||
"SpecialMobs.ShadowsWitch",
|
||||
"SpecialMobs.UndeadWitch",
|
||||
"SpecialMobs.WildsWitch",
|
||||
"SpecialMobs.WindWitch");
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
@@ -148,6 +148,7 @@ public class GuiVacuumChest extends GuiContainerBaseEIO {
|
||||
break;
|
||||
case RANGE_ID:
|
||||
te.setShowRange(showRangeB.isSelected());
|
||||
break;
|
||||
case ID_WHITELIST:
|
||||
itemFilter = te.getItemFilter();
|
||||
if (itemFilter != null) {
|
||||
|
||||
Reference in new issue
Block a user