aboutsummaryrefslogtreecommitdiff
path: root/games/devtest/mods/unittests
diff options
context:
space:
mode:
authorJude Melton-Houghton <jwmhjwmh@gmail.com>2022-05-09 18:21:08 -0400
committersfan5 <sfan5@live.de>2022-05-10 22:37:05 +0200
commitd17d7eba14f6a1328a3b58ee086df5ffa56304d6 (patch)
tree08cf739340644a25a409a83ed6fb8a63c5b4dfe5 /games/devtest/mods/unittests
parent4fb4991f5e7e7430831100137288e848d181b7fc (diff)
downloadminetest-d17d7eba14f6a1328a3b58ee086df5ffa56304d6.tar.gz
minetest-d17d7eba14f6a1328a3b58ee086df5ffa56304d6.tar.bz2
minetest-d17d7eba14f6a1328a3b58ee086df5ffa56304d6.zip
Fix cooking and fuel crafts with aliases
Diffstat (limited to 'games/devtest/mods/unittests')
-rw-r--r--games/devtest/mods/unittests/crafting_prepare.lua14
1 files changed, 10 insertions, 4 deletions
diff --git a/games/devtest/mods/unittests/crafting_prepare.lua b/games/devtest/mods/unittests/crafting_prepare.lua
index a09734827..5cf5775e0 100644
--- a/games/devtest/mods/unittests/crafting_prepare.lua
+++ b/games/devtest/mods/unittests/crafting_prepare.lua
@@ -31,25 +31,31 @@ minetest.register_craftitem("unittests:steel_ingot", {
groups = { dummy = 1 },
})
+-- Use aliases in recipes for more complete testing
+
+minetest.register_alias("unittests:steel_ingot_alias", "unittests:steel_ingot")
+minetest.register_alias("unittests:coal_lump_alias", "unittests:coal_lump")
+minetest.register_alias("unittests:iron_lump_alias", "unittests:iron_lump")
+
-- Recipes for tests: Normal crafting, cooking and fuel
minetest.register_craft({
output = 'unittests:torch 4',
recipe = {
- {'unittests:coal_lump'},
+ {'unittests:coal_lump_alias'},
{'unittests:stick'},
}
})
minetest.register_craft({
type = "cooking",
- output = "unittests:steel_ingot",
- recipe = "unittests:iron_lump",
+ output = "unittests:steel_ingot_alias",
+ recipe = "unittests:iron_lump_alias",
})
minetest.register_craft({
type = "fuel",
- recipe = "unittests:coal_lump",
+ recipe = "unittests:coal_lump_alias",
burntime = 40,
})