Skip to content

Commit d104b9b

Browse files
Vanessa Ezekowitzparamat
Vanessa Ezekowitz
authored andcommittedMay 18, 2017
Chest: Redo new chests to use single-tile textures where possible
This keeps the filenames the same, but adds a new "inside" double texture for the open chest. Use regular drawtype for closed chest and delete the "cube.obj" model. X-flip the right-side texture for the closed chest.
1 parent 758d501 commit d104b9b

8 files changed

+93
-122
lines changed
 

Diff for: ‎mods/default/README.txt

+5-5
Original file line numberDiff line numberDiff line change
@@ -136,10 +136,10 @@ BlockMen (CC BY-SA 3.0):
136136
default_lava_source_animated.png
137137
default_lava_flowing_animated.png
138138
default_stick.png
139-
default_chest_front.png -- Texture kept for mod compability
140-
default_chest_lock.png -- Texture kept for mod compability
141-
default_chest_side.png -- Texture kept for mod compability
142-
default_chest_top.png -- Texture kept for mod compability
139+
default_chest_front.png
140+
default_chest_lock.png
141+
default_chest_side.png
142+
default_chest_top.png
143143
default_mineral_mese.png
144144
default_meselamp.png
145145
bubble.png
@@ -154,7 +154,7 @@ sofar (CC BY-SA 3.0):
154154
default_aspen_tree
155155
default_aspen_tree_top, derived from default_pine_tree_top (by paramat)
156156
default_aspen_wood, derived from default_pine_wood (by paramat)
157-
default_chest_wood, default_chest_wood_locked derived from default_chest_* textures by BlockMen
157+
default_chest_inside
158158

159159
sofar (WTFPL):
160160
default_gravel.png -- Derived from Gambit's PixelBOX texture pack light gravel

Diff for: ‎mods/default/models/chest_open.obj

+67-76
Original file line numberDiff line numberDiff line change
@@ -1,88 +1,79 @@
1-
# Blender v2.78 (sub 0) OBJ File: 'chest_open.blend'
1+
# Blender v2.78 (sub 0) OBJ File: 'chest-open.blend'
22
# www.blender.org
3-
mtllib chest_open.mtl
4-
o Bottom_Cube.001
5-
v -0.500000 -0.500000 0.500000
6-
v -0.500000 0.187500 0.500000
7-
v -0.500000 -0.500000 -0.500000
3+
o Top_Cube.002_None_Top_Cube.002_None_bottom
4+
v -0.500000 0.408471 0.720970
5+
v -0.500000 1.115578 0.013863
6+
v -0.500000 0.894607 -0.207108
7+
v -0.500000 0.187501 0.499999
8+
v 0.500000 1.115578 0.013863
9+
v 0.500000 0.408471 0.720970
10+
v 0.500000 0.187501 0.499999
11+
v 0.500000 0.894607 -0.207108
812
v -0.500000 0.187500 -0.500000
13+
v -0.500000 -0.500000 -0.500000
14+
v -0.500000 -0.500000 0.500000
15+
v 0.500000 0.187500 -0.500000
916
v 0.500000 -0.500000 0.500000
10-
v 0.500000 0.187500 0.500000
1117
v 0.500000 -0.500000 -0.500000
12-
v 0.500000 0.187500 -0.500000
13-
vt 0.7500 0.3438
14-
vt 0.5000 0.3438
15-
vt 0.5000 0.0000
16-
vt 0.7500 0.0000
17-
vt 0.2500 0.3438
18-
vt 0.2500 0.0000
19-
vt 0.0000 0.3438
18+
vt 0.0000 1.0000
19+
vt 0.0000 0.0000
20+
vt 1.0000 0.0000
21+
vt 1.0000 1.0000
22+
vt 1.0000 0.0000
23+
vt 1.0000 1.0000
24+
vt 0.0000 1.0000
2025
vt 0.0000 0.0000
21-
vt 0.7500 0.8438
22-
vt 0.5000 0.8438
23-
vt 0.5000 0.5000
24-
vt 0.7500 0.5000
25-
vt 0.2500 0.5000
26-
vt 0.2500 1.0000
2726
vt 0.0000 1.0000
28-
vt 0.0000 0.5000
29-
vt 0.7500 -0.0000
30-
vt 0.7500 0.5000
31-
vt 1.0000 0.5000
27+
vt 1.0000 1.0000
28+
vt 1.0000 0.6875
29+
vt 0.0000 0.6875
30+
vt 1.0000 1.0000
31+
vt 0.0000 0.6875
32+
vt 1.0000 0.6875
33+
vt 1.0000 0.6875
3234
vt 1.0000 0.0000
33-
vn -1.0000 0.0000 0.0000
34-
vn 0.0000 0.0000 -1.0000
35-
vn 1.0000 0.0000 0.0000
36-
vn 0.0000 0.0000 1.0000
37-
vn 0.0000 -1.0000 0.0000
38-
vn 0.0000 1.0000 0.0000
39-
g Bottom_Cube.001_None
40-
usemtl None
41-
s off
42-
f 2/1/1 4/2/1 3/3/1 1/4/1
43-
f 4/2/2 8/5/2 7/6/2 3/3/2
44-
f 8/5/3 6/7/3 5/8/3 7/6/3
45-
f 6/9/4 2/10/4 1/11/4 5/12/4
46-
f 1/13/5 3/14/5 7/15/5 5/16/5
47-
f 6/17/6 8/18/6 4/19/6 2/20/6
48-
o Top_Cube.002
49-
v -0.500000 0.187501 0.499999
50-
v -0.500000 0.408471 0.720970
51-
v -0.500000 0.894607 -0.207108
52-
v -0.500000 1.115578 0.013863
53-
v 0.500000 0.187501 0.499999
54-
v 0.500000 0.408471 0.720970
55-
v 0.500000 0.894607 -0.207108
56-
v 0.500000 1.115578 0.013863
57-
vt 0.7500 0.5000
58-
vt 0.5000 0.5000
59-
vt 0.5000 0.3438
60-
vt 0.7500 0.3438
61-
vt 0.2500 0.5000
62-
vt 0.2500 0.3438
63-
vt 0.0000 0.5000
64-
vt 0.0000 0.3438
65-
vt 0.7500 1.0000
66-
vt 0.5000 1.0000
67-
vt 0.5000 0.8438
68-
vt 0.7500 0.8438
35+
vt 0.0000 0.0000
36+
vt 1.0000 0.6875
37+
vt 1.0000 0.0000
38+
vt 1.0000 1.0000
39+
vt 1.0000 0.6875
40+
vt 1.0000 0.0000
41+
vt 0.0000 1.0000
42+
vt 0.0000 0.6875
43+
vt 0.0000 0.6875
44+
vt 0.0000 0.0000
6945
vt 1.0000 0.5000
7046
vt 1.0000 1.0000
71-
vt 0.7500 1.0000
72-
vt 0.7500 0.5000
73-
vt 0.2500 1.0000
47+
vt 0.0000 1.0000
48+
vt 0.0000 0.5000
49+
vt 0.0000 0.0000
50+
vt 1.0000 0.0000
51+
vn 0.0000 0.7071 0.7071
52+
vn -0.0000 -1.0000 -0.0000
7453
vn -1.0000 0.0000 0.0000
75-
vn 0.0000 0.7071 -0.7071
76-
vn 1.0000 0.0000 0.0000
54+
vn 1.0000 0.0000 -0.0000
7755
vn 0.0000 -0.7071 0.7071
78-
vn 0.0000 -0.7071 -0.7071
79-
vn 0.0000 0.7071 0.7071
80-
g Top_Cube.002_None
81-
usemtl None
56+
vn 0.0000 0.0000 1.0000
57+
vn -0.0000 0.7071 -0.7071
58+
vn -0.0000 0.0000 -1.0000
59+
vn -0.0000 -0.7071 -0.7071
60+
vn -0.0000 1.0000 -0.0000
61+
g Top_Cube.002_None_Top_Cube.002_None_bottom_Top_Cube.002_None_Top_Cube.002_None_bottom_Top
8262
s off
83-
f 10/21/7 12/22/7 11/23/7 9/24/7
84-
f 12/22/8 16/25/8 15/26/8 11/23/8
85-
f 16/25/9 14/27/9 13/28/9 15/26/9
86-
f 14/29/10 10/30/10 9/31/10 13/32/10
87-
f 9/33/11 11/34/11 15/35/11 13/36/11
88-
f 14/37/12 16/25/12 12/22/12 10/30/12
63+
f 6/1/1 5/2/1 2/3/1 1/4/1
64+
g Top_Cube.002_None_Top_Cube.002_None_bottom_Top_Cube.002_None_Top_Cube.002_None_bottom_Bottom
65+
f 11/5/2 10/6/2 14/7/2 13/8/2
66+
g Top_Cube.002_None_Top_Cube.002_None_bottom_Top_Cube.002_None_Top_Cube.002_None_bottom_Right-Left
67+
f 1/9/3 2/10/3 3/11/3 4/12/3
68+
f 5/13/4 6/1/4 7/14/4 8/15/4
69+
f 4/12/3 9/16/3 10/17/3 11/18/3
70+
f 12/19/4 7/14/4 13/8/4 14/20/4
71+
g Top_Cube.002_None_Top_Cube.002_None_bottom_Top_Cube.002_None_Top_Cube.002_None_bottom_Back
72+
f 6/21/5 1/9/5 4/12/5 7/22/5
73+
f 7/22/6 4/12/6 11/18/6 13/23/6
74+
g Top_Cube.002_None_Top_Cube.002_None_bottom_Top_Cube.002_None_Top_Cube.002_None_bottom_Front
75+
f 2/10/7 5/24/7 8/25/7 3/11/7
76+
f 9/16/8 12/26/8 14/27/8 10/17/8
77+
g Top_Cube.002_None_Top_Cube.002_None_bottom_Top_Cube.002_None_Top_Cube.002_None_bottom_Inside
78+
f 4/28/9 3/29/9 8/30/9 7/31/9
79+
f 7/31/10 12/32/10 9/33/10 4/28/10

Diff for: ‎mods/default/models/cube.obj

-38
This file was deleted.

Diff for: ‎mods/default/nodes.lua

+21-3
Original file line numberDiff line numberDiff line change
@@ -1999,7 +1999,11 @@ function default.register_chest(name, d)
19991999
return false
20002000
end
20012001

2002-
def_closed.mesh = "cube.obj"
2002+
def_closed.mesh = nil
2003+
def_closed.drawtype = nil
2004+
def_closed.tiles[6] = def.tiles[5] -- swap textures around for "normal"
2005+
def_closed.tiles[5] = def.tiles[3] -- drawtype to make them match the mesh
2006+
def_closed.tiles[3] = def.tiles[3].."^[transformFX"
20032007

20042008
minetest.register_node("default:" .. name, def_closed)
20052009
minetest.register_node("default:" .. name .. "_open", def_opened)
@@ -2026,7 +2030,14 @@ end
20262030

20272031
default.register_chest("chest", {
20282032
description = "Chest",
2029-
tiles = { "default_chest_wood.png" },
2033+
tiles = {
2034+
"default_chest_top.png",
2035+
"default_chest_top.png",
2036+
"default_chest_side.png",
2037+
"default_chest_side.png",
2038+
"default_chest_front.png",
2039+
"default_chest_inside.png"
2040+
},
20302041
sounds = default.node_sound_wood_defaults(),
20312042
sound_open = "default_chest_open",
20322043
sound_close = "default_chest_close",
@@ -2035,7 +2046,14 @@ default.register_chest("chest", {
20352046

20362047
default.register_chest("chest_locked", {
20372048
description = "Locked Chest",
2038-
tiles = { "default_chest_wood_locked.png" },
2049+
tiles = {
2050+
"default_chest_top.png",
2051+
"default_chest_top.png",
2052+
"default_chest_side.png",
2053+
"default_chest_side.png",
2054+
"default_chest_lock.png",
2055+
"default_chest_inside.png"
2056+
},
20392057
sounds = default.node_sound_wood_defaults(),
20402058
sound_open = "default_chest_open",
20412059
sound_close = "default_chest_close",

Diff for: ‎mods/default/textures/default_chest_inside.png

102 Bytes

Error rendering embedded code

Invalid image source.

Diff for: ‎mods/default/textures/default_chest_top.png

1 Byte

Error rendering embedded code

Invalid image source.

Diff for: ‎mods/default/textures/default_chest_wood.png

-2.27 KB
Binary file not shown.

Diff for: ‎mods/default/textures/default_chest_wood_locked.png

-2.36 KB
Binary file not shown.

0 commit comments

Comments
 (0)
Please sign in to comment.