TNT: Add on_blast to all nodes with an inventory
[oweals/minetest_game.git] / mods / default / tools.lua
1 -- mods/default/tools.lua
2
3 -- The hand
4 minetest.register_item(":", {
5         type = "none",
6         wield_image = "wieldhand.png",
7         wield_scale = {x=1,y=1,z=2.5},
8         tool_capabilities = {
9                 full_punch_interval = 0.9,
10                 max_drop_level = 0,
11                 groupcaps = {
12                         crumbly = {times={[2]=3.00, [3]=0.70}, uses=0, maxlevel=1},
13                         snappy = {times={[3]=0.40}, uses=0, maxlevel=1},
14                         oddly_breakable_by_hand = {times={[1]=3.50,[2]=2.00,[3]=0.70}, uses=0}
15                 },
16                 damage_groups = {fleshy=1},
17         }
18 })
19
20 --
21 -- Picks
22 --
23
24 minetest.register_tool("default:pick_wood", {
25         description = "Wooden Pickaxe",
26         inventory_image = "default_tool_woodpick.png",
27         tool_capabilities = {
28                 full_punch_interval = 1.2,
29                 max_drop_level=0,
30                 groupcaps={
31                         cracky = {times={[3]=1.60}, uses=10, maxlevel=1},
32                 },
33                 damage_groups = {fleshy=2},
34         },
35 })
36 minetest.register_tool("default:pick_stone", {
37         description = "Stone Pickaxe",
38         inventory_image = "default_tool_stonepick.png",
39         tool_capabilities = {
40                 full_punch_interval = 1.3,
41                 max_drop_level=0,
42                 groupcaps={
43                         cracky = {times={[2]=2.0, [3]=1.00}, uses=20, maxlevel=1},
44                 },
45                 damage_groups = {fleshy=3},
46         },
47 })
48 minetest.register_tool("default:pick_steel", {
49         description = "Steel Pickaxe",
50         inventory_image = "default_tool_steelpick.png",
51         tool_capabilities = {
52                 full_punch_interval = 1.0,
53                 max_drop_level=1,
54                 groupcaps={
55                         cracky = {times={[1]=4.00, [2]=1.60, [3]=0.80}, uses=20, maxlevel=2},
56                 },
57                 damage_groups = {fleshy=4},
58         },
59 })
60 minetest.register_tool("default:pick_bronze", {
61         description = "Bronze Pickaxe",
62         inventory_image = "default_tool_bronzepick.png",
63         tool_capabilities = {
64                 full_punch_interval = 1.0,
65                 max_drop_level=1,
66                 groupcaps={
67                         cracky = {times={[1]=4.00, [2]=1.60, [3]=0.80}, uses=30, maxlevel=2},
68                 },
69                 damage_groups = {fleshy=4},
70         },
71 })
72 minetest.register_tool("default:pick_mese", {
73         description = "Mese Pickaxe",
74         inventory_image = "default_tool_mesepick.png",
75         tool_capabilities = {
76                 full_punch_interval = 0.9,
77                 max_drop_level=3,
78                 groupcaps={
79                         cracky = {times={[1]=2.4, [2]=1.2, [3]=0.60}, uses=20, maxlevel=3},
80                 },
81                 damage_groups = {fleshy=5},
82         },
83 })
84 minetest.register_tool("default:pick_diamond", {
85         description = "Diamond Pickaxe",
86         inventory_image = "default_tool_diamondpick.png",
87         tool_capabilities = {
88                 full_punch_interval = 0.9,
89                 max_drop_level=3,
90                 groupcaps={
91                         cracky = {times={[1]=2.0, [2]=1.0, [3]=0.50}, uses=30, maxlevel=3},
92                 },
93                 damage_groups = {fleshy=5},
94         },
95 })
96
97 --
98 -- Shovels
99 --
100
101 minetest.register_tool("default:shovel_wood", {
102         description = "Wooden Shovel",
103         inventory_image = "default_tool_woodshovel.png",
104         wield_image = "default_tool_woodshovel.png^[transformR90",
105         tool_capabilities = {
106                 full_punch_interval = 1.2,
107                 max_drop_level=0,
108                 groupcaps={
109                         crumbly = {times={[1]=3.00, [2]=1.60, [3]=0.60}, uses=10, maxlevel=1},
110                 },
111                 damage_groups = {fleshy=2},
112         },
113 })
114 minetest.register_tool("default:shovel_stone", {
115         description = "Stone Shovel",
116         inventory_image = "default_tool_stoneshovel.png",
117         wield_image = "default_tool_stoneshovel.png^[transformR90",
118         tool_capabilities = {
119                 full_punch_interval = 1.4,
120                 max_drop_level=0,
121                 groupcaps={
122                         crumbly = {times={[1]=1.80, [2]=1.20, [3]=0.50}, uses=20, maxlevel=1},
123                 },
124                 damage_groups = {fleshy=2},
125         },
126 })
127 minetest.register_tool("default:shovel_steel", {
128         description = "Steel Shovel",
129         inventory_image = "default_tool_steelshovel.png",
130         wield_image = "default_tool_steelshovel.png^[transformR90",
131         tool_capabilities = {
132                 full_punch_interval = 1.1,
133                 max_drop_level=1,
134                 groupcaps={
135                         crumbly = {times={[1]=1.50, [2]=0.90, [3]=0.40}, uses=30, maxlevel=2},
136                 },
137                 damage_groups = {fleshy=3},
138         },
139 })
140 minetest.register_tool("default:shovel_bronze", {
141         description = "Bronze Shovel",
142         inventory_image = "default_tool_bronzeshovel.png",
143         wield_image = "default_tool_bronzeshovel.png^[transformR90",
144         tool_capabilities = {
145                 full_punch_interval = 1.1,
146                 max_drop_level=1,
147                 groupcaps={
148                         crumbly = {times={[1]=1.50, [2]=0.90, [3]=0.40}, uses=40, maxlevel=2},
149                 },
150                 damage_groups = {fleshy=3},
151         },
152 })
153 minetest.register_tool("default:shovel_mese", {
154         description = "Mese Shovel",
155         inventory_image = "default_tool_meseshovel.png",
156         wield_image = "default_tool_meseshovel.png^[transformR90",
157         tool_capabilities = {
158                 full_punch_interval = 1.0,
159                 max_drop_level=3,
160                 groupcaps={
161                         crumbly = {times={[1]=1.20, [2]=0.60, [3]=0.30}, uses=20, maxlevel=3},
162                 },
163                 damage_groups = {fleshy=4},
164         },
165 })
166 minetest.register_tool("default:shovel_diamond", {
167         description = "Diamond Shovel",
168         inventory_image = "default_tool_diamondshovel.png",
169         wield_image = "default_tool_diamondshovel.png^[transformR90",
170         tool_capabilities = {
171                 full_punch_interval = 1.0,
172                 max_drop_level=1,
173                 groupcaps={
174                         crumbly = {times={[1]=1.10, [2]=0.50, [3]=0.30}, uses=30, maxlevel=3},
175                 },
176                 damage_groups = {fleshy=4},
177         },
178 })
179
180 --
181 -- Axes
182 --
183
184 minetest.register_tool("default:axe_wood", {
185         description = "Wooden Axe",
186         inventory_image = "default_tool_woodaxe.png",
187         tool_capabilities = {
188                 full_punch_interval = 1.0,
189                 max_drop_level=0,
190                 groupcaps={
191                         choppy = {times={[2]=3.00, [3]=1.60}, uses=10, maxlevel=1},
192                 },
193                 damage_groups = {fleshy=2},
194         },
195 })
196 minetest.register_tool("default:axe_stone", {
197         description = "Stone Axe",
198         inventory_image = "default_tool_stoneaxe.png",
199         tool_capabilities = {
200                 full_punch_interval = 1.2,
201                 max_drop_level=0,
202                 groupcaps={
203                         choppy={times={[1]=3.00, [2]=2.00, [3]=1.30}, uses=20, maxlevel=1},
204                 },
205                 damage_groups = {fleshy=3},
206         },
207 })
208 minetest.register_tool("default:axe_steel", {
209         description = "Steel Axe",
210         inventory_image = "default_tool_steelaxe.png",
211         tool_capabilities = {
212                 full_punch_interval = 1.0,
213                 max_drop_level=1,
214                 groupcaps={
215                         choppy={times={[1]=2.50, [2]=1.40, [3]=1.00}, uses=20, maxlevel=2},
216                 },
217                 damage_groups = {fleshy=4},
218         },
219 })
220 minetest.register_tool("default:axe_bronze", {
221         description = "Bronze Axe",
222         inventory_image = "default_tool_bronzeaxe.png",
223         tool_capabilities = {
224                 full_punch_interval = 1.0,
225                 max_drop_level=1,
226                 groupcaps={
227                         choppy={times={[1]=2.50, [2]=1.40, [3]=1.00}, uses=30, maxlevel=2},
228                 },
229                 damage_groups = {fleshy=4},
230         },
231 })
232 minetest.register_tool("default:axe_mese", {
233         description = "Mese Axe",
234         inventory_image = "default_tool_meseaxe.png",
235         tool_capabilities = {
236                 full_punch_interval = 0.9,
237                 max_drop_level=1,
238                 groupcaps={
239                         choppy={times={[1]=2.20, [2]=1.00, [3]=0.60}, uses=20, maxlevel=3},
240                 },
241                 damage_groups = {fleshy=6},
242         },
243 })
244 minetest.register_tool("default:axe_diamond", {
245         description = "Diamond Axe",
246         inventory_image = "default_tool_diamondaxe.png",
247         tool_capabilities = {
248                 full_punch_interval = 0.9,
249                 max_drop_level=1,
250                 groupcaps={
251                         choppy={times={[1]=2.10, [2]=0.90, [3]=0.50}, uses=30, maxlevel=2},
252                 },
253                 damage_groups = {fleshy=7},
254         },
255 })
256
257 --
258 -- Swords
259 --
260
261 minetest.register_tool("default:sword_wood", {
262         description = "Wooden Sword",
263         inventory_image = "default_tool_woodsword.png",
264         tool_capabilities = {
265                 full_punch_interval = 1,
266                 max_drop_level=0,
267                 groupcaps={
268                         snappy={times={[2]=1.6, [3]=0.40}, uses=10, maxlevel=1},
269                 },
270                 damage_groups = {fleshy=2},
271         }
272 })
273 minetest.register_tool("default:sword_stone", {
274         description = "Stone Sword",
275         inventory_image = "default_tool_stonesword.png",
276         tool_capabilities = {
277                 full_punch_interval = 1.2,
278                 max_drop_level=0,
279                 groupcaps={
280                         snappy={times={[2]=1.4, [3]=0.40}, uses=20, maxlevel=1},
281                 },
282                 damage_groups = {fleshy=4},
283         }
284 })
285 minetest.register_tool("default:sword_steel", {
286         description = "Steel Sword",
287         inventory_image = "default_tool_steelsword.png",
288         tool_capabilities = {
289                 full_punch_interval = 0.8,
290                 max_drop_level=1,
291                 groupcaps={
292                         snappy={times={[1]=2.5, [2]=1.20, [3]=0.35}, uses=30, maxlevel=2},
293                 },
294                 damage_groups = {fleshy=6},
295         }
296 })
297 minetest.register_tool("default:sword_bronze", {
298         description = "Bronze Sword",
299         inventory_image = "default_tool_bronzesword.png",
300         tool_capabilities = {
301                 full_punch_interval = 0.8,
302                 max_drop_level=1,
303                 groupcaps={
304                         snappy={times={[1]=2.5, [2]=1.20, [3]=0.35}, uses=40, maxlevel=2},
305                 },
306                 damage_groups = {fleshy=6},
307         }
308 })
309 minetest.register_tool("default:sword_mese", {
310         description = "Mese Sword",
311         inventory_image = "default_tool_mesesword.png",
312         tool_capabilities = {
313                 full_punch_interval = 0.7,
314                 max_drop_level=1,
315                 groupcaps={
316                         snappy={times={[1]=2.0, [2]=1.00, [3]=0.35}, uses=30, maxlevel=3},
317                 },
318                 damage_groups = {fleshy=7},
319         }
320 })
321 minetest.register_tool("default:sword_diamond", {
322         description = "Diamond Sword",
323         inventory_image = "default_tool_diamondsword.png",
324         tool_capabilities = {
325                 full_punch_interval = 0.7,
326                 max_drop_level=1,
327                 groupcaps={
328                         snappy={times={[1]=1.90, [2]=0.90, [3]=0.30}, uses=40, maxlevel=3},
329                 },
330                 damage_groups = {fleshy=8},
331         }
332 })