我用的 Cubik Studio 软件里有注释:tint index是草方块、刷怪蛋、药水的着色通道
(cubik里的模型及其配置)
尝试1:tintindex设为0,结果游戏中直接不显示那个元素
(瓶子在我手上和快捷栏里,物品栏里是两个不同的药水瓶)
尝试2:下载vanilla3D材质(有3D药水瓶模型),解包分析,没发现什么差别(除了他在cullface信息里注释了作者信息,不过物品模型应该不影响)
我的代码
vanilla3D的代码
尝试1:tintindex设为0,结果游戏中直接不显示那个元素
尝试2:下载vanilla3D材质(有3D药水瓶模型),解包分析,没发现什么差别(除了他在cullface信息里注释了作者信息,不过物品模型应该不影响)
我的代码
vanilla3D的代码
本帖最后由 ⊙v⊙ 于 2018-3-31 11:42 编辑
告诉你...为什么...
你的Box14就是药水那块对吧,
而这块用的是#particle路径的材质,items/potion_overlay
uv的范围是 10.5, 0.5 ~ 14.5, 4.5
那么,potion_overlay这个贴图的10.5, 0.5 ~ 14.5, 4.5的这个位置,是完全透明的
所以以你uv得出的位置,就算不加tintindex,也是透明的呢,没毛病
解决办法
直接修改Box14贴图的uv 成这样 [0.01,0.01,15.99,15.99] ,也是可以的,不过还是建议...
给Box14加张(比如纯白色的)贴图
至于你其他那些可能不是问题的问题...
如果不是方块模型,cullface无意义。至于他的cullface...是乱填的
快捷栏和手上的是同一个模型
告诉你...为什么...
你的Box14就是药水那块对吧,
而这块用的是#particle路径的材质,items/potion_overlay
uv的范围是 10.5, 0.5 ~ 14.5, 4.5
那么,potion_overlay这个贴图的10.5, 0.5 ~ 14.5, 4.5的这个位置,是完全透明的
所以以你uv得出的位置,就算不加tintindex,也是透明的呢,没毛病
解决办法
直接修改Box14贴图的uv 成这样 [0.01,0.01,15.99,15.99] ,也是可以的,不过还是建议...
给Box14加张(比如纯白色的)贴图
至于你其他那些可能不是问题的问题...
如果不是方块模型,cullface无意义。至于他的cullface...是乱填的
快捷栏和手上的是同一个模型
本帖最后由 MC.cdasc 于 2018-4-1 10:11 编辑
问题是我那是半透明的呀?半透明不能用吗?另外改成纯白试过了也不能用。
⊙v⊙ 发表于 2018-4-1 05:29
告诉你...为什么...
你的Box14就是药水那块对吧,
问题是我那是半透明的呀?半透明不能用吗?另外改成纯白试过了也不能用。
本帖最后由 ⊙v⊙ 于 2018-4-1 09:37 编辑
你这么问的话,
要么是你没读懂我在说什么
要么是你不清楚为什么加了tintindex会无显示
要么,根本就不知道你自己在做什么...
emmm...把使用tintindex的element放在elements里的首位
MC.cdasc 发表于 2018-3-31 16:08
问题是我那是半透明的呀?半透明不能用吗?
要么是你没读懂我在说什么
要么是你不清楚为什么加了tintindex会无显示
要么,根本就不知道你自己在做什么...
emmm...把使用tintindex的element放在elements里的首位
本帖最后由 ⊙v⊙ 于 2018-3-31 18:15 编辑
等等 我再看看 感觉有什么不对劲.......除了前面提到的你选取错误之外...
暂时得出的另一个原因是你瓶身的贴图透明度不够
这是我用的例子,穿过玻璃看不到中间的羊毛的话,说明你玻璃的贴图还需再透明一点,也不要太低(低于10%的话就是完全透明了)
复制代码
暂时得出的另一个原因是你瓶身的贴图透明度不够
这是我用的例子,穿过玻璃看不到中间的羊毛的话,说明你玻璃的贴图还需再透明一点,也不要太低(低于10%的话就是完全透明了)
- {
- "textures": {
- "0": "3dres/potion_bottle",
- "1": "blocks/wool_colored_white"
- },
- "elements": [
- {
- "from": [5.5, 2, 5.5],"to": [10.5, 6, 10.5],
- "faces": {
- "north": {"uv": [0, 0, 16, 16],"texture": "#1","tintindex": 0},
- "east": {"uv": [0, 0, 16, 16],"texture": "#1","tintindex": 0},
- "south": {"uv": [0, 0, 16, 16],"texture": "#1","tintindex": 0},
- "west": {"uv": [0, 0, 16, 16],"texture": "#1","tintindex": 0},
- "up": {"uv": [0, 0, 16, 16],"texture": "#1","tintindex": 0},
- "down": {"uv": [0, 0, 16, 16],"texture": "#1","tintindex": 0}
- }
- },
- {
- "from": [4.5, 1, 3.5],"to": [11.5, 8, 4.5],
- "faces": {
- "north": {"uv": [0, 0, 16, 16],"texture": "#0"},
- "east": {"uv": [0, 0, 16, 16],"texture": "#0"},
- "south": {"uv": [0, 0, 16, 16],"texture": "#0"},
- "west": {"uv": [0, 0, 16, 16],"texture": "#0"},
- "up": {"uv": [0, 0, 16, 16],"texture": "#0"},
- "down": {"uv": [0, 0, 16, 16],"texture": "#0"}
- }
- }
- ]
- }
⊙v⊙ 发表于 2018-4-1 10:11
你这么问的话,
要么是你没读懂我在说什么
要么是你不清楚为什么加了tintindex会无显示
这个半透明的东西说不定和element的顺序有关系
- {
- "__comment": "Designed by Blue_Beaker with Cubik Studio - https://cubik.studio",
- "textures": {
- "texture": "3dres/potion_bottle",
- "particle": "items/potion_overlay"
- },
- "elements": [
- {
- "__comment": "Box14",
- "from": [ 4, 1, 4 ],
- "to": [ 12, 7, 12 ],
- "faces": {
- "down": { "uv": [ 10.5, 0.5, 14.5, 4.5 ], "texture": "#particle", "tintindex": 0 },
- "up": { "uv": [ 10.5, 0.5, 14.5, 4.5 ], "texture": "#particle", "tintindex": 0 },
- "north": { "uv": [ 10.5, 0.5, 14.5, 4.5 ], "texture": "#particle", "tintindex": 0 },
- "south": { "uv": [ 10.5, 0.5, 14.5, 4.5 ], "texture": "#particle", "tintindex": 0 },
- "west": { "uv": [ 10.5, 0.5, 14.5, 4.5 ], "texture": "#particle", "tintindex": 0 },
- "east": { "uv": [ 10.5, 0.5, 14.5, 4.5 ], "texture": "#particle", "tintindex": 0 }
- }
- },
- {
- "__comment": "Box1",
- "from": [ 3, 0, 3 ],
- "to": [ 13, 1, 13 ],
- "faces": {
- "down": { "uv": [ 0, 0, 5, 5 ], "texture": "#texture" },
- "up": { "uv": [ 5, 0, 10, 5 ], "texture": "#texture" }
- }
- },
- {
- "__comment": "Box1",
- "from": [ 3, 0, 3 ],
- "to": [ 13, 10, 4 ],
- "faces": {
- "north": { "uv": [ 0, 0, 5, 5 ], "texture": "#texture" },
- "south": { "uv": [ 5, 0, 10, 5 ], "texture": "#texture" }
- }
- },
- {
- "__comment": "Box1",
- "from": [ 3, 0, 12 ],
- "to": [ 13, 10, 13 ],
- "faces": {
- "north": { "uv": [ 5, 0, 10, 5 ], "texture": "#texture" },
- "south": { "uv": [ 0, 0, 5, 5 ], "texture": "#texture" }
- }
- },
- {
- "__comment": "Box1",
- "from": [ 3, 0, 3 ],
- "to": [ 4, 10, 13 ],
- "faces": {
- "west": { "uv": [ 0, 0, 5, 5 ], "texture": "#texture" },
- "east": { "uv": [ 5, 0, 10, 5 ], "texture": "#texture" }
- }
- },
- {
- "__comment": "Box1",
- "from": [ 12, 0, 3 ],
- "to": [ 13, 10, 13 ],
- "faces": {
- "west": { "uv": [ 5, 0, 10, 5 ], "texture": "#texture" },
- "east": { "uv": [ 0, 0, 5, 5 ], "texture": "#texture" }
- }
- },
- {
- "__comment": "Box1",
- "from": [ 3, 9, 3 ],
- "to": [ 13, 10, 13 ],
- "faces": {
- "down": { "uv": [ 10, 5.5, 15, 10.5 ], "texture": "#texture" },
- "up": { "uv": [ 10, 10.5, 15, 15.5 ], "texture": "#texture" }
- }
- },
- {
- "__comment": "Box7",
- "from": [ 6, 9, 6 ],
- "to": [ 7, 13, 10 ],
- "faces": {
- "west": { "uv": [ 6, 6.5, 8, 8.5 ], "texture": "#texture" },
- "east": { "uv": [ 8, 6.5, 10, 8.5 ], "texture": "#texture" }
- }
- },
- {
- "__comment": "Box7",
- "from": [ 9, 9, 6 ],
- "to": [ 10, 13, 10 ],
- "faces": {
- "west": { "uv": [ 8, 6.5, 10, 8.5 ], "texture": "#texture" },
- "east": { "uv": [ 6, 6.5, 8, 8.5 ], "texture": "#texture" }
- }
- },
- {
- "__comment": "Box7",
- "from": [ 6, 9, 6 ],
- "to": [ 10, 13, 7 ],
- "faces": {
- "north": { "uv": [ 6, 6.5, 8, 8.5 ], "texture": "#texture" },
- "south": { "uv": [ 8, 6.5, 10, 8.5 ], "texture": "#texture" }
- }
- },
- {
- "__comment": "Box7",
- "from": [ 6, 9, 9 ],
- "to": [ 10, 13, 10 ],
- "faces": {
- "north": { "uv": [ 8, 6.5, 10, 8.5 ], "texture": "#texture" },
- "south": { "uv": [ 6, 6.5, 8, 8.5 ], "texture": "#texture" }
- }
- },
- {
- "__comment": "Box11",
- "from": [ 5, 12, 5 ],
- "to": [ 11, 13, 11 ],
- "faces": {
- "down": { "uv": [ 6, 10, 9, 13 ], "texture": "#texture" },
- "up": { "uv": [ 6, 10, 9, 13 ], "texture": "#texture" },
- "north": { "uv": [ 6, 9, 9, 9.5 ], "texture": "#texture" },
- "south": { "uv": [ 6, 9, 9, 9.5 ], "texture": "#texture" },
- "west": { "uv": [ 6, 9, 9, 9.5 ], "texture": "#texture" },
- "east": { "uv": [ 6, 9, 9, 9.5 ], "texture": "#texture" }
- }
- },
- {
- "__comment": "Box12",
- "from": [ 6, 13, 6 ],
- "to": [ 10, 13.5, 10 ],
- "faces": {
- "down": { "uv": [ 0, 5.5, 4, 9.5 ], "texture": "#texture" },
- "up": { "uv": [ 0, 5.5, 4, 9.5 ], "texture": "#texture" },
- "north": { "uv": [ 6, 5.5, 10, 6.5 ], "texture": "#texture" },
- "south": { "uv": [ 6, 5.5, 10, 6.5 ], "texture": "#texture" },
- "west": { "uv": [ 6, 5.5, 10, 6.5 ], "texture": "#texture" },
- "east": { "uv": [ 6, 5.5, 10, 6.5 ], "texture": "#texture" }
- }
- },
- {
- "__comment": "Box12",
- "from": [ 7, 10.5, 7 ],
- "to": [ 9, 13.5, 9 ],
- "faces": {
- "down": { "uv": [ 4, 5.5, 6, 7.5 ], "texture": "#texture" },
- "north": { "uv": [ 4, 7.5, 6, 10.5 ], "texture": "#texture" },
- "south": { "uv": [ 4, 7.5, 6, 10.5 ], "texture": "#texture" },
- "west": { "uv": [ 4, 7.5, 6, 10.5 ], "texture": "#texture" },
- "east": { "uv": [ 4, 7.5, 6, 10.5 ], "texture": "#texture" }
- }
- }
- ],
- "display": {
- "thirdperson_righthand": {
- "rotation": [ 75, 45, 0 ],
- "translation": [ 0, 2.5, 0 ],
- "scale": [ 0.375, 0.375, 0.375 ]
- },
- "thirdperson_lefthand": {
- "rotation": [ 75, 45, 0 ],
- "translation": [ 0, 2.5, 0 ],
- "scale": [ 0.375, 0.375, 0.375 ]
- },
- "firstperson_righthand": {
- "rotation": [ 0, 45, 0 ],
- "translation": [ 0, 3, 0 ],
- "scale": [ 0.4, 0.4, 0.4 ]
- },
- "firstperson_lefthand": {
- "rotation": [ 0, 45, 0 ],
- "translation": [ 0, 3, 0 ],
- "scale": [ 0.4, 0.4, 0.4 ]
- },
- "gui": {
- "rotation": [ 30, 225, 0 ],
- "scale": [ 0.625, 0.625, 0.625 ]
- },
- "ground": {
- "translation": [ 0, 2, 0 ],
- "scale": [ 0.5, 0.5, 0.5 ]
- }
- }
- }
这个试试,把Box14拉到了最前,原来还和element的顺序有关...学到了