
Variant Swap 是一款模组,允许你通过按下可自定义按键(默认为 Z 键)并配合滚动鼠标滚轮来切换手中物品的变种。当你滚动时,屏幕顶部还会短暂显示选中物品前后变种的快速预览(持续数秒)。
在创造模式下,你可以遍历该物品所有可用的变种;而在生存模式下,它仅显示你背包中已有的物品。它同时兼容原版和模组物品!
自定义设置
该模组生成的映射文件和配置文件位于你的 Minecraft(或服务器)文件夹下的 /config/Variant Swap/ 目录中。
config.json 中的可用设置:
- OP 等级(默认为 4)——用于
/variant-swap 命令
- 延迟(默认为 50ms)——用于限制滚动频率
在服务器上,建议根据需要调整 OP 等级。可以使用 /variant-swap 命令将延迟(冷却时间)重置为默认值,或将其更改为其他值(单位仍为毫秒)。
面向开发者
如果你的模组添加了物品或方块,并希望将它们组织到特定的自定义类别中,请为每个物品/方块添加 variant_swap 标签。此标签将决定该物品所属的分组。
例如,假设你有一个模组添加了各种家具物品,并希望按木材类型而非将所有椅子归为一类来进行分类。你可以使用 variant_swap:oak 标记所有橡木物品(即 oak 或你想要的任意类别名称),使用 variant_swap:spruce 标记所有云杉物品,依此类推。

Variant Swap is a mod that lets you change the variant of the item you're holding by using a customizable key (Z by default) and scrolling. When you scroll, you'll also see at the top of the screen a quick preview of what's before and after the selected item (for a few seconds).
In Creative mode, you can switch through every available variant of the item, while in Survival mode it only shows items you have in your inventory. It works with both vanilla and modded items!
Customization
The mod's generated mappings and configuration file are located in your Minecraft (or server) folder under /config/Variant Swap/.
Available settings in config.json:
- OP level (4 by default) - for the
/variant-swap command
- Delay (50ms by default) - this is to throttle the scrolling
On servers it is recommended to change the OP level as desired. The /variant-swap command can be used to reset the delay (cooldown) to its default value or to change it to another value (still in ms).
For Developers
If your mod adds items or blocks and you want to organize them into specific custom categories, add a variant_swap tag to each item/block. This tag will determine the group in which the item is categorized.
For example, imagine you have a mod that adds various furniture items, and you want to categorize them by wood type instead of grouping all chairs together. You could tag all oak items with variant_swap:oak (so oak or whatever you wanna call the category), all spruce items with variant_swap:spruce, and so on.
评论 0
登录后参与评分
还没有评论,来抢沙发吧