v1.1.0 release merge.
This commit is contained in:
commit
aa9e358879
339 changed files with 2290 additions and 1116 deletions
|
@ -12,23 +12,20 @@ MOD_JAR=$(filter-out %-sources.jar,$(wildcard build/libs/${MOD_JAR_PREFIX}*.jar)
|
|||
ifeq ($(OS),Windows_NT)
|
||||
GRADLE=gradlew.bat --no-daemon
|
||||
GRADLE_STOP=gradlew.bat --stop
|
||||
INSTALL_DIR=$(realpath ${APPDATA}/.minecraft)
|
||||
SERVER_INSTALL_DIR=$(realpath ${APPDATA}/minecraft-server-forge-1.12.2-14.23.5.2768)
|
||||
DJS=djs
|
||||
else
|
||||
GRADLE=./gradlew --no-daemon
|
||||
GRADLE_STOP=./gradlew --stop
|
||||
INSTALL_DIR=~/.minecraft
|
||||
SERVER_INSTALL_DIR=~/.minecraft-server-forge-1.12.2-14.23.5.2768
|
||||
DJS=djs
|
||||
endif
|
||||
TASK=$(DJS) ../meta/lib/tasks.js
|
||||
|
||||
wildcardr=$(foreach d,$(wildcard $1*),$(call wildcardr,$d/,$2) $(filter $(subst *,%,$2),$d))
|
||||
|
||||
#
|
||||
# Targets
|
||||
#
|
||||
.PHONY: default mod init clean clean-all mrproper all run install sanatize dist-check dist dist-files start-server port-languages
|
||||
.PHONY: default mod init clean clean-all mrproper all run install sanitize dist-check dist dist-files start-server
|
||||
|
||||
default: mod
|
||||
|
||||
|
@ -65,42 +62,28 @@ run:
|
|||
@echo "[1.12] Running client ..."
|
||||
@$(GRADLE) runClient
|
||||
|
||||
install: $(MOD_JAR) |
|
||||
@sleep 2s
|
||||
@if [ ! -d "$(INSTALL_DIR)" ]; then echo "Cannot find installation minecraft directory."; false; fi
|
||||
@echo "[1.12] Installing '$(MOD_JAR)' to '$(INSTALL_DIR)/mods' ..."
|
||||
@[ -d "$(INSTALL_DIR)/mods" ] || mkdir "$(INSTALL_DIR)/mods"
|
||||
@rm -f "$(INSTALL_DIR)/mods/${MOD_JAR_PREFIX}"*.jar
|
||||
@cp -f "$(MOD_JAR)" "$(INSTALL_DIR)/mods/"
|
||||
@echo "[1.12] Installing '$(MOD_JAR)' to '$(SERVER_INSTALL_DIR)/mods' ..."
|
||||
@rm -f "$(SERVER_INSTALL_DIR)/mods/${MOD_JAR_PREFIX}"*.jar
|
||||
@[ -d "$(SERVER_INSTALL_DIR)/mods" ] && cp -f "$(MOD_JAR)" "$(SERVER_INSTALL_DIR)/mods/"
|
||||
|
||||
start-server:
|
||||
-@make -s install
|
||||
@echo "[1.12] Starting local dedicated server ..."
|
||||
@cd "$(SERVER_INSTALL_DIR)" && java -jar forge-1.12.2-14.23.5.2768-universal.jar nogui
|
||||
|
||||
sanatize:
|
||||
@echo "[1.12] Running sanatising tasks ..."
|
||||
@djs tasks.js sanatize
|
||||
@djs tasks.js sync-languages
|
||||
@djs tasks.js version-check
|
||||
@djs tasks.js update-json
|
||||
sanitize:
|
||||
@echo "[1.12] Running sanitising tasks ..."
|
||||
@$(TASK) sanitize
|
||||
@$(TASK) sync-languages
|
||||
@$(TASK) version-check
|
||||
@$(TASK) update-json
|
||||
@git status -s .
|
||||
|
||||
install: $(MOD_JAR) |
|
||||
@$(TASK) install
|
||||
|
||||
start-server: install
|
||||
@$(TASK) start-server
|
||||
|
||||
dist-check:
|
||||
@echo "[1.12] Running dist checks ..."
|
||||
@djs tasks.js dist-check
|
||||
@$(TASK) dist-check
|
||||
|
||||
dist-files: clean-all init mod
|
||||
@echo "[1.12] Distribution files ..."
|
||||
@mkdir -p dist
|
||||
@cp build/libs/$(MOD_JAR_PREFIX)* dist/
|
||||
@djs tasks.js dist
|
||||
@$(TASK) dist
|
||||
|
||||
dist: sanatize dist-check dist-files
|
||||
|
||||
port-languages:
|
||||
@echo "[1.12] Porting language files to 1.14 ..."
|
||||
@djs tasks.js port-languages
|
||||
dist: sanitize dist-check dist-files
|
||||
|
|
|
@ -4,4 +4,4 @@ org.gradle.jvmargs=-Xmx8G
|
|||
version_minecraft=1.12.2
|
||||
version_forge=14.23.5.2768
|
||||
version_jei=4.10.0.198
|
||||
version_engineersdecor=1.1.0-b1
|
||||
version_engineersdecor=1.1.0
|
||||
|
|
|
@ -1,6 +1,9 @@
|
|||
{
|
||||
"homepage": "https://www.curseforge.com/minecraft/mc-mods/engineers-decor/",
|
||||
"1.12.2": {
|
||||
"1.1.0": "[R] Maintenance Release build v1.1.0. Changes: * Compatibility fixes. * E-Furnace speed selection bug fixed. * Block Placer improvements. ~ v1.1.0-b3 [/] Version skipped for 1.12.2.",
|
||||
"1.1.0-b2": "[F] Block Placer defers placements if collidable entities are in the way (issue #98, thx DrakoAlcarus).\n[F] Added Block verification during TE ticking in case devices are moved (issue #101, thx D0CTOR-ZED).",
|
||||
"1.1.0-b1": "[F] Fixed Electrical Furnace speed sanitizing bug (issue #97, thx therobotmenace).\n[M] Changed Labeled Crate Nesting to circumvent server crashing in combination with the Sponge mod.",
|
||||
"1.0.20": "[R] Release based on v1.0.20-b6. Release-to-release changes: * Manual back ported. * Steel Mesh Fence Gate back ported. * E-Furnace speed selection switch back ported. * Labeled Crate back ported. * Minor bug fixes, compatibility changes.",
|
||||
"1.0.20-b6": "[F] Implemented compat related to issue #91.",
|
||||
"1.0.20-b5": "[A] Back-ported Patchouli based Manual (you need to install Vazkii_'s Patchouli, too).\n[A] Back-ported Steel Mesh Fence Gate.\n[M] Minor back-porting compatibility refractoring.",
|
||||
|
@ -88,7 +91,7 @@
|
|||
"1.0.0-b1": "[A] Initial structure.\n[A] Added clinker bricks and clinker brick stairs.\n[A] Added slag bricks and slag brick stairs.\n[A] Added metal rung ladder.\n[A] Added staggered metal steps ladder.\n[A] Added treated wood ladder.\n[A] Added treated wood pole.\n[A] Added treated wood table."
|
||||
},
|
||||
"promos": {
|
||||
"1.12.2-recommended": "1.0.20",
|
||||
"1.12.2-latest": "1.0.20"
|
||||
"1.12.2-recommended": "1.1.0",
|
||||
"1.12.2-latest": "1.1.0"
|
||||
}
|
||||
}
|
|
@ -10,7 +10,21 @@ Mod sources for Minecraft version 1.12.2.
|
|||
----
|
||||
## Version history
|
||||
|
||||
~ v1.1.0-b1 [M]
|
||||
-------------------------------------------------------------------
|
||||
- v1.1.0 [R] Maintenance Release build v1.1.0. Changes:
|
||||
* Compatibility fixes.
|
||||
* E-Furnace speed selection bug fixed.
|
||||
* Block Placer improvements.
|
||||
-------------------------------------------------------------------
|
||||
|
||||
~ v1.1.0-b3 [/] Version skipped for 1.12.2.
|
||||
|
||||
- v1.1.0-b2 [F] Block Placer defers placements if collidable entities are in the way (issue #98, thx DrakoAlcarus).
|
||||
[F] Added Block verification during TE ticking in case devices are moved (issue #101, thx D0CTOR-ZED).
|
||||
|
||||
- v1.1.0-b1 [F] Fixed Electrical Furnace speed sanitizing bug (issue #97, thx therobotmenace).
|
||||
[M] Changed Labeled Crate Nesting to circumvent server crashing
|
||||
in combination with the Sponge mod.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
- v1.0.20 [R] Release based on v1.0.20-b6. Release-to-release changes:
|
||||
|
|
|
@ -212,7 +212,7 @@ public class ModContent
|
|||
ModAuxiliaries.getPixeledAABB(0,0,0, 16,16,16)
|
||||
);
|
||||
|
||||
public static final BlockDecorLabeledCrate.DecorLabeledCrateBlock LABELED_CRATE = new BlockDecorLabeledCrate.DecorLabeledCrateBlock(
|
||||
public static final BlockDecorLabeledCrate LABELED_CRATE = new BlockDecorLabeledCrate(
|
||||
"labeled_crate",
|
||||
BlockDecor.CFG_CUTOUT|BlockDecor.CFG_HORIZIONTAL|BlockDecor.CFG_LOOK_PLACEMENT|BlockDecor.CFG_OPPOSITE_PLACEMENT,
|
||||
Material.WOOD, 0.5f, 128f, SoundType.METAL,
|
||||
|
|
|
@ -266,15 +266,16 @@ public class BlockDecorBreaker extends BlockDecorDirectedHorizontal
|
|||
public void update()
|
||||
{
|
||||
if(--tick_timer_ > 0) return;
|
||||
final IBlockState device_state = world.getBlockState(pos);
|
||||
if(!(device_state.getBlock() instanceof BlockDecorBreaker)) { tick_timer_ = TICK_INTERVAL; return; }
|
||||
if(world.isRemote) {
|
||||
IBlockState state = world.getBlockState(pos);
|
||||
if(!state.getValue(ACTIVE)) {
|
||||
if(!device_state.getValue(ACTIVE)) {
|
||||
tick_timer_ = TICK_INTERVAL;
|
||||
} else {
|
||||
tick_timer_ = 1;
|
||||
// not sure if is so cool to do this each tick ... may be simplified/removed again.
|
||||
SoundEvent sound = SoundEvents.BLOCK_WOOD_HIT;
|
||||
SoundType stype = world.getBlockState(pos.offset(state.getValue(FACING))).getBlock().getSoundType();
|
||||
SoundType stype = world.getBlockState(pos.offset(device_state.getValue(FACING))).getBlock().getSoundType();
|
||||
if((stype == SoundType.CLOTH) || (stype == SoundType.PLANT) || (stype == SoundType.SNOW)) {
|
||||
sound = SoundEvents.BLOCK_CLOTH_HIT;
|
||||
} else if((stype == SoundType.GROUND) || (stype == SoundType.SAND)) {
|
||||
|
@ -284,7 +285,6 @@ public class BlockDecorBreaker extends BlockDecorDirectedHorizontal
|
|||
}
|
||||
} else {
|
||||
tick_timer_ = TICK_INTERVAL;
|
||||
final IBlockState device_state = world.getBlockState(pos);
|
||||
final BlockPos target_pos = pos.offset(device_state.getValue(FACING));
|
||||
final IBlockState target_state = world.getBlockState(target_pos);
|
||||
if((world.isBlockPowered(pos)) || (!isBreakable(target_state, target_pos, world))) {
|
||||
|
|
|
@ -801,6 +801,7 @@ public class BlockDecorDropper extends BlockDecorDirected
|
|||
if((drop_timer_ > 0) && ((--drop_timer_) == 0)) markDirty();
|
||||
if(--tick_timer_ > 0) return;
|
||||
tick_timer_ = TICK_INTERVAL;
|
||||
if(!(world.getBlockState(pos).getBlock() instanceof BlockDecorDropper)) return;
|
||||
boolean dirty = block_power_updated_;
|
||||
final boolean continuous_mode = (drop_logic_ & DROPLOGIC_CONTINUOUS)!=0;
|
||||
boolean redstone_trigger = (block_power_signal_ && ((block_power_updated_) || (continuous_mode)));
|
||||
|
|
|
@ -356,10 +356,12 @@ public class BlockDecorFluidFunnel extends BlockDecor
|
|||
if((world.isRemote) || (--tick_timer_ > 0)) return;
|
||||
tick_timer_ = TICK_INTERVAL;
|
||||
collection_timer_ += TICK_INTERVAL;
|
||||
final IBlockState funnel_state = world.getBlockState(pos);
|
||||
if(!(funnel_state.getBlock() instanceof BlockDecorFluidFunnel)) return;
|
||||
boolean dirty = false;
|
||||
// Collection
|
||||
if((collection_timer_ >= COLLECTION_INTERVAL) && ((tank_==null) || (tank_.amount <= (TANK_CAPACITY-1000)))) {
|
||||
collection_timer_ = 0;
|
||||
collection_timer_ = 0;
|
||||
if(!world.isBlockPowered(pos)) { // redstone disable feature
|
||||
if(last_pick_pos_==null) last_pick_pos_ = pos.up();
|
||||
if(try_collect(pos.up())) dirty = true;
|
||||
|
@ -378,7 +380,6 @@ public class BlockDecorFluidFunnel extends BlockDecor
|
|||
}
|
||||
// Block state
|
||||
int fill_level = (tank_==null) ? 0 : (MathHelper.clamp(tank_.amount/1000,0,FILL_LEVEL_MAX));
|
||||
final IBlockState funnel_state = world.getBlockState(pos);
|
||||
if(funnel_state.getValue(FILL_LEVEL) != fill_level) world.setBlockState(pos, funnel_state.withProperty(FILL_LEVEL, fill_level), 2|16);
|
||||
if(dirty) markDirty();
|
||||
}
|
||||
|
|
|
@ -809,6 +809,8 @@ public class BlockDecorFurnace extends BlockDecorDirected
|
|||
{
|
||||
if(--tick_timer_ > 0) return;
|
||||
tick_timer_ = TICK_INTERVAL;
|
||||
final IBlockState state = world.getBlockState(pos);
|
||||
if(!(state.getBlock() instanceof BlockDecorFurnace)) return;
|
||||
final boolean was_burning = isBurning();
|
||||
if(was_burning) burntime_left_ -= TICK_INTERVAL;
|
||||
if(fuel_burntime_ < 0) fuel_burntime_ = getItemBurnTime(stacks_.get(SMELTING_FUEL_SLOT_NO));
|
||||
|
@ -866,10 +868,7 @@ public class BlockDecorFurnace extends BlockDecorDirected
|
|||
}
|
||||
if(was_burning != isBurning()) {
|
||||
dirty = true;
|
||||
final IBlockState state = world.getBlockState(pos);
|
||||
if(state.getBlock() instanceof BlockDecorFurnace) {
|
||||
world.setBlockState(pos, state.withProperty(LIT, isBurning()));
|
||||
}
|
||||
world.setBlockState(pos, state.withProperty(LIT, isBurning()));
|
||||
}
|
||||
if(dirty) markDirty();
|
||||
}
|
||||
|
|
|
@ -9,10 +9,8 @@
|
|||
package wile.engineersdecor.blocks;
|
||||
|
||||
|
||||
import net.minecraft.init.Blocks;
|
||||
import wile.engineersdecor.ModContent;
|
||||
import wile.engineersdecor.ModEngineersDecor;
|
||||
|
||||
import net.minecraft.block.SoundType;
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.block.state.IBlockState;
|
||||
|
@ -32,6 +30,7 @@ import net.minecraft.util.math.BlockPos;
|
|||
import net.minecraft.util.math.MathHelper;
|
||||
import net.minecraft.util.*;
|
||||
import net.minecraft.stats.StatList;
|
||||
import net.minecraft.init.Blocks;
|
||||
import net.minecraftforge.common.capabilities.Capability;
|
||||
import net.minecraftforge.energy.CapabilityEnergy;
|
||||
import net.minecraftforge.energy.IEnergyStorage;
|
||||
|
@ -316,7 +315,7 @@ public class BlockDecorFurnaceElectrical extends BlockDecorFurnace
|
|||
public static final int HEAT_INCREMENT = 20;
|
||||
public static final int MAX_ENERGY_TRANSFER = 256;
|
||||
public static final int MAX_ENERGY_BUFFER = 32000;
|
||||
public static final int MAX_SPEED_SETTING = 2;
|
||||
public static final int MAX_SPEED_SETTING = 3;
|
||||
public static final int NUM_OF_SLOTS = 7;
|
||||
public static final int SMELTING_INPUT_SLOT_NO = 0;
|
||||
public static final int SMELTING_AUX_SLOT_NO = 1;
|
||||
|
@ -382,7 +381,7 @@ public class BlockDecorFurnaceElectrical extends BlockDecorFurnace
|
|||
proc_time_needed_ = compound.getInteger("CookTimeTotal");
|
||||
energy_stored_ = compound.getInteger("Energy");
|
||||
speed_ = compound.getInteger("SpeedSetting");
|
||||
speed_ = (speed_ < 0) ? (1) : ((speed_>3) ? 3 : speed_);
|
||||
speed_ = (speed_ < 0) ? (1) : ((speed_>MAX_SPEED_SETTING) ? MAX_SPEED_SETTING : speed_);
|
||||
}
|
||||
|
||||
protected void writenbt(NBTTagCompound compound)
|
||||
|
@ -391,7 +390,7 @@ public class BlockDecorFurnaceElectrical extends BlockDecorFurnace
|
|||
compound.setInteger("CookTime", MathHelper.clamp(proc_time_elapsed_, 0, MAX_BURNTIME));
|
||||
compound.setInteger("CookTimeTotal", MathHelper.clamp(proc_time_needed_, 0, MAX_BURNTIME));
|
||||
compound.setInteger("Energy", MathHelper.clamp(energy_stored_,0 , MAX_ENERGY_BUFFER));
|
||||
compound.setInteger("SpeedSetting", MathHelper.clamp(speed_, -1, MAX_SPEED_SETTING));
|
||||
compound.setInteger("SpeedSetting", MathHelper.clamp(speed_, 0, MAX_SPEED_SETTING));
|
||||
ItemStackHelper.saveAllItems(compound, stacks_);
|
||||
}
|
||||
|
||||
|
@ -655,7 +654,7 @@ public class BlockDecorFurnaceElectrical extends BlockDecorFurnace
|
|||
@Override
|
||||
public void onClientPacketReceived(EntityPlayer player, NBTTagCompound nbt)
|
||||
{
|
||||
if(nbt.hasKey("speed")) speed_ = MathHelper.clamp(nbt.getInteger("speed"), 0, 3);
|
||||
if(nbt.hasKey("speed")) speed_ = MathHelper.clamp(nbt.getInteger("speed"), 0, MAX_SPEED_SETTING);
|
||||
markDirty();
|
||||
}
|
||||
|
||||
|
@ -739,6 +738,7 @@ public class BlockDecorFurnaceElectrical extends BlockDecorFurnace
|
|||
{
|
||||
if(--tick_timer_ > 0) return;
|
||||
tick_timer_ = TICK_INTERVAL;
|
||||
if(!(world.getBlockState(pos).getBlock() instanceof BlockDecorFurnaceElectrical)) return;
|
||||
final boolean was_burning = isBurning();
|
||||
if(was_burning) burntime_left_ -= TICK_INTERVAL;
|
||||
if(burntime_left_ < 0) burntime_left_ = 0;
|
||||
|
@ -761,7 +761,7 @@ public class BlockDecorFurnaceElectrical extends BlockDecorFurnace
|
|||
}
|
||||
final ItemStack last_inp_stack = current_smelting_input_stack_;
|
||||
current_smelting_input_stack_ = stacks_.get(SMELTING_INPUT_SLOT_NO);
|
||||
if((!current_smelting_input_stack_.isEmpty()) && (enabled_) && (speed_>0) && (speed_<4)) {
|
||||
if((!current_smelting_input_stack_.isEmpty()) && (enabled_) && (speed_>0) && (speed_<=MAX_SPEED_SETTING)) {
|
||||
if(!current_smelting_input_stack_.isItemEqual(current_smelting_input_stack_)) {
|
||||
proc_time_elapsed_ = 0;
|
||||
proc_time_needed_ = getCookTime(current_smelting_input_stack_);
|
||||
|
|
|
@ -831,12 +831,12 @@ public class BlockDecorHopper extends BlockDecorDirected
|
|||
if((delay_timer_ > 0) && ((--delay_timer_) == 0)) markDirty();
|
||||
if(--tick_timer_ > 0) return;
|
||||
tick_timer_ = TICK_INTERVAL;
|
||||
final IBlockState state = world.getBlockState(pos);
|
||||
if(!(state.getBlock() instanceof BlockDecorHopper)) { block_power_signal_= false; return; }
|
||||
// Cycle init
|
||||
boolean dirty = block_power_updated_;
|
||||
boolean rssignal = ((logic_ & LOGIC_INVERTED)!=0)==(!block_power_signal_);
|
||||
boolean trigger = (rssignal && ((block_power_updated_) || ((logic_ & LOGIC_CONTINUOUS)!=0)));
|
||||
final IBlockState state = world.getBlockState(pos);
|
||||
if(state == null) { block_power_signal_= false; return; }
|
||||
final EnumFacing hopper_facing = state.getValue(FACING);
|
||||
// Trigger edge detection for next cycle
|
||||
{
|
||||
|
|
|
@ -8,6 +8,7 @@
|
|||
*/
|
||||
package wile.engineersdecor.blocks;
|
||||
|
||||
import wile.engineersdecor.ModEngineersDecor;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.SoundType;
|
||||
import net.minecraft.block.material.Material;
|
||||
|
@ -40,13 +41,12 @@ import net.minecraftforge.fml.relauncher.SideOnly;
|
|||
import net.minecraftforge.items.CapabilityItemHandler;
|
||||
import net.minecraftforge.items.IItemHandler;
|
||||
import net.minecraftforge.items.ItemHandlerHelper;
|
||||
import wile.engineersdecor.ModEngineersDecor;
|
||||
|
||||
import javax.annotation.Nonnull;
|
||||
import javax.annotation.Nullable;
|
||||
|
||||
|
||||
public class BlockDecorLabeledCrate
|
||||
public class BlockDecorLabeledCrate extends BlockDecorDirectedHorizontal
|
||||
{
|
||||
public static void on_config(int stack_limit)
|
||||
{
|
||||
|
@ -56,94 +56,129 @@ public class BlockDecorLabeledCrate
|
|||
// Block
|
||||
//--------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
public static class DecorLabeledCrateBlock extends BlockDecorDirectedHorizontal
|
||||
public BlockDecorLabeledCrate(@Nonnull String registryName, long config, @Nullable Material material, float hardness, float resistance, @Nullable SoundType sound, @Nonnull AxisAlignedBB unrotatedAABB)
|
||||
{ super(registryName, config, material, hardness, resistance, sound, unrotatedAABB); }
|
||||
|
||||
@Override
|
||||
public boolean hasTileEntity(IBlockState state)
|
||||
{ return true; }
|
||||
|
||||
@Override
|
||||
@Nullable
|
||||
public TileEntity createTileEntity(World world, IBlockState state)
|
||||
{ return new LabeledCrateTileEntity(); }
|
||||
|
||||
@Override
|
||||
public boolean onBlockActivated(World world, BlockPos pos, IBlockState state, EntityPlayer player, EnumHand hand, EnumFacing facing, float hitX, float hitY, float hitZ)
|
||||
{
|
||||
public DecorLabeledCrateBlock(@Nonnull String registryName, long config, @Nullable Material material, float hardness, float resistance, @Nullable SoundType sound, @Nonnull AxisAlignedBB unrotatedAABB)
|
||||
{ super(registryName, config, material, hardness, resistance, sound, unrotatedAABB); }
|
||||
if(world.isRemote) return true;
|
||||
player.openGui(ModEngineersDecor.instance, ModEngineersDecor.GuiHandler.GUIID_LABELED_CRATE, world, pos.getX(), pos.getY(), pos.getZ());
|
||||
return true;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean hasTileEntity(IBlockState state)
|
||||
{ return true; }
|
||||
@Override
|
||||
public void onBlockPlacedBy(World world, BlockPos pos, IBlockState state, EntityLivingBase placer, ItemStack stack)
|
||||
{
|
||||
if(world.isRemote) return;
|
||||
if((!stack.hasTagCompound()) || (!stack.getTagCompound().hasKey("inventory"))) return;
|
||||
NBTTagCompound inventory_nbt = stack.getTagCompound().getCompoundTag("inventory");
|
||||
if(inventory_nbt.isEmpty()) return;
|
||||
final TileEntity te = world.getTileEntity(pos);
|
||||
if(!(te instanceof LabeledCrateTileEntity)) return;
|
||||
((LabeledCrateTileEntity)te).readnbt(inventory_nbt);
|
||||
((LabeledCrateTileEntity)te).markDirty();
|
||||
}
|
||||
|
||||
@Override
|
||||
@Nullable
|
||||
public TileEntity createTileEntity(World world, IBlockState state)
|
||||
{ return new LabeledCrateTileEntity(); }
|
||||
private ItemStack itemize_with_inventory(World world, BlockPos pos)
|
||||
{
|
||||
TileEntity te = world.getTileEntity(pos);
|
||||
if(!(te instanceof LabeledCrateTileEntity)) return ItemStack.EMPTY;
|
||||
ItemStack stack = new ItemStack(this, 1);
|
||||
NBTTagCompound inventory_nbt = new NBTTagCompound();
|
||||
ItemStackHelper.saveAllItems(inventory_nbt, ((LabeledCrateTileEntity)te).stacks_, false);
|
||||
if(!inventory_nbt.isEmpty()) {
|
||||
NBTTagCompound nbt = new NBTTagCompound();
|
||||
nbt.setTag("inventory", inventory_nbt);
|
||||
stack.setTagCompound(nbt);
|
||||
}
|
||||
return stack;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean onBlockActivated(World world, BlockPos pos, IBlockState state, EntityPlayer player, EnumHand hand, EnumFacing facing, float hitX, float hitY, float hitZ)
|
||||
@Override
|
||||
public boolean removedByPlayer(IBlockState state, World world, BlockPos pos, EntityPlayer player, boolean willHarvest)
|
||||
{
|
||||
if(world.isRemote) return true;
|
||||
final ItemStack stack = itemize_with_inventory(world, pos);
|
||||
if(stack != ItemStack.EMPTY) {
|
||||
world.spawnEntity(new EntityItem(world, pos.getX()+0.5, pos.getY()+0.5, pos.getZ()+0.5, stack));
|
||||
world.setBlockToAir(pos);
|
||||
world.removeTileEntity(pos);
|
||||
return false;
|
||||
} else {
|
||||
return super.removedByPlayer(state, world, pos, player, willHarvest);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onBlockExploded(World world, BlockPos pos, Explosion explosion)
|
||||
{
|
||||
if(world.isRemote) return;
|
||||
TileEntity te = world.getTileEntity(pos);
|
||||
if(!(te instanceof LabeledCrateTileEntity)) return;
|
||||
for(ItemStack stack: ((LabeledCrateTileEntity)te).stacks_) {
|
||||
if(!stack.isEmpty()) world.spawnEntity(new EntityItem(world, pos.getX(), pos.getY(), pos.getZ(), stack));
|
||||
}
|
||||
((LabeledCrateTileEntity)te).reset();
|
||||
super.onBlockExploded(world, pos, explosion);
|
||||
}
|
||||
|
||||
@Override
|
||||
@SuppressWarnings("deprecation")
|
||||
public boolean hasComparatorInputOverride(IBlockState state)
|
||||
{ return true; }
|
||||
|
||||
@Override
|
||||
@SuppressWarnings("deprecation")
|
||||
public int getComparatorInputOverride(IBlockState blockState, World world, BlockPos pos)
|
||||
{ return Container.calcRedstone(world.getTileEntity(pos)); }
|
||||
|
||||
//--------------------------------------------------------------------------------------------------------------------
|
||||
// GUI
|
||||
//--------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
private static class BGui extends GuiContainer
|
||||
{
|
||||
private final LabeledCrateTileEntity te;
|
||||
|
||||
public BGui(InventoryPlayer playerInventory, World world, BlockPos pos, LabeledCrateTileEntity te)
|
||||
{
|
||||
if(world.isRemote) return true;
|
||||
player.openGui(ModEngineersDecor.instance, ModEngineersDecor.GuiHandler.GUIID_LABELED_CRATE, world, pos.getX(), pos.getY(), pos.getZ());
|
||||
return true;
|
||||
super(new BContainer(playerInventory, world, pos, te));
|
||||
this.te = te;
|
||||
xSize = 213;
|
||||
ySize = 206;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onBlockPlacedBy(World world, BlockPos pos, IBlockState state, EntityLivingBase placer, ItemStack stack)
|
||||
{
|
||||
if(world.isRemote) return;
|
||||
if((!stack.hasTagCompound()) || (!stack.getTagCompound().hasKey("inventory"))) return;
|
||||
NBTTagCompound inventory_nbt = stack.getTagCompound().getCompoundTag("inventory");
|
||||
if(inventory_nbt.isEmpty()) return;
|
||||
final TileEntity te = world.getTileEntity(pos);
|
||||
if(!(te instanceof LabeledCrateTileEntity)) return;
|
||||
((LabeledCrateTileEntity)te).readnbt(inventory_nbt);
|
||||
((LabeledCrateTileEntity)te).markDirty();
|
||||
}
|
||||
public void initGui()
|
||||
{ super.initGui(); }
|
||||
|
||||
private ItemStack itemize_with_inventory(World world, BlockPos pos)
|
||||
@Override
|
||||
public void drawScreen(int mouseX, int mouseY, float partialTicks)
|
||||
{
|
||||
TileEntity te = world.getTileEntity(pos);
|
||||
if(!(te instanceof LabeledCrateTileEntity)) return ItemStack.EMPTY;
|
||||
ItemStack stack = new ItemStack(this, 1);
|
||||
NBTTagCompound inventory_nbt = new NBTTagCompound();
|
||||
ItemStackHelper.saveAllItems(inventory_nbt, ((LabeledCrateTileEntity)te).stacks_, false);
|
||||
if(!inventory_nbt.isEmpty()) {
|
||||
NBTTagCompound nbt = new NBTTagCompound();
|
||||
nbt.setTag("inventory", inventory_nbt);
|
||||
stack.setTagCompound(nbt);
|
||||
}
|
||||
return stack;
|
||||
drawDefaultBackground();
|
||||
super.drawScreen(mouseX, mouseY, partialTicks);
|
||||
renderHoveredToolTip(mouseX, mouseY);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean removedByPlayer(IBlockState state, World world, BlockPos pos, EntityPlayer player, boolean willHarvest)
|
||||
protected void drawGuiContainerBackgroundLayer(float partialTicks, int mouseX, int mouseY)
|
||||
{
|
||||
if(world.isRemote) return true;
|
||||
final ItemStack stack = itemize_with_inventory(world, pos);
|
||||
if(stack != ItemStack.EMPTY) {
|
||||
world.spawnEntity(new EntityItem(world, pos.getX()+0.5, pos.getY()+0.5, pos.getZ()+0.5, stack));
|
||||
world.setBlockToAir(pos);
|
||||
world.removeTileEntity(pos);
|
||||
return false;
|
||||
} else {
|
||||
return super.removedByPlayer(state, world, pos, player, willHarvest);
|
||||
}
|
||||
GlStateManager.color(1.0F, 1.0F, 1.0F, 1.0F);
|
||||
mc.getTextureManager().bindTexture(new ResourceLocation(ModEngineersDecor.MODID, "textures/gui/labeled_crate_gui.png"));
|
||||
final int x0=guiLeft, y0=guiTop, w=xSize, h=ySize;
|
||||
drawTexturedModalRect(x0, y0, 0, 0, w, h);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void onBlockExploded(World world, BlockPos pos, Explosion explosion)
|
||||
{
|
||||
if(world.isRemote) return;
|
||||
TileEntity te = world.getTileEntity(pos);
|
||||
if(!(te instanceof LabeledCrateTileEntity)) return;
|
||||
for(ItemStack stack: ((LabeledCrateTileEntity)te).stacks_) {
|
||||
if(!stack.isEmpty()) world.spawnEntity(new EntityItem(world, pos.getX(), pos.getY(), pos.getZ(), stack));
|
||||
}
|
||||
((LabeledCrateTileEntity)te).reset();
|
||||
super.onBlockExploded(world, pos, explosion);
|
||||
}
|
||||
|
||||
@Override
|
||||
@SuppressWarnings("deprecation")
|
||||
public boolean hasComparatorInputOverride(IBlockState state)
|
||||
{ return true; }
|
||||
|
||||
@Override
|
||||
@SuppressWarnings("deprecation")
|
||||
public int getComparatorInputOverride(IBlockState blockState, World world, BlockPos pos)
|
||||
{ return Container.calcRedstone(world.getTileEntity(pos)); }
|
||||
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------------------------
|
||||
|
@ -184,7 +219,7 @@ public class BlockDecorLabeledCrate
|
|||
|
||||
@Override
|
||||
public boolean shouldRefresh(World world, BlockPos pos, IBlockState os, IBlockState ns)
|
||||
{ return (os.getBlock()!=ns.getBlock())||(!(ns.getBlock() instanceof DecorLabeledCrateBlock));}
|
||||
{ return (os.getBlock()!=ns.getBlock())||(!(ns.getBlock() instanceof BlockDecorLabeledCrate));}
|
||||
|
||||
@Override
|
||||
public void readFromNBT(NBTTagCompound compound)
|
||||
|
@ -445,45 +480,6 @@ public class BlockDecorLabeledCrate
|
|||
}
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------------------------
|
||||
// GUI
|
||||
//--------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
@SideOnly(Side.CLIENT)
|
||||
private static class BGui extends GuiContainer
|
||||
{
|
||||
private final LabeledCrateTileEntity te;
|
||||
|
||||
public BGui(InventoryPlayer playerInventory, World world, BlockPos pos, LabeledCrateTileEntity te)
|
||||
{
|
||||
super(new BContainer(playerInventory, world, pos, te));
|
||||
this.te = te;
|
||||
xSize = 213;
|
||||
ySize = 206;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void initGui()
|
||||
{ super.initGui(); }
|
||||
|
||||
@Override
|
||||
public void drawScreen(int mouseX, int mouseY, float partialTicks)
|
||||
{
|
||||
drawDefaultBackground();
|
||||
super.drawScreen(mouseX, mouseY, partialTicks);
|
||||
renderHoveredToolTip(mouseX, mouseY);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void drawGuiContainerBackgroundLayer(float partialTicks, int mouseX, int mouseY)
|
||||
{
|
||||
GlStateManager.color(1.0F, 1.0F, 1.0F, 1.0F);
|
||||
mc.getTextureManager().bindTexture(new ResourceLocation(ModEngineersDecor.MODID, "textures/gui/labeled_crate_gui.png"));
|
||||
final int x0=guiLeft, y0=guiTop, w=xSize, h=ySize;
|
||||
drawTexturedModalRect(x0, y0, 0, 0, w, h);
|
||||
}
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------------------------
|
||||
// Container
|
||||
//--------------------------------------------------------------------------------------------------------------------
|
||||
|
@ -542,7 +538,7 @@ public class BlockDecorLabeledCrate
|
|||
|
||||
@Override
|
||||
public boolean canInteractWith(EntityPlayer player)
|
||||
{ return (world.getBlockState(pos).getBlock() instanceof DecorLabeledCrateBlock) && (player.getDistanceSq(pos) <= 64); }
|
||||
{ return (world.getBlockState(pos).getBlock() instanceof BlockDecorLabeledCrate) && (player.getDistanceSq(pos) <= 64); }
|
||||
|
||||
@Override
|
||||
public boolean canMergeSlot(ItemStack stack, Slot slot)
|
||||
|
|
|
@ -531,6 +531,7 @@ public class BlockDecorMilker extends BlockDecorDirectedHorizontal
|
|||
if((world.isRemote) || ((--tick_timer_ > 0))) return;
|
||||
tick_timer_ = TICK_INTERVAL;
|
||||
final IBlockState block_state = world.getBlockState(pos);
|
||||
if(!(block_state.getBlock() instanceof BlockDecorMilker)) return;
|
||||
boolean dirty = false;
|
||||
if(energy_consumption > 0) {
|
||||
if(energy_stored_ <= 0) return;
|
||||
|
|
|
@ -627,6 +627,8 @@ public class BlockDecorMineralSmelter extends BlockDecorDirectedHorizontal
|
|||
if(world.isRemote) return;
|
||||
if(--tick_timer_ > 0) return;
|
||||
tick_timer_ = TICK_INTERVAL;
|
||||
IBlockState state = world.getBlockState(pos);
|
||||
if(!(state.getBlock() instanceof BlockDecorMineralSmelter)) return;
|
||||
boolean dirty = false;
|
||||
final int last_phase = phase();
|
||||
final ItemStack istack = stacks_.get(0);
|
||||
|
@ -702,8 +704,7 @@ public class BlockDecorMineralSmelter extends BlockDecorDirectedHorizontal
|
|||
}
|
||||
}
|
||||
}
|
||||
IBlockState state = world.getBlockState(pos);
|
||||
if((state.getBlock() instanceof BlockDecorMineralSmelter) && (force_block_update_ || (state.getValue(PHASE) != new_phase))) {
|
||||
if(force_block_update_ || (state.getValue(PHASE) != new_phase)) {
|
||||
state = state.withProperty(PHASE, new_phase);
|
||||
world.setBlockState(pos, state,3|16);
|
||||
world.notifyNeighborsOfStateChange(pos, state.getBlock(),false);
|
||||
|
|
|
@ -207,10 +207,10 @@ public class BlockDecorPassiveFluidAccumulator extends BlockDecorDirected
|
|||
{
|
||||
if((world.isRemote) || (--tick_timer_ > 0)) return;
|
||||
tick_timer_ = tick_idle_interval;
|
||||
final IBlockState state = world.getBlockState(pos);
|
||||
if(!(state.getBlock() instanceof BlockDecorPassiveFluidAccumulator)) return;
|
||||
if(!initialized_) {
|
||||
initialized_ = true;
|
||||
IBlockState state = world.getBlockState(pos);
|
||||
if((state==null) || (!(state.getBlock() instanceof BlockDecorPassiveFluidAccumulator))) return;
|
||||
block_facing_ = state.getValue(FACING);
|
||||
}
|
||||
int n_requested = last_drain_request_amount_;
|
||||
|
|
|
@ -720,7 +720,7 @@ public class BlockDecorPlacer extends BlockDecorDirected
|
|||
}
|
||||
return spit_out(facing);
|
||||
}
|
||||
if(world.getEntitiesWithinAABB(EntityLivingBase.class, new AxisAlignedBB(placement_pos)).size() > 0) return false;
|
||||
if(world.getEntitiesWithinAABB(Entity.class, new AxisAlignedBB(placement_pos), Entity::canBeCollidedWith).size() > 0) return false;
|
||||
if(!world.getBlockState(placement_pos).getBlock().isReplaceable(world, placement_pos)) return false;
|
||||
try {
|
||||
final FakePlayer placer = net.minecraftforge.common.util.FakePlayerFactory.getMinecraft((net.minecraft.world.WorldServer)world);
|
||||
|
@ -748,12 +748,12 @@ public class BlockDecorPlacer extends BlockDecorDirected
|
|||
if(world.isRemote) return;
|
||||
if(--tick_timer_ > 0) return;
|
||||
tick_timer_ = TICK_INTERVAL;
|
||||
final IBlockState state = world.getBlockState(pos);
|
||||
if(!(state.getBlock() instanceof BlockDecorPlacer)) { block_power_signal_= false; return; }
|
||||
// Cycle init
|
||||
boolean dirty = block_power_updated_;
|
||||
boolean rssignal = ((logic_ & LOGIC_INVERTED)!=0)==(!block_power_signal_);
|
||||
boolean trigger = (rssignal && ((block_power_updated_) || ((logic_ & LOGIC_CONTINUOUS)!=0)));
|
||||
final IBlockState state = world.getBlockState(pos);
|
||||
if(state == null) { block_power_signal_= false; return; }
|
||||
final EnumFacing placer_facing = state.getValue(FACING);
|
||||
// Trigger edge detection for next cycle
|
||||
{
|
||||
|
|
|
@ -167,6 +167,8 @@ public class BlockDecorSolarPanel extends BlockDecor
|
|||
{
|
||||
if((world.isRemote) || (--tick_timer_ > 0)) return;
|
||||
tick_timer_ = TICK_INTERVAL;
|
||||
final IBlockState state = world.getBlockState(pos);
|
||||
if(!(state.getBlock() instanceof BlockDecorSolarPanel)) return;
|
||||
current_feedin_ = 0;
|
||||
if(accumulated_power_ > 0) {
|
||||
for(int i=0; (i<transfer_directions_.length) && (accumulated_power_>0); ++i) {
|
||||
|
@ -184,13 +186,11 @@ public class BlockDecorSolarPanel extends BlockDecor
|
|||
if(!world.canSeeSky(pos)) {
|
||||
tick_timer_ = TICK_INTERVAL * 5;
|
||||
current_production_ = 0;
|
||||
IBlockState state = world.getBlockState(pos);
|
||||
if(state.getValue((EXPOSITION))!=2) world.setBlockState(pos, state.withProperty(EXPOSITION, 2));
|
||||
return;
|
||||
}
|
||||
if(--recalc_timer_ > 0) return;
|
||||
recalc_timer_ = ACCUMULATION_INTERVAL + ((int)(Math.random()+.5));
|
||||
IBlockState state = world.getBlockState(pos);
|
||||
int theta = ((((int)(world.getCelestialAngleRadians(1f) * (180.0/Math.PI)))+90) % 360);
|
||||
int e = 2;
|
||||
if(theta > 340) e = 2;
|
||||
|
@ -199,7 +199,7 @@ public class BlockDecorSolarPanel extends BlockDecor
|
|||
else if(theta < 100) e = 2;
|
||||
else if(theta < 135) e = 3;
|
||||
else if(theta < 190) e = 4;
|
||||
IBlockState nstate = state.withProperty(EXPOSITION, e);
|
||||
final IBlockState nstate = state.withProperty(EXPOSITION, e);
|
||||
if(nstate != state) world.setBlockState(pos, nstate, 1|2);
|
||||
final double eff = (1.0-((world.getRainStrength(1f)*0.6)+(world.getThunderStrength(1f)*0.3)));
|
||||
final double rf = Math.sin((Math.PI/2) * Math.sqrt(((double)(((theta<0)||(theta>180))?(0):((theta>90)?(180-theta):(theta))))/90));
|
||||
|
|
|
@ -215,8 +215,10 @@ public class BlockDecorTreeCutter extends BlockDecorDirectedHorizontal
|
|||
public void update()
|
||||
{
|
||||
if(--tick_timer_ > 0) return;
|
||||
final IBlockState device_state = world.getBlockState(pos);
|
||||
if(!(device_state.getBlock() instanceof BlockDecorTreeCutter)) { tick_timer_ = TICK_INTERVAL; return; }
|
||||
if(world.isRemote) {
|
||||
if(!world.getBlockState(pos).getValue(ACTIVE)) {
|
||||
if(!device_state.getValue(ACTIVE)) {
|
||||
tick_timer_ = TICK_INTERVAL;
|
||||
} else {
|
||||
tick_timer_ = 1;
|
||||
|
@ -224,7 +226,6 @@ public class BlockDecorTreeCutter extends BlockDecorDirectedHorizontal
|
|||
}
|
||||
} else {
|
||||
tick_timer_ = TICK_INTERVAL;
|
||||
final IBlockState device_state = world.getBlockState(pos);
|
||||
final BlockPos tree_pos = pos.offset(device_state.getValue(FACING));
|
||||
final IBlockState tree_state = world.getBlockState(tree_pos);
|
||||
if(!TreeCutting.canChop(tree_state) || (world.isBlockPowered(pos))) {
|
||||
|
|
|
@ -656,6 +656,8 @@ public class BlockDecorWasteIncinerator extends BlockDecor
|
|||
if(--tick_timer_ > 0) return;
|
||||
tick_timer_ = TICK_INTERVAL;
|
||||
if(world.isRemote) return;
|
||||
final IBlockState state = world.getBlockState(pos);
|
||||
if(!(state.getBlock() instanceof BlockDecorWasteIncinerator)) return;
|
||||
boolean dirty = false;
|
||||
ItemStack processing_stack = stacks_.get(BURN_SLOT_NO);
|
||||
final boolean was_processing = !processing_stack.isEmpty();
|
||||
|
@ -694,10 +696,7 @@ public class BlockDecorWasteIncinerator extends BlockDecor
|
|||
}
|
||||
if((was_processing != is_processing) || (new_stack_processing)) {
|
||||
if(new_stack_processing) world.playSound(null, pos, SoundEvents.BLOCK_LAVA_AMBIENT, SoundCategory.BLOCKS, 0.05f, 2.4f);
|
||||
final IBlockState state = world.getBlockState(pos);
|
||||
if(state.getBlock() instanceof BlockDecorWasteIncinerator) {
|
||||
world.setBlockState(pos, state.withProperty(LIT, is_processing), 2|16);
|
||||
}
|
||||
world.setBlockState(pos, state.withProperty(LIT, is_processing), 2|16);
|
||||
}
|
||||
if(dirty) markDirty();
|
||||
}
|
||||
|
|
|
@ -28,7 +28,6 @@ import net.minecraft.util.math.MathHelper;
|
|||
import net.minecraftforge.fml.relauncher.Side;
|
||||
import net.minecraftforge.fml.relauncher.SideOnly;
|
||||
import wile.engineersdecor.blocks.BlockDecorLabeledCrate;
|
||||
import wile.engineersdecor.blocks.BlockDecorLabeledCrate.DecorLabeledCrateBlock;
|
||||
import wile.engineersdecor.blocks.BlockDecorTest;
|
||||
|
||||
public class ModTesrs
|
||||
|
@ -114,7 +113,7 @@ public class ModTesrs
|
|||
try {
|
||||
final ItemStack stack = te.getItemFrameStack();
|
||||
if(stack.isEmpty()) return;
|
||||
final int di = MathHelper.clamp(te.getWorld().getBlockState(te.getPos()).getValue(DecorLabeledCrateBlock.FACING).getHorizontalIndex(), 0, 3);
|
||||
final int di = MathHelper.clamp(te.getWorld().getBlockState(te.getPos()).getValue(BlockDecorLabeledCrate.FACING).getHorizontalIndex(), 0, 3);
|
||||
double ox = tr[di][0], oy = tr[di][1], oz = tr[di][2], ry = tr[di][3];
|
||||
GlStateManager.pushMatrix();
|
||||
GlStateManager.disableLighting();
|
||||
|
|
|
@ -1,25 +0,0 @@
|
|||
#!/usr/bin/djs
|
||||
// Note for reviewers/clones: This file is a auxiliary script for my setup. It's not needed to build the mod.
|
||||
"use strict";
|
||||
const constants = include("../meta/lib/constants.js")();
|
||||
const libtask = include("../meta/lib/libtask.js")(constants);
|
||||
const liblang = include("../meta/lib/liblang.1.12.js")(constants);
|
||||
const liblang13 = include("../meta/lib/liblang.1.13.js")(constants);
|
||||
const liblang14 = include("../meta/lib/liblang.1.13.js")(constants);
|
||||
var tasks = {};
|
||||
|
||||
tasks["sync-languages"] = function() {
|
||||
liblang.sync_languages();
|
||||
};
|
||||
|
||||
tasks["port-languages"] = function() {
|
||||
fs.find("src/main/resources/assets/"+ constants.mod_registry_name() +"/lang", '*.lang', function(path){
|
||||
const unified = liblang.load(path);
|
||||
path = path.replace(/\.lang$/,"");
|
||||
liblang13.save("../1.13/"+path+".json", unified);
|
||||
liblang14.save("../1.14/"+path+".json", unified);
|
||||
return false;
|
||||
});
|
||||
};
|
||||
|
||||
libtask.run(tasks, sys.args);
|
|
@ -18,13 +18,14 @@ GRADLE=./gradlew --no-daemon
|
|||
GRADLE_STOP=./gradlew --stop
|
||||
DJS=djs
|
||||
endif
|
||||
TASK=$(DJS) ../meta/lib/tasks.js
|
||||
|
||||
wildcardr=$(foreach d,$(wildcard $1*),$(call wildcardr,$d/,$2) $(filter $(subst *,%,$2),$d))
|
||||
|
||||
#
|
||||
# Targets
|
||||
#
|
||||
.PHONY: default mod data init clean clean-all mrproper all run install sanatize dist-check dist start-server assets
|
||||
.PHONY: default mod data init clean clean-all mrproper all run install sanitize dist-check dist start-server assets
|
||||
|
||||
default: mod
|
||||
|
||||
|
@ -34,9 +35,13 @@ mod:
|
|||
@echo "[1.14] Building mod using gradle ..."
|
||||
@$(GRADLE) build $(GRADLE_OPTS)
|
||||
|
||||
assets:
|
||||
@echo "[1.14] Running asset generators ..."
|
||||
@$(TASK) assets
|
||||
|
||||
data:
|
||||
@echo "[1.14] Running data generators ..."
|
||||
@djs tasks.js datagen
|
||||
@$(TASK) datagen
|
||||
|
||||
clean:
|
||||
@echo "[1.14] Cleaning ..."
|
||||
|
@ -64,28 +69,28 @@ init:
|
|||
@echo "[1.14] Initialising eclipse workspace using gradle ..."
|
||||
@$(GRADLE) eclipse
|
||||
|
||||
sanatize:
|
||||
@echo "[1.14] Running sanatising tasks ..."
|
||||
@djs tasks.js sanatize
|
||||
@djs tasks.js sync-languages
|
||||
@djs tasks.js version-check
|
||||
@djs tasks.js update-json
|
||||
sanitize:
|
||||
@echo "[1.14] Running sanitising tasks ..."
|
||||
@$(TASK) sanitize
|
||||
@$(TASK) sync-languages
|
||||
@$(TASK) version-check
|
||||
@$(TASK) update-json
|
||||
@git status -s .
|
||||
|
||||
install: $(MOD_JAR) |
|
||||
@$(TASK) install
|
||||
|
||||
start-server: install
|
||||
@$(TASK) start-server
|
||||
|
||||
dist-check:
|
||||
@echo "[1.14] Running dist checks ..."
|
||||
@djs tasks.js dist-check
|
||||
@$(TASK) dist-check
|
||||
|
||||
dist-files: clean-all init data mod
|
||||
@echo "[1.14] Distribution files ..."
|
||||
@mkdir -p dist
|
||||
@cp build/libs/$(MOD_JAR_PREFIX)* dist/
|
||||
@djs tasks.js dist
|
||||
@$(TASK) dist
|
||||
|
||||
dist: sanatize dist-check dist-files
|
||||
|
||||
assets:
|
||||
@echo "[1.14] Running asset generators ..."
|
||||
@djs tasks.js create-slab-assets
|
||||
@djs tasks.js create-half-slab-assets
|
||||
@djs tasks.js assets
|
||||
dist: sanitize dist-check dist-files
|
||||
|
|
|
@ -5,4 +5,4 @@ version_minecraft=1.14.4
|
|||
version_forge_minecraft=1.14.4-28.2.3
|
||||
version_fml_mappings=20190719-1.14.3
|
||||
version_jei=1.14.4:6.0.0.10
|
||||
version_engineersdecor=1.1.0-b1
|
||||
version_engineersdecor=1.1.0
|
||||
|
|
|
@ -1,6 +1,10 @@
|
|||
{
|
||||
"homepage": "https://www.curseforge.com/minecraft/mc-mods/engineers-decor/",
|
||||
"1.14.4": {
|
||||
"1.1.0": "[R] Release build v1.1.0. Changes: * GUI button/slider tooltips added (1.5s delay). * IE Sheet Metal Slab Slices added. * Config options extended/updated. * Block Placer improvements. * Block Breaker drop trajectory improved. * Dense Grit Sand textures enhanced. * Pipe Valve redstone connector display fixes. * Compatibility bug fixes.\n[F] Block Placer also defers placements if falling item stacks are in front of it (thx Cid).",
|
||||
"1.1.0-b3": "[F] Block Placer defers placements if collidable entities are in the way (issue #98, thx DrakoAlcarus).\n[M] Block Breaker item drop trajectories have lower speed (fall slightly straighter down).\n[M] Pipe Valves redstone connector also shown if the adjacent block can connect redstone in general.\n[F] Added Block verification during TE ticking in case devices are moved (issue #101, thx D0CTOR-ZED).",
|
||||
"1.1.0-b2": "[A] Added tooltips for buttons/settings in device GUIs (1.5s display delay).",
|
||||
"1.1.0-b1": "[F] Fixed Electrical Furnace speed sanitizing bug (issue #97, thx therobotmenace).\n[A] Sheet Metal Slab Slices added (only available if IE is installed).\n[M] Config options extended/updated.\n[M] Dense Grit Sand textures altered to get slightly more visible structure from distance.",
|
||||
"1.0.20-b7": "[A] Dense Grit Sand added.\n[!] Variant Slab compatibility fix. *This may alter placed slabs of this mod, data fixers don't work yet unfortunately*.",
|
||||
"1.0.20-b6": "[M] Slab Slice placement improved.\n[M] Quite some naming/refractoring under the hood.",
|
||||
"1.0.20-b5": "[A] Electrical Furnace can draw in smelting input items from an adjacent inventory when a Hopper is placed in the auxiliary slot.\n[M] Wrapped Labeled Crate label slot to prevent sorting mods from altering the label.",
|
||||
|
@ -55,7 +59,7 @@
|
|||
"1.0.7-b3": "[A] Initial 1.14.2 port of decorative blocks."
|
||||
},
|
||||
"promos": {
|
||||
"1.14.4-recommended": "",
|
||||
"1.14.4-latest": "1.0.20-b7"
|
||||
"1.14.4-recommended": "1.1.0",
|
||||
"1.14.4-latest": "1.1.0"
|
||||
}
|
||||
}
|
|
@ -11,7 +11,31 @@ Mod sources for Minecraft version 1.14.4.
|
|||
|
||||
## Version history
|
||||
|
||||
~ v1.1.0-b1 [M]
|
||||
-------------------------------------------------------------------
|
||||
- v1.1.0 [R] Release build v1.1.0. Changes:
|
||||
* GUI button/slider tooltips added (1.5s delay).
|
||||
* IE Sheet Metal Slab Slices added.
|
||||
* Config options extended/updated.
|
||||
* Block Placer improvements.
|
||||
* Block Breaker drop trajectory improved.
|
||||
* Dense Grit Sand textures enhanced.
|
||||
* Pipe Valve redstone connector display fixes.
|
||||
* Compatibility bug fixes.
|
||||
-------------------------------------------------------------------
|
||||
[F] Block Placer also defers placements if falling item stacks are in front of it (thx Cid).
|
||||
|
||||
- v1.1.0-b3 [F] Block Placer defers placements if collidable entities are in the way (issue #98, thx DrakoAlcarus).
|
||||
[M] Block Breaker item drop trajectories have lower speed (fall slightly straighter down).
|
||||
[M] Pipe Valves redstone connector also shown if the adjacent block can connect redstone in general.
|
||||
[F] Added Block verification during TE ticking in case devices are moved (issue #101, thx D0CTOR-ZED).
|
||||
|
||||
- v1.1.0-b2 [A] Added tooltips for buttons/settings in device GUIs (1.5s display delay).
|
||||
|
||||
- v1.1.0-b1 [F] Fixed Electrical Furnace speed sanitizing bug (issue #97, thx therobotmenace).
|
||||
[A] Sheet Metal Slab Slices added (only available if IE is installed).
|
||||
[M] Config options extended/updated.
|
||||
[M] Dense Grit Sand textures altered to get slightly more visible structure
|
||||
from distance.
|
||||
|
||||
- v1.0.20-b7 [A] Dense Grit Sand added.
|
||||
[!] Variant Slab compatibility fix. *This may alter placed slabs of this mod,
|
||||
|
|
|
@ -12,20 +12,22 @@ package wile.engineersdecor;
|
|||
import wile.engineersdecor.blocks.*;
|
||||
import wile.engineersdecor.libmc.blocks.StandardBlocks;
|
||||
import wile.engineersdecor.libmc.detail.Auxiliaries;
|
||||
import wile.engineersdecor.libmc.detail.OptionalRecipeCondition;
|
||||
import net.minecraft.nbt.CompoundNBT;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraftforge.common.ForgeConfigSpec;
|
||||
import org.apache.commons.lang3.tuple.Pair;
|
||||
import org.apache.logging.log4j.Logger;
|
||||
|
||||
import javax.annotation.Nullable;
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashSet;
|
||||
|
||||
public class ModConfig
|
||||
{
|
||||
//--------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
private static final Logger LOGGER = ModEngineersDecor.logger();
|
||||
private static final String MODID = ModEngineersDecor.MODID;
|
||||
public static final CommonConfig COMMON;
|
||||
public static final ServerConfig SERVER;
|
||||
public static final ClientConfig CLIENT;
|
||||
|
@ -61,11 +63,11 @@ public class ModConfig
|
|||
builder.comment("Opt-out settings")
|
||||
.push("optout");
|
||||
without_tooltips = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_tooltips")
|
||||
.translation(MODID + ".config.without_tooltips")
|
||||
.comment("Disable CTRL-SHIFT item tooltip display.")
|
||||
.define("without_tooltips", false);
|
||||
without_ters = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_ters")
|
||||
.translation(MODID + ".config.without_ters")
|
||||
.comment("Disable all TERs (tile entity renderers).")
|
||||
.define("without_ters", false);
|
||||
}
|
||||
|
@ -95,12 +97,14 @@ public class ModConfig
|
|||
public final ForgeConfigSpec.BooleanValue without_clinker_bricks;
|
||||
public final ForgeConfigSpec.BooleanValue without_slag_bricks;
|
||||
public final ForgeConfigSpec.BooleanValue without_rebar_concrete;
|
||||
public final ForgeConfigSpec.BooleanValue without_gas_concrete;
|
||||
public final ForgeConfigSpec.BooleanValue without_walls;
|
||||
public final ForgeConfigSpec.BooleanValue without_stairs;
|
||||
public final ForgeConfigSpec.BooleanValue without_ie_concrete_wall;
|
||||
public final ForgeConfigSpec.BooleanValue without_panzer_glass;
|
||||
public final ForgeConfigSpec.BooleanValue without_ladders;
|
||||
public final ForgeConfigSpec.BooleanValue without_treated_wood_furniture;
|
||||
public final ForgeConfigSpec.BooleanValue without_metal_furniture;
|
||||
public final ForgeConfigSpec.BooleanValue without_windows;
|
||||
public final ForgeConfigSpec.BooleanValue without_light_sources;
|
||||
public final ForgeConfigSpec.BooleanValue without_slabs;
|
||||
|
@ -124,6 +128,8 @@ public class ModConfig
|
|||
public final ForgeConfigSpec.BooleanValue without_mineral_smelter;
|
||||
public final ForgeConfigSpec.BooleanValue without_milking_machine;
|
||||
public final ForgeConfigSpec.BooleanValue without_tree_cutter;
|
||||
public final ForgeConfigSpec.BooleanValue without_labeled_crate;
|
||||
public final ForgeConfigSpec.BooleanValue without_fences;
|
||||
public final ForgeConfigSpec.BooleanValue without_chair_sitting;
|
||||
public final ForgeConfigSpec.BooleanValue without_mob_chair_sitting;
|
||||
public final ForgeConfigSpec.BooleanValue without_ladder_speed_boost;
|
||||
|
@ -166,7 +172,7 @@ public class ModConfig
|
|||
builder.comment("Opt-out settings")
|
||||
.push("optout");
|
||||
pattern_excludes = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.pattern_excludes")
|
||||
.translation(MODID + ".config.pattern_excludes")
|
||||
.comment("Opt-out any block by its registry name ('*' wildcard matching, "
|
||||
+ "comma separated list, whitespaces ignored. You must match the whole name, "
|
||||
+ "means maybe add '*' also at the begin and end. Example: '*wood*,*steel*' "
|
||||
|
@ -174,7 +180,7 @@ public class ModConfig
|
|||
+ "The matching result is also traced in the log file. ")
|
||||
.define("pattern_excludes", "");
|
||||
pattern_includes = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.pattern_includes")
|
||||
.translation(MODID + ".config.pattern_includes")
|
||||
.comment("Prevent blocks from being opt'ed by registry name ('*' wildcard matching, "
|
||||
+ "comma separated list, whitespaces ignored. Evaluated before all other opt-out checks. "
|
||||
+ "You must match the whole name, means maybe add '*' also at the begin and end. Example: "
|
||||
|
@ -182,153 +188,169 @@ public class ModConfig
|
|||
+ "The matching result is also traced in the log file.")
|
||||
.define("pattern_includes", "");
|
||||
without_clinker_bricks = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_clinker_bricks")
|
||||
.translation(MODID + ".config.without_clinker_bricks")
|
||||
.comment("Disable clinker bricks and derived blocks.")
|
||||
.define("without_clinker_bricks", false);
|
||||
without_slag_bricks = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_slag_bricks")
|
||||
.translation(MODID + ".config.without_slag_bricks")
|
||||
.comment("Disable slag bricks and derived blocks.")
|
||||
.define("without_slag_bricks", false);
|
||||
without_rebar_concrete = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_rebar_concrete")
|
||||
.translation(MODID + ".config.without_rebar_concrete")
|
||||
.comment("Disable rebar concrete and derived blocks.")
|
||||
.define("without_rebar_concrete", false);
|
||||
without_gas_concrete = builder
|
||||
.translation(MODID + ".config.without_gas_concrete")
|
||||
.comment("Disable gas concrete and derived blocks.")
|
||||
.define("without_gas_concrete", false);
|
||||
without_walls = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_walls")
|
||||
.translation(MODID + ".config.without_walls")
|
||||
.comment("Disable all mod wall blocks.")
|
||||
.define("without_walls", false);
|
||||
without_stairs = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_stairs")
|
||||
.translation(MODID + ".config.without_stairs")
|
||||
.comment("Disable all mod stairs blocks.")
|
||||
.define("without_stairs", false);
|
||||
without_ie_concrete_wall = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_ie_concrete_wall")
|
||||
.translation(MODID + ".config.without_ie_concrete_wall")
|
||||
.comment("Disable IE concrete wall.")
|
||||
.define("without_ie_concrete_wall", false);
|
||||
without_panzer_glass = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_panzer_glass")
|
||||
.translation(MODID + ".config.without_panzer_glass")
|
||||
.comment("Disable panzer glass and derived blocks.")
|
||||
.define("without_panzer_glass", false);
|
||||
without_crafting_table = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_crafting_table")
|
||||
.translation(MODID + ".config.without_crafting_table")
|
||||
.comment("Disable treated wood crafting table.")
|
||||
.define("without_crafting_table", false);
|
||||
without_lab_furnace = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_lab_furnace")
|
||||
.translation(MODID + ".config.without_lab_furnace")
|
||||
.comment("Disable small lab furnace.")
|
||||
.define("without_lab_furnace", false);
|
||||
without_electrical_furnace = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_electrical_furnace")
|
||||
.translation(MODID + ".config.without_electrical_furnace")
|
||||
.comment("Disable small electrical pass-through furnace.")
|
||||
.define("without_electrical_furnace", false);
|
||||
without_treated_wood_furniture = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_treated_wood_furniture")
|
||||
.translation(MODID + ".config.without_treated_wood_furniture")
|
||||
.comment("Disable treated wood table, stool, windowsill, etc.")
|
||||
.define("without_treated_wood_furniture", false);
|
||||
without_metal_furniture = builder
|
||||
.translation(MODID + ".config.without_metal_furniture")
|
||||
.comment("Disable metal tables, etc.")
|
||||
.define("without_metal_furniture", false);
|
||||
without_windows = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_windows")
|
||||
.translation(MODID + ".config.without_windows")
|
||||
.comment("Disable treated wood window, etc.")
|
||||
.define("without_windows", false);
|
||||
without_light_sources = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_light_sources")
|
||||
.translation(MODID + ".config.without_light_sources")
|
||||
.comment("Disable light sources")
|
||||
.define("without_light_sources", false);
|
||||
without_ladders = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_ladders")
|
||||
.translation(MODID + ".config.without_ladders")
|
||||
.comment("Disable ladders")
|
||||
.define("without_ladders", false);
|
||||
without_chair_sitting = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_chair_sitting")
|
||||
.translation(MODID + ".config.without_chair_sitting")
|
||||
.comment("Disable possibility to sit on stools and chairs.")
|
||||
.define("without_chair_sitting", false);
|
||||
without_mob_chair_sitting = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_mob_chair_sitting")
|
||||
.translation(MODID + ".config.without_mob_chair_sitting")
|
||||
.comment("Disable that mobs will sit on chairs and stools.")
|
||||
.define("without_mob_chair_sitting", false);
|
||||
without_ladder_speed_boost = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_ladder_speed_boost")
|
||||
.translation(MODID + ".config.without_ladder_speed_boost")
|
||||
.comment("Disable the speed boost of ladders in this mod.")
|
||||
.define("without_ladder_speed_boost", false);
|
||||
without_crafting_table_history = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_crafting_table_history")
|
||||
.translation(MODID + ".config.without_crafting_table_history")
|
||||
.comment("Disable history refabrication feature of the treated wood crafting table.")
|
||||
.define("without_crafting_table_history", false);
|
||||
without_valves = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_valves")
|
||||
.translation(MODID + ".config.without_valves")
|
||||
.comment("Disable check valve, and redstone controlled valves.")
|
||||
.define("without_valves", false);
|
||||
without_passive_fluid_accumulator = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_passive_fluid_accumulator")
|
||||
.translation(MODID + ".config.without_passive_fluid_accumulator")
|
||||
.comment("Disable the passive fluid accumulator.")
|
||||
.define("without_passive_fluid_accumulator", false);
|
||||
without_waste_incinerator = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_waste_incinerator")
|
||||
.translation(MODID + ".config.without_waste_incinerator")
|
||||
.comment("Disable item disposal/trash/void incinerator device.")
|
||||
.define("without_waste_incinerator", false);
|
||||
without_sign_plates = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_sign_plates")
|
||||
.translation(MODID + ".config.without_sign_plates")
|
||||
.comment("Disable decorative sign plates (caution, hazards, etc).")
|
||||
.define("without_sign_plates", false);
|
||||
without_floor_grating = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_floor_grating")
|
||||
.translation(MODID + ".config.without_floor_grating")
|
||||
.comment("Disable floor gratings.")
|
||||
.define("without_floor_grating", false);
|
||||
without_factory_dropper = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_factory_dropper")
|
||||
.translation(MODID + ".config.without_factory_dropper")
|
||||
.comment("Disable the factory dropper.")
|
||||
.define("without_factory_dropper", false);
|
||||
without_factory_hopper = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_factory_hopper")
|
||||
.translation(MODID + ".config.without_factory_hopper")
|
||||
.comment("Disable the factory hopper.")
|
||||
.define("without_factory_hopper", false);
|
||||
without_factory_placer = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_factory_placer")
|
||||
.translation(MODID + ".config.without_factory_placer")
|
||||
.comment("Disable the factory placer.")
|
||||
.define("without_factory_placer", false);
|
||||
without_block_breaker = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_block_breaker")
|
||||
.translation(MODID + ".config.without_block_breaker")
|
||||
.comment("Disable the small block breaker.")
|
||||
.define("without_block_breaker", false);
|
||||
without_solar_panel = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_solar_panel")
|
||||
.translation(MODID + ".config.without_solar_panel")
|
||||
.comment("Disable the small solar panel.")
|
||||
.define("without_solar_panel", false);
|
||||
without_fluid_funnel = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_fluid_funnel")
|
||||
.translation(MODID + ".config.without_fluid_funnel")
|
||||
.comment("Disable the small fluid collection funnel.")
|
||||
.define("without_fluid_funnel", false);
|
||||
without_mineral_smelter = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_mineral_smelter")
|
||||
.translation(MODID + ".config.without_mineral_smelter")
|
||||
.comment("Disable the small mineral smelter.")
|
||||
.define("without_mineral_smelter", false);
|
||||
without_milking_machine = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_milking_machine")
|
||||
.translation(MODID + ".config.without_milking_machine")
|
||||
.comment("Disable the small milking machine.")
|
||||
.define("without_milking_machine", false);
|
||||
without_tree_cutter = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_tree_cutter")
|
||||
.translation(MODID + ".config.without_tree_cutter")
|
||||
.comment("Disable the small tree cutter.")
|
||||
.define("without_tree_cutter", false);
|
||||
without_labeled_crate = builder
|
||||
.translation(MODID + ".config.without_labeled_crate")
|
||||
.comment("Disable labeled crate.")
|
||||
.define("without_labeled_crate", false);
|
||||
without_slabs = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_slabs")
|
||||
.translation(MODID + ".config.without_slabs")
|
||||
.comment("Disable horizontal half-block slab.")
|
||||
.define("without_slabs", false);
|
||||
without_halfslabs = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_halfslabs")
|
||||
.translation(MODID + ".config.without_halfslabs")
|
||||
.comment("Disable stackable 1/8 block slices.")
|
||||
.define("without_halfslabs", false);
|
||||
without_poles = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_poles")
|
||||
.translation(MODID + ".config.without_poles")
|
||||
.comment("Disable poles of any material.")
|
||||
.define("without_poles", false);
|
||||
without_hsupports = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_hsupports")
|
||||
.translation(MODID + ".config.without_hsupports")
|
||||
.comment("Disable horizontal supports like the double-T support.")
|
||||
.define("without_hsupports", false);
|
||||
without_recipes = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_recipes")
|
||||
.translation(MODID + ".config.without_recipes")
|
||||
.comment("Disable all internal recipes, allowing to use alternative pack recipes.")
|
||||
.define("without_recipes", false);
|
||||
without_fences = builder
|
||||
.translation(MODID + ".config.without_fences")
|
||||
.comment("Disable all fences and fence gates.")
|
||||
.define("without_fences", false);
|
||||
builder.pop();
|
||||
}
|
||||
// --- MISC ---------------------------------------------------------------
|
||||
|
@ -336,16 +358,16 @@ public class ModConfig
|
|||
builder.comment("Miscellaneous settings")
|
||||
.push("miscellaneous");
|
||||
with_experimental = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.with_experimental")
|
||||
.translation(MODID + ".config.with_experimental")
|
||||
.comment("Enables experimental features. Use at own risk.")
|
||||
.define("with_experimental", false);
|
||||
without_direct_slab_pickup = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_direct_slab_pickup")
|
||||
.translation(MODID + ".config.without_direct_slab_pickup")
|
||||
.comment("Disable directly picking up layers from slabs and slab " +
|
||||
" slices by left clicking while looking up/down.")
|
||||
.define("without_direct_slab_pickup", false);
|
||||
with_creative_mode_device_drops = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.with_creative_mode_device_drops")
|
||||
.translation(MODID + ".config.with_creative_mode_device_drops")
|
||||
.comment("Enable that devices are dropped as item also in creative mode, allowing " +
|
||||
" to relocate them with contents and settings.")
|
||||
.define("with_creative_mode_device_drops", false);
|
||||
|
@ -356,130 +378,130 @@ public class ModConfig
|
|||
builder.comment("Tweaks")
|
||||
.push("tweaks");
|
||||
furnace_smelting_speed_percent = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.furnace_smelting_speed_percent")
|
||||
.translation(MODID + ".config.furnace_smelting_speed_percent")
|
||||
.comment("Defines, in percent, how fast the lab furnace smelts compared to " +
|
||||
"a vanilla furnace. 100% means vanilla furnace speed, 150% means the " +
|
||||
"lab furnace is faster. The value can be changed on-the-fly for tuning.")
|
||||
.defineInRange("furnace_smelting_speed_percent", 130, 50, 800);
|
||||
furnace_fuel_efficiency_percent = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.furnace_fuel_efficiency_percent")
|
||||
.translation(MODID + ".config.furnace_fuel_efficiency_percent")
|
||||
.comment("Defines, in percent, how fuel efficient the lab furnace is, compared " +
|
||||
"to a vanilla furnace. 100% means vanilla furnace consumiton, 200% means " +
|
||||
"the lab furnace needs about half the fuel of a vanilla furnace, " +
|
||||
"The value can be changed on-the-fly for tuning.")
|
||||
.defineInRange("furnace_fuel_efficiency_percent", 100, 50, 400);
|
||||
furnace_boost_energy_consumption = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.furnace_boost_energy_consumption")
|
||||
.translation(MODID + ".config.furnace_boost_energy_consumption")
|
||||
.comment("Defines the energy consumption (per tick) for speeding up the smelting process. " +
|
||||
"If IE is installed, an external heater has to be inserted into an auxiliary slot " +
|
||||
"of the lab furnace. The power source needs to be able to provide at least 4 times " +
|
||||
"this consumption (fixed threshold value). The value can be changed on-the-fly for tuning. " +
|
||||
"The default value corresponds to the IE heater consumption.")
|
||||
.defineInRange("furnace_boost_energy_consumption", 24, 8, 1024);
|
||||
.defineInRange("furnace_boost_energy_consumption", 24, 2, 1024);
|
||||
chair_mob_sitting_probability_percent = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.chair_mob_sitting_probability_percent")
|
||||
.translation(MODID + ".config.chair_mob_sitting_probability_percent")
|
||||
.comment("Defines, in percent, how high the probability is that a mob sits on a chair " +
|
||||
"when colliding with it. Can be changed on-the-fly for tuning.")
|
||||
.defineInRange("chair_mob_sitting_probability_percent", 10.0, 0.0, 80.0);
|
||||
chair_mob_standup_probability_percent = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.chair_mob_standup_probability_percent")
|
||||
.translation(MODID + ".config.chair_mob_standup_probability_percent")
|
||||
.comment("Defines, in percent, probable it is that a mob leaves a chair when sitting " +
|
||||
"on it. The 'dice is rolled' about every 20 ticks. There is also a minimum " +
|
||||
"Sitting time of about 3s. The config value can be changed on-the-fly for tuning.")
|
||||
.defineInRange("chair_mob_standup_probability_percent", 1.0, 1e-3, 10.0);
|
||||
with_crafting_quickmove_buttons = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.with_crafting_quickmove_buttons")
|
||||
.translation(MODID + ".config.with_crafting_quickmove_buttons")
|
||||
.comment("Enables small quick-move arrows from/to player/block storage. " +
|
||||
"Makes the UI a bit too busy, therefore disabled by default.")
|
||||
.define("with_crafting_quickmove_buttons", false);
|
||||
without_crafting_mouse_scrolling = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.without_crafting_mouse_scrolling")
|
||||
.translation(MODID + ".config.without_crafting_mouse_scrolling")
|
||||
.comment("Disables increasing/decreasing the crafting grid items by scrolling over the crafting result slot.")
|
||||
.define("without_crafting_mouse_scrolling", false);
|
||||
pipevalve_max_flowrate = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.pipevalve_max_flowrate")
|
||||
.translation(MODID + ".config.pipevalve_max_flowrate")
|
||||
.comment("Defines how many millibuckets can be transferred (per tick) through the valves. " +
|
||||
"That is technically the 'storage size' specified for blocks that want to fill " +
|
||||
"fluids into the valve (the valve has no container and forward that to the output " +
|
||||
"block), The value can be changed on-the-fly for tuning. ")
|
||||
.defineInRange("pipevalve_max_flowrate", 1000, 1, 32000);
|
||||
pipevalve_redstone_gain = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.pipevalve_redstone_gain")
|
||||
.translation(MODID + ".config.pipevalve_redstone_gain")
|
||||
.comment("Defines how many millibuckets per redstone signal strength can be transferred per tick " +
|
||||
"through the analog redstone controlled valves. Note: power 0 is always off, power 15 is always " +
|
||||
"the max flow rate. Between power 1 and 14 this scaler will result in a flow = 'redstone slope' * 'current redstone power'. " +
|
||||
"The value can be changed on-the-fly for tuning. ")
|
||||
.defineInRange("pipevalve_redstone_gain", 20, 1, 32000);
|
||||
e_furnace_speed_percent = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.e_furnace_speed_percent")
|
||||
.translation(MODID + ".config.e_furnace_speed_percent")
|
||||
.comment("Defines, in percent, how fast the electrical furnace smelts compared to " +
|
||||
"a vanilla furnace. 100% means vanilla furnace speed, 150% means the " +
|
||||
"electrical furnace is faster. The value can be changed on-the-fly for tuning.")
|
||||
.defineInRange("e_furnace_speed_percent", EdElectricalFurnace.ElectricalFurnaceTileEntity.DEFAULT_SPEED_PERCENT, 50, 800);
|
||||
e_furnace_power_consumption = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.e_furnace_power_consumption")
|
||||
.translation(MODID + ".config.e_furnace_power_consumption")
|
||||
.comment("Defines how much RF per tick the the electrical furnace consumed (average) for smelting. " +
|
||||
"The feeders transferring items from/to adjacent have this consumption/8 for each stack transaction. " +
|
||||
"The default value is only slightly higher than a furnace with an IE external heater (and no burning fuel inside)." +
|
||||
"The config value can be changed on-the-fly for tuning.")
|
||||
.defineInRange("e_furnace_power_consumption", EdElectricalFurnace.ElectricalFurnaceTileEntity.DEFAULT_ENERGY_CONSUMPTION, 8, 4096);
|
||||
e_furnace_automatic_pulling = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.e_furnace_automatic_pulling")
|
||||
.translation(MODID + ".config.e_furnace_automatic_pulling")
|
||||
.comment("Defines if the electrical furnace automatically pulls items from an inventory at the input side." +
|
||||
"The config value can be changed on-the-fly for tuning.")
|
||||
.define("e_furnace_automatic_pulling", false);
|
||||
small_solar_panel_peak_production = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.small_solar_panel_peak_production")
|
||||
.translation(MODID + ".config.small_solar_panel_peak_production")
|
||||
.comment("Defines the peak power production (at noon) of the Small Solar Panel. " +
|
||||
"Note that the agerage power is much less, as no power is produced at all during the night, " +
|
||||
"and the power curve is nonlinear rising/falling during the day. Bad weather conditions also " +
|
||||
"decrease the production. The config value can be changed on-the-fly for tuning.")
|
||||
.defineInRange("small_solar_panel_peak_production", EdSolarPanel.SolarPanelTileEntity.DEFAULT_PEAK_POWER, 2, 4096);
|
||||
block_breaker_power_consumption = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.block_breaker_power_consumption")
|
||||
.translation(MODID + ".config.block_breaker_power_consumption")
|
||||
.comment("Defines how much RF power the Small Block Breaker requires to magnificently increase the processing speed. " +
|
||||
"The config value can be changed on-the-fly for tuning.")
|
||||
.defineInRange("block_breaker_power_consumption", EdBreaker.BreakerTileEntity.DEFAULT_BOOST_ENERGY, 4, 1024);
|
||||
block_breaker_reluctance = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.block_breaker_reluctance")
|
||||
.translation(MODID + ".config.block_breaker_reluctance")
|
||||
.comment("Defines how much time the Small Block Breaker needs per block hardness, " +
|
||||
"means: 'reluctance' * hardness + min_time, you change the 'reluctance' here." +
|
||||
"The unit is ticks/hardness. " + "The config value can be changed on-the-fly for tuning.")
|
||||
.defineInRange("block_breaker_reluctance", EdBreaker.BreakerTileEntity.DEFAULT_BREAKING_RELUCTANCE, 5, 50);
|
||||
block_breaker_min_breaking_time = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.block_breaker_min_breaking_time")
|
||||
.translation(MODID + ".config.block_breaker_min_breaking_time")
|
||||
.comment("Defines how much time the Small Block Breaker needs at least, better said it's an offset: " +
|
||||
"'reluctance' * hardness + min_time, you change the 'min_time' here, value " +
|
||||
"in ticks." + "The config value can be changed on-the-fly for tuning.")
|
||||
.defineInRange("block_breaker_min_breaking_time", EdBreaker.BreakerTileEntity.DEFAULT_MIN_BREAKING_TIME, 10, 100);
|
||||
block_breaker_requires_power = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.block_breaker_requires_power")
|
||||
.translation(MODID + ".config.block_breaker_requires_power")
|
||||
.comment("Defines if the Small Block Breaker does not work without RF power.")
|
||||
.define("block_breaker_requires_power", false);
|
||||
tree_cuttter_energy_consumption = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.tree_cuttter_energy_consumption")
|
||||
.translation(MODID + ".config.tree_cuttter_energy_consumption")
|
||||
.comment("Defines how much RF power the Small Tree Cutter requires to magnificently increase the processing speed. " +
|
||||
"The config value can be changed on-the-fly for tuning.")
|
||||
.defineInRange("tree_cuttter_energy_consumption", EdTreeCutter.TreeCutterTileEntity.DEFAULT_BOOST_ENERGY, 4, 1024);
|
||||
tree_cuttter_cutting_time_needed = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.tree_cuttter_cutting_time_needed")
|
||||
.translation(MODID + ".config.tree_cuttter_cutting_time_needed")
|
||||
.comment("Defines how much time the Small Tree Cutter needs to cut a tree without RF power. " +
|
||||
"The value is in seconds. With energy it is 6 times faster. " +
|
||||
"The config value can be changed on-the-fly for tuning.")
|
||||
.defineInRange("tree_cuttter_cutting_time_needed", EdTreeCutter.TreeCutterTileEntity.DEFAULT_CUTTING_TIME_NEEDED, 10, 240);
|
||||
tree_cuttter_requires_power = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.tree_cuttter_requires_power")
|
||||
.translation(MODID + ".config.tree_cuttter_requires_power")
|
||||
.comment("Defines if the Small Tree Cutter does not work without RF power.")
|
||||
.define("tree_cuttter_requires_power", false);
|
||||
milking_machine_energy_consumption = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.milking_machine_energy_consumption")
|
||||
.translation(MODID + ".config.milking_machine_energy_consumption")
|
||||
.comment("Defines how much time the Small Milking Machine needs work. " +
|
||||
"Note this is a permanent standby power, not only when the device does something. " +
|
||||
"Use zero to disable energy dependency and energy handling of the machine. " +
|
||||
"The config value can be changed on-the-fly for tuning.")
|
||||
.defineInRange("milking_machine_energy_consumption", EdMilker.MilkerTileEntity.DEFAULT_ENERGY_CONSUMPTION, 0, 1024);
|
||||
milking_machine_milking_delay = builder
|
||||
.translation(ModEngineersDecor.MODID + ".config.milking_machine_milking_delay")
|
||||
.translation(MODID + ".config.milking_machine_milking_delay")
|
||||
.comment("Defines (for each individual cow) the minimum time between milking." )
|
||||
.defineInRange("milking_machine_milking_delay", EdMilker.MilkerTileEntity.DEFAULT_MILKING_DELAY_PER_COW, 1000, 24000);
|
||||
builder.pop();
|
||||
|
@ -492,96 +514,10 @@ public class ModConfig
|
|||
//--------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
public static final boolean isOptedOut(final @Nullable Block block)
|
||||
{ return isOptedOut(block, false); }
|
||||
|
||||
public static final boolean isOptedOut(final @Nullable Block block, boolean with_log_details)
|
||||
{
|
||||
if(block == null) return true;
|
||||
if(block == ModContent.SIGN_MODLOGO) return true;
|
||||
if(COMMON == null) return false;
|
||||
try {
|
||||
if(!COMMON.with_experimental.get()) {
|
||||
if(block instanceof Auxiliaries.IExperimentalFeature) return true;
|
||||
if(ModContent.isExperimentalBlock(block)) return true;
|
||||
}
|
||||
final String rn = block.getRegistryName().getPath();
|
||||
// Hard IE dependent blocks
|
||||
if(!immersiveengineering_installed) {
|
||||
if(block == ModContent.CONCRETE_WALL) return true;
|
||||
if((block instanceof DecorBlock.Normal) && ((((DecorBlock.Normal)block).config & DecorBlock.CFG_HARD_IE_DEPENDENT) != 0)) return true;
|
||||
if((block instanceof StandardBlocks.BaseBlock) && ((((StandardBlocks.BaseBlock)block).config & DecorBlock.CFG_HARD_IE_DEPENDENT) != 0)) return true;
|
||||
}
|
||||
// Force-include/exclude pattern matching
|
||||
try {
|
||||
for(String e:includes_) {
|
||||
if(rn.matches(e)) {
|
||||
if(with_log_details) ModEngineersDecor.logger().info("Optout force include: " + rn);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
for(String e:excludes_) {
|
||||
if(rn.matches(e)) {
|
||||
if(with_log_details) ModEngineersDecor.logger().info("Optout force exclude: " + rn);
|
||||
return true;
|
||||
}
|
||||
}
|
||||
} catch(Throwable ex) {
|
||||
ModEngineersDecor.logger().error("optout include pattern failed, disabling.");
|
||||
includes_.clear();
|
||||
excludes_.clear();
|
||||
}
|
||||
// Early non-opt out type based evaluation
|
||||
if(block instanceof EdCraftingTable.CraftingTableBlock) return COMMON.without_crafting_table.get();
|
||||
if(block instanceof EdElectricalFurnace.ElectricalFurnaceBlock) return COMMON.without_electrical_furnace.get();
|
||||
if((block instanceof EdFurnace.FurnaceBlock) && (!(block instanceof EdElectricalFurnace.ElectricalFurnaceBlock))) return COMMON.without_lab_furnace.get();
|
||||
if(block instanceof EdFluidAccumulator.FluidAccumulatorBlock) return COMMON.without_passive_fluid_accumulator.get();
|
||||
if(block instanceof EdWasteIncinerator.WasteIncineratorBlock) return COMMON.without_waste_incinerator.get();
|
||||
if(block instanceof EdDropper.DropperBlock) return COMMON.without_factory_dropper.get();
|
||||
if(block instanceof EdPlacer.PlacerBlock) return COMMON.without_factory_placer.get();
|
||||
if(block instanceof EdBreaker.BreakerBlock) return COMMON.without_block_breaker.get();
|
||||
if(block instanceof EdSlabSliceBlock) return COMMON.without_halfslabs.get();
|
||||
if(block instanceof EdLadderBlock) return COMMON.without_ladders.get();
|
||||
if(block instanceof EdWindowBlock) return COMMON.without_windows.get();
|
||||
if(block instanceof EdPipeValve.PipeValveBlock) return COMMON.without_valves.get();
|
||||
if(block instanceof EdHorizontalSupportBlock) return COMMON.without_hsupports.get();
|
||||
if(block instanceof EdFloorGratingBlock) return COMMON.without_floor_grating.get();
|
||||
if(block instanceof EdHopper.HopperBlock) return COMMON.without_factory_hopper.get();
|
||||
if(block instanceof EdFluidFunnel.FluidFunnelBlock) return COMMON.without_fluid_funnel.get();
|
||||
if(block instanceof EdSolarPanel.SolarPanelBlock) return COMMON.without_solar_panel.get();
|
||||
if(block instanceof EdMineralSmelter.MineralSmelterBlock) return COMMON.without_mineral_smelter.get();
|
||||
if(block instanceof EdMilker.MilkerBlock) return COMMON.without_milking_machine.get();
|
||||
if(block instanceof EdTreeCutter.TreeCutterBlock) return COMMON.without_tree_cutter.get();
|
||||
// Type based evaluation where later filters may match, too
|
||||
if(COMMON.without_slabs.get() && (block instanceof EdSlabBlock)) return true;
|
||||
if(COMMON.without_stairs.get() && (block instanceof EdStairsBlock)) return true;
|
||||
if(COMMON.without_walls.get() && (block instanceof EdWallBlock)) return true;
|
||||
if(COMMON.without_poles.get() && (block instanceof EdStraightPoleBlock)) return true;
|
||||
// String matching based evaluation
|
||||
if(COMMON.without_clinker_bricks.get() && (rn.startsWith("clinker_brick_"))) return true;
|
||||
if(COMMON.without_slag_bricks.get() && rn.startsWith("slag_brick_")) return true;
|
||||
if(COMMON.without_rebar_concrete.get() && rn.startsWith("rebar_concrete")) return true;
|
||||
if(COMMON.without_ie_concrete_wall.get() && rn.startsWith("concrete_wall")) return true;
|
||||
if(COMMON.without_panzer_glass.get() && rn.startsWith("panzerglass_")) return true;
|
||||
if(COMMON.without_light_sources.get() && rn.endsWith("_light")) return true;
|
||||
if(COMMON.without_sign_plates.get() && rn.startsWith("sign_")) return true;
|
||||
if(COMMON.without_treated_wood_furniture.get()) {
|
||||
if(block instanceof EdChair.ChairBlock) return true;
|
||||
if(rn.equals("treated_wood_table")) return true;
|
||||
if(rn.equals("treated_wood_stool")) return true;
|
||||
if(rn.equals("treated_wood_windowsill")) return true;
|
||||
}
|
||||
} catch(Exception ex) {
|
||||
ModEngineersDecor.logger().error("Exception evaluating the optout config: '" + ex.getMessage() + "'");
|
||||
}
|
||||
return false;
|
||||
}
|
||||
{ return isOptedOut(block.asItem()); }
|
||||
|
||||
public static final boolean isOptedOut(final @Nullable Item item)
|
||||
{
|
||||
if(item == null) return true;
|
||||
if(SERVER == null) return false;
|
||||
return false;
|
||||
}
|
||||
{ return (item!=null) && optouts_.contains(item.getRegistryName().getPath()); }
|
||||
|
||||
public static boolean withExperimental()
|
||||
{ return with_experimental_features_; }
|
||||
|
@ -592,26 +528,164 @@ public class ModConfig
|
|||
//--------------------------------------------------------------------------------------------------------------------
|
||||
// Cache
|
||||
//--------------------------------------------------------------------------------------------------------------------
|
||||
private static final ArrayList<String> includes_ = new ArrayList<String>();
|
||||
private static final ArrayList<String> excludes_ = new ArrayList<String>();
|
||||
|
||||
private static final CompoundNBT server_config_ = new CompoundNBT();
|
||||
public static boolean without_crafting_table = false;
|
||||
public static boolean immersiveengineering_installed = false;
|
||||
public static boolean with_creative_mode_device_drops = false;
|
||||
private static HashSet<String> optouts_ = new HashSet<>();
|
||||
private static boolean with_experimental_features_ = false;
|
||||
private static boolean without_recipes_ = false;
|
||||
public static boolean without_crafting_table = false;
|
||||
public static boolean immersiveengineering_installed = false;
|
||||
public static boolean without_direct_slab_pickup = false;
|
||||
public static boolean with_creative_mode_device_drops = false;
|
||||
|
||||
public static final CompoundNBT getServerConfig() // config that may be synchronized from server to client via net pkg.
|
||||
{ return server_config_; }
|
||||
|
||||
private static final void updateOptouts()
|
||||
{
|
||||
final ArrayList<String> includes_ = new ArrayList<String>();
|
||||
final ArrayList<String> excludes_ = new ArrayList<String>();
|
||||
{
|
||||
String inc = COMMON.pattern_includes.get().toLowerCase().replaceAll(MODID+":", "").replaceAll("[^*_,a-z0-9]", "");
|
||||
if(COMMON.pattern_includes.get() != inc) COMMON.pattern_includes.set(inc);
|
||||
if(!inc.isEmpty()) LOGGER.info("Config pattern includes: '" + inc + "'");
|
||||
String[] incl = inc.split(",");
|
||||
includes_.clear();
|
||||
for(int i=0; i< incl.length; ++i) {
|
||||
incl[i] = incl[i].replaceAll("[*]", ".*?");
|
||||
if(!incl[i].isEmpty()) includes_.add(incl[i]);
|
||||
}
|
||||
}
|
||||
{
|
||||
String exc = COMMON.pattern_excludes.get().toLowerCase().replaceAll(MODID+":", "").replaceAll("[^*_,a-z0-9]", "");
|
||||
if(!exc.isEmpty()) LOGGER.info("Config pattern excludes: '" + exc + "'");
|
||||
String[] excl = exc.split(",");
|
||||
excludes_.clear();
|
||||
for(int i=0; i< excl.length; ++i) {
|
||||
excl[i] = excl[i].replaceAll("[*]", ".*?");
|
||||
if(!excl[i].isEmpty()) excludes_.add(excl[i]);
|
||||
}
|
||||
}
|
||||
|
||||
{
|
||||
boolean with_log_details = false;
|
||||
HashSet<String> optouts = new HashSet<>();
|
||||
ModContent.getRegisteredItems().stream().filter((Item item) -> {
|
||||
if(item == null) return true;
|
||||
if(SERVER == null) return false;
|
||||
return false;
|
||||
}).forEach(
|
||||
e -> optouts.add(e.getRegistryName().getPath())
|
||||
);
|
||||
ModContent.getRegisteredBlocks().stream().filter((Block block) -> {
|
||||
if(block==null) return true;
|
||||
if(block==ModContent.SIGN_MODLOGO) return true;
|
||||
if(COMMON==null) return false;
|
||||
try {
|
||||
if(!COMMON.with_experimental.get()) {
|
||||
if(block instanceof Auxiliaries.IExperimentalFeature) return true;
|
||||
if(ModContent.isExperimentalBlock(block)) return true;
|
||||
}
|
||||
final String rn = block.getRegistryName().getPath();
|
||||
// Hard IE dependent blocks
|
||||
if(!immersiveengineering_installed) {
|
||||
if(block==ModContent.CONCRETE_WALL) return true;
|
||||
if((block instanceof DecorBlock.Normal)&&((((DecorBlock.Normal)block).config&DecorBlock.CFG_HARD_IE_DEPENDENT)!=0))
|
||||
return true;
|
||||
if((block instanceof StandardBlocks.BaseBlock)&&((((StandardBlocks.BaseBlock)block).config&DecorBlock.CFG_HARD_IE_DEPENDENT)!=0))
|
||||
return true;
|
||||
}
|
||||
// Force-include/exclude pattern matching
|
||||
try {
|
||||
for(String e : includes_) {
|
||||
if(rn.matches(e)) {
|
||||
if(with_log_details) LOGGER.info("Optout force include: "+rn);
|
||||
return false;
|
||||
}
|
||||
}
|
||||
for(String e : excludes_) {
|
||||
if(rn.matches(e)) {
|
||||
if(with_log_details) LOGGER.info("Optout force exclude: "+rn);
|
||||
return true;
|
||||
}
|
||||
}
|
||||
} catch(Throwable ex) {
|
||||
LOGGER.error("optout include pattern failed, disabling.");
|
||||
includes_.clear();
|
||||
excludes_.clear();
|
||||
}
|
||||
// Early non-opt out type based evaluation
|
||||
if(block instanceof EdCraftingTable.CraftingTableBlock) return COMMON.without_crafting_table.get();
|
||||
if(block instanceof EdElectricalFurnace.ElectricalFurnaceBlock) return COMMON.without_electrical_furnace.get();
|
||||
if((block instanceof EdFurnace.FurnaceBlock)&&(!(block instanceof EdElectricalFurnace.ElectricalFurnaceBlock))) return COMMON.without_lab_furnace.get();
|
||||
if(block instanceof EdFluidAccumulator.FluidAccumulatorBlock) return COMMON.without_passive_fluid_accumulator.get();
|
||||
if(block instanceof EdWasteIncinerator.WasteIncineratorBlock) return COMMON.without_waste_incinerator.get();
|
||||
if(block instanceof EdDropper.DropperBlock) return COMMON.without_factory_dropper.get();
|
||||
if(block instanceof EdPlacer.PlacerBlock) return COMMON.without_factory_placer.get();
|
||||
if(block instanceof EdBreaker.BreakerBlock) return COMMON.without_block_breaker.get();
|
||||
if(block instanceof EdSlabSliceBlock) return COMMON.without_halfslabs.get();
|
||||
if(block instanceof EdLadderBlock) return COMMON.without_ladders.get();
|
||||
if(block instanceof EdWindowBlock) return COMMON.without_windows.get();
|
||||
if(block instanceof EdPipeValve.PipeValveBlock) return COMMON.without_valves.get();
|
||||
if(block instanceof EdHorizontalSupportBlock) return COMMON.without_hsupports.get();
|
||||
if(block instanceof EdFloorGratingBlock) return COMMON.without_floor_grating.get();
|
||||
if(block instanceof EdHopper.HopperBlock) return COMMON.without_factory_hopper.get();
|
||||
if(block instanceof EdFluidFunnel.FluidFunnelBlock) return COMMON.without_fluid_funnel.get();
|
||||
if(block instanceof EdSolarPanel.SolarPanelBlock) return COMMON.without_solar_panel.get();
|
||||
if(block instanceof EdMineralSmelter.MineralSmelterBlock) return COMMON.without_mineral_smelter.get();
|
||||
if(block instanceof EdMilker.MilkerBlock) return COMMON.without_milking_machine.get();
|
||||
if(block instanceof EdTreeCutter.TreeCutterBlock) return COMMON.without_tree_cutter.get();
|
||||
if(block instanceof EdLabeledCrate.LabeledCrateBlock) return COMMON.without_labeled_crate.get();
|
||||
// Type based evaluation where later filters may match, too
|
||||
if(COMMON.without_slabs.get()&&(block instanceof EdSlabBlock)) return true;
|
||||
if(COMMON.without_stairs.get()&&(block instanceof EdStairsBlock)) return true;
|
||||
if(COMMON.without_walls.get()&&(block instanceof EdWallBlock)) return true;
|
||||
if(COMMON.without_poles.get()&&(block instanceof EdStraightPoleBlock)) return true;
|
||||
// String matching based evaluation
|
||||
if(COMMON.without_clinker_bricks.get()&&(rn.startsWith("clinker_brick_"))) return true;
|
||||
if(COMMON.without_slag_bricks.get()&&rn.startsWith("slag_brick_")) return true;
|
||||
if(COMMON.without_rebar_concrete.get()&&rn.startsWith("rebar_concrete")) return true;
|
||||
if(COMMON.without_gas_concrete.get()&&rn.startsWith("gas_concrete")) return true;
|
||||
if(COMMON.without_ie_concrete_wall.get()&&rn.startsWith("concrete_wall")) return true;
|
||||
if(COMMON.without_panzer_glass.get()&&rn.startsWith("panzerglass_")) return true;
|
||||
if(COMMON.without_light_sources.get()&&rn.endsWith("_light")) return true;
|
||||
if(COMMON.without_sign_plates.get()&&rn.startsWith("sign_")) return true;
|
||||
if(COMMON.without_treated_wood_furniture.get()) {
|
||||
if(block instanceof EdChair.ChairBlock) return true;
|
||||
if(rn.equals("treated_wood_table")) return true;
|
||||
if(rn.equals("treated_wood_stool")) return true;
|
||||
if(rn.equals("treated_wood_windowsill")) return true;
|
||||
if(rn.equals("treated_wood_broad_windowsill")) return true;
|
||||
if(rn.equals("treated_wood_side_table")) return true;
|
||||
}
|
||||
if(COMMON.without_metal_furniture.get()) {
|
||||
if(rn.equals("steel_table")) return true;
|
||||
}
|
||||
if(COMMON.without_fences.get()) {
|
||||
if(block instanceof EdFenceBlock) return true;
|
||||
if(block instanceof EdDoubleGateBlock) return true;
|
||||
}
|
||||
} catch(Exception ex) {
|
||||
LOGGER.error("Exception evaluating the optout config: '"+ex.getMessage()+"'");
|
||||
}
|
||||
return false;
|
||||
}).forEach(
|
||||
e -> optouts.add(e.getRegistryName().getPath())
|
||||
);
|
||||
optouts_ = optouts;
|
||||
}
|
||||
}
|
||||
|
||||
public static final void apply()
|
||||
{
|
||||
without_crafting_table = isOptedOut(ModContent.TREATED_WOOD_CRAFTING_TABLE);
|
||||
immersiveengineering_installed = Auxiliaries.isModLoaded("immersiveengineering");
|
||||
with_experimental_features_ = COMMON.with_experimental.get();
|
||||
if(with_experimental_features_) LOGGER.info("Config: EXPERIMENTAL FEATURES ENABLED.");
|
||||
immersiveengineering_installed = Auxiliaries.isModLoaded("immersiveengineering");
|
||||
updateOptouts();
|
||||
without_crafting_table = isOptedOut(ModContent.TREATED_WOOD_CRAFTING_TABLE);
|
||||
without_recipes_ = COMMON.without_recipes.get();
|
||||
without_direct_slab_pickup = COMMON.without_direct_slab_pickup.get();
|
||||
// -----------------------------------------------------------------------------------------------------------------
|
||||
OptionalRecipeCondition.on_config(with_experimental_features_, without_recipes_, ModConfig::isOptedOut, ModConfig::isOptedOut);
|
||||
EdFurnace.FurnaceTileEntity.on_config(COMMON.furnace_smelting_speed_percent.get(), COMMON.furnace_fuel_efficiency_percent.get(), COMMON.furnace_boost_energy_consumption.get());
|
||||
EdChair.on_config(COMMON.without_chair_sitting.get(), COMMON.without_mob_chair_sitting.get(), COMMON.chair_mob_sitting_probability_percent.get(), COMMON.chair_mob_standup_probability_percent.get());
|
||||
EdLadderBlock.on_config(COMMON.without_ladder_speed_boost.get());
|
||||
|
@ -626,34 +700,15 @@ public class ModConfig
|
|||
EdSlabSliceBlock.on_config(!COMMON.without_direct_slab_pickup.get());
|
||||
EdLabeledCrate.on_config(false);
|
||||
// -----------------------------------------------------------------------------------------------------------------
|
||||
if(with_experimental_features_) {
|
||||
ModEngineersDecor.logger().info("Config: EXPERIMENTAL FEATURES ENABLED.");
|
||||
}
|
||||
{
|
||||
String inc = COMMON.pattern_includes.get().toLowerCase().replaceAll(ModEngineersDecor.MODID+":", "").replaceAll("[^*_,a-z0-9]", "");
|
||||
if(COMMON.pattern_includes.get() != inc) COMMON.pattern_includes.set(inc);
|
||||
if(!inc.isEmpty()) ModEngineersDecor.logger().info("Config pattern includes: '" + inc + "'");
|
||||
String[] incl = inc.split(",");
|
||||
includes_.clear();
|
||||
for(int i=0; i< incl.length; ++i) {
|
||||
incl[i] = incl[i].replaceAll("[*]", ".*?");
|
||||
if(!incl[i].isEmpty()) includes_.add(incl[i]);
|
||||
}
|
||||
}
|
||||
{
|
||||
String exc = COMMON.pattern_includes.get().toLowerCase().replaceAll(ModEngineersDecor.MODID+":", "").replaceAll("[^*_,a-z0-9]", "");
|
||||
if(!exc.isEmpty()) ModEngineersDecor.logger().info("Config pattern excludes: '" + exc + "'");
|
||||
String[] excl = exc.split(",");
|
||||
excludes_.clear();
|
||||
for(int i=0; i< excl.length; ++i) {
|
||||
excl[i] = excl[i].replaceAll("[*]", ".*?");
|
||||
if(!excl[i].isEmpty()) excludes_.add(excl[i]);
|
||||
}
|
||||
}
|
||||
{
|
||||
// Check if the config is already synchronized or has to be synchronised.
|
||||
server_config_.putBoolean("tree_cuttter_requires_power", COMMON.tree_cuttter_requires_power.get());
|
||||
server_config_.putBoolean("block_breaker_requires_power", COMMON.block_breaker_requires_power.get());
|
||||
{
|
||||
String s = String.join(",", optouts_);
|
||||
server_config_.putString("optout", s);
|
||||
if(!s.isEmpty()) LOGGER.info("Opt-outs:" + s);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -14,6 +14,7 @@ package wile.engineersdecor;
|
|||
|
||||
|
||||
import wile.engineersdecor.blocks.*;
|
||||
import wile.engineersdecor.libmc.blocks.StandardBlocks.BaseBlock;
|
||||
import wile.engineersdecor.libmc.detail.Auxiliaries;
|
||||
import wile.engineersdecor.libmc.blocks.StandardBlocks;
|
||||
import net.minecraft.util.Direction;
|
||||
|
@ -44,6 +45,7 @@ import java.util.ArrayList;
|
|||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import java.util.Collections;
|
||||
import java.util.stream.Collectors;
|
||||
import javax.annotation.Nonnull;
|
||||
|
||||
@SuppressWarnings("unused")
|
||||
|
@ -193,12 +195,12 @@ public class ModContent
|
|||
|
||||
public static final EdGlassBlock PANZERGLASS_BLOCK = (EdGlassBlock)(new EdGlassBlock(
|
||||
DecorBlock.CFG_TRANSLUCENT,
|
||||
Block.Properties.create(Material.GLASS, MaterialColor.AIR).hardnessAndResistance(5f, 2000f).sound(SoundType.METAL)
|
||||
Block.Properties.create(Material.GLASS, MaterialColor.AIR).hardnessAndResistance(0.7f, 2000f).sound(SoundType.METAL)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "panzerglass_block"));
|
||||
|
||||
public static final EdSlabBlock PANZERGLASS_SLAB = (EdSlabBlock)(new EdSlabBlock(
|
||||
DecorBlock.CFG_TRANSLUCENT,
|
||||
Block.Properties.create(Material.IRON, MaterialColor.IRON).hardnessAndResistance(5f, 2000f).sound(SoundType.METAL)
|
||||
Block.Properties.create(Material.IRON, MaterialColor.IRON).hardnessAndResistance(0.7f, 2000f).sound(SoundType.METAL)
|
||||
)).setRegistryName(new ResourceLocation(ModEngineersDecor.MODID, "panzerglass_slab"));
|
||||
|
||||
// -------------------------------------------------------------------------------------------------------------------
|
||||
|
@ -713,12 +715,12 @@ public class ModContent
|
|||
HALFSLAB_REBARCONCRETE,
|
||||
HALFSLAB_GASCONCRETE,
|
||||
HALFSLAB_CONCRETE,
|
||||
//HALFSLAB_TREATEDWOOD,
|
||||
//HALFSLAB_SHEETMETALIRON,
|
||||
//HALFSLAB_SHEETMETALSTEEL,
|
||||
//HALFSLAB_SHEETMETALCOPPER,
|
||||
//HALFSLAB_SHEETMETALGOLD,
|
||||
//HALFSLAB_SHEETMETALALUMINIUM,
|
||||
HALFSLAB_TREATEDWOOD,
|
||||
HALFSLAB_SHEETMETALIRON,
|
||||
HALFSLAB_SHEETMETALSTEEL,
|
||||
HALFSLAB_SHEETMETALCOPPER,
|
||||
HALFSLAB_SHEETMETALGOLD,
|
||||
HALFSLAB_SHEETMETALALUMINIUM,
|
||||
CONCRETE_WALL,
|
||||
PANZERGLASS_BLOCK,
|
||||
PANZERGLASS_SLAB,
|
||||
|
@ -949,10 +951,25 @@ public class ModContent
|
|||
public static List<Block> getRegisteredBlocks()
|
||||
{ return Collections.unmodifiableList(registeredBlocks); }
|
||||
|
||||
@Nonnull
|
||||
public static List<Item> getRegisteredItems()
|
||||
{ return new ArrayList<>(); }
|
||||
|
||||
public static final void registerBlocks(final RegistryEvent.Register<Block> event)
|
||||
{
|
||||
if(Auxiliaries.isModLoaded("immersiveengineering")) Auxiliaries.logInfo("Immersive Engineering also installed ...");
|
||||
registeredBlocks.addAll(allBlocks());
|
||||
boolean ie_available = Auxiliaries.isModLoaded("immersiveengineering");
|
||||
if(ie_available) {
|
||||
Auxiliaries.logInfo("Immersive Engineering also installed ...");
|
||||
registeredBlocks.addAll(allBlocks());
|
||||
} else {
|
||||
registeredBlocks.addAll(allBlocks().stream()
|
||||
.filter(block->
|
||||
((!(block instanceof BaseBlock)) || ((((BaseBlock)block).config & DecorBlock.CFG_HARD_IE_DEPENDENT)==0))
|
||||
|| (block == HALFSLAB_CONCRETE) // special case for 1.14 to prevent mod update issues
|
||||
)
|
||||
.collect(Collectors.toList())
|
||||
);
|
||||
}
|
||||
for(Block e:registeredBlocks) event.getRegistry().register(e);
|
||||
Auxiliaries.logInfo("Registered " + Integer.toString(registeredBlocks.size()) + " blocks.");
|
||||
}
|
||||
|
|
|
@ -13,8 +13,9 @@ import wile.engineersdecor.ModEngineersDecor;
|
|||
import wile.engineersdecor.libmc.blocks.StandardBlocks;
|
||||
import wile.engineersdecor.libmc.detail.Auxiliaries;
|
||||
import wile.engineersdecor.libmc.detail.Overlay;
|
||||
import net.minecraft.world.IBlockReader;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraft.world.IBlockReader;
|
||||
import net.minecraft.world.GameRules;
|
||||
import net.minecraft.world.server.ServerWorld;
|
||||
import net.minecraft.state.BooleanProperty;
|
||||
import net.minecraft.state.StateContainer;
|
||||
|
@ -26,6 +27,7 @@ import net.minecraft.tileentity.ITickableTileEntity;
|
|||
import net.minecraft.tileentity.TileEntityType;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.entity.player.PlayerEntity;
|
||||
import net.minecraft.entity.item.ItemEntity;
|
||||
import net.minecraft.item.BlockItemUseContext;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.particles.ParticleTypes;
|
||||
|
@ -272,6 +274,19 @@ public class EdBreaker
|
|||
return true;
|
||||
}
|
||||
|
||||
private static void spawnBlockAsEntity(World world, BlockPos pos, ItemStack stack) {
|
||||
if(world.isRemote || stack.isEmpty() || (!world.getGameRules().getBoolean(GameRules.DO_TILE_DROPS)) || world.restoringBlockSnapshots) return;
|
||||
ItemEntity e = new ItemEntity(world,
|
||||
((world.rand.nextFloat()*0.1)+0.5) + pos.getX(),
|
||||
((world.rand.nextFloat()*0.1)+0.5) + pos.getY(),
|
||||
((world.rand.nextFloat()*0.1)+0.5) + pos.getZ(),
|
||||
stack
|
||||
);
|
||||
e.setDefaultPickupDelay();
|
||||
e.setMotion((world.rand.nextFloat()*0.1-0.05), (world.rand.nextFloat()*0.1-0.03), (world.rand.nextFloat()*0.1-0.05));
|
||||
world.addEntity(e);
|
||||
}
|
||||
|
||||
private boolean breakBlock(BlockState state, BlockPos pos, World world)
|
||||
{
|
||||
if(world.isRemote || (!(world instanceof ServerWorld)) || world.restoringBlockSnapshots) return false; // retry next cycle
|
||||
|
@ -279,7 +294,7 @@ public class EdBreaker
|
|||
final Block block = state.getBlock();
|
||||
drops = Block.getDrops(state, (ServerWorld)world, pos, world.getTileEntity(pos));
|
||||
world.removeBlock(pos, false);
|
||||
for(ItemStack drop:drops) Block.spawnAsEntity(world, pos, drop);
|
||||
for(ItemStack drop:drops) spawnBlockAsEntity(world, pos, drop);
|
||||
SoundType stype = state.getBlock().getSoundType(state, world, pos, null);
|
||||
if(stype != null) world.playSound(null, pos, stype.getPlaceSound(), SoundCategory.BLOCKS, stype.getVolume()*0.6f, stype.getPitch());
|
||||
return true;
|
||||
|
@ -290,15 +305,16 @@ public class EdBreaker
|
|||
public void tick()
|
||||
{
|
||||
if(--tick_timer_ > 0) return;
|
||||
final BlockState device_state = world.getBlockState(pos);
|
||||
if(!(device_state.getBlock() instanceof BreakerBlock)) return;
|
||||
if(world.isRemote) {
|
||||
BlockState state = world.getBlockState(pos);
|
||||
if(!state.get(BreakerBlock.ACTIVE)) {
|
||||
if(!device_state.get(BreakerBlock.ACTIVE)) {
|
||||
tick_timer_ = TICK_INTERVAL;
|
||||
} else {
|
||||
tick_timer_ = 1;
|
||||
// not sure if is so cool to do this each tick ... may be simplified/removed again.
|
||||
SoundEvent sound = SoundEvents.BLOCK_WOOD_HIT;
|
||||
BlockState target_state = world.getBlockState(pos.offset(state.get(BreakerBlock.HORIZONTAL_FACING)));
|
||||
BlockState target_state = world.getBlockState(pos.offset(device_state.get(BreakerBlock.HORIZONTAL_FACING)));
|
||||
SoundType stype = target_state.getBlock().getSoundType(target_state);
|
||||
if((stype == SoundType.CLOTH) || (stype == SoundType.PLANT) || (stype == SoundType.SNOW)) {
|
||||
sound = SoundEvents.BLOCK_WOOL_HIT;
|
||||
|
@ -309,7 +325,6 @@ public class EdBreaker
|
|||
}
|
||||
} else {
|
||||
tick_timer_ = TICK_INTERVAL;
|
||||
final BlockState device_state = world.getBlockState(pos);
|
||||
final BlockPos target_pos = pos.offset(device_state.get(BreakerBlock.HORIZONTAL_FACING));
|
||||
final BlockState target_state = world.getBlockState(target_pos);
|
||||
if((world.isBlockPowered(pos)) || (!isBreakable(target_state, target_pos, world))) {
|
||||
|
|
|
@ -22,6 +22,8 @@ import wile.engineersdecor.libmc.detail.Auxiliaries;
|
|||
import wile.engineersdecor.libmc.detail.Inventories;
|
||||
import wile.engineersdecor.libmc.detail.Inventories.SlotRange;
|
||||
import wile.engineersdecor.libmc.detail.Networking;
|
||||
import wile.engineersdecor.libmc.detail.TooltipDisplay;
|
||||
import wile.engineersdecor.libmc.detail.TooltipDisplay.TipRange;
|
||||
import net.minecraft.inventory.container.*;
|
||||
import net.minecraft.network.play.server.SSetSlotPacket;
|
||||
import net.minecraft.network.NetworkManager;
|
||||
|
@ -59,6 +61,7 @@ import net.minecraftforge.api.distmarker.Dist;
|
|||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
import com.mojang.blaze3d.platform.GlStateManager;
|
||||
import com.google.common.collect.ImmutableList;
|
||||
|
||||
import javax.annotation.Nullable;
|
||||
import java.util.*;
|
||||
import java.util.stream.Collectors;
|
||||
|
@ -1106,6 +1109,7 @@ public class EdCraftingTable
|
|||
protected final PlayerEntity player;
|
||||
protected final ArrayList<Button> buttons = new ArrayList<Button>();
|
||||
protected final boolean history_slot_tooltip[] = {false,false,false,false,false,false,false,false,false,false};
|
||||
protected final TooltipDisplay tooltip = new TooltipDisplay();
|
||||
|
||||
public CraftingTableGui(CraftingTableContainer container, PlayerInventory playerInventory, ITextComponent title)
|
||||
{
|
||||
|
@ -1131,6 +1135,16 @@ public class EdCraftingTable
|
|||
buttons.add(addButton(new ImageButton(x0+59, y0+71, 17, 9, 180,71, 9, BACKGROUND, (bt)->action(CraftingTableContainer.BUTTON_TO_PLAYER))));
|
||||
}
|
||||
}
|
||||
{
|
||||
List<TipRange> tooltips = new ArrayList<>();
|
||||
final String prefix = ModContent.TREATED_WOOD_CRAFTING_TABLE.getTranslationKey() + ".tooltips.";
|
||||
String[] translation_keys = { "next", "prev", "clear", "nextcollisionrecipe", "fromstorage", "tostorage", "fromplayer", "toplayer" };
|
||||
for(int i=0; (i<buttons.size()) && (i<translation_keys.length); ++i) {
|
||||
Button bt = buttons.get(i);
|
||||
tooltips.add(new TipRange(bt.x,bt.y, bt.getWidth(), bt.getHeight(), Auxiliaries.localizable(prefix+translation_keys[i])));
|
||||
}
|
||||
tooltip.init(tooltips);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -1143,7 +1157,7 @@ public class EdCraftingTable
|
|||
}
|
||||
renderBackground();
|
||||
super.render(mouseX, mouseY, partialTicks);
|
||||
renderHoveredToolTip(mouseX, mouseY);
|
||||
if(!tooltip.render(this,mouseX,mouseY)) renderHoveredToolTip(mouseX, mouseY);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -1229,11 +1243,12 @@ public class EdCraftingTable
|
|||
{ action(message, new CompoundNBT()); }
|
||||
|
||||
protected void action(String message, CompoundNBT nbt)
|
||||
{ getContainer().onGuiAction(message, nbt); }
|
||||
{ getContainer().onGuiAction(message, nbt); tooltip.resetTimer(); }
|
||||
|
||||
@Override
|
||||
protected void handleMouseClick(Slot slot, int slotId, int mouseButton, ClickType type)
|
||||
{
|
||||
tooltip.resetTimer();
|
||||
if(type == ClickType.PICKUP) {
|
||||
boolean place_refab = (slot instanceof CraftingResultSlot) && (!slot.getHasStack());
|
||||
if(place_refab && with_assist_direct_history_refab) on_history_item_placement(); // place before crafting -> direct item pick
|
||||
|
@ -1281,6 +1296,7 @@ public class EdCraftingTable
|
|||
@Override
|
||||
public boolean mouseScrolled(double mouseX, double mouseY, double wheel_inc)
|
||||
{
|
||||
tooltip.resetTimer();
|
||||
final Slot resultSlot = this.getSlotUnderMouse();
|
||||
if((!with_crafting_slot_mouse_scrolling) || (!(resultSlot instanceof CraftingResultSlot))) {
|
||||
return this.func_212930_a(mouseX, mouseY).filter((evl) -> {
|
||||
|
|
|
@ -13,6 +13,8 @@ import wile.engineersdecor.ModEngineersDecor;
|
|||
import wile.engineersdecor.libmc.blocks.StandardBlocks;
|
||||
import wile.engineersdecor.libmc.detail.Inventories;
|
||||
import wile.engineersdecor.libmc.detail.Networking;
|
||||
import wile.engineersdecor.libmc.detail.TooltipDisplay;
|
||||
import wile.engineersdecor.libmc.detail.TooltipDisplay.TipRange;
|
||||
import net.minecraft.tileentity.ITickableTileEntity;
|
||||
import net.minecraft.inventory.container.INamedContainerProvider;
|
||||
import net.minecraft.block.DoorBlock;
|
||||
|
@ -23,10 +25,11 @@ import net.minecraft.state.BooleanProperty;
|
|||
import net.minecraft.state.StateContainer;
|
||||
import net.minecraft.tileentity.TileEntityType;
|
||||
import net.minecraft.util.math.*;
|
||||
import net.minecraft.util.text.StringTextComponent;
|
||||
import net.minecraft.util.math.shapes.ISelectionContext;
|
||||
import net.minecraft.util.math.shapes.VoxelShape;
|
||||
import net.minecraft.util.math.shapes.VoxelShapes;
|
||||
import net.minecraft.util.text.StringTextComponent;
|
||||
import net.minecraft.util.text.TranslationTextComponent;
|
||||
import net.minecraft.world.IBlockReader;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.block.BlockState;
|
||||
|
@ -52,6 +55,7 @@ import net.minecraftforge.items.wrapper.SidedInvWrapper;
|
|||
import net.minecraftforge.items.CapabilityItemHandler;
|
||||
import net.minecraftforge.items.IItemHandler;
|
||||
import com.mojang.blaze3d.platform.GlStateManager;
|
||||
|
||||
import javax.annotation.Nullable;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
|
@ -549,6 +553,7 @@ public class EdDropper
|
|||
if((drop_timer_ > 0) && ((--drop_timer_) == 0)) markDirty();
|
||||
if(--tick_timer_ > 0) return;
|
||||
tick_timer_ = TICK_INTERVAL;
|
||||
if(!(world.getBlockState(pos).getBlock() instanceof DropperBlock)) return;
|
||||
final boolean continuous_mode = (drop_logic_ & DROPLOGIC_CONTINUOUS)!=0;
|
||||
boolean dirty = block_power_updated_;
|
||||
boolean redstone_trigger = (block_power_signal_ && ((block_power_updated_) || (continuous_mode)));
|
||||
|
@ -802,25 +807,43 @@ public class EdDropper
|
|||
public static class DropperGui extends ContainerScreen<DropperContainer>
|
||||
{
|
||||
protected final PlayerEntity player_;
|
||||
protected final TooltipDisplay tooltip_ = new TooltipDisplay();
|
||||
|
||||
public DropperGui(DropperContainer container, PlayerInventory player_inventory, ITextComponent title)
|
||||
{ super(container, player_inventory, title); this.player_ = player_inventory.player; }
|
||||
|
||||
@Override
|
||||
public void init()
|
||||
{ super.init(); }
|
||||
{
|
||||
super.init();
|
||||
{
|
||||
final String prefix = ModContent.FACTORY_DROPPER.getTranslationKey() + ".tooltips.";
|
||||
final int x0 = getGuiLeft(), y0 = getGuiTop();
|
||||
tooltip_.init(
|
||||
new TipRange(x0+130, y0+10, 12, 25, new TranslationTextComponent(prefix + "velocity")),
|
||||
new TipRange(x0+145, y0+10, 25, 25, new TranslationTextComponent(prefix + "direction")),
|
||||
new TipRange(x0+129, y0+40, 44, 10, new TranslationTextComponent(prefix + "dropcount")),
|
||||
new TipRange(x0+129, y0+50, 44, 10, new TranslationTextComponent(prefix + "period")),
|
||||
new TipRange(x0+114, y0+51, 9, 9, new TranslationTextComponent(prefix + "rssignal")),
|
||||
new TipRange(x0+162, y0+66, 7, 9, new TranslationTextComponent(prefix + "triggermode")),
|
||||
new TipRange(x0+132, y0+66, 9, 9, new TranslationTextComponent(prefix + "filtergate")),
|
||||
new TipRange(x0+148, y0+66, 9, 9, new TranslationTextComponent(prefix + "externgate"))
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void render(int mouseX, int mouseY, float partialTicks)
|
||||
{
|
||||
renderBackground();
|
||||
super.render(mouseX, mouseY, partialTicks);
|
||||
renderHoveredToolTip(mouseX, mouseY);
|
||||
if(!tooltip_.render(this, mouseX, mouseY)) renderHoveredToolTip(mouseX, mouseY);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean mouseClicked(double mouseX, double mouseY, int mouseButton)
|
||||
{
|
||||
tooltip_.resetTimer();
|
||||
DropperContainer container = (DropperContainer)getContainer();
|
||||
int mx = (int)(mouseX - getGuiLeft() + .5), my = (int)(mouseY - getGuiTop() + .5);
|
||||
if((!isPointInRegion(114, 1, 61, 79, mouseX, mouseY))) {
|
||||
|
|
|
@ -12,6 +12,8 @@ import wile.engineersdecor.ModContent;
|
|||
import wile.engineersdecor.ModEngineersDecor;
|
||||
import wile.engineersdecor.libmc.detail.Inventories;
|
||||
import wile.engineersdecor.libmc.detail.Networking;
|
||||
import wile.engineersdecor.libmc.detail.TooltipDisplay;
|
||||
import wile.engineersdecor.libmc.detail.TooltipDisplay.TipRange;
|
||||
import net.minecraft.world.IBlockReader;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraft.block.BlockState;
|
||||
|
@ -32,6 +34,7 @@ import net.minecraft.entity.LivingEntity;
|
|||
import net.minecraft.util.*;
|
||||
import net.minecraft.util.text.StringTextComponent;
|
||||
import net.minecraft.util.text.ITextComponent;
|
||||
import net.minecraft.util.text.TranslationTextComponent;
|
||||
import net.minecraft.util.math.BlockRayTraceResult;
|
||||
import net.minecraft.util.math.AxisAlignedBB;
|
||||
import net.minecraft.util.math.BlockPos;
|
||||
|
@ -123,7 +126,7 @@ public class EdElectricalFurnace
|
|||
public static final int HEAT_INCREMENT = 20;
|
||||
public static final int MAX_ENERGY_TRANSFER = 1024;
|
||||
public static final int MAX_ENERGY_BUFFER = 32000;
|
||||
public static final int MAX_SPEED_SETTING = 2;
|
||||
public static final int MAX_SPEED_SETTING = 3;
|
||||
public static final int NUM_OF_SLOTS = 7;
|
||||
public static final int SMELTING_INPUT_SLOT_NO = 0;
|
||||
public static final int SMELTING_AUX_SLOT_NO = 1;
|
||||
|
@ -196,7 +199,7 @@ public class EdElectricalFurnace
|
|||
proc_time_needed_ = nbt.getInt("CookTimeTotal");
|
||||
energy_stored_ = nbt.getInt("Energy");
|
||||
speed_ = nbt.getInt("SpeedSetting");
|
||||
speed_ = (speed_ < 0) ? (1) : ((speed_>3) ? 3 : speed_);
|
||||
speed_ = (speed_ < 0) ? (1) : ((speed_>MAX_SPEED_SETTING) ? MAX_SPEED_SETTING : speed_);
|
||||
}
|
||||
|
||||
protected void writenbt(CompoundNBT nbt)
|
||||
|
@ -205,7 +208,7 @@ public class EdElectricalFurnace
|
|||
nbt.putInt("CookTime", MathHelper.clamp(proc_time_elapsed_, 0, MAX_BURNTIME));
|
||||
nbt.putInt("CookTimeTotal", MathHelper.clamp(proc_time_needed_, 0, MAX_BURNTIME));
|
||||
nbt.putInt("Energy", MathHelper.clamp(energy_stored_, 0, MAX_ENERGY_BUFFER));
|
||||
nbt.putInt("SpeedSetting", MathHelper.clamp(speed_, -1, MAX_SPEED_SETTING));
|
||||
nbt.putInt("SpeedSetting", MathHelper.clamp(speed_, 0, MAX_SPEED_SETTING));
|
||||
ItemStackHelper.saveAllItems(nbt, stacks_);
|
||||
}
|
||||
|
||||
|
@ -472,6 +475,7 @@ public class EdElectricalFurnace
|
|||
{
|
||||
if(--tick_timer_ > 0) return;
|
||||
tick_timer_ = TICK_INTERVAL;
|
||||
if(!(world.getBlockState(pos).getBlock() instanceof ElectricalFurnaceBlock)) return;
|
||||
final boolean was_burning = burning();
|
||||
if(was_burning) burntime_left_ -= TICK_INTERVAL;
|
||||
if(burntime_left_ < 0) burntime_left_ = 0;
|
||||
|
@ -492,7 +496,7 @@ public class EdElectricalFurnace
|
|||
} else if(energy_stored_ >= (MAX_ENERGY_BUFFER/2)) {
|
||||
enabled_ = true;
|
||||
}
|
||||
if((!(stacks_.get(SMELTING_INPUT_SLOT_NO)).isEmpty()) && (enabled_) && (speed_>0) && (speed_<4)) {
|
||||
if((!(stacks_.get(SMELTING_INPUT_SLOT_NO)).isEmpty()) && (enabled_) && (speed_>0) && (speed_<=MAX_SPEED_SETTING)) {
|
||||
IRecipe last_recipe = currentRecipe();
|
||||
updateCurrentRecipe();
|
||||
if(currentRecipe() != last_recipe) {
|
||||
|
@ -769,7 +773,7 @@ public class EdElectricalFurnace
|
|||
{
|
||||
if(!(inventory_ instanceof ElectricalFurnaceTileEntity)) return;
|
||||
ElectricalFurnaceTileEntity te = (ElectricalFurnaceTileEntity)inventory_;
|
||||
if(nbt.contains("speed")) te.speed_ = MathHelper.clamp(nbt.getInt("speed"), 0, 3);
|
||||
if(nbt.contains("speed")) te.speed_ = MathHelper.clamp(nbt.getInt("speed"), 0, ElectricalFurnaceTileEntity.MAX_SPEED_SETTING);
|
||||
te.markDirty();
|
||||
}
|
||||
}
|
||||
|
@ -782,20 +786,32 @@ public class EdElectricalFurnace
|
|||
public static class ElectricalFurnaceGui extends ContainerScreen<ElectricalFurnaceContainer>
|
||||
{
|
||||
protected final PlayerEntity player_;
|
||||
protected final TooltipDisplay tooltip_ = new TooltipDisplay();
|
||||
|
||||
public ElectricalFurnaceGui(ElectricalFurnaceContainer container, PlayerInventory player_inventory, ITextComponent title)
|
||||
{ super(container, player_inventory, title); this.player_ = player_inventory.player; }
|
||||
|
||||
@Override
|
||||
public void init()
|
||||
{ super.init(); }
|
||||
{
|
||||
super.init();
|
||||
{
|
||||
final String prefix = ModContent.SMALL_ELECTRICAL_FURNACE.getTranslationKey() + ".tooltips.";
|
||||
final int x0 = getGuiLeft(), y0 = getGuiTop();
|
||||
final Slot aux = container.getSlot(ElectricalFurnaceTileEntity.SMELTING_AUX_SLOT_NO);
|
||||
tooltip_.init(
|
||||
new TipRange(x0+135, y0+50, 25, 25, new TranslationTextComponent(prefix + "speed")),
|
||||
new TipRange(x0+aux.xPos, y0+aux.yPos, 16, 16, new TranslationTextComponent(prefix + "auxslot"))
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void render(int mouseX, int mouseY, float partialTicks)
|
||||
{
|
||||
renderBackground();
|
||||
super.render(mouseX, mouseY, partialTicks);
|
||||
renderHoveredToolTip(mouseX, mouseY);
|
||||
if(!tooltip_.render(this, mouseX, mouseY)) renderHoveredToolTip(mouseX, mouseY);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -825,6 +841,7 @@ public class EdElectricalFurnace
|
|||
@Override
|
||||
public boolean mouseClicked(double mouseX, double mouseY, int mouseButton)
|
||||
{
|
||||
tooltip_.resetTimer();
|
||||
ElectricalFurnaceContainer container = (ElectricalFurnaceContainer)getContainer();
|
||||
int mx = (int)(mouseX - getGuiLeft() + .5), my = (int)(mouseY - getGuiTop() + .5);
|
||||
if((!isPointInRegion(136, 48, 28, 28, mouseX, mouseY))) {
|
||||
|
|
|
@ -212,10 +212,10 @@ public class EdFluidAccumulator
|
|||
{
|
||||
if((world.isRemote) || (--tick_timer_ > 0)) return;
|
||||
tick_timer_ = tick_idle_interval;
|
||||
BlockState state = world.getBlockState(pos);
|
||||
if(!(state.getBlock() instanceof FluidAccumulatorBlock)) return;
|
||||
if(!initialized_) {
|
||||
initialized_ = true;
|
||||
BlockState state = world.getBlockState(pos);
|
||||
if((state==null) || (!(state.getBlock() instanceof FluidAccumulatorBlock))) return;
|
||||
block_facing_ = state.get(FluidAccumulatorBlock.FACING);
|
||||
}
|
||||
int n_requested = last_drain_request_amount_;
|
||||
|
|
|
@ -406,6 +406,8 @@ public class EdFluidFunnel
|
|||
if((world.isRemote) || (--tick_timer_ > 0)) return;
|
||||
tick_timer_ = TICK_INTERVAL;
|
||||
collection_timer_ += TICK_INTERVAL;
|
||||
final BlockState funnel_state = world.getBlockState(pos);
|
||||
if(!(funnel_state.getBlock() instanceof FluidFunnelBlock)) return;
|
||||
boolean dirty = false;
|
||||
// Collection
|
||||
if((collection_timer_ >= COLLECTION_INTERVAL) && ((tank_==null) || (tank_.getAmount() <= (TANK_CAPACITY-1000)))) {
|
||||
|
@ -427,7 +429,6 @@ public class EdFluidFunnel
|
|||
}
|
||||
// Block state
|
||||
int fill_level = (tank_==null) ? 0 : (MathHelper.clamp(tank_.getAmount()/1000,0, FluidFunnelBlock.FILL_LEVEL_MAX));
|
||||
final BlockState funnel_state = world.getBlockState(pos);
|
||||
if(funnel_state.get(FluidFunnelBlock.FILL_LEVEL) != fill_level) world.setBlockState(pos, funnel_state.with(FluidFunnelBlock.FILL_LEVEL, fill_level), 2|16);
|
||||
if(dirty) markDirty();
|
||||
}
|
||||
|
|
|
@ -546,6 +546,8 @@ public class EdFurnace
|
|||
{
|
||||
if(--tick_timer_ > 0) return;
|
||||
tick_timer_ = TICK_INTERVAL;
|
||||
final BlockState state = world.getBlockState(pos);
|
||||
if(!(state.getBlock() instanceof FurnaceBlock)) return;
|
||||
final boolean was_burning = burning();
|
||||
if(was_burning) burntime_left_ -= TICK_INTERVAL;
|
||||
if(burntime_left_ < 0) burntime_left_ = 0;
|
||||
|
@ -602,10 +604,7 @@ public class EdFurnace
|
|||
}
|
||||
if(was_burning != burning()) {
|
||||
dirty = true;
|
||||
final BlockState state = world.getBlockState(pos);
|
||||
if(state.getBlock() instanceof FurnaceBlock) {
|
||||
world.setBlockState(pos, state.with(FurnaceBlock.LIT, burning()));
|
||||
}
|
||||
world.setBlockState(pos, state.with(FurnaceBlock.LIT, burning()));
|
||||
}
|
||||
if(dirty) {
|
||||
markDirty();
|
||||
|
|
|
@ -15,6 +15,8 @@ import wile.engineersdecor.libmc.detail.Auxiliaries;
|
|||
import wile.engineersdecor.libmc.detail.Inventories;
|
||||
import wile.engineersdecor.libmc.detail.Inventories.SlotRange;
|
||||
import wile.engineersdecor.libmc.detail.Networking;
|
||||
import wile.engineersdecor.libmc.detail.TooltipDisplay;
|
||||
import wile.engineersdecor.libmc.detail.TooltipDisplay.TipRange;
|
||||
import net.minecraft.world.IBlockReader;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraft.block.Block;
|
||||
|
@ -617,13 +619,13 @@ public class EdHopper
|
|||
if((delay_timer_ > 0) && ((--delay_timer_) == 0)) markDirty();
|
||||
if(--tick_timer_ > 0) return;
|
||||
tick_timer_ = TICK_INTERVAL;
|
||||
final BlockState state = world.getBlockState(pos);
|
||||
if(!(state.getBlock() instanceof HopperBlock)) { block_power_signal_= false; return; }
|
||||
// Cycle init
|
||||
boolean dirty = block_power_updated_;
|
||||
final boolean rssignal = ((logic_ & LOGIC_INVERTED)!=0)==(!block_power_signal_);
|
||||
final boolean pulse_mode = ((logic_ & LOGIC_CONTINUOUS)==0);
|
||||
boolean trigger = (rssignal && ((block_power_updated_) || (!pulse_mode)));
|
||||
final BlockState state = world.getBlockState(pos);
|
||||
if(state == null) { block_power_signal_= false; return; }
|
||||
final Direction hopper_facing = state.get(HopperBlock.FACING);
|
||||
// Trigger edge detection for next cycle
|
||||
{
|
||||
|
@ -838,25 +840,42 @@ public class EdHopper
|
|||
public static class HopperGui extends ContainerScreen<HopperContainer>
|
||||
{
|
||||
protected final PlayerEntity player_;
|
||||
protected final TooltipDisplay tooltip_ = new TooltipDisplay();
|
||||
|
||||
public HopperGui(HopperContainer container, PlayerInventory player_inventory, ITextComponent title)
|
||||
{ super(container, player_inventory, title); this.player_ = player_inventory.player; }
|
||||
|
||||
@Override
|
||||
public void init()
|
||||
{ super.init(); }
|
||||
{
|
||||
super.init();
|
||||
{
|
||||
final String prefix = ModContent.FACTORY_HOPPER.getTranslationKey() + ".tooltips.";
|
||||
final int x0 = getGuiLeft(), y0 = getGuiTop();
|
||||
tooltip_.init(
|
||||
new TipRange(x0+148, y0+22, 3, 3, new TranslationTextComponent(prefix + "delayindicator")),
|
||||
new TipRange(x0+130, y0+ 9, 40, 10, new TranslationTextComponent(prefix + "range")),
|
||||
new TipRange(x0+130, y0+22, 40, 10, new TranslationTextComponent(prefix + "period")),
|
||||
new TipRange(x0+130, y0+35, 40, 10, new TranslationTextComponent(prefix + "count")),
|
||||
new TipRange(x0+133, y0+49, 9, 9, new TranslationTextComponent(prefix + "rssignal")),
|
||||
new TipRange(x0+145, y0+49, 9, 9, new TranslationTextComponent(prefix + "inversion")),
|
||||
new TipRange(x0+159, y0+49, 9, 9, new TranslationTextComponent(prefix + "triggermode"))
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void render(int mouseX, int mouseY, float partialTicks)
|
||||
{
|
||||
renderBackground();
|
||||
super.render(mouseX, mouseY, partialTicks);
|
||||
renderHoveredToolTip(mouseX, mouseY);
|
||||
if(!tooltip_.render(this, mouseX, mouseY)) renderHoveredToolTip(mouseX, mouseY);
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void handleMouseClick(Slot slot, int slotId, int button, ClickType type)
|
||||
{
|
||||
tooltip_.resetTimer();
|
||||
if((type == ClickType.QUICK_MOVE) && (slot!=null) && slot.getHasStack() && Auxiliaries.isShiftDown() && Auxiliaries.isCtrlDown()) {
|
||||
CompoundNBT nbt = new CompoundNBT();
|
||||
nbt.putInt("slot", slotId);
|
||||
|
@ -869,6 +888,7 @@ public class EdHopper
|
|||
@Override
|
||||
public boolean mouseClicked(double mouseX, double mouseY, int mouseButton)
|
||||
{
|
||||
tooltip_.resetTimer();
|
||||
HopperContainer container = (HopperContainer)getContainer();
|
||||
int mx = (int)(mouseX - getGuiLeft() + .5), my = (int)(mouseY - getGuiTop() + .5);
|
||||
if((!isPointInRegion(126, 1, 49, 60, mouseX, mouseY))) {
|
||||
|
|
|
@ -529,6 +529,7 @@ public class EdMilker
|
|||
tick_timer_ = TICK_INTERVAL;
|
||||
boolean dirty = false;
|
||||
final BlockState block_state = world.getBlockState(pos);
|
||||
if(!(block_state.getBlock() instanceof MilkerBlock)) return;
|
||||
if(!world.isBlockPowered(pos) || (state_ != MilkingState.IDLE)) {
|
||||
if(energy_consumption > 0) {
|
||||
if(energy_stored_ <= 0) return;
|
||||
|
|
|
@ -566,6 +566,8 @@ public class EdMineralSmelter
|
|||
if(world.isRemote) return;
|
||||
if(--tick_timer_ > 0) return;
|
||||
tick_timer_ = TICK_INTERVAL;
|
||||
BlockState state = world.getBlockState(pos);
|
||||
if(!(state.getBlock() instanceof MineralSmelterBlock)) return;
|
||||
boolean dirty = false;
|
||||
final int last_phase = phase();
|
||||
final ItemStack istack = stacks_.get(0);
|
||||
|
@ -655,8 +657,7 @@ public class EdMineralSmelter
|
|||
}
|
||||
}
|
||||
// Block state
|
||||
BlockState state = world.getBlockState(pos);
|
||||
if((state.getBlock() instanceof MineralSmelterBlock) && (force_block_update_ || (state.get(MineralSmelterBlock.PHASE) != new_phase))) {
|
||||
if(force_block_update_ || (state.get(MineralSmelterBlock.PHASE) != new_phase)) {
|
||||
state = state.with(MineralSmelterBlock.PHASE, new_phase);
|
||||
world.setBlockState(pos, state,3|16);
|
||||
world.notifyNeighborsOfStateChange(getPos(), state.getBlock());
|
||||
|
|
|
@ -77,14 +77,13 @@ public class EdPipeValve
|
|||
{
|
||||
if((valve_config & (CFG_REDSTONE_CONTROLLED_VALVE))==0) return state;
|
||||
Direction.Axis bfa = state.get(FACING).getAxis();
|
||||
int bfi = state.get(FACING).getIndex();
|
||||
for(Direction f:Direction.values()) {
|
||||
boolean cn = (f.getAxis() != bfa);
|
||||
if(cn) {
|
||||
BlockPos nbp = pos.offset(f);
|
||||
if((fromPos != null) && (!nbp.equals(fromPos))) continue; // do not change connectors except form the frompos.
|
||||
BlockState nbs = world.getBlockState(nbp);
|
||||
if(!nbs.canProvidePower()) cn = false; // @todo check if there is a direction selective canProvidePower().
|
||||
if((!nbs.canProvidePower()) && (!nbs.canConnectRedstone(world, nbp, f.getOpposite()))) cn = false;
|
||||
}
|
||||
switch(f) {
|
||||
case NORTH: state = state.with(RS_CN_N, cn); break;
|
||||
|
|
|
@ -12,6 +12,8 @@ import wile.engineersdecor.ModContent;
|
|||
import wile.engineersdecor.ModEngineersDecor;
|
||||
import wile.engineersdecor.libmc.blocks.StandardBlocks;
|
||||
import wile.engineersdecor.libmc.detail.Networking;
|
||||
import wile.engineersdecor.libmc.detail.TooltipDisplay;
|
||||
import wile.engineersdecor.libmc.detail.TooltipDisplay.TipRange;
|
||||
import net.minecraft.block.*;
|
||||
import net.minecraft.world.IBlockReader;
|
||||
import net.minecraft.world.World;
|
||||
|
@ -19,6 +21,7 @@ import net.minecraft.world.server.ServerWorld;
|
|||
import net.minecraft.tileentity.ITickableTileEntity;
|
||||
import net.minecraft.tileentity.TileEntityType;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.entity.Entity;
|
||||
import net.minecraft.entity.player.ServerPlayerEntity;
|
||||
import net.minecraft.entity.item.ItemEntity;
|
||||
import net.minecraft.entity.LivingEntity;
|
||||
|
@ -32,9 +35,10 @@ import net.minecraft.inventory.container.Container;
|
|||
import net.minecraft.inventory.container.Slot;
|
||||
import net.minecraft.client.gui.screen.inventory.ContainerScreen;
|
||||
import net.minecraft.util.*;
|
||||
import net.minecraft.util.math.*;
|
||||
import net.minecraft.util.text.ITextComponent;
|
||||
import net.minecraft.util.text.StringTextComponent;
|
||||
import net.minecraft.util.text.TranslationTextComponent;
|
||||
import net.minecraft.util.math.*;
|
||||
import net.minecraft.util.math.shapes.ISelectionContext;
|
||||
import net.minecraft.util.math.shapes.VoxelShape;
|
||||
import net.minecraft.util.math.shapes.VoxelShapes;
|
||||
|
@ -439,7 +443,7 @@ public class EdPlacer
|
|||
return true;
|
||||
}
|
||||
|
||||
private boolean try_place(Direction facing)
|
||||
private boolean try_place(Direction facing, boolean triggered)
|
||||
{
|
||||
if(world.isRemote) return false;
|
||||
BlockPos placement_pos = pos.offset(facing);
|
||||
|
@ -487,7 +491,18 @@ public class EdPlacer
|
|||
placement_pos = placement_pos.up();
|
||||
}
|
||||
}
|
||||
} else if(!world.getBlockState(placement_pos).getMaterial().isReplaceable()) {
|
||||
} else if(
|
||||
(!world.getBlockState(placement_pos).getMaterial().isReplaceable()) ||
|
||||
(!world.getEntitiesWithinAABB(Entity.class, new AxisAlignedBB(placement_pos), (Entity e)->{
|
||||
if(e.canBeCollidedWith()) return true;
|
||||
if(triggered) return false;
|
||||
if((e instanceof ItemEntity)) {
|
||||
if((e.getMotion().getY() > 0) || (e.getMotion().getY() < -0.5)) return true; // not falling or falling by
|
||||
if(Math.abs(e.getMotion().getX())+Math.abs(e.getMotion().getZ()) > 0) return true; // not straight
|
||||
}
|
||||
return false;
|
||||
}).isEmpty())
|
||||
) {
|
||||
block = Blocks.AIR;
|
||||
no_space = true;
|
||||
}
|
||||
|
@ -556,13 +571,14 @@ public class EdPlacer
|
|||
if(world.isRemote) return;
|
||||
if(--tick_timer_ > 0) return;
|
||||
tick_timer_ = TICK_INTERVAL;
|
||||
// Cycle init
|
||||
boolean dirty = block_power_updated_;
|
||||
boolean rssignal = ((logic_ & LOGIC_INVERTED)!=0)==(!block_power_signal_);
|
||||
boolean trigger = (rssignal && ((block_power_updated_) || ((logic_ & LOGIC_CONTINUOUS)!=0)));
|
||||
final BlockState state = world.getBlockState(pos);
|
||||
if(state == null) { block_power_signal_= false; return; }
|
||||
if(!(state.getBlock() instanceof PlacerBlock)) { block_power_signal_= false; return; }
|
||||
// Cycle init
|
||||
final boolean updated = block_power_updated_;
|
||||
final boolean rssignal = ((logic_ & LOGIC_INVERTED)!=0)==(!block_power_signal_);
|
||||
final boolean trigger = (rssignal && ((updated) || ((logic_ & LOGIC_CONTINUOUS)!=0)));
|
||||
final Direction placer_facing = state.get(PlacerBlock.FACING);
|
||||
boolean dirty = updated;
|
||||
// Trigger edge detection for next cycle
|
||||
{
|
||||
boolean tr = world.isBlockPowered(pos);
|
||||
|
@ -571,7 +587,7 @@ public class EdPlacer
|
|||
if(block_power_updated_) dirty = true;
|
||||
}
|
||||
// Placing
|
||||
if(trigger && try_place(placer_facing)) dirty = true;
|
||||
if(trigger && try_place(placer_facing, rssignal && updated)) dirty = true;
|
||||
if(dirty) markDirty();
|
||||
if(trigger && (tick_timer_ > TICK_INTERVAL)) tick_timer_ = TICK_INTERVAL;
|
||||
}
|
||||
|
@ -689,25 +705,38 @@ public class EdPlacer
|
|||
public static class PlacerGui extends ContainerScreen<PlacerContainer>
|
||||
{
|
||||
protected final PlayerEntity player_;
|
||||
protected final TooltipDisplay tooltip_ = new TooltipDisplay();
|
||||
|
||||
public PlacerGui(PlacerContainer container, PlayerInventory player_inventory, ITextComponent title)
|
||||
{ super(container, player_inventory, title); this.player_ = player_inventory.player; }
|
||||
|
||||
@Override
|
||||
public void init()
|
||||
{ super.init(); }
|
||||
{
|
||||
super.init();
|
||||
{
|
||||
final String prefix = ModContent.FACTORY_PLACER.getTranslationKey() + ".tooltips.";
|
||||
final int x0 = getGuiLeft(), y0 = getGuiTop();
|
||||
tooltip_.init(
|
||||
new TipRange(x0+133, y0+49, 9, 9, new TranslationTextComponent(prefix + "rssignal")),
|
||||
new TipRange(x0+145, y0+49, 9, 9, new TranslationTextComponent(prefix + "inversion")),
|
||||
new TipRange(x0+159, y0+49, 9, 9, new TranslationTextComponent(prefix + "triggermode"))
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void render(int mouseX, int mouseY, float partialTicks)
|
||||
{
|
||||
renderBackground();
|
||||
super.render(mouseX, mouseY, partialTicks);
|
||||
renderHoveredToolTip(mouseX, mouseY);
|
||||
if(!tooltip_.render(this, mouseX, mouseY)) renderHoveredToolTip(mouseX, mouseY);
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean mouseClicked(double mouseX, double mouseY, int mouseButton)
|
||||
{
|
||||
tooltip_.resetTimer();
|
||||
PlacerContainer container = (PlacerContainer)getContainer();
|
||||
int mx = (int)(mouseX - getGuiLeft() + .5), my = (int)(mouseY - getGuiTop() + .5);
|
||||
if((!isPointInRegion(126, 1, 49, 60, mouseX, mouseY))) {
|
||||
|
|
|
@ -193,6 +193,8 @@ public class EdSolarPanel
|
|||
{
|
||||
if((world.isRemote) || (--tick_timer_ > 0)) return;
|
||||
tick_timer_ = TICK_INTERVAL;
|
||||
final BlockState state = world.getBlockState(pos);
|
||||
if(!(state.getBlock() instanceof SolarPanelBlock)) return;
|
||||
current_feedin_ = 0;
|
||||
if(output_enabled_) {
|
||||
for(int i=0; (i<transfer_directions_.length) && (accumulated_power_>0); ++i) {
|
||||
|
@ -211,13 +213,11 @@ public class EdSolarPanel
|
|||
if(!world.canBlockSeeSky(pos)) {
|
||||
tick_timer_ = TICK_INTERVAL * 5;
|
||||
current_production_ = 0;
|
||||
BlockState state = world.getBlockState(pos);
|
||||
if(state.get((SolarPanelBlock.EXPOSITION))!=2) world.setBlockState(pos, state.with(SolarPanelBlock.EXPOSITION, 2));
|
||||
return;
|
||||
}
|
||||
if(--recalc_timer_ > 0) return;
|
||||
recalc_timer_ = ACCUMULATION_INTERVAL + ((int)(Math.random()+.5));
|
||||
BlockState state = world.getBlockState(pos);
|
||||
int theta = ((((int)(world.getCelestialAngleRadians(1f) * (180.0/Math.PI)))+90) % 360);
|
||||
int e = 2;
|
||||
if(theta > 340) e = 2;
|
||||
|
|
|
@ -214,8 +214,10 @@ public class EdTreeCutter
|
|||
public void tick()
|
||||
{
|
||||
if(--tick_timer_ > 0) return;
|
||||
final BlockState device_state = world.getBlockState(pos);
|
||||
if(!(device_state.getBlock() instanceof TreeCutterBlock)) { tick_timer_ = TICK_INTERVAL; return; }
|
||||
if(world.isRemote) {
|
||||
if(!world.getBlockState(pos).get(TreeCutterBlock.ACTIVE)) {
|
||||
if(!device_state.get(TreeCutterBlock.ACTIVE)) {
|
||||
tick_timer_ = TICK_INTERVAL;
|
||||
} else {
|
||||
tick_timer_ = 1;
|
||||
|
@ -223,7 +225,6 @@ public class EdTreeCutter
|
|||
}
|
||||
} else {
|
||||
tick_timer_ = TICK_INTERVAL;
|
||||
final BlockState device_state = world.getBlockState(pos);
|
||||
final BlockPos tree_pos = pos.offset(device_state.get(TreeCutterBlock.HORIZONTAL_FACING));
|
||||
final BlockState tree_state = world.getBlockState(tree_pos);
|
||||
if(!TreeCutting.canChop(tree_state) || (world.isBlockPowered(pos))) {
|
||||
|
|
|
@ -509,6 +509,8 @@ public class EdWasteIncinerator
|
|||
if(--tick_timer_ > 0) return;
|
||||
tick_timer_ = TICK_INTERVAL;
|
||||
if(world.isRemote) return;
|
||||
final BlockState state = world.getBlockState(pos);
|
||||
if(!(state.getBlock() instanceof WasteIncineratorBlock)) return;
|
||||
boolean dirty = false;
|
||||
ItemStack processing_stack = stacks_.get(BURN_SLOT_NO);
|
||||
final boolean was_processing = !processing_stack.isEmpty();
|
||||
|
@ -542,10 +544,7 @@ public class EdWasteIncinerator
|
|||
}
|
||||
if((was_processing != is_processing) || (new_stack_processing)) {
|
||||
if(new_stack_processing) world.playSound(null, pos, SoundEvents.BLOCK_LAVA_AMBIENT, SoundCategory.BLOCKS, 0.05f, 2.4f);
|
||||
final BlockState state = world.getBlockState(pos);
|
||||
if(state.getBlock() instanceof WasteIncineratorBlock) {
|
||||
world.setBlockState(pos, state.with(WasteIncineratorBlock.LIT, is_processing), 2|16);
|
||||
}
|
||||
world.setBlockState(pos, state.with(WasteIncineratorBlock.LIT, is_processing), 2|16);
|
||||
}
|
||||
if(dirty) markDirty();
|
||||
}
|
||||
|
|
|
@ -17,10 +17,14 @@ import mezz.jei.api.registration.IRecipeTransferRegistration;
|
|||
import mezz.jei.api.constants.VanillaTypes;
|
||||
import mezz.jei.api.runtime.IJeiRuntime;
|
||||
import net.minecraft.block.Block;
|
||||
import net.minecraft.item.BlockItem;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.util.ResourceLocation;
|
||||
import java.util.ArrayList;
|
||||
import java.util.HashSet;
|
||||
import java.util.List;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
|
||||
@mezz.jei.api.JeiPlugin
|
||||
public class JEIPlugin implements mezz.jei.api.IModPlugin
|
||||
|
@ -48,15 +52,21 @@ public class JEIPlugin implements mezz.jei.api.IModPlugin
|
|||
@Override
|
||||
public void onRuntimeAvailable(IJeiRuntime jeiRuntime)
|
||||
{
|
||||
List<ItemStack> blacklisted = new ArrayList<>();
|
||||
HashSet<Item> blacklisted = new HashSet<>();
|
||||
for(Block e: ModContent.getRegisteredBlocks()) {
|
||||
if(ModConfig.isOptedOut(e)) {
|
||||
blacklisted.add(new ItemStack(e.asItem()));
|
||||
if(ModConfig.isOptedOut(e) && (e.asItem().getRegistryName().getPath()).equals((e.getRegistryName().getPath()))) {
|
||||
blacklisted.add(e.asItem());
|
||||
}
|
||||
}
|
||||
for(Item e: ModContent.getRegisteredItems()) {
|
||||
if(ModConfig.isOptedOut(e) && (!(e instanceof BlockItem))) {
|
||||
blacklisted.add(e);
|
||||
}
|
||||
}
|
||||
if(!blacklisted.isEmpty()) {
|
||||
List<ItemStack> blacklist = blacklisted.stream().map(ItemStack::new).collect(Collectors.toList());
|
||||
try {
|
||||
jeiRuntime.getIngredientManager().removeIngredientsAtRuntime(VanillaTypes.ITEM, blacklisted);
|
||||
jeiRuntime.getIngredientManager().removeIngredientsAtRuntime(VanillaTypes.ITEM, blacklist);
|
||||
} catch(Exception e) {
|
||||
ModEngineersDecor.logger().warn("Exception in JEI opt-out processing: '" + e.getMessage() + "', skipping further JEI optout processing.");
|
||||
}
|
||||
|
|
|
@ -10,10 +10,12 @@ package wile.engineersdecor.libmc.detail;
|
|||
|
||||
import net.minecraft.entity.player.PlayerEntity;
|
||||
import net.minecraft.entity.player.PlayerInventory;
|
||||
import net.minecraft.inventory.ItemStackHelper;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.CompoundNBT;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.Direction;
|
||||
import net.minecraft.util.NonNullList;
|
||||
import net.minecraft.util.math.BlockPos;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraft.inventory.IInventory;
|
||||
|
@ -86,7 +88,9 @@ public class Inventories
|
|||
}
|
||||
|
||||
private static ItemStack checked(ItemStack stack)
|
||||
{ return stack.isEmpty() ? ItemStack.EMPTY : stack; } // explicit EMPTY return
|
||||
{ return stack.isEmpty() ? ItemStack.EMPTY : stack; }
|
||||
|
||||
//--------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
public static class SlotRange
|
||||
{
|
||||
|
@ -138,7 +142,7 @@ public class Inventories
|
|||
for(int i = start_slot; i < end_slot; ++i) {
|
||||
final int sno = reverse ? (end_slot-1-i) : (i);
|
||||
final ItemStack stack = inventory.getStackInSlot(sno);
|
||||
if(stack.isEmpty() || (!inventory.isItemValidForSlot(sno, mvstack))) {
|
||||
if(stack.isEmpty()) {
|
||||
empties[sno] = true;
|
||||
} else if(areItemStacksIdentical(stack, mvstack)) {
|
||||
matches[sno] = true;
|
||||
|
@ -148,7 +152,7 @@ public class Inventories
|
|||
// first iteration: fillup existing stacks
|
||||
for(int i = start_slot; i < end_slot; ++i) {
|
||||
final int sno = reverse ? (end_slot-1-i) : (i);
|
||||
if(empties[sno] || !matches[sno]) continue;
|
||||
if((empties[sno]) || (!matches[sno])) continue;
|
||||
final ItemStack stack = inventory.getStackInSlot(sno);
|
||||
int nmax = Math.min(limit_left, stack.getMaxStackSize() - stack.getCount());
|
||||
if(mvstack.getCount() <= nmax) {
|
||||
|
@ -180,7 +184,7 @@ public class Inventories
|
|||
}
|
||||
for(i=insert_start;i < insert_end; ++i) {
|
||||
final int sno = reverse ? (end_slot-1-i) : (i);
|
||||
if(!empties[sno]) continue;
|
||||
if((!empties[sno]) || (!inventory.isItemValidForSlot(sno, mvstack))) continue;
|
||||
int nmax = Math.min(limit_left, mvstack.getCount());
|
||||
ItemStack moved = mvstack.copy();
|
||||
moved.setCount(nmax);
|
||||
|
@ -195,7 +199,7 @@ public class Inventories
|
|||
final int sno = reverse ? (end_slot-1-i) : (i);
|
||||
if(!matches[sno]) continue;
|
||||
int ii = (empties[sno-1]) ? (sno-1) : (empties[sno+1] ? (sno+1) : -1);
|
||||
if(ii >= 0) {
|
||||
if((ii >= 0) && (inventory.isItemValidForSlot(ii, mvstack))) {
|
||||
int nmax = Math.min(limit_left, mvstack.getCount());
|
||||
ItemStack moved = mvstack.copy();
|
||||
moved.setCount(nmax);
|
||||
|
@ -209,7 +213,7 @@ public class Inventories
|
|||
// third iteration: use any empty slots
|
||||
for(int i = start_slot; i < end_slot; ++i) {
|
||||
final int sno = reverse ? (end_slot-1-i) : (i);
|
||||
if(!empties[sno]) continue;
|
||||
if((!empties[sno]) || (!inventory.isItemValidForSlot(sno, mvstack))) continue;
|
||||
int nmax = Math.min(limit_left, mvstack.getCount());
|
||||
ItemStack placed = mvstack.copy();
|
||||
placed.setCount(nmax);
|
||||
|
@ -303,4 +307,33 @@ public class Inventories
|
|||
{ return inventory.isItemValidForSlot(offset+index, stack); }
|
||||
}
|
||||
|
||||
//--------------------------------------------------------------------------------------------------------------------
|
||||
|
||||
public static NonNullList<ItemStack> readNbtStacks(CompoundNBT nbt, String key, int size)
|
||||
{
|
||||
NonNullList<ItemStack> stacks = NonNullList.withSize(size, ItemStack.EMPTY);
|
||||
if((nbt == null) || (!nbt.contains(key,10))) return stacks;
|
||||
CompoundNBT stacknbt = nbt.getCompound(key);
|
||||
ItemStackHelper.loadAllItems(stacknbt, stacks);
|
||||
return stacks;
|
||||
}
|
||||
|
||||
public static CompoundNBT writeNbtStacks(CompoundNBT nbt, String key, NonNullList<ItemStack> stacks, boolean omit_trailing_empty)
|
||||
{
|
||||
CompoundNBT stacknbt = new CompoundNBT();
|
||||
if(omit_trailing_empty) {
|
||||
for(int i=stacks.size()-1; i>=0; --i) {
|
||||
if(!stacks.get(i).isEmpty()) break;
|
||||
stacks.remove(i);
|
||||
}
|
||||
}
|
||||
ItemStackHelper.saveAllItems(stacknbt, stacks);
|
||||
if(nbt == null) nbt = new CompoundNBT();
|
||||
nbt.put(key, stacknbt);
|
||||
return nbt;
|
||||
}
|
||||
|
||||
public static CompoundNBT writeNbtStacks(CompoundNBT nbt, String key, NonNullList<ItemStack> stacks)
|
||||
{ return writeNbtStacks(nbt, key, stacks, false); }
|
||||
|
||||
}
|
||||
|
|
|
@ -0,0 +1,103 @@
|
|||
/*
|
||||
* @file Tooltip.java
|
||||
* @author Stefan Wilhelm (wile)
|
||||
* @copyright (C) 2018 Stefan Wilhelm
|
||||
* @license MIT (see https://opensource.org/licenses/MIT)
|
||||
*
|
||||
* Delayed tooltip for a selected area. Constructed with a
|
||||
* GUI, invoked in `render()`.
|
||||
*/
|
||||
package wile.engineersdecor.libmc.detail;
|
||||
|
||||
import net.minecraft.client.Minecraft;
|
||||
import net.minecraft.client.gui.screen.inventory.ContainerScreen;
|
||||
import net.minecraft.inventory.container.Container;
|
||||
import net.minecraft.util.math.MathHelper;
|
||||
import net.minecraft.util.text.ITextComponent;
|
||||
import net.minecraftforge.api.distmarker.Dist;
|
||||
import net.minecraftforge.api.distmarker.OnlyIn;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.Collections;
|
||||
import java.util.List;
|
||||
|
||||
|
||||
@OnlyIn(Dist.CLIENT)
|
||||
public class TooltipDisplay
|
||||
{
|
||||
private static long default_delay = 1500;
|
||||
private static int default_max_deviation = 1;
|
||||
|
||||
public static void config(long delay, int max_deviation)
|
||||
{
|
||||
default_delay = (long)MathHelper.clamp((long)delay, 500L, 5000L);
|
||||
default_max_deviation = MathHelper.clamp(max_deviation, 1, 5);
|
||||
}
|
||||
|
||||
// ---------------------------------------------------------------------------------------------------
|
||||
|
||||
public static class TipRange
|
||||
{
|
||||
public final int x0,y0,x1,y1;
|
||||
public final ITextComponent text;
|
||||
public TipRange(int x, int y, int w, int h, ITextComponent text)
|
||||
{ this.text=text; this.x0=x; this.y0=y; this.x1=x0+w-1; this.y1=y0+h-1; }
|
||||
}
|
||||
|
||||
// ---------------------------------------------------------------------------------------------------
|
||||
|
||||
private List<TipRange> ranges = new ArrayList<>();
|
||||
private long delay = default_delay;
|
||||
private int max_deviation = default_max_deviation;
|
||||
private int x_last, y_last;
|
||||
private long t;
|
||||
|
||||
public TooltipDisplay()
|
||||
{ t = System.currentTimeMillis(); }
|
||||
|
||||
public void init(List<TipRange> ranges, long delay_ms, int max_deviation_xy)
|
||||
{
|
||||
this.ranges = ranges;
|
||||
this.delay = delay_ms;
|
||||
this.max_deviation = max_deviation_xy;
|
||||
t = System.currentTimeMillis();
|
||||
x_last = y_last = 0;
|
||||
}
|
||||
|
||||
public void init(List<TipRange> ranges)
|
||||
{ init(ranges, default_delay, default_max_deviation); }
|
||||
|
||||
public void init(TipRange... ranges)
|
||||
{ init(Arrays.asList(ranges), default_delay, default_max_deviation); }
|
||||
|
||||
public void resetTimer()
|
||||
{ t = System.currentTimeMillis(); }
|
||||
|
||||
public <T extends Container> boolean render(final ContainerScreen<T> gui, int x, int y)
|
||||
{
|
||||
if((Math.abs(x-x_last) > max_deviation) || (Math.abs(y-y_last) > max_deviation)) {
|
||||
x_last = x;
|
||||
y_last = y;
|
||||
resetTimer();
|
||||
return false;
|
||||
} else if(Math.abs(System.currentTimeMillis()-t) < delay) {
|
||||
return false;
|
||||
} else if(ranges.stream().noneMatch(
|
||||
(tip)->{
|
||||
if((x<tip.x0) || (x>tip.x1) || (y<tip.y0) || (y>tip.y1)) return false;
|
||||
String text = tip.text.getFormattedText();
|
||||
if(!text.isEmpty() && (!text.startsWith("block."))) {
|
||||
gui.renderTooltip(Collections.singletonList(tip.text.getFormattedText()), x, y, Minecraft.getInstance().fontRenderer);
|
||||
}
|
||||
return true;
|
||||
})
|
||||
){
|
||||
resetTimer();
|
||||
return false;
|
||||
} else {
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
}
|
|
@ -71,10 +71,28 @@
|
|||
"block.engineersdecor.dense_grit_sand_block.help": "§6A compressed sandy soil mixed with stone grid, as known from machine and storage yards.§r Flowers don't really grow on that. Position dependent texture variations.",
|
||||
"block.engineersdecor.factory_dropper": "Factory Dropper",
|
||||
"block.engineersdecor.factory_dropper.help": "§6Dropper suitable for advanced factory automation.§r Has twelve round-robin selected slots. Drop force, angle, stack size, and cool-down delay adjustable using sliders in the GUI. Three stack compare slots (below the inventory slots) with logical AND or OR can be used as internal trigger source. The internal trigger can be AND'ed or OR'ed with the external redstone signal trigger. Trigger simulation buttons for testing. Pre-opens shutter door when internal trigger conditions are met. Drops all matching stacks simultaneously. Simply click on all elements in the GUI to see how it works.",
|
||||
"block.engineersdecor.factory_dropper.tooltips.direction": "Drop direction x/y (-45° to +45°)",
|
||||
"block.engineersdecor.factory_dropper.tooltips.dropcount": "Drop stack size (1 to 32 items)",
|
||||
"block.engineersdecor.factory_dropper.tooltips.externgate": "External signal combination logic (AND or OR)§r\n§8AND: Drop only on an external signal.\nOR: Drop filter matches automatically, non-matching items on external trigger.",
|
||||
"block.engineersdecor.factory_dropper.tooltips.filtergate": "Filter combination gate logic (AND or OR)§r\n§8AND: Drop the stacks as specified in the filters when ALL filters are green.\nOR: Drop the stack of each individual filter when green.",
|
||||
"block.engineersdecor.factory_dropper.tooltips.period": "Drop delay (1s to 10s)",
|
||||
"block.engineersdecor.factory_dropper.tooltips.rssignal": "External Redstone signal indicator\n §8(click to generate a test trigger).",
|
||||
"block.engineersdecor.factory_dropper.tooltips.triggermode": "Trigger mode (pulse/continuous)§r\n§8Pulse: One drop for each OFF->ON of the external signal.\nContinuous: Drop as long as the external signal is ON.",
|
||||
"block.engineersdecor.factory_dropper.tooltips.velocity": "Drop velocity (slow to fast speed)",
|
||||
"block.engineersdecor.factory_hopper": "Factory Hopper",
|
||||
"block.engineersdecor.factory_hopper.help": "§6Hopper suitable for advanced factory automation.§r Can transfer half-stacks, max collection range 9x9.\n GUI Slider controls: Collection range (0 to 4), insertion delay (0.5s to 10s), insertion stack size (1 to 32).\n GUI Redstone controls: Not inverted / inverted (default), pulse mode / continuous mode (default).",
|
||||
"block.engineersdecor.factory_hopper.tooltips.count": "Insertion stack size §8(1 to 32 items)",
|
||||
"block.engineersdecor.factory_hopper.tooltips.delayindicator": "Delay indicator\n§8Blinks when the insertion delay timer has not expired yet, or when the Hopper cannot insert into the adjacent inventory.",
|
||||
"block.engineersdecor.factory_hopper.tooltips.inversion": "Inversion mode §8(inverted/not inverted)",
|
||||
"block.engineersdecor.factory_hopper.tooltips.period": "Insertion delay §8(1s to 10s)",
|
||||
"block.engineersdecor.factory_hopper.tooltips.range": "Collection radius §8(0 to 4)",
|
||||
"block.engineersdecor.factory_hopper.tooltips.rssignal": "External Redstone signal indicator",
|
||||
"block.engineersdecor.factory_hopper.tooltips.triggermode": "Trigger mode §8(continuous/pulse)",
|
||||
"block.engineersdecor.factory_placer": "Factory Block Placer",
|
||||
"block.engineersdecor.factory_placer.help": "§6Allows placing blocks and planting crops or trees.§r\n GUI Redstone controls: Not inverted / inverted (default), pulse mode / continuous mode (default).\n Also supports spike planing from underneath the soil. Spits out items that it cannot place or plant.",
|
||||
"block.engineersdecor.factory_placer.tooltips.inversion": "Inversion mode §8(inverted/not inverted)",
|
||||
"block.engineersdecor.factory_placer.tooltips.rssignal": "External Redstone signal indicator",
|
||||
"block.engineersdecor.factory_placer.tooltips.triggermode": "Trigger mode §8(continuous/pulse)",
|
||||
"block.engineersdecor.gas_concrete": "Gas Concrete Block",
|
||||
"block.engineersdecor.gas_concrete.help": "§6Low hardness, high production yield concrete.§r Easy to break decorative concrete block.",
|
||||
"block.engineersdecor.gas_concrete_slab": "Gas Concrete Slab",
|
||||
|
@ -159,6 +177,8 @@
|
|||
"block.engineersdecor.small_block_breaker.status": "SOC: %1$s%% of %2$sRF§r | progress: %3$s%%",
|
||||
"block.engineersdecor.small_electrical_furnace": "Small Electrical Furnace",
|
||||
"block.engineersdecor.small_electrical_furnace.help": "§6Small metal cased pass-through furnace.§r Automatically draws items from the input side and puts items into the inventory at the output side. Items can be inserted or drawn from all sides using hoppers. Implicitly bypasses items that cannot be smelted or cooked to the output. Slightly more energy efficient and faster than a heated cobblestone furnace. Fifos and feeders transfer whole stacks. Feeders require a bit of power.",
|
||||
"block.engineersdecor.small_electrical_furnace.tooltips.auxslot": "Auxiliary slot\n§8Place a Hopper here to enable automatic feeding from the input side.",
|
||||
"block.engineersdecor.small_electrical_furnace.tooltips.speed": "Smelting speed selection §8(OFF/I/II/III)",
|
||||
"block.engineersdecor.small_fluid_funnel": "Small Fluid Collection Funnel",
|
||||
"block.engineersdecor.small_fluid_funnel.help": "§6Collects fluids above it.§r Has an internal tank with three buckets capacity. Traces flowing fluids to nearby source blocks. The fluid can be obtained with fluid transfer systems or a bucket. Fills only tanks below (gravity transfer). Compatible with vanilla infinite-water-source creation.",
|
||||
"block.engineersdecor.small_lab_furnace": "Small Laboratory Furnace",
|
||||
|
@ -207,6 +227,14 @@
|
|||
"block.engineersdecor.treated_wood_broad_windowsill.help": "§6Simple window decoration.",
|
||||
"block.engineersdecor.treated_wood_crafting_table": "Treated Wood Crafting Table",
|
||||
"block.engineersdecor.treated_wood_crafting_table.help": "§6Robust and weather-proof.§r Eight storage slots, keeps inventory, no vanilla recipe book.\n Click up/down arrow buttons for crafting history selection, output slot for item placement, X-button to clear crafting grid and history. Shift-click stack: player-to-storage stack transfer when crafting grid empty, otherwise player-to-grid stack transfer. Automatically distributes the clicked stack. Shift-Ctrl-click stack: Move all same stacks. Mouse wheel over crafting slot: Increase/decrease crafting grid items.",
|
||||
"block.engineersdecor.treated_wood_crafting_table.tooltips.clear": "Clear grid to player inventory",
|
||||
"block.engineersdecor.treated_wood_crafting_table.tooltips.fromplayer": "Move items from player inventory",
|
||||
"block.engineersdecor.treated_wood_crafting_table.tooltips.fromstorage": "Move items from storage",
|
||||
"block.engineersdecor.treated_wood_crafting_table.tooltips.next": "Next crafting history recipe",
|
||||
"block.engineersdecor.treated_wood_crafting_table.tooltips.nextcollisionrecipe": "Show next colliding recipe",
|
||||
"block.engineersdecor.treated_wood_crafting_table.tooltips.prev": "Previous crafting history recipe",
|
||||
"block.engineersdecor.treated_wood_crafting_table.tooltips.toplayer": "Clear grid to player inventory",
|
||||
"block.engineersdecor.treated_wood_crafting_table.tooltips.tostorage": "Clear grid to storage",
|
||||
"block.engineersdecor.treated_wood_floor": "Treated Wood Floor",
|
||||
"block.engineersdecor.treated_wood_floor.help": "§6Decorative floor tiles with texture variations.§r",
|
||||
"block.engineersdecor.treated_wood_ladder": "Treated Wood Ladder",
|
||||
|
|
|
@ -71,10 +71,28 @@
|
|||
"block.engineersdecor.dense_grit_sand_block.help": "§6A compressed sandy soil mixed with stone grid, as known from machine and storage yards.§r Flowers don't really grow on that. Position dependent texture variations.",
|
||||
"block.engineersdecor.factory_dropper": "Фабричный выбрасыватель",
|
||||
"block.engineersdecor.factory_dropper.help": "§6Выбрасыватель подходит для продвинутой автоматизации производства.§r Имеет 12 выборочных слотов. Сила броска, угол, размер стопки и задержка настраиваются в GUI. 3 слота сравнения стека с логическим И или ИЛИ могут использоваться в качестве внутреннего источника запуска. Внутренний триггер может быть И или ИЛИ с внешним триггерным сигналом красного камня. Триггерные кнопки симуляции для тестирования. Предварительно открывает дверцу затвора, когда выполняются условия внутреннего запуска. Сбрасывает все соответствующие стеки одновременно. Нажмите на все элементы в GUI, чтобы увидеть, как это работает.",
|
||||
"block.engineersdecor.factory_dropper.tooltips.direction": "Drop direction x/y (-45° to +45°)",
|
||||
"block.engineersdecor.factory_dropper.tooltips.dropcount": "Drop stack size (1 to 32 items)",
|
||||
"block.engineersdecor.factory_dropper.tooltips.externgate": "External signal combination logic (AND or OR)§r\n§8AND: Drop only on an external signal.\nOR: Drop filter matches automatically, non-matching items on external trigger.",
|
||||
"block.engineersdecor.factory_dropper.tooltips.filtergate": "Filter combination gate logic (AND or OR)§r\n§8AND: Drop the stacks as specified in the filters when ALL filters are green.\nOR: Drop the stack of each individual filter when green.",
|
||||
"block.engineersdecor.factory_dropper.tooltips.period": "Drop delay (1s to 10s)",
|
||||
"block.engineersdecor.factory_dropper.tooltips.rssignal": "External Redstone signal indicator\n §8(click to generate a test trigger).",
|
||||
"block.engineersdecor.factory_dropper.tooltips.triggermode": "Trigger mode (pulse/continuous)§r\n§8Pulse: One drop for each OFF->ON of the external signal.\nContinuous: Drop as long as the external signal is ON.",
|
||||
"block.engineersdecor.factory_dropper.tooltips.velocity": "Drop velocity (slow to fast speed)",
|
||||
"block.engineersdecor.factory_hopper": "Фабричная воронка",
|
||||
"block.engineersdecor.factory_hopper.help": "§6Воронка для продвинутой автоматизации производства.§r Может передавать полустеки, максимальный диапазон сбора 9x9.\n GUI ползунки: Диапазон сбора (0 до 4), задержка помещения(0.5сек до 10сек), размер стека помещения (1 до 32).\n GUI редстоун: Не инвертирован / инвертирован (по умолчанию), пульс режим / постоянный режим (по умолчанию).",
|
||||
"block.engineersdecor.factory_hopper.tooltips.count": "Insertion stack size §8(1 to 32 items)",
|
||||
"block.engineersdecor.factory_hopper.tooltips.delayindicator": "Delay indicator\n§8Blinks when the insertion delay timer has not expired yet, or when the Hopper cannot insert into the adjacent inventory.",
|
||||
"block.engineersdecor.factory_hopper.tooltips.inversion": "Inversion mode §8(inverted/not inverted)",
|
||||
"block.engineersdecor.factory_hopper.tooltips.period": "Insertion delay §8(1s to 10s)",
|
||||
"block.engineersdecor.factory_hopper.tooltips.range": "Collection radius §8(0 to 4)",
|
||||
"block.engineersdecor.factory_hopper.tooltips.rssignal": "External Redstone signal indicator",
|
||||
"block.engineersdecor.factory_hopper.tooltips.triggermode": "Trigger mode §8(continuous/pulse)",
|
||||
"block.engineersdecor.factory_placer": "Фабричный разместитель блоков",
|
||||
"block.engineersdecor.factory_placer.help": "§6Позволяет размещать блоки и сажать урожай или деревья.§r\n GUI редстоун: Не инвертирован / инвертирован (по умолчанию), пульс режим / постоянный режим (по умолчанию).\n Also supports spike planing from underneath the soil. Выплевывает предметы, которые он не может поместить или посадить.",
|
||||
"block.engineersdecor.factory_placer.tooltips.inversion": "Inversion mode §8(inverted/not inverted)",
|
||||
"block.engineersdecor.factory_placer.tooltips.rssignal": "External Redstone signal indicator",
|
||||
"block.engineersdecor.factory_placer.tooltips.triggermode": "Trigger mode §8(continuous/pulse)",
|
||||
"block.engineersdecor.gas_concrete": "Газобетон",
|
||||
"block.engineersdecor.gas_concrete.help": "§6Низкая твердость, высокая производительность бетона.§r Легко ломающийся декоративный бетонный блок.",
|
||||
"block.engineersdecor.gas_concrete_slab": "Газобетонная плита",
|
||||
|
@ -159,6 +177,8 @@
|
|||
"block.engineersdecor.small_block_breaker.status": "SOC: %1$s%% of %2$sRF§r | progress: %3$s%%",
|
||||
"block.engineersdecor.small_electrical_furnace": "Компактная конвейерная электрическая печь",
|
||||
"block.engineersdecor.small_electrical_furnace.help": "§6Компактная конвейерная печь в металлическом корпусе.§r Автоматически принимает предметы со стороны ввода и складывает в инвентарь со стороны вывода. Предметы можно помещать/забирать со всех сторон с помощью воронок. Без проблем пропускает элементы, которые нельзя выплавить или приготовить. Чуть более энергоэффективная и быстрая, чем утеплённая булыжная печь. Транспортировка работает стеками. Механизм требует мало энергии.",
|
||||
"block.engineersdecor.small_electrical_furnace.tooltips.auxslot": "Auxiliary slot\n§8Place a Hopper here to enable automatic feeding from the input side.",
|
||||
"block.engineersdecor.small_electrical_furnace.tooltips.speed": "Smelting speed selection §8(OFF/I/II/III)",
|
||||
"block.engineersdecor.small_fluid_funnel": "Малая воронка для сбора жидкости",
|
||||
"block.engineersdecor.small_fluid_funnel.help": "§6Собирает жидкости над ним.§r Имеет внутренний бак на три ведра. Прослеживает текучие жидкости к соседним блокам источника. Жидкость может быть получена с помощью систем передачи жидкости или ведра. Заполняет только резервуары ниже (сила гравитации). Совместим с ванильным источником бесконечной воды.",
|
||||
"block.engineersdecor.small_lab_furnace": "Компактная лабораторная печь",
|
||||
|
@ -207,6 +227,14 @@
|
|||
"block.engineersdecor.treated_wood_broad_windowsill.help": "§6Простое оформление окон.",
|
||||
"block.engineersdecor.treated_wood_crafting_table": "Верстак из обработанного дерева",
|
||||
"block.engineersdecor.treated_wood_crafting_table.help": "§6Прочный и устойчивый к погодным условиям. Восемь слотов для хранения. Хранит инвентарь. Нажимайте кнопки со стрелками вверх/вниз для выбора из истории, выходной слот для размещения предметов, X-кнопка очистить сетку крафта и историю. Shift-клик по стеку: передача стека от игрока в хранилище при создании если сетка пуста, в противном случае перенос от игрока в сетку. Автоматически распределяет кликаемый стек. Shift-Ctrl-клик по стаку: перемещает одинаковые стаки. Колёсико мыши: добавляет/отнимает предметы в сетке.",
|
||||
"block.engineersdecor.treated_wood_crafting_table.tooltips.clear": "Clear grid to player inventory",
|
||||
"block.engineersdecor.treated_wood_crafting_table.tooltips.fromplayer": "Move items from player inventory",
|
||||
"block.engineersdecor.treated_wood_crafting_table.tooltips.fromstorage": "Move items from storage",
|
||||
"block.engineersdecor.treated_wood_crafting_table.tooltips.next": "Next crafting history recipe",
|
||||
"block.engineersdecor.treated_wood_crafting_table.tooltips.nextcollisionrecipe": "Show next colliding recipe",
|
||||
"block.engineersdecor.treated_wood_crafting_table.tooltips.prev": "Previous crafting history recipe",
|
||||
"block.engineersdecor.treated_wood_crafting_table.tooltips.toplayer": "Clear grid to player inventory",
|
||||
"block.engineersdecor.treated_wood_crafting_table.tooltips.tostorage": "Clear grid to storage",
|
||||
"block.engineersdecor.treated_wood_floor": "Пол из обработанного дерева",
|
||||
"block.engineersdecor.treated_wood_floor.help": "§6Декоративная напольная плитка с текстурными вариациями.§r",
|
||||
"block.engineersdecor.treated_wood_ladder": "Лестница из обработанного дерева",
|
||||
|
|
|
@ -71,10 +71,28 @@
|
|||
"block.engineersdecor.dense_grit_sand_block.help": "§6A compressed sandy soil mixed with stone grid, as known from machine and storage yards.§r Flowers don't really grow on that. Position dependent texture variations.",
|
||||
"block.engineersdecor.factory_dropper": "工厂掉落器",
|
||||
"block.engineersdecor.factory_dropper.help": "§6适用于高级工厂自动化的掉落器。§r有十二个轮询选择的储物格。 掉落的力度、角度、一叠数量和冷却延时可在GUI调节。三个 内部比较槽带有逻辑与或逻辑或功能,可用作内部触发源。内部触发 还能和外部红石信号触发再进行逻辑与或逻辑或。触发模拟按钮仅作测试用途。 当内部触发条件满足时,预先打开卷帘门。所有符合条件的物品 会同时掉落。点击GUI的各处来了解如何运作。",
|
||||
"block.engineersdecor.factory_dropper.tooltips.direction": "Drop direction x/y (-45° to +45°)",
|
||||
"block.engineersdecor.factory_dropper.tooltips.dropcount": "Drop stack size (1 to 32 items)",
|
||||
"block.engineersdecor.factory_dropper.tooltips.externgate": "External signal combination logic (AND or OR)§r\n§8AND: Drop only on an external signal.\nOR: Drop filter matches automatically, non-matching items on external trigger.",
|
||||
"block.engineersdecor.factory_dropper.tooltips.filtergate": "Filter combination gate logic (AND or OR)§r\n§8AND: Drop the stacks as specified in the filters when ALL filters are green.\nOR: Drop the stack of each individual filter when green.",
|
||||
"block.engineersdecor.factory_dropper.tooltips.period": "Drop delay (1s to 10s)",
|
||||
"block.engineersdecor.factory_dropper.tooltips.rssignal": "External Redstone signal indicator\n §8(click to generate a test trigger).",
|
||||
"block.engineersdecor.factory_dropper.tooltips.triggermode": "Trigger mode (pulse/continuous)§r\n§8Pulse: One drop for each OFF->ON of the external signal.\nContinuous: Drop as long as the external signal is ON.",
|
||||
"block.engineersdecor.factory_dropper.tooltips.velocity": "Drop velocity (slow to fast speed)",
|
||||
"block.engineersdecor.factory_hopper": "工厂漏斗",
|
||||
"block.engineersdecor.factory_hopper.help": "§6适用于高级工厂自动化的漏斗。§r可一次传输半组物品,最大收集范围9x9。\n GUI滑动条:控制收集距离(0到4),插入延迟(0.5秒到10秒),插入一叠物品的大小(1到32)。\n GUI红石控制:不反相/反相(默认),脉冲模式/持续模式(默认)。",
|
||||
"block.engineersdecor.factory_hopper.tooltips.count": "Insertion stack size §8(1 to 32 items)",
|
||||
"block.engineersdecor.factory_hopper.tooltips.delayindicator": "Delay indicator\n§8Blinks when the insertion delay timer has not expired yet, or when the Hopper cannot insert into the adjacent inventory.",
|
||||
"block.engineersdecor.factory_hopper.tooltips.inversion": "Inversion mode §8(inverted/not inverted)",
|
||||
"block.engineersdecor.factory_hopper.tooltips.period": "Insertion delay §8(1s to 10s)",
|
||||
"block.engineersdecor.factory_hopper.tooltips.range": "Collection radius §8(0 to 4)",
|
||||
"block.engineersdecor.factory_hopper.tooltips.rssignal": "External Redstone signal indicator",
|
||||
"block.engineersdecor.factory_hopper.tooltips.triggermode": "Trigger mode §8(continuous/pulse)",
|
||||
"block.engineersdecor.factory_placer": "工厂方块放置器",
|
||||
"block.engineersdecor.factory_placer.help": "§6能够放置方块和种植作物或树。§r\n GUI红石控制:不反相/反相(默认),脉冲模式/持续模式(默认)。\n 也支持从耕地下方穿透方块种植。会吐出不能放置或种植的物品。",
|
||||
"block.engineersdecor.factory_placer.tooltips.inversion": "Inversion mode §8(inverted/not inverted)",
|
||||
"block.engineersdecor.factory_placer.tooltips.rssignal": "External Redstone signal indicator",
|
||||
"block.engineersdecor.factory_placer.tooltips.triggermode": "Trigger mode §8(continuous/pulse)",
|
||||
"block.engineersdecor.gas_concrete": "加气混凝土",
|
||||
"block.engineersdecor.gas_concrete.help": "§6低硬度,高产出的混凝土。§r容易破坏的装饰性混凝土方块。",
|
||||
"block.engineersdecor.gas_concrete_slab": "加气混凝土台阶",
|
||||
|
@ -159,6 +177,8 @@
|
|||
"block.engineersdecor.small_block_breaker.status": "SOC: %1$s%% of %2$sRF§r | progress: %3$s%%",
|
||||
"block.engineersdecor.small_electrical_furnace": "小型电炉",
|
||||
"block.engineersdecor.small_electrical_furnace.help": "§6小型金属封装穿过式熔炉。§r 自动从输入端获取物品并在输出端物品栏放置物品。 物品能从所有面使用漏斗插入或提取。无法熔炼或烹饪的物品会直接送到出口。 比加热的圆石炉有稍微高的能效比和更快。 先进先出和自动输出一次移动一组物品。自动输出需要一点能量。",
|
||||
"block.engineersdecor.small_electrical_furnace.tooltips.auxslot": "Auxiliary slot\n§8Place a Hopper here to enable automatic feeding from the input side.",
|
||||
"block.engineersdecor.small_electrical_furnace.tooltips.speed": "Smelting speed selection §8(OFF/I/II/III)",
|
||||
"block.engineersdecor.small_fluid_funnel": "小型流体收集漏斗",
|
||||
"block.engineersdecor.small_fluid_funnel.help": "§6收集上方的流体。§r有一个三桶大的内部储罐。会 追溯流体到附近的源方块。流体可被流体运输系统或桶 移出。只会装满下方的储罐(重力传输)。与原版 无限水兼容。",
|
||||
"block.engineersdecor.small_lab_furnace": "小型实验室炉",
|
||||
|
@ -207,6 +227,14 @@
|
|||
"block.engineersdecor.treated_wood_broad_windowsill.help": "§6简单的窗户装饰。",
|
||||
"block.engineersdecor.treated_wood_crafting_table": "防腐木合成台",
|
||||
"block.engineersdecor.treated_wood_crafting_table.help": "§6坚固,防风防雨。§r内含八个存储格,破坏后保留内容物,没有原版合成书。\n 单击上/下箭头按钮可选择合成历史,单击输出格自动放置物品,单击X按钮 清除合成栏和历史。Shift单击一叠物品:合成格空时转移到存储格, 非空时到合成栏。会自动分配转移的物品。",
|
||||
"block.engineersdecor.treated_wood_crafting_table.tooltips.clear": "Clear grid to player inventory",
|
||||
"block.engineersdecor.treated_wood_crafting_table.tooltips.fromplayer": "Move items from player inventory",
|
||||
"block.engineersdecor.treated_wood_crafting_table.tooltips.fromstorage": "Move items from storage",
|
||||
"block.engineersdecor.treated_wood_crafting_table.tooltips.next": "Next crafting history recipe",
|
||||
"block.engineersdecor.treated_wood_crafting_table.tooltips.nextcollisionrecipe": "Show next colliding recipe",
|
||||
"block.engineersdecor.treated_wood_crafting_table.tooltips.prev": "Previous crafting history recipe",
|
||||
"block.engineersdecor.treated_wood_crafting_table.tooltips.toplayer": "Clear grid to player inventory",
|
||||
"block.engineersdecor.treated_wood_crafting_table.tooltips.tostorage": "Clear grid to storage",
|
||||
"block.engineersdecor.treated_wood_floor": "防腐木地板",
|
||||
"block.engineersdecor.treated_wood_floor.help": "§6装饰性地板砖,有可变的贴图。§r",
|
||||
"block.engineersdecor.treated_wood_ladder": "防腐木梯",
|
||||
|
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s0_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_aluminum"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s0_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_aluminum"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s1_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_aluminum"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s1_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_aluminum"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s2_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_aluminum"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s2_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_aluminum"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s3_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_aluminum"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s3_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_aluminum"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s4_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_aluminum"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s4_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_aluminum"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s5_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_aluminum"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s5_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_aluminum"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s6_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_aluminum"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s6_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_aluminum"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s7_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_aluminum"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s7_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_aluminum"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s8_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_aluminum"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s8_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_aluminum"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s9_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_aluminum"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s9_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_aluminum"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_sa_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_aluminum"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_sa_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_aluminum"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_sb_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_aluminum"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_sb_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_aluminum"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_sc_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_aluminum"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_sc_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_aluminum"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_sd_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_aluminum"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_sd_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_aluminum"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_se_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_aluminum"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_se_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_aluminum"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s0_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_copper"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s0_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_copper"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s1_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_copper"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s1_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_copper"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s2_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_copper"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s2_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_copper"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s3_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_copper"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s3_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_copper"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s4_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_copper"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s4_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_copper"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s5_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_copper"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s5_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_copper"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s6_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_copper"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s6_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_copper"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s7_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_copper"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s7_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_copper"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s8_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_copper"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s8_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_copper"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s9_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_copper"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s9_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_copper"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_sa_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_copper"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_sa_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_copper"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_sb_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_copper"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_sb_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_copper"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_sc_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_copper"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_sc_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_copper"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_sd_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_copper"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_sd_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_copper"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_se_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_copper"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_se_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_copper"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s0_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_gold"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s0_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_gold"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s1_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_gold"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s1_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_gold"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s2_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_gold"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s2_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_gold"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s3_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_gold"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s3_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_gold"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s4_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_gold"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s4_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_gold"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s5_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_gold"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s5_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_gold"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s6_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_gold"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s6_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_gold"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s7_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_gold"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s7_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_gold"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s8_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_gold"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s8_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_gold"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s9_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_gold"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s9_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_gold"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_sa_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_gold"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_sa_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_gold"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_sb_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_gold"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_sb_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_gold"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_sc_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_gold"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_sc_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_gold"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_sd_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_gold"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_sd_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_gold"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_se_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_gold"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_se_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_gold"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s0_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_iron"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s0_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_iron"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s1_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_iron"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s1_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_iron"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s2_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_iron"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s2_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_iron"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s3_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_iron"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s3_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_iron"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s4_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_iron"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s4_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_iron"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s5_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_iron"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s5_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_iron"}}
|
|
@ -1 +1 @@
|
|||
{"parent":"engineersdecor:block/slab/generic/halfslab_s6_model","textures":{"all":"immersiveengineering:blocks/sheetmetal_iron"}}
|
||||
{"parent":"engineersdecor:block/slab/generic/halfslab_s6_model","textures":{"all":"immersiveengineering:block/metal/sheetmetal_iron"}}
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue