-
Notifications
You must be signed in to change notification settings - Fork 2
/
archaeology.lua
64 lines (55 loc) · 2.25 KB
/
archaeology.lua
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
-- LUALOCALS < ---------------------------------------------------------
local minetest, nodecore
= minetest, nodecore
-- LUALOCALS > ---------------------------------------------------------
local modname = minetest.get_current_modname()
--<>----------------------------------------------------------------<>--
local function brush_fossil(node, item, remain)
nodecore.register_craft({
label = "brush fossil",
action = "pummel",
priority = 1,
-- duration = 10,
toolgroups = {brushy = 1}, --crumbly for the time being until i solve 'brushy' issue
indexkeys = {modname .. ":fossil_" ..node},
nodes = {
{match = modname .. ":fossil_" ..node, replace = remain}
},
items = {
{name = item},
}
})
end
local function strata(substrata, eroded)
brush_fossil("amber_" ..substrata.. "_loose", modname.. ":amber", eroded)
brush_fossil("bug_amber_" ..substrata.. "_loose", modname.. ":amber_bug", eroded)
brush_fossil("sponge_" ..substrata.. "_loose", modname.. ":cast_sponge", eroded)
brush_fossil("shell_" ..substrata.. "_loose", modname.. ":cast_shell", eroded)
brush_fossil("tooth_" ..substrata.. "_loose", modname.. ":tooth", eroded)
brush_fossil("scale_" ..substrata.. "_loose", modname.. ":cast_scale", eroded)
if minetest.get_modpath("wc_naturae") then
brush_fossil("leaf_" ..substrata.. "_loose", modname.. ":cast_leaf", eroded)
brush_fossil("fungus_" ..substrata.. "_loose", modname.. ":cast_fungus", eroded)
end
if minetest.get_modpath("ncshark") then
brush_fossil("shark_" ..substrata.. "_loose", modname.. ":cast_shark", eroded)
end
if minetest.get_modpath("wc_crystals") then
brush_fossil("geode_" ..substrata.. "_loose", "wc_crystals:geode", eroded)
end
end
strata("sandy", "nc_terrain:sand")
strata("muddy", "nc_terrain:dirt")
strata("tarry", "nc_terrain:gravel")
strata("limey", "nc_optics:glass_crude")
if minetest.get_modpath("wc_naturae") then
strata("shelly", "wc_naturae:coquina")
end
if minetest.get_modpath("wc_pottery") then
strata("smecy", "wc_pottery:clay")
end
if minetest.get_modpath("wc_coal") then
strata("dusty", "wc_coal:lignite_loose", 1)
strata("bitty", "wc_coal:bituminite_loose", 1)
strata("anthy", "wc_coal:anthracite_loose", 1)
end