文档目录
组装机界面
Thermal 组装机界面(MachineCrafterScreen 190 高窗口):9 输入槽行、26×26 产物槽、medium 流体罐、流体进度箭头 (110,22) 与 SetRecipe 确认按钮 (142,52)。
组装机玩家
import {
THERMAL_DEMO_PLAYER_HOTBAR,
THERMAL_DEMO_PLAYER_MAIN,
} from "../thermal-demo-data";
import { ThermalCrafterScreen } from "./index";
/**
* ThermalCrafterScreen 预览用例:4 木板 → 工作台(组装机 crafter)。
*/
export function ThermalCrafterScreenDemo() {
return (
<ThermalCrafterScreen
energy={{ amount: 240000, capacity: 400000 }}
fluid={{ amount: 2700, capacity: 4000, tint: "#3c64c8" }}
input={{ count: 1, icon: "oak-planks", tooltip: "橡木木板" }}
inputs={[
{ count: 1, icon: "oak-planks", tooltip: "橡木木板" },
{ count: 1, icon: "oak-planks", tooltip: "橡木木板" },
{ count: 1, icon: "oak-planks", tooltip: "橡木木板" },
null,
null,
null,
null,
null,
]}
onSlotClick={() => {}}
output={{ count: 1, icon: "crafting-table", tooltip: "工作台" }}
playerHotbar={THERMAL_DEMO_PLAYER_HOTBAR}
playerItems={THERMAL_DEMO_PLAYER_MAIN}
progress={0.3}
/>
);
}
安装
$pnpm add @tennantite/thermalnpm 方式安装编译产物;需要改造源码请用上方的 CLI 拷贝安装。
源码
packages/thermal/src/thermal-crafter-screen/index.tsxnpm 包保留源码目录,可直接复制改造。