use i3 compression
This commit is contained in:
parent
0b7e4e45be
commit
5b6ee3c5fa
@ -21,5 +21,5 @@ read_globals = {
|
||||
"vector", "ItemStack", "dump", "DIR_DELIM", "VoxelArea", "Settings", "PcgRandom", "VoxelManip", "PseudoRandom",
|
||||
|
||||
--mod produced
|
||||
"fl_dyes", "fl_hand", "fl_tools", "mobkit", "fl_tnt",
|
||||
"fl_dyes", "fl_hand", "fl_tools", "mobkit", "fl_tnt", "i3",
|
||||
}
|
@ -41,4 +41,8 @@ how to handle mob damage in fl_wildlife
|
||||
crafts
|
||||
------
|
||||
start at fl_plantlife and keep working down
|
||||
furnace needs to get done
|
||||
furnace needs to get done
|
||||
|
||||
compression
|
||||
-----------
|
||||
paintings, plants, saplings, eggs
|
@ -132,4 +132,16 @@ local function craft_hacks(itemstack, player, old_craft_grid, craft_inv)
|
||||
end
|
||||
|
||||
minetest.register_craft_predict(craft_hacks)
|
||||
minetest.register_on_craft(craft_hacks)
|
||||
minetest.register_on_craft(craft_hacks)
|
||||
|
||||
if minetest.get_modpath("i3") then
|
||||
local colors = {}
|
||||
for counter, dye in pairs(fl_dyes.dyes) do
|
||||
if dye[1] ~= "red" then table.insert(colors, dye[1]) end
|
||||
end
|
||||
|
||||
i3.compress("fl_beds:bed_red", {
|
||||
replace = "red",
|
||||
by = colors
|
||||
})
|
||||
end
|
@ -1 +1,2 @@
|
||||
depends = fl_wool
|
||||
depends = fl_wool
|
||||
optional_depends = i3
|
1
mods/fl_bricks/mod.conf
Normal file
1
mods/fl_bricks/mod.conf
Normal file
@ -0,0 +1 @@
|
||||
depends = fl_dyes
|
@ -59,4 +59,16 @@ for counter, dye in pairs(fl_dyes.dyes) do
|
||||
"fl_dyes:" .. dye[1] .. "_dye"
|
||||
},
|
||||
})
|
||||
end
|
||||
|
||||
if minetest.get_modpath("i3") then
|
||||
local colors = {}
|
||||
for _, dye in pairs(fl_dyes.dyes) do
|
||||
if dye[1] ~= "red" then table.insert(colors, dye[1]) end
|
||||
end
|
||||
|
||||
i3.compress("fl_dyes:red_dye", {
|
||||
replace = "red",
|
||||
by = colors
|
||||
})
|
||||
end
|
1
mods/fl_dyes/mod.conf
Normal file
1
mods/fl_dyes/mod.conf
Normal file
@ -0,0 +1 @@
|
||||
optional_depends = i3
|
@ -92,4 +92,21 @@ minetest.register_craft({
|
||||
type = "fuel",
|
||||
recipe = "fl_ores:coal_block",
|
||||
burntime = 370,
|
||||
})
|
||||
})
|
||||
|
||||
if minetest.get_modpath("i3") then
|
||||
local base_material = {"stone", "ors", "tuff", "desert_stone", "savannah"}
|
||||
local ore = {"iron", "copper", "tin", "gold", "diamond", "mithite"}
|
||||
for _, mat in pairs(base_material) do
|
||||
i3.compress("fl_ores:coal_in_" .. mat, {
|
||||
replace = "coal",
|
||||
by = ore
|
||||
})
|
||||
end
|
||||
|
||||
ore[#ore] = nil
|
||||
i3.compress("fl_ores:mithite_block", {
|
||||
replace = "mithite",
|
||||
by = ore
|
||||
})
|
||||
end
|
@ -1 +1,2 @@
|
||||
depends = fl_stone
|
||||
depends = fl_stone
|
||||
optional_depends = i3
|
1
mods/fl_stone/mod.conf
Normal file
1
mods/fl_stone/mod.conf
Normal file
@ -0,0 +1 @@
|
||||
optional_depends = i3
|
@ -62,7 +62,20 @@ local function create_sand_types(name, rgroups, sgroups, blgroups, brgroups)
|
||||
minetest.register_alias("fl_topsoil:" .. name, "fl_stone:" .. name)
|
||||
end
|
||||
|
||||
create_sand_types("sand")
|
||||
create_sand_types("silver_sand")
|
||||
create_sand_types("desert_sand")
|
||||
local sand_types = {"sand", "silver_sand", "desert_sand"}
|
||||
|
||||
for _, type in pairs(sand_types) do
|
||||
create_sand_types(type)
|
||||
end
|
||||
|
||||
if minetest.get_modpath("i3") then
|
||||
local types = {"", "stone", "stone_block", "stone_brick"}
|
||||
sand_types[#sand_types] = nil
|
||||
for _, type in pairs(types) do
|
||||
i3.compress("fl_stone:desert_sand" .. type, {
|
||||
replace = "desert_sand",
|
||||
by = sand_types
|
||||
})
|
||||
end
|
||||
end
|
||||
|
||||
|
@ -73,13 +73,21 @@ local function create_stone_types(name, rgroups, sgroups, blgroups, brgroups)
|
||||
minetest.register_alias("fl_terrain:" .. name .. "_brick", "fl_stone:" .. name .. "_brick")
|
||||
end
|
||||
|
||||
create_stone_types("stone")
|
||||
create_stone_types("mossy_stone")
|
||||
create_stone_types("savannah")
|
||||
create_stone_types("ors")
|
||||
create_stone_types("tuff")
|
||||
create_stone_types("basalt")
|
||||
create_stone_types("gneiss")
|
||||
create_stone_types("desert_stone")
|
||||
local stone_types = {"stone", "mossy_stone", "savannah", "ors", "tuff", "basalt", "gneiss", "desert_stone"}
|
||||
|
||||
--granite, brown granite,
|
||||
for _, type in pairs(stone_types) do
|
||||
create_stone_types(type)
|
||||
end
|
||||
|
||||
--granite, brown granite,
|
||||
|
||||
if minetest.get_modpath("i3") then
|
||||
local types = {"", "_rubble", "_block", "_brick"}
|
||||
stone_types[#stone_types] = nil
|
||||
for _, type in pairs(types) do
|
||||
i3.compress("fl_stone:desert_stone" .. type, {
|
||||
replace = "desert_stone",
|
||||
by = stone_types
|
||||
})
|
||||
end
|
||||
end
|
@ -238,11 +238,19 @@ local function shelf_nodes(name)
|
||||
end
|
||||
end
|
||||
|
||||
shelf_nodes("acacia")
|
||||
shelf_nodes("apple")
|
||||
shelf_nodes("aspen")
|
||||
shelf_nodes("pine")
|
||||
shelf_nodes("spruce")
|
||||
shelf_nodes("yellow_ipe")
|
||||
shelf_nodes("willow")
|
||||
shelf_nodes("baobab")
|
||||
local wood_types = {"acacia", "aspen", "pine", "spruce", "yellow_ipe", "willow", "baobab", "apple"}
|
||||
local shelf_types = {"book", "empty", "multi", "vessel"}
|
||||
|
||||
for _, wood in pairs(wood_types) do
|
||||
shelf_nodes(wood)
|
||||
end
|
||||
|
||||
if minetest.get_modpath("i3") then
|
||||
wood_types[#wood_types] = nil
|
||||
for _, shelf in pairs(shelf_types) do
|
||||
i3.compress("fl_storage:apple_" .. shelf .. "_shelf", {
|
||||
replace = "apple",
|
||||
by = wood_types
|
||||
})
|
||||
end
|
||||
end
|
@ -1 +1,2 @@
|
||||
depends = fl_trees
|
||||
depends = fl_trees
|
||||
optional_depends = i3
|
@ -1 +1,2 @@
|
||||
depends = fl_workshop
|
||||
depends = fl_workshop
|
||||
optional_depends = i3
|
@ -214,4 +214,13 @@ make_anvil_crafts("bronze")
|
||||
make_anvil_crafts("gold")
|
||||
make_anvil_crafts("steel")
|
||||
make_anvil_crafts("stone")
|
||||
make_anvil_crafts("wood")
|
||||
make_anvil_crafts("wood")
|
||||
|
||||
if minetest.get_modpath("i3") then
|
||||
for _, type in pairs(types) do
|
||||
i3.compress("fl_tools:diamond" .. type, {
|
||||
replace = "diamond",
|
||||
by = {"wood", "stone", "steel", "gold", "bronze"}
|
||||
})
|
||||
end
|
||||
end
|
1
mods/fl_trees/mod.conf
Normal file
1
mods/fl_trees/mod.conf
Normal file
@ -0,0 +1 @@
|
||||
optional_depends = i3
|
@ -70,21 +70,27 @@ local function tree_nodes(name, tgroup, lgroup, pgroup)
|
||||
})
|
||||
end
|
||||
|
||||
tree_nodes("acacia")
|
||||
tree_nodes("apple")
|
||||
tree_nodes("aspen")
|
||||
tree_nodes("pine")
|
||||
tree_nodes("spruce")
|
||||
tree_nodes("yellow_ipe")
|
||||
tree_nodes("willow")
|
||||
tree_nodes("baobab")
|
||||
tree_nodes("palm")
|
||||
tree_nodes("jungletree")
|
||||
|
||||
minetest.register_node("fl_trees:dead_aspen_leaves", {
|
||||
description = "dead aspen leaves",
|
||||
drawtype = "allfaces_optional",
|
||||
paramtype = "light",
|
||||
tiles = {"farlands_dead_aspen_leaves.png"},
|
||||
groups = {dig_tree = 3, tree = 1, leaf = 1},
|
||||
})
|
||||
})
|
||||
|
||||
local wtypes = {"acacia", "aspen", "pine", "spruce", "yellow_ipe", "willow", "baobab", "palm", "jungletree", "apple"}
|
||||
|
||||
for _, wood in pairs(wtypes) do
|
||||
tree_nodes(wood)
|
||||
end
|
||||
|
||||
if minetest.get_modpath("i3") then
|
||||
local types = {"plank", "trunk", "leaves"}
|
||||
wtypes[#wtypes] = nil
|
||||
for _, type in pairs(types) do
|
||||
i3.compress("fl_trees:apple_" .. type, {
|
||||
replace = "apple",
|
||||
by = wtypes
|
||||
})
|
||||
end
|
||||
end
|
Loading…
x
Reference in New Issue
Block a user