
一款简单但可自定义的多按钮缩放工具,适用于 Minecraft。
它允许设置最多 3 个按键绑定,并支持自定义缩放倍率以及开启/关闭平滑摄像机效果。
本模组主要旨在用于学习,欢迎使用,但其最大目的是学习和教授 Fabric 模组开发。
Fabric 学习笔记文档
虽然我们自认并非 Fabric 专家,但我们希望分享我们的学习历程,希望能帮助其他人入门 Fabric 模组开发和 Java 编程。
因此,我们目前正在(进行中)编写详细的代码注释。未来,根据反馈,我们可能会制作基于文字或视频的教程。
在此查看代码注释。
使用方法
安装方法
在为正确版本的 Minecraft 安装 Fabric 加载器后,将最新版的 Zoom-o-matic 及其兼容依赖项放入 .minecraft/mods 文件夹中。
依赖项
Fabric Mod Loader(安装以使用)
Fabric API(放入模组文件夹)
owo-lib(放入模组文件夹)
使用模组
默认的“缩放 1”按键绑定为 "c",该键已被占用,因此你需要解绑“保存快捷栏激活器”或将 zoom1 绑定到其他按键,以使模组正常工作。
模组菜单
该模组已注册到 Mod Menu 中,如果你愿意,可以通过该 GUI 调整设置,否则也可以使用命令。
按键绑定
可在 Minecraft 正常按键绑定菜单中的 Zoom-o-Matic 部分找到。
选项 -> 控制 -> 按键绑定
滚动缩放
在缩放时,你可以使用鼠标滚轮向内或向外滚动以进行更多或更少的缩放。
缩放倍率
调整缩放程度,使用命令:
/ZoomO ZoomAmount Zoom_X YY
- X = 缩放按键编号,(1, 2 或 3。)
- YY 是百分比缩放倍率,(1 - 99)
平滑摄像机切换
切换在缩放时是否启用 smooth_camera,这会减缓移动速度。
/ZoomO SmoothCamera Zoom_X YY
- X = 缩放按键编号,(1, 2 或 3。)
- YY true/false
滚动缩放文本显示切换
切换在使用鼠标滚轮时是否在屏幕上以文本形式显示当前百分比缩放倍率。
/ZoomO ActionBarWriting XX
关于本模组与计划
本模组旨在作为一个学习如何为 Minecraft 开发 Fabric 模组的平台。这是我们的第一个模组,所以我们知道它并不完美,但这并不是重点。
目标是优化它,使其变得更好,并通过改进功能来更深入地了解模组开发。
以下是我们希望按优先级进行的改进列表:
- 移除 owo 依赖项 —— 即创建一个独立于世界的数据存储系统。
添加滚动缩放(已完成)
- 添加自定义的、可自定义的平滑算法,
- 添加自定义 GUI
- 添加更多按键绑定(包括通过 GUI 添加更多按键绑定)
- 添加动画
- 添加可自定义的动画
致谢
@Fej1Dev 在整个过程中与我并肩合作,他亲自编写了大量代码,并在我被卡住时提供帮助!
@LogcialGeekBoy 及 Logical Zoom —— 本模组中使用的一些代码(主要是 mixin)来自 Logical Zoom,但更重要的是,他的模组激发了我们制作自己模组的想法。

A simple, but customizable multi-button zoom tool for Minecraft.
It allows for up to 3 keybinds with customizable zoom and on / off smooth camera.
This mod is for learning most of all, feel free to use it, but its biggest purpose is learning and teaching to mod fabric.
Documentation for Learning Fabric
While we are certaintly not experts on fabric, we would like to share our journey and in a hope that it can help others get started with learning fabric modding and Java.
As such, we are currently working (in progress) on a detailed commentary of the code. In the future we may work towards a tutorial either written or video based on feedback.
Find the code commentary here.
Usage
To install
After fabric mod loader has been installed for the correct version place the latest Zoom-o-matic release with compatible dependencies in the .minecraft/mods folder.
Dependencies
Fabric Mod Loader (Install to use)
Fabric API (Place in mod folder)
owo-lib (Place in mod folder)
Using the Mod
The default Zoom 1 Keybind is "c" which is already bound, so you need to unbind "Save Hotbar Activator" or bind zoom1 to another key to make the mod work.
Mod Menu
The mod is registered in mod menu, so you can adjust settings through that GUI if you desire, otherwise you can use commands.
Keybinds
Are found in the Zoom-o-Matic section of the normal minecraft keybind menu.
Options -> Controls -> Keybinds
Scroll Zoom
When zooming you can scroll in or out with your mousewheel to zoom more or less.
Zoom Amount
Adjusts the amount of zooming, with
/ZoomO ZoomAmount Zoom_X YY
- X = Zoom Keybind #, (1, 2, or 3.)
- YY is the % zoom, (1 - 99)
Smooth Camera Toggle
Toggles whether smooth_camera should be active when zooming, which slows down movement.
/ZoomO SmoothCamera Zoom_X YY
- X = Zoom Keybind #, (1, 2, or 3.)
- YY true/false
Scroll Zoom Text Toggle
Toggles whether you have the % zoom displayed in text when using the scroll wheel.
/ZoomO ActionBarWriting XX
About This Mod & Plans
This mod is meant to be a place to learn how to mod fabric mods for minecraft. This our first mod, so we know it's not 100% perfect, but that's not the point.
The goal is to optimize it, make it better, and improve the features in order to help learn more about modding.
Here is a list of improvements we would like to make, in order of want:
- Remove owo dependency - i.e. Create a world-independent data saving system.
Add scrolling zoom (done)
- Add a custom, customizable smoother,
- Add a custom GUI
- Add more keybinds (including more keybinds, via GUI)
- Add animations
- Add customizable animations
Credit
@Fej1Dev has been hand and hand in this entire process, coding large portions himself, and helping me when I get stuck with my portions!
@LogcialGeekBoy & Logical Zoom - Some of the code used in this mod (mainly the mixin) was from Logical Zoom, but more importantly was that his mod inspired us to make our own.
评论 0
登录后参与评分
还没有评论,来抢沙发吧