diff --git a/src/main/java/thaumicenergistics/common/integration/jade/InfusionMonitorProvider.java b/src/main/java/thaumicenergistics/common/integration/jade/InfusionMonitorProvider.java new file mode 100644 index 0000000..0229c80 --- /dev/null +++ b/src/main/java/thaumicenergistics/common/integration/jade/InfusionMonitorProvider.java @@ -0,0 +1,106 @@ +package thaumicenergistics.common.integration.jade; + +import net.minecraft.nbt.CompoundTag; +import net.minecraft.network.chat.Component; +import net.minecraft.resources.ResourceLocation; +import snownee.jade.api.BlockAccessor; +import snownee.jade.api.IBlockComponentProvider; +import snownee.jade.api.IServerDataProvider; +import snownee.jade.api.ITooltip; +import snownee.jade.api.config.IPluginConfig; +import snownee.jade.api.ui.IElementHelper; +import thaumicenergistics.ThaumicEnergistics; +import thaumicenergistics.common.tiles.TileInfusionMonitor; +import thaumicenergistics.common.tiles.TileInfusionMonitor.RiskData; + +/** + * 注魔监视器 Jade 显示:网络连接时展示附近注魔祭坛的 5 档风险 + 不稳定度 + 档位文字。 + * 服务端把 BE 缓存的 RiskData 写入 NBT,客户端渲染。 + */ +public enum InfusionMonitorProvider implements IBlockComponentProvider, IServerDataProvider { + INSTANCE; + + private static final String KEY = "InfusionMonitorRisk"; + private static final int TIER_COLOR = 0xFF55FFFF; + + @Override + public void appendServerData(CompoundTag data, BlockAccessor accessor) { + if (accessor.getBlockEntity() instanceof TileInfusionMonitor monitor) { + RiskData risk = monitor.getCachedRisk(); + CompoundTag tag = new CompoundTag(); + tag.putBoolean("found", risk.found()); + tag.putBoolean("crafting", risk.crafting()); + tag.putInt("tier", risk.tier()); + tag.putInt("instability", risk.instability()); + tag.putInt("symmetry", risk.symmetry()); + tag.putInt("recipeInstability", risk.recipeInstability()); + tag.putString("tierText", risk.tierText()); + tag.putString("shortages", risk.shortages()); + tag.putInt("totalNeeded", risk.totalNeeded()); + data.put(KEY, tag); + } + } + + @Override + public void appendTooltip(ITooltip tooltip, BlockAccessor accessor, IPluginConfig config) { + if (!accessor.getServerData().contains(KEY)) return; + CompoundTag tag = accessor.getServerData().getCompound(KEY); + boolean found = tag.getBoolean("found"); + + // 标题:监视器 + 状态 + tooltip.add(Component.translatable("thaumicenergistics.jade.monitor.title")); + + if (!found) { + tooltip.add(Component.translatable("thaumicenergistics.jade.monitor.no_matrix")); + return; + } + + boolean crafting = tag.getBoolean("crafting"); + int tier = tag.getInt("tier"); + int instability = tag.getInt("instability"); + int symmetry = tag.getInt("symmetry"); + int recipeInstability = tag.getInt("recipeInstability"); + String tierText = tag.getString("tierText"); + String shortages = tag.getString("shortages"); + int totalNeeded = tag.getInt("totalNeeded"); + + // 档位:⭐×tier / 5 + String stars = "★".repeat(Math.max(1, tier)) + "☆".repeat(5 - tier); + tooltip.add(Component.literal(stars + " (" + tier + "/5)") + .withStyle(style -> style.withColor(tierColor(tier)))); + + // 不稳定度(分解:基础 + 祭坛) + tooltip.add(Component.translatable("thaumicenergistics.jade.monitor.instability", + instability, recipeInstability, symmetry)); + + // 档位文字(后果描述) + if (!tierText.isEmpty()) { + tooltip.add(Component.literal(tierText)); + } + + // 源质缺口 + if (crafting) { + tooltip.add(Component.translatable("thaumicenergistics.jade.monitor.crafting")); + } + if (!shortages.isEmpty()) { + tooltip.add(Component.translatable("thaumicenergistics.jade.monitor.shortages", shortages)); + } else if (totalNeeded > 0) { + tooltip.add(Component.translatable("thaumicenergistics.jade.monitor.essence_ok")); + } + } + + private static int tierColor(int tier) { + return switch (tier) { + case 1 -> 0xFF55FF55; // 绿 + case 2 -> 0xFFAAFF55; // 黄绿 + case 3 -> 0xFFFFFF55; // 黄 + case 4 -> 0xFFFFAA55; // 橙 + default -> 0xFFFF5555; // 红 + }; + } + + @Override + public ResourceLocation getUid() { + return ResourceLocation.fromNamespaceAndPath(ThaumicEnergistics.MODID, "infusion_monitor"); + } +} diff --git a/src/main/java/thaumicenergistics/common/tiles/InfusionRiskCalculator.java b/src/main/java/thaumicenergistics/common/tiles/InfusionRiskCalculator.java new file mode 100644 index 0000000..f4f10fc --- /dev/null +++ b/src/main/java/thaumicenergistics/common/tiles/InfusionRiskCalculator.java @@ -0,0 +1,199 @@ +package thaumicenergistics.common.tiles; + +import net.minecraft.core.BlockPos; +import net.minecraft.world.item.ItemStack; +import net.minecraft.world.level.Level; +import net.minecraft.world.level.block.entity.BlockEntity; +import thaumcraft.api.aspects.Aspect; +import thaumcraft.api.aspects.AspectList; +import thaumcraft.api.aspects.IAspectContainer; +import thaumcraft.common.blockentities.InfusionMatrixBlockEntity; +import thaumcraft.common.blockentities.PedestalBlockEntity; +import thaumicenergistics.common.tiles.TileInfusionMonitor.RiskData; + +import java.util.ArrayList; +import java.util.List; +import java.util.Map; +import java.util.concurrent.ConcurrentHashMap; + +/** + * 注魔风险计算:扫描附近的注魔矩阵,按 5 档风险显示。 + *

+ * 判定依据(与 0.2.2.95 {@code InfusionMatrixBlockEntity} 源码一致): + *

+ */ +public final class InfusionRiskCalculator { + + /** 扫描祭坛的半径。 */ + private static final int MATRIX_SEARCH_RADIUS = 16; + /** 源质扫描半径(对应 EssentiaHandler.drainEssentia 的 range=12)。 */ + private static final int ESSENTIA_SCAN_RADIUS = 12; + + private InfusionRiskCalculator() {} + + /** 附近注魔矩阵信息。 */ + public record InfusionMatrixInfo(BlockPos matrixPos, InfusionMatrixBlockEntity matrix) {} + + /** 扫描指定位置附近的注魔矩阵(取最近的)。 */ + public static InfusionMatrixInfo scanNearbyMatrix(Level level, BlockPos center) { + InfusionMatrixBlockEntity nearest = null; + int bestDist = Integer.MAX_VALUE; + for (int dx = -MATRIX_SEARCH_RADIUS; dx <= MATRIX_SEARCH_RADIUS; dx++) { + for (int dz = -MATRIX_SEARCH_RADIUS; dz <= MATRIX_SEARCH_RADIUS; dz++) { + // 注魔矩阵在 y 方向位置固定(中央柱在下方 2 格),扫描 3 层高度 + for (int dy = -4; dy <= 4; dy++) { + BlockPos pos = center.offset(dx, dy, dz); + if (level.getBlockEntity(pos) instanceof InfusionMatrixBlockEntity matrix) { + int dist = dx * dx + dz * dz + dy * dy; + if (dist < bestDist) { + bestDist = dist; + nearest = matrix; + } + } + } + } + } + return nearest != null ? new InfusionMatrixInfo(nearest.getBlockPos(), nearest) : null; + } + + /** + * 计算风险数据。若祭坛正在注魔,用实时 instability;否则估算: + * 复制 matches() 匹配当前祭坛布局的配方(忽略研究门禁),得出配方基础不稳定 + 祭坛对称度。 + */ + public static RiskData computeRisk(Level level, InfusionMatrixInfo info) { + InfusionMatrixBlockEntity matrix = info.matrix(); + boolean crafting = matrix.crafting(); + int symmetry = matrix.symmetry(); + int recipeInstability; + int instability; + + if (crafting) { + // 注魔中:instability() 实时(可能被源质不足推高) + instability = Math.min(25, matrix.instability()); + recipeInstability = Math.max(0, instability - symmetry); + } else { + // 未开始:估算配方基础不稳定 + recipeInstability = estimateRecipeInstability(level, info); + instability = Math.min(25, recipeInstability + symmetry); + } + + // 源质缺口:剩余所需 vs 周围可抽 + String shortages = ""; + int totalNeeded = 0; + AspectList remaining = matrix.remainingEssentia(); + if (remaining != null && remaining.size() > 0) { + Map available = scanAvailableEssentia(level, info.matrixPos()); + StringBuilder sb = new StringBuilder(); + for (Aspect aspect : remaining.aspects()) { + int need = remaining.amount(aspect); + if (need <= 0) continue; + totalNeeded += need; + long have = available.getOrDefault(aspect, 0L); + if (have < need) { + if (!sb.isEmpty()) sb.append(","); + sb.append(aspect.getTag()).append(" 缺 ").append(need - have); + } + } + shortages = sb.toString(); + } + + int tier = tierFor(instability, shortages, totalNeeded); + return new RiskData(true, crafting, tier, instability, symmetry, recipeInstability, + tierText(tier), shortages, totalNeeded); + } + + /** 5 档判定:不稳定度 + 源质缺口强制升级。 */ + private static int tierFor(int instability, String shortages, int totalNeeded) { + int tier; + if (instability <= 1) tier = 1; + else if (instability <= 3) tier = 2; + else if (instability <= 6) tier = 3; + else if (instability <= 12) tier = 4; + else tier = 5; + // 源质缺口强制升级 + if (!shortages.isEmpty()) { + // 缺口过半(总需 > 0 且缺口文字非空)→ 至少 4 档;严重 → 5 档 + if (totalNeeded > 0 && shortages.length() > 20) { + tier = Math.max(tier, 5); + } else { + tier = Math.max(tier, 4); + } + } + return tier; + } + + /** 档位对应文字(玩家视角后果)。 */ + public static String tierText(int tier) { + return switch (tier) { + case 1 -> "基本安静,偶发弹飞 1 个物品"; + case 2 -> "弹飞常见;闪电/咒波几乎不出现"; + case 3 -> "弹飞+可能电击;咒波罕见"; + case 4 -> "电击/爆炸/咒波都可能;可能销毁物品"; + case 5 -> "频繁销毁/爆炸/咒波/精神污染——不要开始"; + default -> ""; + }; + } + + /** 未注魔时估算匹配配方的配方基础不稳定(复制 matches 但忽略研究门禁)。 */ + private static int estimateRecipeInstability(Level level, InfusionMatrixInfo info) { + InfusionMatrixBlockEntity matrix = info.matrix(); + try { + // 取中央柱物品(注魔矩阵正下方 2 格) + PedestalBlockEntity center = level.getBlockEntity(info.matrixPos().below(2)) instanceof PedestalBlockEntity ped + ? ped : null; + if (center == null || center.heldStack().isEmpty()) { + return 0; + } + ItemStack central = center.heldStack(); + // 收集周围柱物品(与 scanSurroundings 一致的 ±8 范围简化版) + List components = new ArrayList<>(); + for (int dx = -8; dx <= 8; dx++) { + for (int dz = -8; dz <= 8; dz++) { + if (dx == 0 && dz == 0) continue; + for (int dy = 1; dy <= 10; dy++) { + BlockEntity be = level.getBlockEntity(info.matrixPos().offset(dx, -dy, dz)); + if (be instanceof PedestalBlockEntity ped && !ped.heldStack().isEmpty()) { + components.add(ped.heldStack()); + break; + } + } + } + } + // 找匹配配方(忽略研究:直接比对中央 + 组件,不调 matches 以免研究门禁) + for (Object o : thaumcraft.api.ThaumcraftApi.getCraftingRecipes()) { + if (!(o instanceof thaumcraft.api.crafting.InfusionRecipe recipe)) continue; + if (!recipe.getRecipeInput().is(central.getItem())) continue; + // 简化:中央物品匹配即采用其基础不稳定(组件精确匹配留给 craftingStart 处理) + return recipe.instability(central); + } + } catch (Exception ignored) { + } + return 0; + } + + /** 扫描周围 12 格内源质容器,汇总每种源质可抽量。 */ + private static Map scanAvailableEssentia(Level level, BlockPos matrixPos) { + Map totals = new ConcurrentHashMap<>(); + for (int dx = -ESSENTIA_SCAN_RADIUS; dx <= ESSENTIA_SCAN_RADIUS; dx++) { + for (int dy = -6; dy <= 6; dy++) { + for (int dz = -ESSENTIA_SCAN_RADIUS; dz <= ESSENTIA_SCAN_RADIUS; dz++) { + BlockEntity be = level.getBlockEntity(matrixPos.offset(dx, dy, dz)); + if (be == null || be == level.getBlockEntity(matrixPos)) continue; + if (be instanceof IAspectContainer container) { + AspectList aspects = container.getAspects(); + if (aspects == null) continue; + for (Aspect aspect : aspects.aspects()) { + int amt = aspects.getAmount(aspect); + if (amt > 0) totals.merge(aspect, (long) amt, Long::sum); + } + } + } + } + } + return totals; + } +} diff --git a/src/main/java/thaumicenergistics/common/tiles/TileInfusionMonitor.java b/src/main/java/thaumicenergistics/common/tiles/TileInfusionMonitor.java new file mode 100644 index 0000000..1ef0335 --- /dev/null +++ b/src/main/java/thaumicenergistics/common/tiles/TileInfusionMonitor.java @@ -0,0 +1,517 @@ +package thaumicenergistics.common.tiles; + +import net.minecraft.core.BlockPos; +import net.minecraft.core.Direction; +import net.minecraft.core.HolderLookup; +import net.minecraft.nbt.CompoundTag; +import net.minecraft.network.chat.Component; +import net.minecraft.world.Container; +import net.minecraft.world.Containers; +import net.minecraft.world.SimpleContainer; +import net.minecraft.world.entity.EntityType; +import net.minecraft.world.entity.Display; +import net.minecraft.world.entity.player.Player; +import net.minecraft.world.item.ItemStack; +import net.minecraft.world.level.Level; +import net.minecraft.world.level.block.entity.BlockEntity; +import net.minecraft.world.level.block.state.BlockState; +import net.minecraft.world.phys.AABB; +import net.neoforged.neoforge.common.extensions.IPlayerExtension; +import net.neoforged.neoforge.network.PacketDistributor; + +import java.util.EnumSet; +import java.util.List; + +import appeng.api.networking.GridFlags; +import appeng.api.networking.GridHelper; +import appeng.api.networking.IGrid; +import appeng.api.networking.IGridNode; +import appeng.api.networking.IGridNodeListener; +import appeng.api.networking.IManagedGridNode; +import appeng.api.networking.IInWorldGridNodeHost; +import appeng.api.util.AECableType; +import net.minecraft.world.item.Items; +import thaumicenergistics.ThaumicEnergistics; +import thaumicenergistics.init.ModBlockEntities; +import thaumicenergistics.init.ModBlocks; + +/** + * 注魔监视器(灵气观测器)方块实体。 + *
    + *
  • 1 格物品槽:Shift+右键放入魔导手册(book 状态)。
  • + *
  • AE2 网格节点:连接 ME 网络后 network 状态=true。
  • + *
  • 每 tick 扫描附近注魔矩阵,缓存风险数据供 Jade 显示(5 档风险/不稳定度/档位文字)。
  • + *
+ * 方块状态: + *
    + *
  1. 默认 → off 模型
  2. + *
  3. 放手册 → off + book
  4. + *
  5. 手册 + 连网 → off + book + on
  6. + *
  7. 连网(无手册)→ off + Jade 显示
  8. + *
+ */ +public class TileInfusionMonitor extends ThETileBase implements IInWorldGridNodeHost { + + /** 手册槽位。 */ + public static final int BOOK_SLOT = 0; + private static final int SCAN_INTERVAL = 10; // 每 10 tick 扫描一次祭坛 + + protected final IManagedGridNode mainNode; + private final SimpleContainer inventory = new SimpleContainer(1) { + @Override + public void setChanged() { + super.setChanged(); + TileInfusionMonitor.this.setChanged(); + TileInfusionMonitor.this.updateBookState(); + } + }; + + private int scanCounter = 0; + private BlockPos matrixPos = null; + + /** 缓存的注魔风险数据(弹窗显示)。 */ + private RiskData cachedRisk = RiskData.NONE; + + /** 悬浮气泡实体(text_display,服务端引用)。 */ + private net.minecraft.world.entity.Display.TextDisplay bubble; + + /** 气泡实体 Tag(用于坐标匹配查找)。 */ + private static final String BUBBLE_TAG = "thaumicenergistics:monitor_bubble"; + /** 气泡背景:半透明深灰(ARGB,Alpha=176)。 */ + private static final int BUBBLE_BG_COLOR = 0xB0333333; + /** 气泡行宽(换行宽度)。中文全角字符约 12px,最长行"不稳定度: 9 (基础 5 + 祭坛 4)"约 240px—— + * 必须大于最长行,否则行尾空格被换行逻辑丢弃、背景只包住分段 → 右侧看似截断。 */ + private static final int BUBBLE_LINE_WIDTH = 320; + + private final IGridNodeListener nodeListener = new IGridNodeListener<>() { + @Override + public void onSaveChanges(TileInfusionMonitor owner, IGridNode node) { + owner.setChanged(); + } + + @Override + public void onStateChanged(TileInfusionMonitor owner, IGridNode node, State state) { + if (state == State.POWER) { + owner.updateNetworkState(); + } + owner.markForUpdate(); + } + }; + + public TileInfusionMonitor(BlockPos pos, BlockState state) { + super(ModBlockEntities.INFUSION_MONITOR.get(), pos, state); + this.mainNode = GridHelper.createManagedNode(this, nodeListener) + .setVisualRepresentation(thaumicenergistics.init.ModItems.INFUSION_MONITOR_ITEM.get()) + .setInWorldNode(true) + .setTagName("proxy") + .setFlags(GridFlags.REQUIRE_CHANNEL) + .setExposedOnSides(EnumSet.allOf(Direction.class)); + this.mainNode.setIdlePowerUsage(40.0); + } + + @Override + public void onLoad() { + super.onLoad(); + if (level != null && !level.isClientSide()) { + mainNode.create(level, getBlockPos()); + } + updateBookState(); + updateNetworkState(); + } + + @Override + public void setRemoved() { + super.setRemoved(); + if (level != null && !level.isClientSide()) { + discardBubble(); + } + if (mainNode != null) { + mainNode.destroy(); + } + } + + @Override + public void onChunkUnloaded() { + super.onChunkUnloaded(); + if (mainNode != null) { + mainNode.destroy(); + } + } + + @Override + public void onBreakBlock() { + super.onBreakBlock(); + if (level != null && !level.isClientSide) { + discardBubble(); + Containers.dropContents(level, worldPosition, inventory); + } + } + + // ===== tick / 扫描 ===== + + public static void tick(Level level, BlockPos pos, BlockState state, TileInfusionMonitor be) { + if (level.isClientSide()) return; + if (++be.scanCounter >= SCAN_INTERVAL) { + be.scanCounter = 0; + be.scanMatrix(); + } + be.updateNetworkState(); + be.updateBubble(); + } + + /** 扫描附近注魔矩阵并缓存风险数据。 */ + private void scanMatrix() { + BlockPos found = null; + InfusionRiskCalculator.InfusionMatrixInfo info = InfusionRiskCalculator.scanNearbyMatrix(level, worldPosition); + RiskData newRisk = info != null ? InfusionRiskCalculator.computeRisk(level, info) : RiskData.NONE; + boolean riskChanged = !newRisk.equals(this.cachedRisk); + this.cachedRisk = newRisk; + if (info != null) { + found = info.matrixPos(); + } + if (riskChanged || !java.util.Objects.equals(found, this.matrixPos)) { + this.matrixPos = found; + markForUpdate(); + } + } + + // ===== 网格节点 / 状态同步 ===== + + private void updateNetworkState() { + if (level == null || level.isClientSide()) return; + boolean net = mainNode.isActive(); + BlockState st = getBlockState(); + if (st.getValue(ModBlocks.NETWORK) != net) { + level.setBlock(worldPosition, st.setValue(ModBlocks.NETWORK, net), 3); + // setBlock 后本 BE 仍存在;刷新引用 + BlockEntity be = level.getBlockEntity(worldPosition); + if (be != null && be != this) { + be.setChanged(); + } + } + } + + private void updateBookState() { + if (level == null || level.isClientSide()) return; + boolean hasBook = !inventory.getItem(BOOK_SLOT).isEmpty(); + BlockState st = getBlockState(); + if (st.getValue(ModBlocks.BOOK) != hasBook) { + level.setBlock(worldPosition, st.setValue(ModBlocks.BOOK, hasBook), 3); + BlockEntity be = level.getBlockEntity(worldPosition); + if (be != null && be != this) { + be.setChanged(); + } + } + } + + // ===== 悬浮气泡(text_display 实体) ===== + + /** + * 每 tick 更新气泡:条件 = 放入魔导手册 且 连接 AE 网络 且 检测到注魔祭坛。 + * 满足 → 生成/更新气泡;不满足 → 销毁气泡。 + */ + private void updateBubble() { + if (level == null || level.isClientSide()) return; + boolean shouldShow = getBlockState().getValue(ModBlocks.BOOK) + && getBlockState().getValue(ModBlocks.NETWORK) + && cachedRisk.found(); + if (shouldShow) { + ensureBubble(); + if (bubble != null) { + applyBubbleNbt(buildBubbleText(cachedRisk)); + } + } else { + discardBubble(); + } + } + + /** 确保气泡实体存在(不存在则生成;区块重载后按 Tag 找回旧实体)。 */ + private void ensureBubble() { + if (bubble != null && bubble.isAlive()) return; + bubble = findBubble(); + if (bubble != null) return; + bubble = EntityType.TEXT_DISPLAY.create(level); + if (bubble == null) return; + bubble.setPos(worldPosition.getX() + 0.5, worldPosition.getY() + 1.4, worldPosition.getZ() + 0.5); + // 1.21.1 TextDisplay 配置 API 均为 private/protected:反射调用 readAdditionalSaveData + // 用 summon 命令同款 NBT 一次配置全部字段(text/background/billboard/shadow/see_through 等)。 + applyBubbleNbt(buildBubbleText(cachedRisk)); + bubble.addTag(BUBBLE_TAG); + level.addFreshEntity(bubble); + } + + /** 反射调用 readAdditionalSaveData(CompoundTag) 配置气泡(缓存 Method)。 */ + private static java.lang.reflect.Method READ_NBT_METHOD; + + private void applyBubbleNbt(Component text) { + if (bubble == null || level == null) return; + try { + if (READ_NBT_METHOD == null) { + READ_NBT_METHOD = net.minecraft.world.entity.Entity.class + .getDeclaredMethod("readAdditionalSaveData", CompoundTag.class); + READ_NBT_METHOD.setAccessible(true); + } + CompoundTag nbt = new CompoundTag(); + nbt.putString("text", Component.Serializer.toJson(text, level.registryAccess())); + nbt.putBoolean("default_background", false); + nbt.putInt("background", BUBBLE_BG_COLOR); + nbt.putString("billboard", "vertical"); + nbt.putInt("line_width", BUBBLE_LINE_WIDTH); + nbt.putBoolean("shadow", true); + nbt.putBoolean("see_through", false); + // 文字调小:transformation.scale 整体缩到 0.5(text_display 无字号参数,靠实体缩放) + CompoundTag transform = new CompoundTag(); + transform.put("scale", floatList(0.5F, 0.5F, 0.5F)); + transform.put("translation", floatList(0F, 0F, 0F)); + transform.put("left_rotation", floatList(0F, 0F, 0F, 1F)); + transform.put("right_rotation", floatList(0F, 0F, 0F, 1F)); + nbt.put("transformation", transform); + READ_NBT_METHOD.invoke(bubble, nbt); + } catch (Exception e) { + ThaumicEnergistics.LOG.warn("[Monitor] 气泡配置失败: {}", e.toString()); + } + } + + /** 构造 FloatTag 列表(1.21.1 CompoundTag 无 putFloatArray,需 ListTag)。 */ + private static net.minecraft.nbt.ListTag floatList(float... values) { + net.minecraft.nbt.ListTag list = new net.minecraft.nbt.ListTag(); + for (float v : values) { + list.add(net.minecraft.nbt.FloatTag.valueOf(v)); + } + return list; + } + + /** 按 Tag + 方块附近 AABB 查找已存在的气泡。 */ + private net.minecraft.world.entity.Display.TextDisplay findBubble() { + if (level == null) return null; + AABB aabb = new AABB(worldPosition).inflate(0.15, 2.0, 0.15); + List list = level.getEntitiesOfClass( + net.minecraft.world.entity.Display.TextDisplay.class, aabb, + e -> e.getTags().contains(BUBBLE_TAG)); + return list.isEmpty() ? null : list.get(0); + } + + /** 销毁气泡(方块拆除/条件不满足时)。 */ + private void discardBubble() { + if (bubble != null && bubble.isAlive()) { + bubble.discard(); + } else { + net.minecraft.world.entity.Display.TextDisplay found = findBubble(); + if (found != null) { + found.discard(); + } + } + bubble = null; + } + + /** 风险数据 → 气泡多行文本(2 行:注魔风险/不稳定度;描述改由右键在聊天框显示)。 */ + private static Component buildBubbleText(RiskData risk) { + // 内边距必须用不间断空格(\u00A0):普通空格在行尾会被字体布局裁剪, + // 导致背景只包住左侧、右侧贴边。NBSP 有真实字形,两侧都保留。 + String pad = "\u00A0\u00A0"; // 左右内边距(NBSP) + String tierWord = tierWord(risk.tier()); + + Component line1 = Component.literal(pad + "注魔风险: " + tierWord + pad) + .withStyle(style -> style.withColor(tierColor(risk.tier()))); + Component line2 = Component.literal(pad + "不稳定度: " + risk.instability() + + " (基础 " + risk.recipeInstability() + " + 祭坛 " + risk.symmetry() + ")" + pad) + .withStyle(style -> style.withColor(0xFFFFFFFF)); + + // 上下各留一个空行(垂直内边距) + return Component.literal("\n") + .append(line1).append("\n") + .append(line2).append("\n"); + } + + /** 5 档文字(无星星)。 */ + private static String tierWord(int tier) { + return switch (tier) { + case 1 -> "极低"; + case 2 -> "低"; + case 3 -> "中"; + case 4 -> "高"; + case 5 -> "极高"; + default -> "?"; + }; + } + + /** 5 档描述(神秘时代风)。 */ + private static String tierDesc(int tier) { + return switch (tier) { + case 1 -> "灵光如镜,仪式安然"; + case 2 -> "灵光微澜,无碍仪式"; + case 3 -> "符文低鸣,灵光流转不宁"; + case 4 -> "裂隙于虚空中睁开,注视着祭坛"; + case 5 -> "咒波翻涌,裂隙将吞没一切"; + default -> ""; + }; + } + + /** 档位颜色:1 绿 → 5 红。 */ + private static int tierColor(int tier) { + return switch (tier) { + case 1 -> 0xFF55FF55; + case 2 -> 0xFFAAFF55; + case 3 -> 0xFFFFFF55; + case 4 -> 0xFFFFAA55; + default -> 0xFFFF5555; + }; + } + + /** 放入魔导手册(方块右键拦截后调用,防止书自身 use 打开界面)。 */ + public void placeBook(Player player, ItemStack held) { + if (level == null || level.isClientSide()) return; + if (inventory.getItem(BOOK_SLOT).isEmpty()) { + inventory.setItem(BOOK_SLOT, held.copyWithCount(1)); + if (!player.getAbilities().instabuild) { + held.shrink(1); + } + setChanged(); + } + } + + /** 取回魔导手册(Shift+右键)。 */ + public void retrieveBook(Player player) { + if (level == null || level.isClientSide()) return; + ItemStack book = inventory.getItem(BOOK_SLOT); + if (!book.isEmpty()) { + if (!player.getInventory().add(book)) { + net.minecraft.world.Containers.dropItemStack(level, worldPosition.getX(), worldPosition.getY(), worldPosition.getZ(), book); + } + inventory.setItem(BOOK_SLOT, ItemStack.EMPTY); + setChanged(); + } + } + + /** 右键:在玩家聊天框显示当前风险档位 + 描述。 */ + public void showDescriptionInChat(Player player) { + if (level == null || level.isClientSide()) return; + if (!cachedRisk.found()) { + player.sendSystemMessage(Component.literal("§7韵魔观测器: 未检测到注魔祭坛")); + return; + } + String tierWord = tierWord(cachedRisk.tier()); + String desc = tierDesc(cachedRisk.tier()); + // 档位行用档位颜色 + Component msg = Component.literal("注魔风险: ") + .withStyle(style -> style.withColor(tierColor(cachedRisk.tier()))) + .append(Component.literal(tierWord + " §f—— " + desc)); + player.sendSystemMessage(msg); + } + + public static boolean isThaumonomicon(ItemStack stack) { + if (stack.isEmpty()) return false; + return stack.is(net.minecraft.core.registries.BuiltInRegistries.ITEM.get( + net.minecraft.resources.ResourceLocation.fromNamespaceAndPath("thaumcraft", "thaumonomicon"))); + } + + // ===== 访问器 ===== + + public Container getInventory() { + return inventory; + } + + public boolean hasBook() { + return !inventory.getItem(BOOK_SLOT).isEmpty(); + } + + public RiskData getCachedRisk() { + return cachedRisk; + } + + // ===== IInWorldGridNodeHost ===== + + @Override + public IGridNode getGridNode(Direction dir) { + return mainNode.getNode(); + } + + public AECableType getCableConnectionType(Direction dir) { + return AECableType.SMART; + } + + public void markForUpdate() { + if (level != null) { + setChanged(); + level.sendBlockUpdated(worldPosition, getBlockState(), getBlockState(), 3); + // blockEntityChanged → 触发 getUpdateTag 同步到客户端(悬浮弹窗数据依赖) + level.blockEntityChanged(worldPosition); + } + } + + // ===== NBT ===== + + @Override + public CompoundTag getUpdateTag(HolderLookup.Provider reg) { + CompoundTag tag = super.getUpdateTag(reg); + saveRiskToTag(tag); + if (!inventory.getItem(BOOK_SLOT).isEmpty()) { + tag.put("Book", inventory.getItem(BOOK_SLOT).save(reg)); + } + return tag; + } + + @Override + public void handleUpdateTag(CompoundTag tag, HolderLookup.Provider reg) { + super.handleUpdateTag(tag, reg); + loadRiskFromTag(tag); + if (tag.contains("Book")) { + inventory.setItem(BOOK_SLOT, ItemStack.parseOptional(reg, tag.getCompound("Book"))); + } + } + + private void saveRiskToTag(CompoundTag tag) { + tag.putBoolean("RiskFound", cachedRisk.found()); + tag.putBoolean("RiskCrafting", cachedRisk.crafting()); + tag.putInt("RiskTier", cachedRisk.tier()); + tag.putInt("RiskInstability", cachedRisk.instability()); + tag.putInt("RiskSymmetry", cachedRisk.symmetry()); + tag.putInt("RiskRecipeInstability", cachedRisk.recipeInstability()); + tag.putString("RiskTierText", cachedRisk.tierText()); + tag.putString("RiskShortages", cachedRisk.shortages()); + tag.putInt("RiskTotalNeeded", cachedRisk.totalNeeded()); + } + + private void loadRiskFromTag(CompoundTag tag) { + this.cachedRisk = new RiskData( + tag.getBoolean("RiskFound"), + tag.getBoolean("RiskCrafting"), + tag.getInt("RiskTier"), + tag.getInt("RiskInstability"), + tag.getInt("RiskSymmetry"), + tag.getInt("RiskRecipeInstability"), + tag.getString("RiskTierText"), + tag.getString("RiskShortages"), + tag.getInt("RiskTotalNeeded")); + } + + @Override + protected void loadAdditional(CompoundTag tag, HolderLookup.Provider reg) { + super.loadAdditional(tag, reg); + if (tag.contains("Book")) { + inventory.setItem(BOOK_SLOT, ItemStack.parseOptional(reg, tag.getCompound("Book"))); + } + if (tag.contains("MatrixPos")) { + matrixPos = BlockPos.of(tag.getLong("MatrixPos")); + } + mainNode.loadFromNBT(tag); + } + + @Override + protected void saveAdditional(CompoundTag tag, HolderLookup.Provider reg) { + super.saveAdditional(tag, reg); + if (!inventory.getItem(BOOK_SLOT).isEmpty()) { + tag.put("Book", inventory.getItem(BOOK_SLOT).save(reg)); + } + if (matrixPos != null) { + tag.putLong("MatrixPos", matrixPos.asLong()); + } + mainNode.saveToNBT(tag); + } + + /** 注魔风险缓存数据(Jade 用)。 */ + public record RiskData(boolean found, boolean crafting, int tier, int instability, int symmetry, + int recipeInstability, String tierText, String shortages, int totalNeeded) { + public static final RiskData NONE = new RiskData(false, false, 0, 0, 0, 0, "", "", 0); + } +} diff --git a/src/main/resources/assets/thaumicenergistics/blockstates/alkusure86fumo.json b/src/main/resources/assets/thaumicenergistics/blockstates/alkusure86fumo.json new file mode 100644 index 0000000..3ae5806 --- /dev/null +++ b/src/main/resources/assets/thaumicenergistics/blockstates/alkusure86fumo.json @@ -0,0 +1,12 @@ +{ + "variants": { + "facing=north,variant=false": { "model": "thaumicenergistics:block/alkusure86fumo", "y": 0 }, + "facing=south,variant=false": { "model": "thaumicenergistics:block/alkusure86fumo", "y": 180 }, + "facing=east,variant=false": { "model": "thaumicenergistics:block/alkusure86fumo", "y": 90 }, + "facing=west,variant=false": { "model": "thaumicenergistics:block/alkusure86fumo", "y": 270 }, + "facing=north,variant=true": { "model": "thaumicenergistics:block/a999csfumo", "y": 0 }, + "facing=south,variant=true": { "model": "thaumicenergistics:block/a999csfumo", "y": 180 }, + "facing=east,variant=true": { "model": "thaumicenergistics:block/a999csfumo", "y": 90 }, + "facing=west,variant=true": { "model": "thaumicenergistics:block/a999csfumo", "y": 270 } + } +} diff --git a/src/main/resources/assets/thaumicenergistics/blockstates/infusion_monitor.json b/src/main/resources/assets/thaumicenergistics/blockstates/infusion_monitor.json new file mode 100644 index 0000000..badc49e --- /dev/null +++ b/src/main/resources/assets/thaumicenergistics/blockstates/infusion_monitor.json @@ -0,0 +1,16 @@ +{ + "multipart": [ + { "when": { "facing": "north" }, "apply": { "model": "thaumicenergistics:block/infusion_monitor_off", "y": 180 } }, + { "when": { "facing": "south" }, "apply": { "model": "thaumicenergistics:block/infusion_monitor_off", "y": 0 } }, + { "when": { "facing": "east" }, "apply": { "model": "thaumicenergistics:block/infusion_monitor_off", "y": 270 } }, + { "when": { "facing": "west" }, "apply": { "model": "thaumicenergistics:block/infusion_monitor_off", "y": 90 } }, + { "when": { "facing": "north", "book": "true" }, "apply": { "model": "thaumicenergistics:block/infusion_monitor_book", "y": 180 } }, + { "when": { "facing": "south", "book": "true" }, "apply": { "model": "thaumicenergistics:block/infusion_monitor_book", "y": 0 } }, + { "when": { "facing": "east", "book": "true" }, "apply": { "model": "thaumicenergistics:block/infusion_monitor_book", "y": 270 } }, + { "when": { "facing": "west", "book": "true" }, "apply": { "model": "thaumicenergistics:block/infusion_monitor_book", "y": 90 } }, + { "when": { "facing": "north", "book": "true", "network": "true" }, "apply": { "model": "thaumicenergistics:block/infusion_monitor_on", "y": 180 } }, + { "when": { "facing": "south", "book": "true", "network": "true" }, "apply": { "model": "thaumicenergistics:block/infusion_monitor_on", "y": 0 } }, + { "when": { "facing": "east", "book": "true", "network": "true" }, "apply": { "model": "thaumicenergistics:block/infusion_monitor_on", "y": 270 } }, + { "when": { "facing": "west", "book": "true", "network": "true" }, "apply": { "model": "thaumicenergistics:block/infusion_monitor_on", "y": 90 } } + ] +} diff --git a/src/main/resources/assets/thaumicenergistics/models/block/a999csfumo.json b/src/main/resources/assets/thaumicenergistics/models/block/a999csfumo.json new file mode 100644 index 0000000..405b0e3 --- /dev/null +++ b/src/main/resources/assets/thaumicenergistics/models/block/a999csfumo.json @@ -0,0 +1,216 @@ +{ + "format_version": "1.9.0", + "credit": "Made with _leng", + "render_type": "cutout", + "textures": { + "1": "thaumicenergistics:block/alkusure86fumo", + "particle": "thaumicenergistics:block/alkusure86fumo" + }, + "elements": [ + { + "name": "Head", + "from": [4.35, 4.48613, 8.33113], + "to": [11.65, 11.78613, 15.63113], + "rotation": {"angle": 22.5, "axis": "x", "origin": [7.975, 8.21113, 11.90613]}, + "faces": { + "north": {"uv": [2, 2, 4, 4], "texture": "#1"}, + "east": {"uv": [0, 2, 2, 4], "texture": "#1"}, + "south": {"uv": [6, 2, 8, 4], "texture": "#1"}, + "west": {"uv": [4, 2, 6, 4], "texture": "#1"}, + "up": {"uv": [4, 2, 2, 0], "texture": "#1"}, + "down": {"uv": [4, 0, 6, 2], "texture": "#1"} + } + }, + { + "name": "Hat Layer", + "from": [4.1, 4.48613, 7.98113], + "to": [11.8, 12.08613, 15.68113], + "rotation": {"angle": 22.5, "axis": "x", "origin": [7.975, 8.21113, 11.90613]}, + "faces": { + "north": {"uv": [10, 2, 12, 4], "texture": "#1"}, + "east": {"uv": [8, 2, 10, 4], "texture": "#1"}, + "south": {"uv": [14, 2, 16, 4], "texture": "#1"}, + "west": {"uv": [12, 2, 14, 4], "texture": "#1"}, + "up": {"uv": [12, 2, 10, 0], "texture": "#1"}, + "down": {"uv": [12, 0, 14, 2], "texture": "#1"} + } + }, + { + "name": "Left Arm", + "from": [3.89, -0.57401, 9.01167], + "to": [5.39, 5.42599, 11.01167], + "rotation": {"angle": -22.5, "axis": "z", "origin": [4.6527, 2.42599, 10.01167]}, + "faces": { + "north": {"uv": [9, 13, 9.75, 16], "texture": "#1"}, + "east": {"uv": [8, 13, 9, 16], "texture": "#1"}, + "south": {"uv": [10.75, 13, 11.5, 16], "texture": "#1"}, + "west": {"uv": [9.75, 13, 10.5, 16], "texture": "#1"}, + "up": {"uv": [9, 12, 9.75, 13], "texture": "#1"}, + "down": {"uv": [9.75, 12, 10.5, 13], "texture": "#1"} + } + }, + { + "name": "Left Arm Layer", + "from": [3.8154, -0.67401, 8.91167], + "to": [5.5154, 5.52599, 11.11167], + "rotation": {"angle": -22.5, "axis": "z", "origin": [4.6527, 2.42599, 10.01167]}, + "faces": { + "north": {"uv": [13, 13, 13.75, 16], "texture": "#1"}, + "east": {"uv": [12, 13, 13, 16], "texture": "#1"}, + "south": {"uv": [14.5, 13, 15.25, 16], "texture": "#1"}, + "west": {"uv": [13.75, 13, 14.5, 16], "texture": "#1"}, + "up": {"uv": [13, 12, 13.75, 13], "texture": "#1"}, + "down": {"uv": [13.75, 12, 14.5, 13], "texture": "#1"} + } + }, + { + "name": "RightArm", + "from": [10.48, -0.65754, 8.979], + "to": [11.98, 5.34246, 10.979], + "rotation": {"angle": 22.5, "axis": "z", "origin": [11.13663, 2.34246, 9.979]}, + "faces": { + "north": {"uv": [11, 5, 11.75, 8], "texture": "#1"}, + "east": {"uv": [10, 5, 11, 8], "texture": "#1"}, + "south": {"uv": [12.75, 5, 13.5, 8], "texture": "#1"}, + "west": {"uv": [11.75, 5, 12.5, 8], "texture": "#1"}, + "up": {"uv": [11, 4, 11.75, 5], "texture": "#1"}, + "down": {"uv": [12.5, 4, 11.75, 5], "texture": "#1"} + } + }, + { + "name": "Right Arm Layer", + "from": [10.36163, -0.75754, 8.879], + "to": [12.06163, 5.44246, 11.079], + "rotation": {"angle": 22.5, "axis": "z", "origin": [11.16163, 2.34246, 9.979]}, + "faces": { + "north": {"uv": [11, 9, 11.75, 12], "texture": "#1"}, + "east": {"uv": [10, 9, 11, 12], "texture": "#1"}, + "south": {"uv": [12.75, 9, 13.5, 12], "texture": "#1"}, + "west": {"uv": [11.75, 9, 12.5, 12], "texture": "#1"}, + "up": {"uv": [11, 8, 11.75, 9], "texture": "#1"}, + "down": {"uv": [12.5, 8, 11.75, 9], "texture": "#1"} + } + }, + { + "name": "Left Leg", + "from": [7.77, -0.23, -0.23], + "to": [10.23, 2.23, 6.23], + "rotation": {"angle": -22.5, "axis": "y", "origin": [8, 0.1, 7]}, + "faces": { + "north": {"uv": [2, 4, 3, 5], "texture": "#1"}, + "east": {"uv": [0, 8, 1, 5], "rotation": 90, "texture": "#1"}, + "south": {"uv": [1, 4, 2, 5], "texture": "#1"}, + "west": {"uv": [2, 5, 3, 8], "rotation": 90, "texture": "#1"}, + "up": {"uv": [2, 8, 1, 5], "texture": "#1"}, + "down": {"uv": [3, 5, 4, 8], "texture": "#1"} + } + }, + { + "name": "Left Leg Layer", + "from": [7.67, -0.33, -0.33], + "to": [10.33, 2.33, 6.33], + "rotation": {"angle": -22.5, "axis": "y", "origin": [8, 0.1, 7]}, + "faces": { + "north": {"uv": [2, 8, 3, 9], "texture": "#1"}, + "east": {"uv": [0, 12, 1, 9], "rotation": 90, "texture": "#1"}, + "south": {"uv": [1, 8, 2, 9], "texture": "#1"}, + "west": {"uv": [2, 9, 3, 12], "rotation": 90, "texture": "#1"}, + "up": {"uv": [2, 12, 1, 9], "texture": "#1"}, + "down": {"uv": [3, 9, 4, 12], "texture": "#1"} + } + }, + { + "name": "Right Leg", + "from": [5.77, -0.23, -0.23], + "to": [8.23, 2.23, 6.23], + "rotation": {"angle": 22.5, "axis": "y", "origin": [8, 0.1, 7]}, + "faces": { + "north": {"uv": [6, 12, 7, 13], "texture": "#1"}, + "east": {"uv": [4, 16, 5, 13], "rotation": 90, "texture": "#1"}, + "south": {"uv": [5, 12, 6, 13], "texture": "#1"}, + "west": {"uv": [6, 13, 7, 16], "rotation": 90, "texture": "#1"}, + "up": {"uv": [6, 16, 5, 13], "texture": "#1"}, + "down": {"uv": [7, 13, 8, 16], "texture": "#1"} + } + }, + { + "name": "Right Leg Layer", + "from": [5.67, -0.33, -0.33], + "to": [8.33, 2.33, 6.33], + "rotation": {"angle": 22.5, "axis": "y", "origin": [8, 0.1, 7]}, + "faces": { + "north": {"uv": [2, 12, 3, 13], "texture": "#1"}, + "east": {"uv": [0, 16, 1, 13], "rotation": 90, "texture": "#1"}, + "south": {"uv": [1, 12, 2, 13], "texture": "#1"}, + "west": {"uv": [2, 13, 3, 16], "rotation": 90, "texture": "#1"}, + "up": {"uv": [2, 16, 1, 13], "texture": "#1"}, + "down": {"uv": [3, 13, 4, 16], "texture": "#1"} + } + }, + { + "name": "Body", + "from": [5.6, -1, 9.6], + "to": [10.4, 5, 12.4], + "rotation": {"angle": 45, "axis": "x", "origin": [7.975, 5.4, 10.925]}, + "faces": { + "north": {"uv": [5, 5, 7, 8], "texture": "#1"}, + "east": {"uv": [4, 5, 5, 8], "texture": "#1"}, + "south": {"uv": [8, 5, 10, 8], "texture": "#1"}, + "west": {"uv": [7, 5, 8, 8], "texture": "#1"}, + "up": {"uv": [5, 5, 7, 4], "texture": "#1"}, + "down": {"uv": [7, 5, 9, 4], "texture": "#1"} + } + }, + { + "name": "Body Layer", + "from": [5.5, -1.1, 9.5], + "to": [10.5, 5.1, 12.5], + "rotation": {"angle": 45, "axis": "x", "origin": [7.975, 5.4, 10.925]}, + "faces": { + "north": {"uv": [5, 9, 7, 12], "texture": "#1"}, + "east": {"uv": [4, 9, 5, 12], "texture": "#1"}, + "south": {"uv": [8, 9, 10, 12], "texture": "#1"}, + "west": {"uv": [7, 9, 8, 12], "texture": "#1"}, + "up": {"uv": [5, 9, 7, 8], "texture": "#1"}, + "down": {"uv": [7, 9, 9, 8], "texture": "#1"} + } + } + ], + "display": { + "thirdperson_righthand": { + "rotation": [60, 0, 0], + "translation": [0.25, 4.25, 1.25], + "scale": [0.7, 0.7, 0.7] + }, + "thirdperson_lefthand": { + "rotation": [60, 0, 0], + "translation": [0.25, 4.25, 1.25], + "scale": [0.7, 0.7, 0.7] + }, + "firstperson_righthand": { + "rotation": [0, 120, 0], + "translation": [0, 3.75, 0], + "scale": [0.5, 0.5, 0.5] + }, + "firstperson_lefthand": { + "rotation": [0, 123, 0], + "translation": [0, 3.75, 0], + "scale": [0.5, 0.5, 0.5] + }, + "ground": { + "translation": [0, 2, 0], + "scale": [0.5, 0.5, 0.5] + }, + "gui": { + "rotation": [15, 150, 0], + "translation": [-0.25, 0.25, 0], + "scale": [0.9, 0.9, 0.9] + }, + "head": { + "translation": [12.75, 1.5, 0] + }, + "fixed": { + "translation": [0, 0, -3.5] + } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/thaumicenergistics/models/block/alkusure86fumo.json b/src/main/resources/assets/thaumicenergistics/models/block/alkusure86fumo.json new file mode 100644 index 0000000..df8df1f --- /dev/null +++ b/src/main/resources/assets/thaumicenergistics/models/block/alkusure86fumo.json @@ -0,0 +1,217 @@ +{ + "format_version": "1.9.0", + "credit": "Made with _leng", + "render_type": "cutout", + "textures": { + "1": "thaumicenergistics:block/alkusure86fumo", + "particle": "thaumicenergistics:block/alkusure86fumo" + }, + "elements": [ + { + "name": "Head", + "from": [4.35, 4.69613, 8.33113], + "to": [11.65, 11.99613, 15.63113], + "rotation": {"angle": 22.5, "axis": "x", "origin": [7.975, 8.42113, 11.90613]}, + "faces": { + "north": {"uv": [2, 2, 4, 4], "texture": "#1"}, + "east": {"uv": [0, 2, 2, 4], "texture": "#1"}, + "south": {"uv": [6, 2, 8, 4], "texture": "#1"}, + "west": {"uv": [4, 2, 6, 4], "texture": "#1"}, + "up": {"uv": [4, 2, 2, 0], "texture": "#1"}, + "down": {"uv": [4, 0, 6, 2], "texture": "#1"} + } + }, + { + "name": "Hat Layer", + "from": [4.1, 4.69613, 7.98113], + "to": [11.8, 12.29613, 15.68113], + "rotation": {"angle": 22.5, "axis": "x", "origin": [7.975, 8.42113, 11.90613]}, + "faces": { + "north": {"uv": [10, 2, 12, 4], "texture": "#1"}, + "east": {"uv": [8, 2, 10, 4], "texture": "#1"}, + "south": {"uv": [14, 2, 16, 4], "texture": "#1"}, + "west": {"uv": [12, 2, 14, 4], "texture": "#1"}, + "up": {"uv": [12, 2, 10, 0], "texture": "#1"}, + "down": {"uv": [12, 0, 14, 2], "texture": "#1"} + } + }, + { + "name": "Left Arm", + "from": [3.89, -0.36401, 9.01167], + "to": [5.39, 5.63599, 11.01167], + "rotation": {"angle": -22.5, "axis": "z", "origin": [4.6527, 2.63599, 10.01167]}, + "faces": { + "north": {"uv": [9, 13, 9.75, 16], "texture": "#1"}, + "east": {"uv": [8, 13, 9, 16], "texture": "#1"}, + "south": {"uv": [10.75, 13, 11.5, 16], "texture": "#1"}, + "west": {"uv": [9.75, 13, 10.5, 16], "texture": "#1"}, + "up": {"uv": [9, 12, 9.75, 13], "texture": "#1"}, + "down": {"uv": [10.5, 12, 9.75, 13], "texture": "#1"} + } + }, + { + "name": "Left Arm Layer", + "from": [3.8154, -0.46401, 8.91167], + "to": [5.5154, 5.73599, 11.11167], + "rotation": {"angle": -22.5, "axis": "z", "origin": [4.6527, 2.63599, 10.01167]}, + "faces": { + "north": {"uv": [13, 13, 13.75, 16], "texture": "#1"}, + "east": {"uv": [12, 13, 13, 16], "texture": "#1"}, + "south": {"uv": [14.5, 13, 15.25, 16], "texture": "#1"}, + "west": {"uv": [13.75, 13, 14.5, 16], "texture": "#1"}, + "up": {"uv": [13, 12, 13.75, 13], "texture": "#1"}, + "down": {"uv": [13.75, 12, 14.5, 13], "texture": "#1"} + } + }, + { + "name": "RightArm", + "from": [10.48, -0.44754, 8.979], + "to": [11.98, 5.55246, 10.979], + "rotation": {"angle": 22.5, "axis": "z", "origin": [11.13663, 2.55246, 9.979]}, + "faces": { + "north": {"uv": [11, 5, 11.75, 8], "texture": "#1"}, + "east": {"uv": [10, 5, 11, 8], "texture": "#1"}, + "south": {"uv": [12.75, 5, 13.5, 8], "texture": "#1"}, + "west": {"uv": [11.75, 5, 12.5, 8], "texture": "#1"}, + "up": {"uv": [11, 4, 11.75, 5], "texture": "#1"}, + "down": {"uv": [12.5, 4, 11.75, 5], "texture": "#1"} + } + }, + { + "name": "Right Arm Layer", + "from": [10.36163, -0.54754, 8.879], + "to": [12.06163, 5.65246, 11.079], + "rotation": {"angle": 22.5, "axis": "z", "origin": [11.16163, 2.55246, 9.979]}, + "faces": { + "north": {"uv": [11, 9, 11.75, 12], "texture": "#1"}, + "east": {"uv": [10, 9, 11, 12], "texture": "#1"}, + "south": {"uv": [12.75, 9, 13.5, 12], "texture": "#1"}, + "west": {"uv": [11.75, 9, 12.5, 12], "texture": "#1"}, + "up": {"uv": [11, 8, 11.75, 9], "texture": "#1"}, + "down": {"uv": [12.5, 8, 11.75, 9], "texture": "#1"} + } + }, + { + "name": "Left Leg", + "from": [7.77, -0.02, -0.23], + "to": [10.23, 2.44, 6.23], + "rotation": {"angle": -22.5, "axis": "y", "origin": [8, 0.31, 7]}, + "faces": { + "north": {"uv": [2, 4, 3, 5], "texture": "#1"}, + "east": {"uv": [0, 8, 1, 5], "rotation": 90, "texture": "#1"}, + "south": {"uv": [1, 4, 2, 5], "texture": "#1"}, + "west": {"uv": [2, 5, 3, 8], "rotation": 90, "texture": "#1"}, + "up": {"uv": [2, 8, 1, 5], "texture": "#1"}, + "down": {"uv": [3, 5, 4, 8], "texture": "#1"} + } + }, + { + "name": "Left Leg Layer", + "from": [7.67, -0.12, -0.33], + "to": [10.33, 2.54, 6.33], + "rotation": {"angle": -22.5, "axis": "y", "origin": [8, 0.31, 7]}, + "faces": { + "north": {"uv": [2, 8, 3, 9], "texture": "#1"}, + "east": {"uv": [0, 12, 1, 9], "rotation": 90, "texture": "#1"}, + "south": {"uv": [1, 8, 2, 9], "texture": "#1"}, + "west": {"uv": [2, 9, 3, 12], "rotation": 90, "texture": "#1"}, + "up": {"uv": [2, 12, 1, 9], "texture": "#1"}, + "down": {"uv": [3, 9, 4, 12], "texture": "#1"} + } + }, + { + "name": "Right Leg", + "from": [5.77, -0.02, -0.23], + "to": [8.23, 2.44, 6.23], + "rotation": {"angle": 22.5, "axis": "y", "origin": [8, 0.31, 7]}, + "faces": { + "north": {"uv": [6, 12, 7, 13], "texture": "#1"}, + "east": {"uv": [4, 16, 5, 13], "rotation": 90, "texture": "#1"}, + "south": {"uv": [5, 12, 6, 13], "texture": "#1"}, + "west": {"uv": [6, 13, 7, 16], "rotation": 90, "texture": "#1"}, + "up": {"uv": [6, 16, 5, 13], "texture": "#1"}, + "down": {"uv": [7, 13, 8, 16], "texture": "#1"} + } + }, + { + "name": "Right Leg Layer", + "from": [5.67, -0.12, -0.33], + "to": [8.33, 2.54, 6.33], + "rotation": {"angle": 22.5, "axis": "y", "origin": [8, 0.31, 7]}, + "faces": { + "north": {"uv": [2, 12, 3, 13], "texture": "#1"}, + "east": {"uv": [0, 16, 1, 13], "rotation": 90, "texture": "#1"}, + "south": {"uv": [1, 12, 2, 13], "texture": "#1"}, + "west": {"uv": [2, 13, 3, 16], "rotation": 90, "texture": "#1"}, + "up": {"uv": [2, 16, 1, 13], "texture": "#1"}, + "down": {"uv": [3, 13, 4, 16], "texture": "#1"} + } + }, + { + "name": "Body", + "from": [5.6, -0.79, 9.6], + "to": [10.4, 5.21, 12.4], + "rotation": {"angle": 45, "axis": "x", "origin": [7.975, 5.61, 10.925]}, + "faces": { + "north": {"uv": [5, 5, 7, 8], "texture": "#1"}, + "east": {"uv": [4, 5, 5, 8], "texture": "#1"}, + "south": {"uv": [8, 5, 10, 8], "texture": "#1"}, + "west": {"uv": [7, 5, 8, 8], "texture": "#1"}, + "up": {"uv": [5, 5, 7, 4], "texture": "#1"}, + "down": {"uv": [7, 5, 9, 4], "texture": "#1"} + } + }, + { + "name": "Body Layer", + "from": [5.5, -0.89, 9.5], + "to": [10.5, 5.31, 12.5], + "rotation": {"angle": 45, "axis": "x", "origin": [7.975, 5.61, 10.925]}, + "faces": { + "north": {"uv": [5, 9, 7, 12], "texture": "#1"}, + "east": {"uv": [4, 9, 5, 12], "texture": "#1"}, + "south": {"uv": [8, 9, 10, 12], "texture": "#1"}, + "west": {"uv": [7, 9, 8, 12], "texture": "#1"}, + "up": {"uv": [5, 9, 7, 8], "texture": "#1"}, + "down": {"uv": [7, 9, 9, 8], "texture": "#1"} + } + } + ], + "display": { + "thirdperson_righthand": { + "rotation": [37.5, 0, 0], + "translation": [0.25, 3, 3], + "scale": [0.5, 0.5, 0.5] + }, + "thirdperson_lefthand": { + "rotation": [42.75, 0, 0], + "translation": [0.25, 2.75, 3.5], + "scale": [0.5, 0.5, 0.5] + }, + "firstperson_righthand": { + "rotation": [0, 120, 0], + "translation": [0, 3.75, 0], + "scale": [0.5, 0.5, 0.5] + }, + "firstperson_lefthand": { + "rotation": [0, 123, 0], + "translation": [0, 3.75, 0], + "scale": [0.5, 0.5, 0.5] + }, + "ground": { + "translation": [0, 2, 0], + "scale": [0.5, 0.5, 0.5] + }, + "gui": { + "rotation": [15, 150, 0], + "translation": [0, 1.75, 0], + "scale": [0.95, 0.95, 0.95] + }, + "head": { + "translation": [12.75, 1.5, 0] + }, + "fixed": { + "rotation": [-21.5, 0, 0], + "translation": [0, 0, -3.5] + } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/thaumicenergistics/models/block/infusion_monitor_book.json b/src/main/resources/assets/thaumicenergistics/models/block/infusion_monitor_book.json new file mode 100644 index 0000000..06f615a --- /dev/null +++ b/src/main/resources/assets/thaumicenergistics/models/block/infusion_monitor_book.json @@ -0,0 +1,127 @@ +{ + "format_version": "1.21.6", + "credit": "Made with Blockbench", + "parent": "block/block", + "render_type": "cutout", + "texture_size": [64, 64], + "textures": { + "particle": "ae2:block/generics/back", + "model": "thaumicenergistics:block/infusion_monitor" + }, + "elements": [ + { + "from": [6.05, 8.99925, 3.0925], + "to": [9.95, 10.44225, 12.9075], + "faces": { + "north": {"uv": [7.5, 8.75, 8.5, 9.25], "texture": "#model"}, + "east": {"uv": [8.5, 6, 11, 6.5], "texture": "#model"}, + "south": {"uv": [7.5, 8.75, 8.5, 9.25], "texture": "#model"}, + "west": {"uv": [8.5, 6, 11, 6.5], "texture": "#model"}, + "up": {"uv": [2.5, 10.5, 1.5, 8], "texture": "#model"}, + "down": {"uv": [3.5, 8, 2.5, 10.5], "texture": "#model"} + } + }, + { + "from": [9.55658, 9.18425, 3.125], + "to": [15.40658, 9.83425, 12.875], + "rotation": {"angle": 22.5, "axis": "z", "origin": [10.20658, 10.08299, 6.375]}, + "faces": { + "north": {"uv": [7.5, 8.5, 9, 8.75], "texture": "#model"}, + "east": {"uv": [7, 6, 7.25, 8.5], "rotation": 270, "texture": "#model"}, + "south": {"uv": [9, 8.5, 7.5, 8.75], "texture": "#model"}, + "west": {"uv": [8.5, 6.5, 11, 6.75], "texture": "#model"}, + "up": {"uv": [8.5, 8.5, 7, 6], "texture": "#model"}, + "down": {"uv": [1.5, 8, 0, 10.5], "texture": "#model"} + } + }, + { + "from": [8.44801, 9.34995, 3.775], + "to": [14.29801, 10.64995, 12.225], + "rotation": {"angle": 22.5, "axis": "z", "origin": [9.09801, 9.34995, 6.3425]}, + "faces": { + "north": {"uv": [8.5, 7.75, 10, 8], "texture": "#model"}, + "east": {"uv": [8.5, 7.75, 10, 8], "texture": "#model"}, + "south": {"uv": [8.5, 7.75, 10, 8], "texture": "#model"}, + "west": {"uv": [8.5, 7, 10.5, 7.25], "texture": "#model"}, + "up": {"uv": [9.5, 2.75, 8, 0.75], "texture": "#model"} + } + }, + { + "from": [7.142, 12.36275, 3.775], + "to": [12.992, 12.36275, 12.225], + "rotation": {"angle": 45, "axis": "z", "origin": [10.067, 12.36275, 8]}, + "faces": { + "up": {"uv": [9.5, 0.75, 8, 2.75], "texture": "#model"}, + "down": {"uv": [9.5, 0.75, 8, 2.75], "texture": "#model"} + } + }, + { + "from": [3.008, 12.36925, 3.775], + "to": [8.858, 12.36925, 12.225], + "rotation": {"angle": -45, "axis": "z", "origin": [5.933, 12.36925, 8]}, + "faces": { + "up": {"uv": [8, 0.75, 9.5, 2.75], "texture": "#model"}, + "down": {"uv": [8, 0.75, 9.5, 2.75], "texture": "#model"} + } + }, + { + "from": [2.04834, 11.09116, 3.775], + "to": [7.89834, 12.39116, 12.225], + "rotation": {"angle": -22.5, "axis": "z", "origin": [2.69834, 11.09116, 6.3425]}, + "faces": { + "north": {"uv": [8.5, 7.75, 10, 8], "texture": "#model"}, + "east": {"uv": [8.5, 7.25, 10.5, 7.5], "texture": "#model"}, + "south": {"uv": [8.5, 7.75, 10, 8], "texture": "#model"}, + "west": {"uv": [8.5, 7.75, 10, 8], "texture": "#model"}, + "up": {"uv": [8, 0.75, 9.5, 2.75], "texture": "#model"} + } + }, + { + "from": [0.54702, 10.09853, 3.125], + "to": [6.39702, 10.74853, 12.875], + "rotation": {"angle": -22.5, "axis": "z", "origin": [3.47202, 10.42353, 8]}, + "faces": { + "north": {"uv": [9, 8.5, 7.5, 8.75], "texture": "#model"}, + "east": {"uv": [8.5, 6.75, 11, 7], "texture": "#model"}, + "south": {"uv": [8.5, 7.5, 10, 7.75], "texture": "#model"}, + "west": {"uv": [7.25, 8.5, 7, 6], "rotation": 270, "texture": "#model"}, + "up": {"uv": [7, 8.5, 8.5, 6], "texture": "#model"}, + "down": {"uv": [0, 8, 1.5, 10.5], "texture": "#model"} + } + } + ], + "display": { + "thirdperson_righthand": { + "rotation": [75, 45, 0], + "translation": [0, 2.5, 0], + "scale": [0.375, 0.375, 0.375] + }, + "thirdperson_lefthand": { + "rotation": [75, 45, 0], + "translation": [0, 2.5, 0], + "scale": [0.375, 0.375, 0.375] + }, + "firstperson_righthand": { + "rotation": [0, 45, 0], + "scale": [0.4, 0.4, 0.4] + }, + "firstperson_lefthand": { + "rotation": [0, -135, 0], + "scale": [0.4, 0.4, 0.4] + }, + "ground": { + "translation": [0, 3, 0], + "scale": [0.25, 0.25, 0.25] + }, + "gui": { + "rotation": [30, -135, 0], + "scale": [0.625, 0.625, 0.625] + }, + "head": { + "translation": [0, 14.25, 0] + }, + "fixed": { + "scale": [0.5, 0.5, 0.5] + } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/thaumicenergistics/models/block/infusion_monitor_off.json b/src/main/resources/assets/thaumicenergistics/models/block/infusion_monitor_off.json new file mode 100644 index 0000000..ccdbf4c --- /dev/null +++ b/src/main/resources/assets/thaumicenergistics/models/block/infusion_monitor_off.json @@ -0,0 +1,246 @@ +{ + "format_version": "1.21.6", + "credit": "Made with Blockbench", + "parent": "block/block", + "render_type": "cutout", + "texture_size": [64, 64], + "textures": { + "particle": "ae2:block/generics/back", + "model": "thaumicenergistics:block/infusion_monitor" + }, + "elements": [ + { + "name": "base1", + "from": [2, 0, 2], + "to": [14, 8, 14], + "faces": { + "north": {"uv": [7, 4, 10, 6], "texture": "#model"}, + "east": {"uv": [7, 4, 10, 6], "texture": "#model"}, + "south": {"uv": [7, 4, 10, 6], "texture": "#model"}, + "west": {"uv": [7, 4, 10, 6], "texture": "#model"}, + "up": {"uv": [7, 7, 4, 4], "texture": "#model"}, + "down": {"uv": [7, 7, 4, 10], "texture": "#model", "cullface": "south"} + } + }, + { + "name": "base2", + "from": [0, 1, 0], + "to": [16, 4, 16], + "faces": { + "north": {"uv": [8, 0, 12, 0.75], "texture": "#model"}, + "east": {"uv": [8, 0, 12, 0.75], "texture": "#model"}, + "south": {"uv": [8, 0, 12, 0.75], "texture": "#model"}, + "west": {"uv": [8, 0, 12, 0.75], "texture": "#model"}, + "up": {"uv": [4, 4, 0, 0], "texture": "#model"}, + "down": {"uv": [4, 4, 0, 8], "texture": "#model"} + } + }, + { + "name": "base_light_side", + "from": [-0.001, 0.999, 6.999], + "to": [0.001, 3.001, 9.001], + "faces": { + "east": {"uv": [8.5, 8, 9, 8.5], "texture": "#model"}, + "west": {"uv": [9, 8.5, 8.5, 8], "texture": "#model"} + } + }, + { + "name": "base_light_side", + "from": [6.999, 0.999, -0.001], + "to": [9.001, 3.001, 0.001], + "faces": { + "north": {"uv": [9, 8.5, 8.5, 8], "texture": "#model"}, + "south": {"uv": [8.5, 8.5, 9, 8], "texture": "#model"} + } + }, + { + "name": "base_light_side", + "from": [15.999, 0.999, 6.999], + "to": [16.001, 3.001, 9.001], + "faces": { + "east": {"uv": [9, 8.5, 8.5, 8], "texture": "#model"}, + "west": {"uv": [8.5, 8.5, 9, 8], "texture": "#model"} + } + }, + { + "name": "base_light_side", + "from": [6.999, 0.999, 15.999], + "to": [9.001, 3.001, 16.001], + "faces": { + "north": {"uv": [8.5, 8.5, 9, 8], "texture": "#model"}, + "south": {"uv": [9, 8.5, 8.5, 8], "texture": "#model"} + } + }, + { + "name": "base_light_bottom", + "from": [0, 1, 0], + "to": [16, 1, 16], + "faces": { + "up": {"uv": [8, 4, 4, 0], "texture": "#model"}, + "down": {"uv": [8, 0, 4, 4], "texture": "#model"} + } + }, + { + "name": "base_side", + "from": [2.31462, 1.37727, 4], + "to": [4.31462, 5.37727, 12], + "rotation": {"angle": -22.5, "axis": "z", "origin": [8, 7.25, 8]}, + "faces": { + "north": {"uv": [7, 8.5, 7.5, 9.5], "texture": "#model"}, + "south": {"uv": [7.5, 8.5, 7, 9.5], "texture": "#model"}, + "west": {"uv": [9.5, 0.75, 11.5, 1.75], "texture": "#model"} + } + }, + { + "name": "base_side", + "from": [11.68538, 1.37727, 4], + "to": [13.68538, 5.37727, 12], + "rotation": {"angle": 22.5, "axis": "z", "origin": [8, 7.25, 8]}, + "faces": { + "north": {"uv": [7.5, 8.5, 7, 9.5], "texture": "#model"}, + "east": {"uv": [11.5, 0.75, 9.5, 1.75], "texture": "#model"}, + "south": {"uv": [7, 8.5, 7.5, 9.5], "texture": "#model"} + } + }, + { + "name": "base_side", + "from": [4, 1.39257, 2.31158], + "to": [12, 5.39257, 4.31158], + "rotation": {"angle": 22.5, "axis": "x", "origin": [8, 7.25, 8]}, + "faces": { + "north": {"uv": [9.5, 0.75, 11.5, 1.75], "texture": "#model"}, + "east": {"uv": [7, 8.5, 7.5, 9.5], "texture": "#model"}, + "west": {"uv": [7.5, 8.5, 7, 9.5], "texture": "#model"} + } + }, + { + "name": "base_side", + "from": [4, 1.37727, 11.68538], + "to": [12, 5.37727, 13.68538], + "rotation": {"angle": -22.5, "axis": "x", "origin": [8, 7.25, 8]}, + "faces": { + "east": {"uv": [7.5, 8.5, 7, 9.5], "texture": "#model"}, + "south": {"uv": [9.5, 0.75, 11.5, 1.75], "texture": "#model"}, + "west": {"uv": [7, 8.5, 7.5, 9.5], "texture": "#model"} + } + }, + { + "from": [3, 8, 3], + "to": [4, 9, 5], + "faces": { + "north": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "east": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "south": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "west": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "up": {"uv": [3.75, 9.25, 3.5, 9], "texture": "#model"} + } + }, + { + "from": [11, 8, 12], + "to": [12, 9, 13], + "faces": { + "north": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "south": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "west": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "up": {"uv": [3.75, 9.25, 3.5, 9], "texture": "#model"} + } + }, + { + "from": [12, 8, 11], + "to": [13, 9, 13], + "faces": { + "north": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "east": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "south": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "west": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "up": {"uv": [3.75, 9.25, 3.5, 9], "texture": "#model"} + } + }, + { + "from": [4, 8, 12], + "to": [5, 9, 13], + "faces": { + "north": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "east": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "south": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "up": {"uv": [3.75, 9.25, 3.5, 9], "texture": "#model"} + } + }, + { + "from": [3, 8, 11], + "to": [4, 9, 13], + "faces": { + "north": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "east": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "south": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "west": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "up": {"uv": [3.75, 9.25, 3.5, 9], "texture": "#model"} + } + }, + { + "from": [4, 8, 3], + "to": [5, 9, 4], + "faces": { + "north": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "east": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "south": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "up": {"uv": [3.75, 9.25, 3.5, 9], "texture": "#model"} + } + }, + { + "from": [12, 8, 3], + "to": [13, 9, 5], + "faces": { + "north": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "east": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "south": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "west": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "up": {"uv": [3.75, 9.25, 3.5, 9], "texture": "#model"} + } + }, + { + "from": [11, 8, 3], + "to": [12, 9, 4], + "faces": { + "north": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "south": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "west": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "up": {"uv": [3.75, 9.25, 3.5, 9], "texture": "#model"} + } + } + ], + "display": { + "thirdperson_righthand": { + "rotation": [75, 45, 0], + "translation": [0, 2.5, 0], + "scale": [0.375, 0.375, 0.375] + }, + "thirdperson_lefthand": { + "rotation": [75, 45, 0], + "translation": [0, 2.5, 0], + "scale": [0.375, 0.375, 0.375] + }, + "firstperson_righthand": { + "rotation": [0, 45, 0], + "scale": [0.4, 0.4, 0.4] + }, + "firstperson_lefthand": { + "rotation": [0, -135, 0], + "scale": [0.4, 0.4, 0.4] + }, + "ground": { + "translation": [0, 3, 0], + "scale": [0.25, 0.25, 0.25] + }, + "gui": { + "rotation": [30, -135, 0], + "scale": [0.625, 0.625, 0.625] + }, + "head": { + "translation": [0, 14.25, 0] + }, + "fixed": { + "scale": [0.5, 0.5, 0.5] + } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/thaumicenergistics/models/block/infusion_monitor_on.json b/src/main/resources/assets/thaumicenergistics/models/block/infusion_monitor_on.json new file mode 100644 index 0000000..34fc271 --- /dev/null +++ b/src/main/resources/assets/thaumicenergistics/models/block/infusion_monitor_on.json @@ -0,0 +1,143 @@ +{ + "format_version": "1.21.6", + "credit": "Made with Blockbench", + "parent": "block/block", + "render_type": "translucent", + "texture_size": [64, 64], + "textures": { + "particle": "ae2:block/generics/back", + "lights": "ae2:block/molecular_assembler_lights" + }, + "elements": [ + { + "name": "cube_outline", + "from": [10.05, 10.54225, 13.0075], + "to": [5.95, 8.89925, 2.9925], + "faces": { + "north": {"uv": [2, 2, 3, 2.97], "rotation": 180, "texture": "#lights"}, + "south": {"uv": [2, 13, 3, 14], "rotation": 180, "texture": "#lights"}, + "up": {"uv": [3, 2.05, 2, 13.95], "rotation": 180, "texture": "#lights"} + } + }, + { + "name": "cube_outline", + "from": [15.50658, 9.93425, 12.975], + "to": [9.45658, 9.08425, 3.025], + "rotation": {"angle": 22.5, "axis": "z", "origin": [10.20658, 10.08299, 6.375]}, + "faces": { + "north": {"uv": [2, 2, 3, 13.95], "rotation": 180, "texture": "#lights"}, + "south": {"uv": [3, 2, 2, 13.95], "rotation": 180, "texture": "#lights"}, + "west": {"uv": [2.05, 14, 3, 2], "rotation": 180, "texture": "#lights"}, + "up": {"uv": [2, 2, 3, 14], "rotation": 180, "texture": "#lights"}, + "down": {"uv": [2, 14, 3, 2], "rotation": 180, "texture": "#lights"} + } + }, + { + "name": "cube_outline", + "from": [6.49702, 10.84853, 12.975], + "to": [0.44702, 9.99853, 3.025], + "rotation": {"angle": -22.5, "axis": "z", "origin": [3.47202, 10.42353, 8]}, + "faces": { + "north": {"uv": [3, 2.05, 2, 14], "rotation": 180, "texture": "#lights"}, + "east": {"uv": [2.05, 2, 3, 14], "rotation": 180, "texture": "#lights"}, + "south": {"uv": [2, 2, 3, 13.95], "rotation": 180, "texture": "#lights"}, + "up": {"uv": [3, 2, 2, 14], "rotation": 180, "texture": "#lights"}, + "down": {"uv": [3, 14, 2, 2], "rotation": 180, "texture": "#lights"} + } + }, + { + "name": "cube_outline", + "from": [14.39801, 10.74995, 12.325], + "to": [8.34801, 9.24995, 3.675], + "rotation": {"angle": 22.5, "axis": "z", "origin": [9.09801, 9.34995, 6.3425]}, + "faces": { + "north": {"uv": [2, 2, 3, 14], "rotation": 180, "texture": "#lights"}, + "east": {"uv": [2, 2.05, 3, 14], "rotation": 180, "texture": "#lights"}, + "south": {"uv": [2, 2, 3, 14], "rotation": 180, "texture": "#lights"}, + "west": {"uv": [2, 2, 3, 14], "rotation": 180, "texture": "#lights"}, + "down": {"uv": [2, 14, 3, 2], "rotation": 180, "texture": "#lights"} + } + }, + { + "name": "cube_outline", + "from": [7.99834, 12.49116, 12.325], + "to": [1.94834, 10.99116, 3.675], + "rotation": {"angle": -22.5, "axis": "z", "origin": [2.69834, 11.09116, 6.3425]}, + "faces": { + "north": {"uv": [2, 2, 14, 3], "rotation": 180, "texture": "#lights"}, + "east": {"uv": [2, 2, 3, 14], "rotation": 180, "texture": "#lights"}, + "south": {"uv": [2, 13, 14, 14], "rotation": 180, "texture": "#lights"}, + "west": {"uv": [2, 2, 3, 13.95], "rotation": 180, "texture": "#lights"}, + "up": {"uv": [2, 2, 3, 14], "rotation": 180, "texture": "#lights"}, + "down": {"uv": [3, 14, 2, 2], "rotation": 180, "texture": "#lights"} + } + }, + { + "name": "cube_outline", + "from": [13.092, 12.46275, 12.325], + "to": [7.042, 12.26275, 3.675], + "rotation": {"angle": 45, "axis": "z", "origin": [10.067, 12.36275, 8]}, + "faces": { + "up": {"uv": [2, 2, 3, 14], "rotation": 180, "texture": "#lights"}, + "down": {"uv": [2, 14, 3, 2], "rotation": 180, "texture": "#lights"} + } + }, + { + "name": "cube_outline", + "from": [8.958, 12.46925, 12.325], + "to": [2.908, 12.26925, 3.675], + "rotation": {"angle": -45, "axis": "z", "origin": [5.933, 12.36925, 8]}, + "faces": { + "up": {"uv": [3, 2, 2, 14], "rotation": 180, "texture": "#lights"}, + "down": {"uv": [3, 14, 2, 2], "rotation": 180, "texture": "#lights"} + } + }, + { + "name": "cube_outline_outline", + "from": [6.4, 7.9, 6.4], + "to": [9.6, 9.1, 9.6], + "faces": { + "north": {"uv": [2.1, 2.1, 2.85, 13.95], "rotation": 180, "texture": "#lights"}, + "east": {"uv": [2.87, 2.03, 2.12, 13.98], "rotation": 180, "texture": "#lights"}, + "south": {"uv": [2, 2.0025, 2.99, 13.9925], "rotation": 180, "texture": "#lights"}, + "west": {"uv": [2.85, 2.1, 2.1, 13.95], "rotation": 180, "texture": "#lights"}, + "up": {"uv": [2, 2, 3, 3], "rotation": 180, "texture": "#lights"}, + "down": {"uv": [2, 2, 3, 3], "rotation": 180, "texture": "#lights"} + } + } + ], + "display": { + "thirdperson_righthand": { + "rotation": [75, 45, 0], + "translation": [0, 2.5, 0], + "scale": [0.375, 0.375, 0.375] + }, + "thirdperson_lefthand": { + "rotation": [75, 45, 0], + "translation": [0, 2.5, 0], + "scale": [0.375, 0.375, 0.375] + }, + "firstperson_righthand": { + "rotation": [0, 45, 0], + "scale": [0.4, 0.4, 0.4] + }, + "firstperson_lefthand": { + "rotation": [0, -135, 0], + "scale": [0.4, 0.4, 0.4] + }, + "ground": { + "translation": [0, 3, 0], + "scale": [0.25, 0.25, 0.25] + }, + "gui": { + "rotation": [30, -135, 0], + "scale": [0.625, 0.625, 0.625] + }, + "head": { + "translation": [0, 14.25, 0] + }, + "fixed": { + "scale": [0.5, 0.5, 0.5] + } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/thaumicenergistics/models/item/alkusure86fumo.json b/src/main/resources/assets/thaumicenergistics/models/item/alkusure86fumo.json new file mode 100644 index 0000000..07574bd --- /dev/null +++ b/src/main/resources/assets/thaumicenergistics/models/item/alkusure86fumo.json @@ -0,0 +1,3 @@ +{ + "parent": "thaumicenergistics:block/alkusure86fumo" +} diff --git a/src/main/resources/assets/thaumicenergistics/models/item/infusion_monitor.json b/src/main/resources/assets/thaumicenergistics/models/item/infusion_monitor.json new file mode 100644 index 0000000..479620f --- /dev/null +++ b/src/main/resources/assets/thaumicenergistics/models/item/infusion_monitor.json @@ -0,0 +1,326 @@ +{ + "format_version": "1.21.6", + "credit": "Made with Blockbench", + "parent": "block/block", + "render_type": "cutout", + "texture_size": [64, 64], + "textures": { + "particle": "ae2:block/generics/back", + "model": "thaumicenergistics:block/infusion_monitor" + }, + "elements": [ + { + "name": "base1", + "from": [2, 0, 2], + "to": [14, 8, 14], + "faces": { + "north": {"uv": [7, 4, 10, 6], "texture": "#model"}, + "east": {"uv": [7, 4, 10, 6], "texture": "#model"}, + "south": {"uv": [7, 4, 10, 6], "texture": "#model"}, + "west": {"uv": [7, 4, 10, 6], "texture": "#model"}, + "up": {"uv": [7, 7, 4, 4], "texture": "#model"}, + "down": {"uv": [7, 7, 4, 10], "texture": "#model", "cullface": "south"} + } + }, + { + "name": "base2", + "from": [0, 1, 0], + "to": [16, 4, 16], + "faces": { + "north": {"uv": [8, 0, 12, 0.75], "texture": "#model"}, + "east": {"uv": [8, 0, 12, 0.75], "texture": "#model"}, + "south": {"uv": [8, 0, 12, 0.75], "texture": "#model"}, + "west": {"uv": [8, 0, 12, 0.75], "texture": "#model"}, + "up": {"uv": [4, 4, 0, 0], "texture": "#model"}, + "down": {"uv": [4, 4, 0, 8], "texture": "#model"} + } + }, + { + "name": "base_light_side", + "from": [-0.001, 0.999, 6.999], + "to": [0.001, 3.001, 9.001], + "faces": { + "east": {"uv": [8.5, 8, 9, 8.5], "texture": "#model"}, + "west": {"uv": [9, 8.5, 8.5, 8], "texture": "#model"} + } + }, + { + "name": "base_light_side", + "from": [6.999, 0.999, -0.001], + "to": [9.001, 3.001, 0.001], + "faces": { + "north": {"uv": [9, 8.5, 8.5, 8], "texture": "#model"}, + "south": {"uv": [8.5, 8.5, 9, 8], "texture": "#model"} + } + }, + { + "name": "base_light_side", + "from": [15.999, 0.999, 6.999], + "to": [16.001, 3.001, 9.001], + "faces": { + "east": {"uv": [9, 8.5, 8.5, 8], "texture": "#model"}, + "west": {"uv": [8.5, 8.5, 9, 8], "texture": "#model"} + } + }, + { + "name": "base_light_side", + "from": [6.999, 0.999, 15.999], + "to": [9.001, 3.001, 16.001], + "faces": { + "north": {"uv": [8.5, 8.5, 9, 8], "texture": "#model"}, + "south": {"uv": [9, 8.5, 8.5, 8], "texture": "#model"} + } + }, + { + "name": "base_light_bottom", + "from": [0, 1, 0], + "to": [16, 1, 16], + "faces": { + "up": {"uv": [8, 4, 4, 0], "texture": "#model"}, + "down": {"uv": [8, 0, 4, 4], "texture": "#model"} + } + }, + { + "name": "base_side", + "from": [2.31462, 1.37727, 4], + "to": [4.31462, 5.37727, 12], + "rotation": {"angle": -22.5, "axis": "z", "origin": [8, 7.25, 8]}, + "faces": { + "north": {"uv": [7, 8.5, 7.5, 9.5], "texture": "#model"}, + "south": {"uv": [7.5, 8.5, 7, 9.5], "texture": "#model"}, + "west": {"uv": [9.5, 0.75, 11.5, 1.75], "texture": "#model"} + } + }, + { + "name": "base_side", + "from": [11.68538, 1.37727, 4], + "to": [13.68538, 5.37727, 12], + "rotation": {"angle": 22.5, "axis": "z", "origin": [8, 7.25, 8]}, + "faces": { + "north": {"uv": [7.5, 8.5, 7, 9.5], "texture": "#model"}, + "east": {"uv": [11.5, 0.75, 9.5, 1.75], "texture": "#model"}, + "south": {"uv": [7, 8.5, 7.5, 9.5], "texture": "#model"} + } + }, + { + "name": "base_side", + "from": [4, 1.39257, 2.31158], + "to": [12, 5.39257, 4.31158], + "rotation": {"angle": 22.5, "axis": "x", "origin": [8, 7.25, 8]}, + "faces": { + "north": {"uv": [9.5, 0.75, 11.5, 1.75], "texture": "#model"}, + "east": {"uv": [7, 8.5, 7.5, 9.5], "texture": "#model"}, + "west": {"uv": [7.5, 8.5, 7, 9.5], "texture": "#model"} + } + }, + { + "name": "base_side", + "from": [4, 1.37727, 11.68538], + "to": [12, 5.37727, 13.68538], + "rotation": {"angle": -22.5, "axis": "x", "origin": [8, 7.25, 8]}, + "faces": { + "east": {"uv": [7.5, 8.5, 7, 9.5], "texture": "#model"}, + "south": {"uv": [9.5, 0.75, 11.5, 1.75], "texture": "#model"}, + "west": {"uv": [7, 8.5, 7.5, 9.5], "texture": "#model"} + } + }, + { + "from": [3, 8, 3], + "to": [4, 9, 5], + "faces": { + "north": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "east": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "south": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "west": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "up": {"uv": [3.75, 9.25, 3.5, 9], "texture": "#model"} + } + }, + { + "from": [11, 8, 12], + "to": [12, 9, 13], + "faces": { + "north": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "south": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "west": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "up": {"uv": [3.75, 9.25, 3.5, 9], "texture": "#model"} + } + }, + { + "from": [12, 8, 11], + "to": [13, 9, 13], + "faces": { + "north": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "east": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "south": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "west": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "up": {"uv": [3.75, 9.25, 3.5, 9], "texture": "#model"} + } + }, + { + "from": [4, 8, 12], + "to": [5, 9, 13], + "faces": { + "north": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "east": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "south": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "up": {"uv": [3.75, 9.25, 3.5, 9], "texture": "#model"} + } + }, + { + "from": [3, 8, 11], + "to": [4, 9, 13], + "faces": { + "north": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "east": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "south": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "west": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "up": {"uv": [3.75, 9.25, 3.5, 9], "texture": "#model"} + } + }, + { + "from": [4, 8, 3], + "to": [5, 9, 4], + "faces": { + "north": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "east": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "south": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "up": {"uv": [3.75, 9.25, 3.5, 9], "texture": "#model"} + } + }, + { + "from": [12, 8, 3], + "to": [13, 9, 5], + "faces": { + "north": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "east": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "south": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "west": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "up": {"uv": [3.75, 9.25, 3.5, 9], "texture": "#model"} + } + }, + { + "from": [11, 8, 3], + "to": [12, 9, 4], + "faces": { + "north": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "south": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "west": {"uv": [3.5, 9, 3.75, 9.25], "texture": "#model"}, + "up": {"uv": [3.75, 9.25, 3.5, 9], "texture": "#model"} + } + }, + { + "from": [6.05, 8.99925, 3.0925], + "to": [9.95, 10.44225, 12.9075], + "faces": { + "north": {"uv": [7.5, 8.75, 8.5, 9.25], "texture": "#model"}, + "east": {"uv": [8.5, 6, 11, 6.5], "texture": "#model"}, + "south": {"uv": [7.5, 8.75, 8.5, 9.25], "texture": "#model"}, + "west": {"uv": [8.5, 6, 11, 6.5], "texture": "#model"}, + "up": {"uv": [2.5, 10.5, 1.5, 8], "texture": "#model"}, + "down": {"uv": [3.5, 8, 2.5, 10.5], "texture": "#model"} + } + }, + { + "from": [9.55658, 9.18425, 3.125], + "to": [15.40658, 9.83425, 12.875], + "rotation": {"angle": 22.5, "axis": "z", "origin": [10.20658, 10.08299, 6.375]}, + "faces": { + "north": {"uv": [7.5, 8.5, 9, 8.75], "texture": "#model"}, + "east": {"uv": [7, 6, 7.25, 8.5], "rotation": 270, "texture": "#model"}, + "south": {"uv": [9, 8.5, 7.5, 8.75], "texture": "#model"}, + "west": {"uv": [8.5, 6.5, 11, 6.75], "texture": "#model"}, + "up": {"uv": [8.5, 8.5, 7, 6], "texture": "#model"}, + "down": {"uv": [1.5, 8, 0, 10.5], "texture": "#model"} + } + }, + { + "from": [8.44801, 9.34995, 3.775], + "to": [14.29801, 10.64995, 12.225], + "rotation": {"angle": 22.5, "axis": "z", "origin": [9.09801, 9.34995, 6.3425]}, + "faces": { + "north": {"uv": [8.5, 7.75, 10, 8], "texture": "#model"}, + "east": {"uv": [8.5, 7.75, 10, 8], "texture": "#model"}, + "south": {"uv": [8.5, 7.75, 10, 8], "texture": "#model"}, + "west": {"uv": [8.5, 7, 10.5, 7.25], "texture": "#model"}, + "up": {"uv": [9.5, 2.75, 8, 0.75], "texture": "#model"} + } + }, + { + "from": [7.142, 12.36275, 3.775], + "to": [12.992, 12.36275, 12.225], + "rotation": {"angle": 45, "axis": "z", "origin": [10.067, 12.36275, 8]}, + "faces": { + "up": {"uv": [9.5, 0.75, 8, 2.75], "texture": "#model"}, + "down": {"uv": [9.5, 0.75, 8, 2.75], "texture": "#model"} + } + }, + { + "from": [3.008, 12.36925, 3.775], + "to": [8.858, 12.36925, 12.225], + "rotation": {"angle": -45, "axis": "z", "origin": [5.933, 12.36925, 8]}, + "faces": { + "up": {"uv": [8, 0.75, 9.5, 2.75], "texture": "#model"}, + "down": {"uv": [8, 0.75, 9.5, 2.75], "texture": "#model"} + } + }, + { + "from": [2.04834, 11.09116, 3.775], + "to": [7.89834, 12.39116, 12.225], + "rotation": {"angle": -22.5, "axis": "z", "origin": [2.69834, 11.09116, 6.3425]}, + "faces": { + "north": {"uv": [8.5, 7.75, 10, 8], "texture": "#model"}, + "east": {"uv": [8.5, 7.25, 10.5, 7.5], "texture": "#model"}, + "south": {"uv": [8.5, 7.75, 10, 8], "texture": "#model"}, + "west": {"uv": [8.5, 7.75, 10, 8], "texture": "#model"}, + "up": {"uv": [8, 0.75, 9.5, 2.75], "texture": "#model"} + } + }, + { + "from": [0.54702, 10.09853, 3.125], + "to": [6.39702, 10.74853, 12.875], + "rotation": {"angle": -22.5, "axis": "z", "origin": [3.47202, 10.42353, 8]}, + "faces": { + "north": {"uv": [9, 8.5, 7.5, 8.75], "texture": "#model"}, + "east": {"uv": [8.5, 6.75, 11, 7], "texture": "#model"}, + "south": {"uv": [8.5, 7.5, 10, 7.75], "texture": "#model"}, + "west": {"uv": [7.25, 8.5, 7, 6], "rotation": 270, "texture": "#model"}, + "up": {"uv": [7, 8.5, 8.5, 6], "texture": "#model"}, + "down": {"uv": [0, 8, 1.5, 10.5], "texture": "#model"} + } + } + ], + "display": { + "thirdperson_righthand": { + "rotation": [75, 45, 0], + "translation": [0, 2.5, 0], + "scale": [0.375, 0.375, 0.375] + }, + "thirdperson_lefthand": { + "rotation": [75, 45, 0], + "translation": [0, 2.5, 0], + "scale": [0.375, 0.375, 0.375] + }, + "firstperson_righthand": { + "rotation": [0, 45, 0], + "scale": [0.4, 0.4, 0.4] + }, + "firstperson_lefthand": { + "rotation": [0, -135, 0], + "scale": [0.4, 0.4, 0.4] + }, + "ground": { + "translation": [0, 3, 0], + "scale": [0.25, 0.25, 0.25] + }, + "gui": { + "rotation": [30, -135, 0], + "scale": [0.625, 0.625, 0.625] + }, + "head": { + "translation": [0, 14.25, 0] + }, + "fixed": { + "scale": [0.5, 0.5, 0.5] + } + } +} \ No newline at end of file diff --git a/src/main/resources/assets/thaumicenergistics/textures/block/alkusure86fumo.png b/src/main/resources/assets/thaumicenergistics/textures/block/alkusure86fumo.png new file mode 100644 index 0000000..d658899 Binary files /dev/null and b/src/main/resources/assets/thaumicenergistics/textures/block/alkusure86fumo.png differ diff --git a/src/main/resources/assets/thaumicenergistics/textures/block/infusion_monitor.png b/src/main/resources/assets/thaumicenergistics/textures/block/infusion_monitor.png new file mode 100644 index 0000000..6e740d7 Binary files /dev/null and b/src/main/resources/assets/thaumicenergistics/textures/block/infusion_monitor.png differ