截图
介绍
Hologram API
A simple API for supporting in-world text rendering on the client side. This mod was created to simplify the creation process of my mods. Feel free to use this mod for your projects if it suits your needs.
List of my mods using this API:
| Modrinth |Curseforge |
| ———— |———— |
|Holo Damage Indicator|Holo Damage Indicator|
|Holo Health Indicator|Holo Health Indicator|
|Holo Items|Holo Items|

For developers
Setup
Download a version of the mod that is suitable for your version.
Add this to dependencies
modApi files("<your file path>")
should be replaced to where your downloaded mod is.
Note: use double “\\`<br>`
instead of \“ in your path to avoid formatting.
Example:
modApi files("C:\\Users\\UserName\\Documents\\hologram_api-fabric-1.0.0 1.21.1.jar")
Example Usage
Component component = Component.literal("Hello World!").withStyle(ChatFormatting.GREEN); //create a minecraft component
Hologram hologram = HologramAPI.create(comp, 0,80,0).lifetime(40).shadow(true).scale(2).renderDistance(20); //creating the hologram
hologram.onUpdate(h -> { //setting the animation (updates 20 times a second)
h.y += 0.05f; //example animation to rise one block up every tick.
});
This creates a hologram with text “Hello World!” at coordinates 0, 80 ,0. It lasts for a total of 40 seconds and has a scale of 2. Additionally, it will only render when the player is within 20 blocks of radius.
常见问题
Hologram API 支持哪些 Minecraft 版本?
Hologram API 支持 Minecraft Java 版 1.20.1–26.3,共 16 个版本,可用的加载器:Fabric / Forge / NeoForge。下载时注意选择和你游戏版本一致的文件。
Hologram API 怎么安装?
先用 PCL2 或 HMCL 启动器安装对应版本的 Fabric / Forge / NeoForge,再把下载的 .jar 文件放进游戏目录的 mods 文件夹,重新启动游戏即可。开启了版本隔离的,mods 文件夹在 versions/版本名 下面。运行环境:仅客户端。
tricube 的其他作品
查看全部 →
Craft Config Lib
A client-side configuration library that supports presets and built-in keybinds.
Better Tab Info
Improves tab list with extra info (TPS & numerical ping), customizable rows and columns, as well as scrolling.
Optimized Fullbright
Fullbright mod that disables the lighting system to improve performance. Now toggleable with a keybind!
Holo Damage Indicator
Adds client-sided, customizable and animated damage indicators when entities take damage/heal.
评论
登录后评论和评分