From c285e6be78cb6ba0884578c40f7cce7cb5ecfa47 Mon Sep 17 00:00:00 2001 From: jhqwqmc <2110242767@qq.com> Date: Fri, 12 Sep 2025 10:37:22 +0800 Subject: [PATCH] =?UTF-8?q?feat(block):=20=E6=B7=BB=E5=8A=A0=E5=8F=B0?= =?UTF-8?q?=E7=81=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../default/configuration/blocks.yml | 110 ++++++++++++++++++ .../default/configuration/categories.yml | 6 +- .../default/configuration/furniture.yml | 51 -------- 3 files changed, 113 insertions(+), 54 deletions(-) diff --git a/common-files/src/main/resources/resources/default/configuration/blocks.yml b/common-files/src/main/resources/resources/default/configuration/blocks.yml index 757d0d468..2384cba31 100644 --- a/common-files/src/main/resources/resources/default/configuration/blocks.yml +++ b/common-files/src/main/resources/resources/default/configuration/blocks.yml @@ -739,6 +739,116 @@ items#misc: facing=west,shape=straight: appearance: facing=west,shape=straight id: 11 + default:table_lamp: + material: nether_brick + custom-model-data: 3011 + data: + item-name: + model: + type: minecraft:model + path: minecraft:item/custom/table_lamp + behavior: + type: block_item + block: + loot: + template: default:loot_table/self + settings: + template: + - default:sound/metal + overrides: + hardness: 1 + resistance: 1 + replaceable: false + is-redstone-conductor: false + is-suffocating: false + behaviors: + - type: toggleable_lamp_block + can-open-with-hand: true + - type: sturdy_base_block + direction: down + support-types: + - full + - center + states: + properties: + lit: + type: boolean + default: false + facing: + type: 4-direction + default: north + appearances: + east_off: + state: barrier + entity-renderer: + item: default:table_lamp + north_off: + state: barrier + entity-renderer: + item: default:table_lamp + yaw: -90 + south_off: + state: barrier + entity-renderer: + item: default:table_lamp + yaw: 90 + west_off: + state: barrier + entity-renderer: + item: default:table_lamp + yaw: 180 + east_on: + state: barrier + entity-renderer: + item: default:table_lamp + north_on: + state: barrier + entity-renderer: + item: default:table_lamp + yaw: -90 + south_on: + state: barrier + entity-renderer: + item: default:table_lamp + yaw: 90 + west_on: + state: barrier + entity-renderer: + item: default:table_lamp + yaw: 180 + variants: + facing=east,lit=false: + appearance: east_off + id: 12 + facing=north,lit=false: + appearance: north_off + id: 13 + facing=south,lit=false: + appearance: south_off + id: 14 + facing=west,lit=false: + appearance: west_off + id: 15 + facing=east,lit=true: + appearance: east_on + id: 16 + settings: + luminance: 15 + facing=north,lit=true: + appearance: north_on + id: 17 + settings: + luminance: 15 + facing=south,lit=true: + appearance: south_on + id: 18 + settings: + luminance: 15 + facing=west,lit=true: + appearance: west_on + id: 19 + settings: + luminance: 15 recipes#misc: default:chinese_lantern: type: shaped diff --git a/common-files/src/main/resources/resources/default/configuration/categories.yml b/common-files/src/main/resources/resources/default/configuration/categories.yml index 989c66a4b..8dc018294 100644 --- a/common-files/src/main/resources/resources/default/configuration/categories.yml +++ b/common-files/src/main/resources/resources/default/configuration/categories.yml @@ -52,10 +52,9 @@ categories: default:furniture: name: <#FFD700> hidden: true - icon: default:table_lamp + icon: default:flower_basket list: - default:bench - - default:table_lamp - default:wooden_chair - default:flower_basket default:misc: @@ -83,4 +82,5 @@ categories: - default:sleeper_sofa - minecraft:air - minecraft:air - - default:sofa \ No newline at end of file + - default:sofa + - default:table_lamp \ No newline at end of file diff --git a/common-files/src/main/resources/resources/default/configuration/furniture.yml b/common-files/src/main/resources/resources/default/configuration/furniture.yml index 23212868d..e54a3ccb0 100644 --- a/common-files/src/main/resources/resources/default/configuration/furniture.yml +++ b/common-files/src/main/resources/resources/default/configuration/furniture.yml @@ -42,57 +42,6 @@ items: template: default:loot_table/furniture arguments: item: default:bench - default:table_lamp: - material: nether_brick - custom-model-data: 2001 - data: - item-name: - model: - type: minecraft:model - path: minecraft:item/custom/table_lamp - behavior: - type: furniture_item - furniture: - settings: - item: default:table_lamp - sounds: - break: minecraft:block.lantern.break - place: minecraft:block.lantern.place - placement: - ground: - loot-spawn-offset: 0,0.2,0 - rules: - rotation: ANY - alignment: QUARTER - elements: - - item: default:table_lamp - display-transform: NONE - billboard: FIXED - translation: 0,0.5,0 - rotation: 90 - hitboxes: - - position: 0,0,0 - type: interaction - blocks-building: true - width: 0.7 - height: 0.1 - interactive: true - - position: 0,0.1,-0.1 - type: interaction - blocks-building: true - width: 0.1 - height: 0.6 - interactive: true - - position: 0,0.6,0.15 - type: interaction - blocks-building: true - width: 0.4 - height: 0.4 - interactive: true - loot: - template: default:loot_table/furniture - arguments: - item: default:table_lamp default:wooden_chair: material: nether_brick custom-model-data: 2002