]> git.lizzy.rs Git - dragonfireclient.git/blob - doc/texture_packs.txt
Merge pull request #59 from PrairieAstronomer/readme_irrlicht_change
[dragonfireclient.git] / doc / texture_packs.txt
1 Minetest Texture Pack Reference
2 ===============================
3
4 Texture packs allow you to replace textures provided by a mod with your own
5 textures.
6
7 Texture pack directory structure
8 --------------------------------
9
10     textures
11     |-- Texture Pack
12     |   |-- texture_pack.conf
13     |   |-- screenshot.png
14     |   |-- description.txt
15     |   |-- override.txt
16     |   |-- your_texture_1.png
17     |   |-- your_texture_2.png
18     `-- Another Texture Pack
19
20 ### Texture Pack
21 This is a directory containing the entire contents of a single texture pack.
22 It can be chosen more or less freely and will also become the name of the
23 texture pack. The name must not be “base”.
24
25 ### `texture_pack.conf`
26 A key-value config file with the following keys:
27
28 * `title` - human readable title
29 * `description` - short description, shown in the content tab
30
31 ### `description.txt`
32 **Deprecated**, you should use texture_pack.conf instead.
33
34 A file containing a short description of the texture pack to be shown in the
35 content tab.
36
37 ### `screenshot.png`
38 A preview image showing an in-game screenshot of this texture pack; it will be
39 shown in the texture packs tab. It should have an aspect ratio of 3:2 and a
40 minimum size of 300×200 pixels.
41
42 ### `your_texture_1.png`, `your_texture_2.png`, etc.
43 Any other PNG files will be interpreted as textures. They must have the same
44 names as the textures they are supposed to override. For example, to override
45 the apple texture of Minetest Game, add a PNG file named `default_apple.png`.
46
47 The custom textures do not necceessarily require the same size as their
48 originals, but this might be required for a few particular textures. When
49 unsure, just test your texture pack in-game.
50
51 Texture modifiers
52 -----------------
53
54 See lua_api.txt for texture modifiers
55
56 Special textures
57 ----------------
58
59 These texture names are hardcoded into the engine but can also be overwritten
60 by texture packs. All existing fallback textures can be found in the directory
61 `textures/base/pack`.
62
63 ### Gameplay textures
64
65 * `bubble.png`: the bubble texture when the player is drowning
66                 (default size: 12×12)
67 * `bubble_gone.png`: like `bubble.png`, but denotes lack of breath
68                      (transparent by default, same size as bubble.png)
69
70 * `crack_anylength.png`: node overlay texture when digging
71
72 * `crosshair.png`
73     * the crosshair texture in the center of the screen. The settings
74       `crosshair_color` and `crosshair_alpha` are used to create a cross
75       when no texture is found.
76
77 * `object_crosshair.png`
78     * the crosshair seen when pointing at an object. The settings
79     `crosshair_color` and `crosshair_alpha` are used to create a cross
80     when no texture is found.
81
82 * `halo.png`: used for the node highlighting mesh
83
84 * `heart.png`: used to display the health points of the player
85                (default size: 12×12)
86 * `heart_gone.png`: like `heart.png`, but denotes lack of health points
87                     (transparent by default, same size as heart.png)
88
89 * `minimap_mask_round.png`: round minimap mask, white gets replaced by the map
90 * `minimap_mask_square.png`: mask used for the square minimap
91 * `minimap_overlay_round.png`: overlay texture for the round minimap
92 * `minimap_overlay_square.png`: overlay texture for the square minimap
93 * `object_marker_red.png`: texture for players on the minimap
94 * `player_marker.png`: texture for the own player on the square minimap
95 * `no_texture_airlike.png`: fallback inventory image for airlike nodes
96 * `no_texture.png`: fallback image for unspecified textures
97
98 * `player.png`: front texture of the 2D upright sprite player
99 * `player_back.png`: back texture of the 2D upright sprite player
100
101 * `progress_bar.png`: foreground texture of the loading screen's progress bar
102 * `progress_bar_bg.png`: background texture of the loading screen's progress bar
103
104 * `moon.png`: texture of the moon. Default texture is generated by Minetest
105 * `moon_tonemap.png`: tonemap to be used when `moon.png` was found
106 * `sun.png`: texture of the sun. Default texture is generated by Minetest
107 * `sun_tonemap.png`: tonemap to be used when `sun.png` was found
108 * `sunrisebg.png`: shown sky texture when the sun rises
109
110 * `smoke_puff.png`: texture used when an object died by punching
111
112 * `unknown_item.png`: shown texture when an item definition was not found
113 * `unknown_node.png`: shown texture when a node definition was not found
114 * `unknown_object.png`: shown texture when an entity definition was not found
115
116 * `wieldhand.png`: texture of the wieldhand
117
118 Note: The default textures of `player.png`, `player_back.png` and `wieldhand.png`
119 are placeholders intended to be overwritten by the game.
120
121 ### Mainmenu textures
122
123 * `menu_bg.png`: used as mainmenu background when the clouds are disabled
124 * `menu_header.png`: header texture when no texture pack is selected
125
126 * `no_screenshot.png`
127     * texture when no screenshot was found for a texture pack or mod
128
129 * `server_flags_creative.png`: icon for creative servers
130 * `server_flags_damage.png`: icon for enabled damage on servers
131 * `server_flags_favorite.png`: icon for your favorite servers
132 * `server_flags_pvp.png`: icon for enabled PvP on servers
133
134 ### Android textures
135
136 * `down_arrow.png`
137 * `left_arrow.png`
138 * `right_arrow.png`
139 * `up_arrow.png`
140
141 * `drop_btn.png`
142 * `fast_btn.png`
143 * `fly_btn.png`
144 * `jump_btn.png`
145 * `noclip_btn.png`
146
147 * `camera_btn.png`
148 * `chat_btn.png`
149 * `inventory_btn.png`
150 * `rangeview_btn.png`
151
152 * `debug_btn.png`
153 * `gear_icon.png`
154 * `rare_controls.png`
155
156 Texture Overrides
157 -----------------
158
159 You can override the textures of nodes and items from a
160 texture pack using texture overrides. To do this, create one or
161 more files in a texture pack called override.txt
162
163 Each line in an override.txt file is a rule. It consists of
164
165         itemname target texture
166
167 For example,
168
169         default:dirt_with_grass sides default_stone.png
170
171 or
172
173         default:sword_steel inventory my_steel_sword.png
174
175 You can list multiple targets on one line as a comma-separated list:
176
177         default:tree top,bottom my_special_tree.png
178
179 You can use texture modifiers, as usual:
180
181         default:dirt_with_grass sides default_stone.png^[brighten
182
183 Finally, if a line is empty or starts with '#' it will be considered
184 a comment and not read as a rule. You can use this to better organize
185 your override.txt files.
186
187 Here are targets you can choose from:
188
189 | target        | behavior                                          |
190 |---------------|---------------------------------------------------|
191 | left          | x- face                                           |
192 | right         | x+ face                                           |
193 | front         | z- face                                           |
194 | back          | z+ face                                           |
195 | top           | y+ face                                           |
196 | bottom        | y- face                                           |
197 | sides         | x-, x+, z-, z+ faces                              |
198 | all           | All faces. You can also use '*' instead of 'all'. |
199 | special1      | The first entry in the special_tiles list         |
200 | special2      | The second entry in the special_tiles list        |
201 | special3      | The third entry in the special_tiles list         |
202 | special4      | The fourth entry in the special_tiles list        |
203 | special5      | The fifth entry in the special_tiles list         |
204 | special6      | The sixth entry in the special_tiles list         |
205 | inventory     | The inventory texture                             |
206 | wield         | The texture used when held by the player          |
207
208 Nodes support all targets, but other items only support 'inventory'
209 and 'wield'.
210
211 ### Using the special targets
212
213 The special* targets only apply to specific drawtypes:
214
215 * `flowingliquid`: special1 sets the top texture, special2 sets the side texture
216 * `allfaces_optional`: special1 is used by simple mode, see below
217 * `glasslike_framed`: When containing a liquid, special1 sets the liquid texture
218 * `glasslike_framed_optional`: Same as `glasslike_framed`
219 * `plantlike_rooted`: special1 sets the plant's texture
220
221 Designing leaves textures for the leaves rendering options
222 ----------------------------------------------------------
223
224 Minetest has three modes for rendering leaves nodes if the node has the
225 `allfaces_optional` drawtype.
226
227 ### Fancy
228
229 Uses the texture specified in the `tiles` nodedef field.
230 The texture should have some transparent pixels and be in the RGBA format so
231 that the transparent pixels can have color information.
232 Faces of every leaves node are rendered even if they are inside a solid volume
233 of leaves; this gives a dense appearance.
234
235 ### Opaque
236
237 Uses the texture specified in `tiles` but makes it opaque by converting each
238 transparent pixel into an opaque pixel that uses the color information of that
239 transparent pixel.
240 Due to this the `tiles` texture format must be RGBA not 'indexed alpha' to allow
241 each transparent pixel to have color information.
242
243 The colors of the transparent pixels should be set for a good appearance in
244 `opaque` mode. This can be done by painting the pixels the desired colors then
245 erasing them. Then when saving the texture, use the 'save color information from
246 transparent pixels' option (or equivalent).
247
248 ### Simple
249
250 Uses the texture specified in the `special_tiles` nodedef field if it exists, if
251 not, the `tiles` texture.
252 The `special_tiles` texture should have fewer transparent pixels than the
253 `tiles` texture and be in the 'indexed alpha' format.
254
255 This mode is between the other two in terms of appearance and rendering load.
256 The nodes are rendered using the `glasslike` drawtype, only showing the surface
257 faces for any solid volume of leaves, not the internal faces.
258 Due to this the `tiles` texture might appear lacking in density, so optionally a
259 `special_tiles` texture can be used to provide a texture with fewer transparent
260 pixels for a denser appearance.