原版 Minecraft 中的机械变色龙
此数据包为你的 Minecraft 世界添加了机械变色龙。隐藏或狩猎,并通过涂装让自己与装饰融为一体,以避免在回合结束前被发现。
如何游玩?
将数据包添加到你的世界中,并在所有人都就位后点击“开始回合”。
选择角色,当所有人都准备好后,只需点击开始按钮即可开始游戏。
躲藏者
作为躲藏者,你的目标是与环境融为一体,通过涂装自己并尝试在时间限制内不被发现。
- 使用画笔左键点击,从你所看的方块中选择颜色
- 使用画笔右键点击,对自己的身体进行涂装
- 打开设置以进一步自定义颜色和画笔大小
- 右键点击盔甲架以更改姿势
- 右键点击角来挑衅猎人
猎人
作为猎人,你的目标是在时间限制内找到所有躲藏者。
- 使用烈焰棒右键点击,朝你所看的方向射击以发现躲藏者
特性
- 6 种自定义姿势
- 通过左键点击从任意方块拾取颜色
- 通过右键点击进行涂装
- 使用游戏内调色板自定义颜色,包含亮度和饱和度值
- 切换方向性阴影的开启或关闭,以完美融入环境
- 从 4 种画笔大小中选择:像素 | 十字 | 面部 | 立方体
- 所有画笔都会自动围绕体积包裹,以便于涂装
- 响应式游戏内用户界面,便于轻松开始新回合,并预览参与者
- 添加自定义出生点,可以在任何地方游玩
- 攀爬任何表面
- 在涂装模式下双击空格键飞行,以触及身体的每个角落
免责声明
如果你打算在已有的世界中进行游玩,建议使用备份以防万一。该数据包使用自定义物品并会清空你的物品栏,请确保在开始前将所有物品安全存储,以便之后恢复状态。
这是如何制作的?
- 资产预计算管道: Python 资产管道(
tools/)从游戏文件中烘焙方块状态、模型和纹理坐标,将其整合到一个优化的、扁平化的 NBT 注册表中。这些大量数据仅在服务器启动时加载一次。
- 射线投射解析: 对于吸管工具(读取世界内方块模型纹理以采样颜色),我使用了基于
Bookshelf 库的自定义包装器来计算虚拟射线-平面交点。画笔则完全使用本数据包原生计算的数学方法实现。
- 模块化显示绑定: 自定义模型是使用缩放后的
text_display 实体构建的。每个像素共享一个共同的长方体原点,平移、缩放和四元数旋转都被烘焙到静态实体变换中。
- 动态着色: 通过计算移动长方体的世界空间法线向量来近似方向光照,沿六个轴为涂装颜色添加带色调的阴影。(此功能可在画笔设置中开启或关闭)
- 包围体积层次结构 (BVH) & 命中检测: 具备两级射线投射战斗系统。快速的粗略阶段针对全局轴对齐包围盒 (AABB) 检查射线,而精细阶段利用分离轴定理 (SAT) 将射线投影到代表四肢的单个旋转定向包围盒 (OBB) 上。
- 对话框: 使用大量宏函数在游戏运行时重建每个 UI 布局,以实现读取数据储层的响应式控制
花了多长时间?
两周
是谁做的?
是我,Icodak,哇哈哈哈!
Meccha Chameleon in vanilla minecraft
This datapack adds meccha chameleon to your minecraft world. Hide or hunt and paint yourself to blend in with the decor to avoid getting spotted before the end of the round
How to play ?
Add the datapack to your world and tap the "Start round" once everyone is present
Pick a role, once everyone's ready simply hit the start button and you'll be good to go
Hider
As a hider your goal is to blend with the decor, paint yourself and try to not get spotted within the time limit.
- Left click with the brush to select the color from the block you're looking at
- Right click with the brush to paint your body
- Open the settings to further customise your color and brush size
- Right click the armor stand to change your pose
- Right click the horn to taunt the hunters
Hunter
As a hunter your goal is to find every hider within the time limit
- Right click with the blaze rod to shoot where you're looking to spot a hider
Features
- 6 Custom poses
- Pick color from any block with left click
- Paint with right click
- Customize your color with an in game color palette with brightness and saturation values
- Toggle directional shadows ON or OFF to blend perfectly with the decor
- Choose from 4 brush sizes: Pixel | Cross | Face | Cube
- All brushes automatically wrap around the volume for ease of painting
- Responsive in game UI to easily start new rounds with a preview of participants
- Add your custom spawn locations to play anywhere you want
- Climb on any surface
- Fly by double pressing space while in paint mode to reach every corner of your body
Disclaimer
If you intend to play on a pre existing world I suggest that you use a backup just in case. The datapack uses custom items and clears your inventory, make sure you have everything stored safely before starting to recover your state afterwards
How was this made ?
- Asset Pre-Computation Pipeline: A Python asset pipeline (
tools/) bakes blockstates, models, and texture coordinates from the game files into into an optimized, flat NBT registry. This heavy data loads exactly once on server startup.
- Raycast Resolution: For the Eyedropper (reading in-world block model textures to sample colors) I used custom wrappers around the
Bookshelf library to calculate virtual ray-plane intersections. The Paintbrush is done using math only compute native to this pack
- Modular Display Rigging: Custom models are constructed using scaled
text_display entities. Every pixel shares a common cuboid origin, with translation, scale, and quaternion rotations baked into static entity transformations.
- Dynamic Shading: Approximates directional lighting by calculating the world-space normal vectors of moving cuboids, adding a tinted shadow to the painted color across six axes. (This feature can be turned on or off in the brush settings)
- Bounding Volume Hierarchy (BVH) & Hit Detection: Features a two-tiered raycasting combat system. A fast broad phase checks rays against a global axis-aligned bounding box (AABB), while a narrow phase utilizes the Separating Axis Theorem (SAT) to project rays onto individual rotated oriented bounding boxes (OBBs) representing limbs.
- Dialogs Use a heavy amount of macro functions to rebuild at runtime each UI layout to have responsive controls reading data storages
How long did this take ?
Two weeks
Who did this ?
It was I Icodak mwahahaha !
评论 0
登录后参与评分
还没有评论,来抢沙发吧