
Halftimber 是什么?
Halftimber 是一个资源包和数据包,用于制作带有外露木质框架的 半木结构建筑。Halftimber 添加了多种纹理,可用于装饰你的中世纪、早期现代风格以及温馨风格的建筑。

它是如何工作的?
Halftimber 使用物品展示框来显示具有自定义模型数据(custom model data)的原木、去皮原木和菌核。所有类型的原木均受支持,每种都会生成相应颜色的纹理。你也可以使用黑色羊毛来获得黑色纹理。
由于使用的是物品展示框进行显示,你可以旋转纹理以进一步自定义,并以不同方式重叠它们。
纹理范围从单个方块到 3x3 方块不等。请查看画廊中的纹理参考表(也包含在资源包的 .zip 文件中)获取完整列表。纹理的起始位置为左下角,但 diagonal_flipped(对角线翻转) 除外,其起始位置为右下角。
创造模式
对于创造模式建造者来说,只需安装资源包即可。你只需要一条带有适当自定义模型数据的 /give 命令:
/give @p 你选择的方块[custom_model_data={strings:["纹理宽度x高度"]}]
自定义模型数据的格式为 [纹理]_[方块宽度]x[方块高度]。有关所有选项,请参阅画廊中的纹理参考表!
例如,要获得一根对角线梁,横跨三个方块宽、两个方块高,且颜色与橡木原木匹配:
/give @p oak_log[custom_model_data={strings:["diagonal_3x2"]}]
这可以直接放入物品展示框中。你可以通过命令给自己隐形物品展示框,或者在放置后使用 /data merge 使其变为隐形。
/give @p item_frame[entity_data={id:"minecraft:item_frame",Invisible:1b}] 1
/data merge entity @e[type=item_frame,limit=1,sort=nearest] {Invisible:1b}
或者,如果你想要使用木材锯,可以安装数据包。
数据包与生存模式支持
通过安装数据包,生存模式玩家也可以使用该功能,尽管目前的实现略显笨拙。即使在生存世界中,我认为也需要启用命令才能使其正常工作。
安装数据包后,你可以合成木材锯。

右键点击时,木材锯会打开木材菜单。这只是一个带有点击事件的书籍界面,它会将你选择的自定义模型数据添加到最近的物品展示框中持有的物品上,并附带工具提示,说明所选纹理及其尺寸。如果该物品是支持的方块(即原木),你应该立即看到它变成所选的形状。

左键点击时,木材锯会切换三格范围内最近的一个物品展示框的可见性,允许生存模式玩家使用隐形物品展示框进行建造。
如果你犯了错误,只需再次使用木材菜单更改选择即可。被赋予自定义模型数据的原木在放置后会失去该数据。
注意事项和问题
- 桦木原木和去皮苍白橡木原木使用相同的白色,这与任一方块的实际颜色都不完全匹配。这是用于给纹理着色的着色系统的一个限制。
- 诡异菌核和绯红菌核使用相同的紫色。但是,它们的去皮变体分别呈现适当的蓝色和红色。
- 当物品展示框及其显示的物品超出玩家视野时,渲染会停止。因此,当玩家走过或转身导致作为起点的物品展示框离开屏幕时,此模组添加的纹理可能会停止渲染。这在较宽的纹理(如 3 格宽)上更为明显。
- 由于该系统使用物品展示框(实体),如果使用数量非常多,可能会对性能产生影响。我在中端 PC 上游玩时没有注意到任何影响,不过我使用了 Sodium 和 Optimized Block Entities,后者还有允许物品展示框从更远距离渲染的优势。
- 木材菜单存在一个问题:每条命令在执行前都会显示警告消息。未来我应该重新制作它以使用 /trigger 来避免这个问题,但目前看来多一次点击是必要的。
致谢与权限
致谢
感谢 Rasa Novum 制作的 Timber Frames Mod。我实际上没有玩过他们的模组,但看了他们的截图后,这个想法促使我制作了此资源包,尽管这个想法在我脑海中搁置了很长时间。Timber Frames 的截图也启发了 Halftimber 中木质框架的外观。
权限
如果你的建筑使用了此资源包,你可以将其重新打包并在世界存档中或随同世界存档一起分发。资源包和数据包可以包含在整合包(或数据包包?)中,并在服务器上使用的。始终欢迎提及 Splunged(我)并提供指向此处的链接。
请勿将 Halftimber 包含在任何商业产品中或对其进行再分发。例如,请不要将其用于你打算出售的付费建筑,也不要将其用于有盈利模式的服务器。

What is Halftimber?
Halftimber is a resource and data pack for making half-timbered buildings with exposed wooden framing. Halftimber adds a wide variety of textures that can be used for decorating your medieval, early modern and cozy builds.

How does it work?
Halftimber uses item frames to display logs, stripped logs and stems with custom model data. All logs are supported, each one producing textures in an appropriate color. Black wool can also be used to get black textures.
Because item frames are used for the display, textures can be rotated for further customization and to overlap them in different ways.
Textures range from a single block, up to 3x3 blocks. Check the texture reference in the gallery (also included in the resource pack .zip) for the full list. Textures originate from the bottom left, with the exception of diagonal_flipped, which originates from the bottom right.
Creative
For creative builders, only the resource pack is strictly necessary. A /give command with the appropriate custom model data is all you need:
/give @p BLOCK-OF-YOUR-CHOICE[custom_model_data={strings:["TEXTURE_WIDTHxHEIGHT"]}]
Custom model data is formatted as [texture]_[width in blocks]x[height in blocks]. See the texture reference in the gallery for all the options!
For example, to get a diagonal beam, spanning three blocks width and two blocks height, color matched to an oak log:
/give @p oak_log[custom_model_data={strings:["diagonal_3x2"]}]
This can be placed straight into an item frame. You can give yourself invisible item frames via command, or use /data merge to make an item frame invisible after placing it.
/give @p item_frame[entity_data={id:"minecraft:item_frame",Invisible:1b}] 1
/data merge entity @e[type=item_frame,limit=1,sort=nearest] {Invisible:1b}
Alternatively, you can install the data pack if you want access to the timber saw.
Data Pack and Survival Support
Survival is supported via the data pack, though implementation is currently slightly clunky. Even in a survival world I believe commands need to be enabled in order to make this work properly.
With the data pack installed, you can craft the timber saw.

On right click, the timber saw opens up the timber menu. This is simply a written book interface with click events that will add the custom model data of your choice, as well as a tool tip clarifying the chosen texture and its dimensions, to the nearest item held in an item frame. If this item is a supported block (i.e. a log) then you should immediately see it change into the chosen shape.

On left click, the timber saw toggles the visibility of the nearest item frame within three blocks, allowing survival players to build with invisible item frames.
If you make a mistake then you can simply use the timber menu again to change your selection. Logs which have been given custom model data will lose it if placed.
Notes and Issues
- Birch Logs and Stripped Pale Oak Log use the same white color, which isn't actually a perfect match with either block. This is a limitation of the tint system used to color the textures.
- Warped Stem and Crimson Stem use the same purple color. However, the stripped variants are appropriately blue and red.
- Item frames and their displayed item stop rendering once they're out of the player's view. Because of this, the textures added by this mod may stop rendering as the player walks past or if the player turns, and the item frame that serves as their origin leaves the screen. This is more noticeable on larger textures like the ones that are 3 blocks wide.
- Because the system uses item frames, which are entities, there is a potential performance impact if you use a very high amount. I haven't noticed any impact playing on a midrange PC, though I do use Sodium and Optimized Block Entities, which also has the advantage of allowing item frames to render from further away.
- The timber menu suffers from the problem of every command displaying a warning message before it executes. In future I should remake it to use /trigger in order to sidestep this but for the time being I'm afraid an extra click is necessary.
Credits and Permissions
Credits
Credit to the Timber Frames Mod by Rasa Novum. I haven't actually played their mod but looking at the screenshots of theirs nudged me to make this pack, after sitting on the idea for a long time. The screenshots of Timber Frames also inspired the appearance of the wooden frames in Halftimber.
Permissions
You can repackage and redistribute the resource pack in or alongside world saves if your builds use it. The resource pack and data pack can be included in mod packs (or data pack packs?) and used on servers. Credit to Splunged (me) and a link back here are always appreciated.
Please do not include or redistribute Halftimber in anything commercial. E.g. please do not use it for paywalled builds you intend to sell, and please do not use it for servers that are monetized.
评论 0
登录后参与评分
还没有评论,来抢沙发吧