Aquamarine
用于简化模组中创建大型结构(Multiblock)的库。
本模组有助于创建类似“现代工业化”的大型结构,即包含控制器、内部方块以及用于输入/输出(IO)的接口方块的大型结构。
注意:该项目尚未完工,但已可运行。它旨在作为我其他使用大型结构的模组的底层库,也可供他人使用。
文档已存在,但尚未涵盖所有内容,仍在完善中(WIP)。
功能
大型结构
大型结构由列表组成,包括普通成员和接口标记(hatch flags)。普通成员定义该位置应放置何种方块。接口标记定义哪些类型的接口可以替换该位置。可以提供空标记。
大型结构可以轻松访问其附加的接口,以便在大型结构与接口之间传输物品/流体/能量。
大型结构渲染
逐层渲染大型结构预览。

指示哪些方块可以被接口替换。
如果大型结构中的某个方块可以被玩家手中持有的接口替换,则该方块周围将显示绿色轮廓。

一次性渲染整个大型结构。
不推荐这样做,因为渲染效果怪异,且逐层渲染更易于构建。
使用方法
添加依赖
在 gradle.properties 中添加版本
aquamarine_version = 0.0.1-1.21.3 # 请从下载页面替换为版本 ID
在 build.gradle 中添加仓库
repositories {
maven { url 'https://jitpack.io' }
}
在 build.gradle 中添加依赖
dependencies {
modApi "com.github.KrazyMiner001:Aquamarine:${project.aquamarine_version}"
}
使用
创建一个继承自 MultiblockBlockEntity 并实现相关方法的类。
创建一个继承自 HatchBlockEntity 并实现相关方法的类。
为这两种块实体创建对应的方块。
大型结构。
(更好的解释待补充 todo)
Aquamarine
Multiblock library to allow creation of multiblocks in mods easier.
This mod help create "Modern Industrialization-like" multiblocks, i.e. multiblocks which have a controller, some innert blocks, and hatch blocks for IO.
Note: This project is very unfinished but works. This is intended as a base library for my other mods using multiblock but can be used by others.
Docs exist but not for everything, still WIP.
Features
Multiblocks
Multiblocks are made of lists both simple members and hatch flags. The simple member defines what block goes at that position. The hatch flags define what hatch types can replace that position. Empty flags can be provided.
Multiblocks can easily access their attached hatches to transfer items/fluids/energy between multiblock and hatch.
Multiblock Rendering
Rendering multiblock previews layer by layer.

Indicating which blocks can be replaced by hatches.
If a block in the multiblock can be replaced by a hatch that the player is holding, the block will have a green outline around it.

Rendering entire multiblock at one.
Not recommended as it renders weirdly and layer by layer is easier to build.
How to use
Adding dependancy
Add version to gradle.properties
aquamarine_version = 0.0.1-1.21.3 # replace with version id from download page
Add repository to build.gradle
repositories {
maven { url 'https://jitpack.io' }
}
Add dependency to build.gradle
dependencies {
modApi "com.github.KrazyMiner001:Aquamarine:${project.aquamarine_version}"
}
Using
Create a class which extends MultiblockBlockEntity and implements methods.
Create a class which extends HatchBlockEntity and implements methods.
Create blocks for both block entities.
Multiblock.
(better explanation todo)
评论 0
登录后参与评分
还没有评论,来抢沙发吧