distilling out more dependencies

This commit is contained in:
FaceDeer
2022-08-01 21:38:01 -06:00
parent b6c4dedcfb
commit 57792c07f8
15 changed files with 140 additions and 98 deletions

View File

@ -19,8 +19,11 @@ df_farming.node_names.string = df_dependencies.node_name_string
df_farming.node_names.dirt_moss = "df_farming:dirt_with_cave_moss"
df_farming.node_names.floor_fungus = "df_farming:cobble_with_floor_fungus"
df_farming.bucket_register_liquid = df_dependencies.bucket_register_liquid
-- these are only for initialization
minetest.after(0, function()
df_farming.sounds = nil
df_farming.node_names = nil
df_farming.bucket_register_liquid = nil
end)

View File

@ -1,4 +1,4 @@
name = df_farming
description = Adds farmable underground plants that die in sunlight. Also includes various cooking reactions.
depends = df_dependencies
optional_depends = farming, cottages, bucket, dynamic_liquid, doc, crafting, footprints, oil
optional_depends = farming, cottages, dynamic_liquid, doc, crafting, footprints, oil

View File

@ -138,7 +138,7 @@ end
----------------------------------------------
-- Syrup
if minetest.get_modpath("bucket") then
if df_dependencies.bucket_register_liquid then
minetest.register_node("df_farming:dwarven_syrup_source", {
description = S("Dwarven Syrup Source"),
_doc_items_longdesc = df_farming.doc.sweet_pod_syrup_desc,
@ -236,7 +236,7 @@ if minetest.get_modpath("bucket") then
sounds = df_farming.sounds.syrup,
})
bucket.register_liquid(
df_farming.bucket_register_liquid(
"df_farming:dwarven_syrup_source",
"df_farming:dwarven_syrup_flowing",
"df_farming:dwarven_syrup_bucket",