From f537af33bc6d49750c18aa9bdfe4259fb253555a Mon Sep 17 00:00:00 2001 From: FaceDeer Date: Fri, 29 Sep 2023 16:09:25 -0600 Subject: [PATCH] cleaning up some stuff with luacheck. --- .luacheckrc | 66 ++ big_webs/init.lua | 6 +- bones_loot/init.lua | 16 +- bubblesponge/init.lua | 22 +- chasms/init.lua | 10 +- collectible_lore/init.lua | 6 +- collectible_lore/items.lua | 12 +- df_achievements/farming.lua | 2 +- df_achievements/food.lua | 2 +- df_achievements/init.lua | 10 +- df_achievements/misc.lua | 8 +- df_achievements/travel.lua | 16 +- df_ambience/init.lua | 10 +- df_ambience/soundsets.lua | 2 +- df_caverns/dungeon_loot.lua | 10 +- df_caverns/lava_sea.lua | 24 +- df_caverns/level1.lua | 40 +- df_caverns/level2.lua | 55 +- df_caverns/level3.lua | 54 +- df_caverns/lorebooks.lua | 8 +- df_caverns/oil_sea.lua | 18 +- df_caverns/primordial.lua | 34 +- df_caverns/schematics/lamppost.lua | 2 +- df_caverns/schematics/medium_building.lua | 172 ++-- df_caverns/schematics/oubliette.lua | 10 +- df_caverns/schematics/small_building.lua | 86 +- df_caverns/schematics/small_slab.lua | 2 +- df_caverns/shared.lua | 16 +- df_caverns/sunless_sea.lua | 48 +- df_caverns/surface_tunnels.lua | 22 +- df_caverns/underworld.lua | 78 +- df_dependencies/config.lua | 4 +- df_dependencies/helper_functions.lua | 18 +- df_dependencies/mapgen.lua | 22 +- df_dependencies/nodes.lua | 2 +- df_farming/cave_wheat.lua | 8 +- df_farming/config.lua | 4 +- df_farming/dimple_cup.lua | 8 +- df_farming/pig_tail.lua | 10 +- df_farming/plants.lua | 24 +- df_farming/plump_helmet.lua | 24 +- df_farming/sweet_pod.lua | 12 +- df_lorebooks/ecology_trees.lua | 6 +- df_lorebooks/geology_the_great_caverns.lua | 4 +- df_mapitems/castle_coral.lua | 4 +- df_mapitems/config.lua | 4 +- df_mapitems/crystals_ruby.lua | 2 +- df_mapitems/glow_worms.lua | 4 +- df_mapitems/ground_cover.lua | 10 +- df_mapitems/snareweed.lua | 6 +- df_mapitems/util.lua | 6 +- df_primordial_items/ceiling_fungus.lua | 8 +- df_primordial_items/fungal_nodes.lua | 2 +- df_primordial_items/giant_fern.lua | 58 +- df_primordial_items/giant_mycelium.lua | 18 +- df_primordial_items/jungle_mushroom.lua | 8 +- df_primordial_items/jungle_nodes.lua | 8 +- df_primordial_items/jungle_tree.lua | 14 +- df_primordial_items/primordial_mushroom.lua | 892 +++++++++--------- df_trees/black_cap.lua | 8 +- df_trees/blood_thorn.lua | 19 +- df_trees/config.lua | 4 +- df_trees/fungiwood.lua | 10 +- df_trees/goblin_cap.lua | 10 +- df_trees/nether_cap.lua | 8 +- df_trees/schematics/goblin_cap_big.lua | 198 ++-- df_trees/schematics/goblin_cap_big_hut.lua | 198 ++-- df_trees/schematics/goblin_cap_bigger.lua | 260 ++--- df_trees/schematics/goblin_cap_bigger_hut.lua | 258 ++--- df_trees/spindlestem.lua | 42 +- df_trees/spore_tree.lua | 22 +- df_trees/torchspine.lua | 33 +- df_trees/tower_cap.lua | 8 +- df_trees/tunnel_tube.lua | 16 +- df_underworld_items/config.lua | 4 +- df_underworld_items/crystals_amethyst.lua | 12 +- df_underworld_items/glow_stone.lua | 2 +- df_underworld_items/glowing_pit_plasma.lua | 4 +- df_underworld_items/puzzle_chest.lua | 12 +- df_underworld_items/puzzle_seal.lua | 72 +- df_underworld_items/slade.lua | 4 +- df_underworld_items/slade_drill.lua | 2 +- hunter_statue/init.lua | 20 +- ice_sprites/init.lua | 4 +- looped_node_sound/init.lua | 4 +- mine_gas/init.lua | 14 +- oil/init.lua | 6 +- pit_caves/init.lua | 28 +- 88 files changed, 1695 insertions(+), 1644 deletions(-) create mode 100644 .luacheckrc diff --git a/.luacheckrc b/.luacheckrc new file mode 100644 index 0000000..a0dd5e7 --- /dev/null +++ b/.luacheckrc @@ -0,0 +1,66 @@ +read_globals = { + "minetest", + "ItemStack", + "VoxelArea", + "AreaStore", + table = {fields = {"copy", "indexof"}}, + "vector", + "default", + "dump", + "core", +} + +globals = { + "awards", + "big_webs", + "bones_loot", + "bubblesponge", + "bucket", + "chasms", + "collectible_lore", + "cottages", + "df_achievements", + "df_ambience", + "df_caverns", + "df_dependencies", + "df_dependencies", + "df_farming", + "df_mapitems", + "df_primordial_items", + "df_trees", + "df_underworld_items", + "doors", + "dungeon_loot", + "dynamic_liquid", + "footprints", + "hunter_statue", + "ice_sprites", + "looped_node_sound", + "mapgen_helper", + "mcl_buckets", + "mcl_explosions", + "mcl_fences", + "mcl_flowers", + "mcl_formspec", + "mcl_mapgen", + "mcl_sounds", + "mcl_stairs", + "mcl_vars", + "mcl_worlds", + "mesecon", + "name_generator", + "named_waypoints", + "oil", + "pit_caves", + "playerplus", + "radiant_damage", + "simplecrafting_lib", + "stairs", + "stairsplus", + "subterrane", + "tnt", +} + +max_line_length = false +unused_args = false +unused = false \ No newline at end of file diff --git a/big_webs/init.lua b/big_webs/init.lua index a540f6a..5ad0650 100644 --- a/big_webs/init.lua +++ b/big_webs/init.lua @@ -73,8 +73,8 @@ local get_web_nodes = function(pos, webs, anchors) end elseif in_anchor_group(check_node.name) then anchors[minetest.hash_node_position(check_pos)] = true - end - end + end + end end local web_line = function(pos, dir, distance) @@ -164,7 +164,7 @@ minetest.register_node("big_webs:webbing", { minetest.item_drop(ItemStack("big_webs:webbing"), nil, web_pos) end minetest.get_node_timer(web_pos):stop() -- no need to recheck - end + end end, _mcl_blast_resistance = 1.0, _mcl_hardness = 0.5, diff --git a/bones_loot/init.lua b/bones_loot/init.lua index 2989626..632b03a 100644 --- a/bones_loot/init.lua +++ b/bones_loot/init.lua @@ -47,7 +47,7 @@ else local inv = minetest.get_meta(pos):get_inventory() return inv:is_empty("main") end, - + on_construct = function(pos) local meta = minetest.get_meta(pos) meta:set_string("formspec", bones_formspec) @@ -111,7 +111,7 @@ local get_loot_list = function(pos, loot_type, exclusive_loot_type) else loot_table = local_loot end - + local item_list = {} local pos_y = pos.y for _, loot in ipairs(loot_table) do @@ -138,7 +138,7 @@ end bones_loot.get_loot = function(pos, loot_type, max_stacks, exclusive_loot_type) local item_list = get_loot_list(pos, loot_type, exclusive_loot_type) shuffle(item_list) - + -- apply chances / randomized amounts and collect resulting items local items = {} for _, loot in ipairs(item_list) do @@ -149,7 +149,7 @@ bones_loot.get_loot = function(pos, loot_type, max_stacks, exclusive_loot_type) if loot.count ~= nil then amount = math.random(loot.count[1], loot.count[2]) end - + if itemdef.tool_capabilities then for n = 1, amount do local wear = math.random(0.20 * 65535, 0.75 * 65535) -- 20% to 75% wear @@ -169,7 +169,7 @@ bones_loot.get_loot = function(pos, loot_type, max_stacks, exclusive_loot_type) end end if max_stacks <= 0 then break end - end + end return items end @@ -181,7 +181,7 @@ bones_loot.place_bones = function(pos, loot_type, max_stacks, infotext, exclusiv end meta:set_string("infotext", infotext) meta:set_string("formspec", bones_formspec) - + if max_stacks and max_stacks > 0 then local loot = bones_loot.get_loot(pos, loot_type, max_stacks, exclusive_loot_type) local inv = meta:get_inventory() @@ -195,11 +195,11 @@ end minetest.register_lbm({ label = "Repair underworld bones formspec", name = "bones_loot:repair_underworld_bones_formspec", - nodenames = {bones_node}, + nodenames = {bones_node}, action = function(pos, node) local meta = minetest.get_meta(pos) if not meta:get("formspec") then meta:set_string("formspec", bones_formspec) - end + end end, }) diff --git a/bubblesponge/init.lua b/bubblesponge/init.lua index 7afc766..4238770 100644 --- a/bubblesponge/init.lua +++ b/bubblesponge/init.lua @@ -20,10 +20,10 @@ local function setting(stype, name, default, description) value = default end config[name] = value - + if print_settingtypes then minetest.debug(CONFIG_FILE_PREFIX..name.." ("..description..") "..stype.." "..tostring(default)) - end + end end setting("int", "uses", 30, "Number of uses for a bubblesponge") @@ -59,7 +59,7 @@ minetest.register_tool("bubblesponge:tank", { wield_image = "bubblesponge_frond.png", stack_max = 1, groups = {bubblesponge_tank = 1}, - + on_place = function(itemstack, user, pointed_thing) return use_airtank(itemstack, user) end, @@ -78,7 +78,7 @@ minetest.register_tool("bubblesponge:bundle", { wield_image = "bubblesponge_bundle.png", stack_max = 1, groups = {bubblesponge_tank = 1}, - + on_place = function(itemstack, user, pointed_thing) return use_airtank(itemstack, user) end, @@ -119,27 +119,27 @@ minetest.register_node("bubblesponge:stem", { items = {"bubblesponge:stem"}, }, }, - }, + }, drawtype = "normal", paramtype = "light", is_ground_content = false, light_source = 6, - + on_timer = function(pos, elapsed) local timer = minetest.get_node_timer(pos) elapsed = elapsed - config.growth_seconds timer:set(config.growth_seconds, elapsed) - + if pos.y > config.y_max then return end - + pos.y = pos.y + 1 - + if minetest.find_node_near(pos, 4, "air", true) then return end - + local tries = 0 while tries < 3 do local this_node = minetest.get_node(pos).name @@ -152,7 +152,7 @@ minetest.register_node("bubblesponge:stem", { end end end, - + on_construct = function(pos) minetest.get_node_timer(pos):start(config.growth_seconds + math.random(-0.1, 0.1)*config.growth_seconds) --minetest.get_node_timer(pos):set(1, config.growth_seconds * 6) -- immediate growth diff --git a/chasms/init.lua b/chasms/init.lua index 1429926..18a20bc 100644 --- a/chasms/init.lua +++ b/chasms/init.lua @@ -116,19 +116,19 @@ minetest.register_on_generated(function(minp, maxp, seed) if minp.y >= maxy or maxp.y <= miny then return end - + -- check if webs are present local webs local webs_present = false if big_webs_path then - local seed = math.random()*10000000 + local web_seed = math.random()*10000000 math.randomseed(minp.y + z_displace*minp.z) -- use consistent seeds across the x axis if math.random() < web_probability then webs_present = true end - math.randomseed(seed) + math.randomseed(web_seed) end - + local vm, emin, emax = minetest.get_mapgen_object("voxelmanip") vm:get_data(data) @@ -163,7 +163,7 @@ minetest.register_on_generated(function(minp, maxp, seed) end end end - + vm:set_data(data) vm:calc_lighting() vm:write_to_map() diff --git a/collectible_lore/init.lua b/collectible_lore/init.lua index 3167588..1a20fef 100644 --- a/collectible_lore/init.lua +++ b/collectible_lore/init.lua @@ -7,7 +7,7 @@ collectible_lore.lorebooks = {} local ids = {} -on_collected_callbacks = {} +local on_collected_callbacks = {} collectible_lore.register_on_collected = function(callback) table.insert(on_collected_callbacks, callback) @@ -69,7 +69,7 @@ end collectible_lore.register_lorebook = function(def) if def.id == nil then - minetest.log("error", "[collectible_lore] nil id for def " .. dump(def)) + minetest.log("error", "[collectible_lore] nil id for def " .. dump(def)) return false end if ids[def.id] then @@ -101,7 +101,7 @@ minetest.register_chatcommand("collectible", { minetest.chat_send_player(name, dump(collectible_lore.get_player_collected(second))) return end - + minetest.chat_send_player(name, S("error parsing command")) end, }) diff --git a/collectible_lore/items.lua b/collectible_lore/items.lua index 2ab5d42..314060e 100644 --- a/collectible_lore/items.lua +++ b/collectible_lore/items.lua @@ -15,7 +15,7 @@ end local get_itemslot_bg = df_dependencies.get_itemslot_bg -function get_cairn_formspec(pos) +local function get_cairn_formspec(pos) local spos = pos.x .. "," .. pos.y .. "," .. pos.z local formspec = "size[8,9]" @@ -58,7 +58,7 @@ local cairn_loot = function(pos, player) return false end list[player_name] = true - + local uncollected = collectible_lore.get_player_uncollected_list(player_name) --minetest.debug(dump(uncollected)) if next(uncollected) then @@ -77,11 +77,11 @@ local cairn_loot = function(pos, player) minetest.show_formspec(player_name, "collectible_lore:cairn_inventory", get_cairn_formspec(pos)) return false end - + local leftover = player:get_inventory():add_item("main", "collectible_lore:satchel") if not leftover:is_empty() then minetest.item_drop(leftover, player, vector.add(pos, vector.new(0,1,0))) - end + end return true end @@ -235,7 +235,7 @@ local get_formspec_for_player = function(player_name) end table.insert(form, "label[0.5,7.5;" .. S("Collected: @1/@2", collected_count, #(collectible_lore.lorebooks)) .. "]") table.insert(form, "button_exit[2.75,7.3;2,0.4;exit;"..S("Exit") .. "]") - + return table.concat(form) end @@ -278,7 +278,7 @@ minetest.register_on_player_receive_fields(function(player, formname, fields) end end) -function tour(player, loc_list) +local function tour(player, loc_list) local pop = table.remove(loc_list) if pop then player:set_pos(pop) diff --git a/df_achievements/farming.lua b/df_achievements/farming.lua index 06469d7..980d4d4 100644 --- a/df_achievements/farming.lua +++ b/df_achievements/farming.lua @@ -143,7 +143,7 @@ awards.register_achievement("dfcaverns_plant_all_farmables", { .."^[combine:32x32:16,0=dfcaverns_dimple_cup_4.png" .."^[combine:32x32:8,8=dfcaverns_plump_helmet_achievement.png" .."^[combine:32x32:0,16=dfcaverns_sweet_pod_6.png" - .."^[combine:32x32:16,16=dfcaverns_quarry_bush_5.png" + .."^[combine:32x32:16,16=dfcaverns_quarry_bush_5.png" .."^[combine:32x32:16,15="..hoe_texture.."^dfcaverns_awards_foregroundx32.png", difficulty = 1 / df_achievements.get_child_achievement_count("dfcaverns_plant_all_farmables"), trigger = { diff --git a/df_achievements/food.lua b/df_achievements/food.lua index c1092f3..e7595a2 100644 --- a/df_achievements/food.lua +++ b/df_achievements/food.lua @@ -6,7 +6,7 @@ for itemname, def in pairs(minetest.registered_items) do local meal_name = string.sub(itemname, 12, -1) local meal_desc = def.description local image = string.sub(def.inventory_image, 1, -7) .. "32.png" - + awards.register_achievement("dfcaverns_meal_"..meal_name, { title = S("Eat @1", meal_desc), description = S("One of the many delights that can be crafted only from fungal growths found deep underground."), diff --git a/df_achievements/init.lua b/df_achievements/init.lua index b38cc4e..efb3898 100644 --- a/df_achievements/init.lua +++ b/df_achievements/init.lua @@ -14,7 +14,7 @@ if awards.run_trigger_callbacks then -- this "run_trigger_callbacks" API call is present in those older versions, so using that -- as a fingerprint to discover them old_awards_version = true - + minetest.register_on_dignode(function(pos, oldnode, digger) -- the old version of awards doesn't handle groups when triggering dug nodes, use this to hack around that local node_name = oldnode.name @@ -23,7 +23,7 @@ if awards.run_trigger_callbacks then elseif minetest.get_item_group(node_name, "dfcaverns_cave_coral") > 0 then awards.unlock(digger:get_player_name(), "dfcaverns_cave_coral") end - end) + end) else -- used to track the progress of achievements that are based off of other achievements awards.register_trigger("dfcaverns_achievements", { @@ -69,10 +69,10 @@ awards.register_on_unlock(function(player_name, def) local def_dfcaverns_achievements = def._dfcaverns_achievements if not def_dfcaverns_achievements then return end local player_awards = awards.player(player_name) - if not player_awards then return end + if not player_awards then return end local unlocked = player_awards.unlocked if not unlocked then return end - + -- the achievement that just got unlocked had one or more "parent" achievements associated with it. for _, achievement_parent in pairs(def_dfcaverns_achievements) do player_awards.dfcaverns_achievements = player_awards.dfcaverns_achievements or {} @@ -86,7 +86,7 @@ awards.register_on_unlock(function(player_name, def) awards.save() if count >= total then minetest.after(4, awards.unlock, player_name, achievement_parent) - end + end end end) diff --git a/df_achievements/misc.lua b/df_achievements/misc.lua index 3b25c31..89128a8 100644 --- a/df_achievements/misc.lua +++ b/df_achievements/misc.lua @@ -44,14 +44,14 @@ if minetest.get_modpath("df_underworld_items") then df_underworld_items.puzzle_seal_solved = function(pos, player) if player == nil then return end awards.unlock(player:get_player_name(), "dfcaverns_solved_puzzle_seal") - end + end awards.register_achievement("dfcaverns_solved_puzzle_seal", { title = S("Solve a Puzzle Seal"), difficulty = 4, description = S("Decipher the code of the ancients. Do you dare turn the key?"), icon = "dfcaverns_puzzle_seal_solvedx32.png^dfcaverns_awards_foregroundx32.png", }) - + df_underworld_items.slade_breacher_triggered = function(pos, player) awards.unlock(player:get_player_name(), "dfcaverns_triggered_slade_breacher") end @@ -62,7 +62,7 @@ if minetest.get_modpath("df_underworld_items") then icon = "dfcaverns_puzzle_seal_activex32.png^dfcaverns_awards_foregroundx32.png", secret=true, }) - + df_underworld_items.ancient_lantern_fixed = function(pos, player) awards.unlock(player:get_player_name(), "dfcaverns_repaired_lantern") end @@ -85,7 +85,7 @@ end if minetest.get_modpath("df_lorebooks") then collectible_lore.register_on_collected(function(player_name, id, state, collected) local count = 0 - for id, val in pairs(collected) do + for _id, val in pairs(collected) do if val then count = count + 1 end end if count >= #(collectible_lore.lorebooks) then diff --git a/df_achievements/travel.lua b/df_achievements/travel.lua index 4bdfa4b..0ee7209 100644 --- a/df_achievements/travel.lua +++ b/df_achievements/travel.lua @@ -29,12 +29,12 @@ local get_player_data = function(player) -- get head level node at player position local pos = player:get_pos() if not pos then return end - + -- get all set nodes around player local ps, cn = minetest.find_nodes_in_area( {x = pos.x - radius, y = pos.y - radius, z = pos.z - radius}, {x = pos.x + radius, y = pos.y + radius, z = pos.z + radius}, all_nodes) - + return { pos = pos, biome = df_caverns.get_biome(pos) or "", @@ -69,7 +69,7 @@ minetest.register_globalstep(function(dtime) player_name = player:get_player_name() player_awards = awards.player(player_name) unlocked = player_awards.unlocked or {} - + if unlocked["dfcaverns_visit_all_caverns"] ~= "dfcaverns_visit_all_caverns" or unlocked["dfcaverns_visit_glowing_pit"] ~= "dfcaverns_visit_glowing_pit" then player_data = get_player_data(player) @@ -95,7 +95,7 @@ minetest.register_globalstep(function(dtime) (biome == "fungispore" and ( check_nodes(node_types.fungiwood, totals) or check_nodes(node_types.sporetree, totals))) - or + or (biome == "towergoblin" and ( check_nodes(node_types.towercap, totals) or check_nodes(node_types.goblincap, totals))) @@ -104,7 +104,7 @@ minetest.register_globalstep(function(dtime) then awards.unlock(player_name, "dfcaverns_visit_sunless_sea") elseif biome == "oil_sea" and (totals["oil:oil_source"] or 0) > 1 then - awards.unlock(player_name, "dfcaverns_visit_oil_sea") + awards.unlock(player_name, "dfcaverns_visit_oil_sea") elseif biome == "underworld" then if (totals["df_underworld_items:slade"] or 0) > 1 then awards.unlock(player_name, "dfcaverns_visit_underworld") @@ -116,10 +116,10 @@ minetest.register_globalstep(function(dtime) pit.location.y = player_pos.y if vector.distance(player_pos, pit.location) <= pit.radius+10 then awards.unlock(player_name, "dfcaverns_visit_glowing_pit") - end + end end elseif biome == "lava_sea" and (totals[lava_node] or 0) > 1 then - awards.unlock(player_name, "dfcaverns_visit_lava_sea") + awards.unlock(player_name, "dfcaverns_visit_lava_sea") elseif biome == "primordial fungus" and check_nodes(node_types.primordial_fungus, totals) then awards.unlock(player_name, "dfcaverns_visit_primordial_fungal") elseif biome == "primordial jungle" and check_nodes(node_types.primordial_jungle, totals) then @@ -138,7 +138,7 @@ minetest.register_globalstep(function(dtime) if pos_y >= nearest_pit.depth and pos_y <= nearest_pit.top and vector.distance(pos, nearest_pit.location) <= 20 then awards.unlock(player_name, "dfcaverns_visit_pit") end - end + end end end end) diff --git a/df_ambience/init.lua b/df_ambience/init.lua index c323dfb..ef5665f 100644 --- a/df_ambience/init.lua +++ b/df_ambience/init.lua @@ -40,7 +40,7 @@ local get_player_data = function(player, name) if not pos then return end local prop = player:get_properties() local eyeh = prop.eye_height or 1.47 -- eye level with fallback - + pos.y = pos.y + eyeh local nod_head = pplus and name and playerplus[name] and playerplus[name].nod_head or minetest.get_node(pos).name @@ -50,7 +50,7 @@ local get_player_data = function(player, name) local ps, cn = minetest.find_nodes_in_area( {x = pos.x - radius, y = pos.y - radius, z = pos.z - radius}, {x = pos.x + radius, y = pos.y + radius, z = pos.z + radius}, set_nodes) - + return { pos = pos, head_node = nod_head, @@ -76,11 +76,11 @@ local get_ambience = function(player, name) if random() < set.frequency then local check_passed local sound_check = set.sound_check - local set_nodes = set.nodes - if sound_check or set_nodes then + local nodes = set.nodes + if sound_check or nodes then player_data = player_data or get_player_data(player, name) end - if ((not set_nodes) or check_nodes(player_data.totals, set_nodes)) and + if ((not nodes) or check_nodes(player_data.totals, nodes)) and ((not sound_check) or sound_check(player_data)) then return set end diff --git a/df_ambience/soundsets.lua b/df_ambience/soundsets.lua index ca29454..eb3e0c2 100644 --- a/df_ambience/soundsets.lua +++ b/df_ambience/soundsets.lua @@ -126,7 +126,7 @@ df_ambience.add_set({ sounds = { {name = "dfcaverns_massive_digging", gain = 1.0}, {name = "dfcaverns_avalanche", gain = 1.0}, - }, + }, sound_check = function(def) return df_caverns.get_biome(def.pos) == "lava_sea" end, diff --git a/df_caverns/dungeon_loot.lua b/df_caverns/dungeon_loot.lua index cae636e..30a0539 100644 --- a/df_caverns/dungeon_loot.lua +++ b/df_caverns/dungeon_loot.lua @@ -67,12 +67,12 @@ bones_loot.register_loot({ {name = "vessels:steel_bottle", chance = 0.4, count = {1,3}, types = {"underworld_warrior"}}, {name = "vessels:glass_bottle", chance = 0.2, count = {1,2}, types = {"underworld_warrior"}}, {name = "vessels:glass_fragments", chance = 0.1, count = {1,4}, types = {"underworld_warrior"}}, - + {name = "default:book", chance = 0.05, count = {1,1}, types = {"underworld_warrior"}}, {name = "default:paper", chance = 0.1, count = {1,6}, types = {"underworld_warrior"}}, {name = "default:skeleton_key", chance = 0.05, count = {1,1}, types = {"underworld_warrior"}}, {name = "default:torch", chance = 0.75, count = {1,10}, types = {"underworld_warrior"}}, - + {name = "default:pick_bronze", chance = 0.15, count = {1,1}, types = {"underworld_warrior"}}, {name = "default:pick_steel", chance = 0.1, count = {1,1}, types = {"underworld_warrior"}}, {name = "default:pick_mese", chance = 0.05, count = {1,1}, types = {"underworld_warrior"}}, @@ -89,7 +89,7 @@ bones_loot.register_loot({ {name = "default:sword_steel", chance = 0.75, count = {1,1}, types = {"underworld_warrior"}}, {name = "default:sword_mese", chance = 0.35, count = {1,1}, types = {"underworld_warrior"}}, {name = "default:sword_diamond", chance = 0.35, count = {1,1}, types = {"underworld_warrior"}}, - + {name = "default:coal_lump", chance = 0.5, count = {1,5}, types = {"underworld_warrior"}}, {name = "default:mese_crystal", chance = 0.1, count = {1,1}, types = {"underworld_warrior"}}, {name = "default:diamond", chance = 0.1, count = {1,1}, types = {"underworld_warrior"}}, @@ -97,7 +97,7 @@ bones_loot.register_loot({ {name = "default:copper_ingot", chance = 0.1, count = {1,2}, types = {"underworld_warrior"}}, {name = "default:bronze_ingot", chance = 0.2, count = {1,5}, types = {"underworld_warrior"}}, {name = "default:gold_ingot", chance = 0.3, count = {1,3}, types = {"underworld_warrior"}}, - {name = "default:mese_crystal_fragment", chance = 0.4, count = {1,5}, types = {"underworld_warrior"}}, + {name = "default:mese_crystal_fragment", chance = 0.4, count = {1,5}, types = {"underworld_warrior"}}, {name = "default:obsidian_shard", chance = 0.4, count = {1,3}, types = {"underworld_warrior"}}, {name = "default:flint", chance = 0.3, count = {1,1}, types = {"underworld_warrior"}}, {name = "default:sign_wall_wood", chance = 0.1, count = {1,4}, types = {"underworld_warrior"}}, @@ -156,4 +156,4 @@ if df_caverns.config.enable_lava_sea then bones_loot.register_loot({name = "df_mapitems:mese_crystal", chance = 0.25, count = {1, 2}, types = {"underworld_warrior"}}) end -end \ No newline at end of file +end \ No newline at end of file diff --git a/df_caverns/lava_sea.lua b/df_caverns/lava_sea.lua index 25e0a35..cdc4dd7 100644 --- a/df_caverns/lava_sea.lua +++ b/df_caverns/lava_sea.lua @@ -65,29 +65,29 @@ minetest.register_on_generated(function(minp, maxp, seed) if minp.y > y_max or maxp.y < y_min then return end - + local t_start = os.clock() math.randomseed(minp.x + minp.y*2^8 + minp.z*2^16 + seed) -- make decorations consistent between runs - + local vm, data, data_param2, area = mapgen_helper.mapgen_vm_data_param2() - + local nvals_cave = mapgen_helper.perlin2d("df_caverns:lava_cave", minp, maxp, perlin_cave) local nvals_wave = mapgen_helper.perlin2d("df_caverns:lava_wave", minp, maxp, perlin_wave) local nvals_mese = mapgen_helper.perlin2d("df_caverns:lava_mese", minp, maxp, perlin_mese) local nvals_lavasurface = mapgen_helper.perlin2d("df_cavern:cracks", minp, maxp, df_caverns.np_cracks) - + for vi, x, y, z in area:iterp_yxz(minp, maxp) do local index2d = mapgen_helper.index2d(minp, maxp, x, z) local abs_cave = math.abs(nvals_cave[index2d]) -- range is from 0 to approximately 2, with 0 being connected and 2s being islands local wave = nvals_wave[index2d] * wave_mult local lava = nvals_lavasurface[index2d] - + local floor_height = math.floor(abs_cave * floor_mult + floor_displace + median + wave) local ceiling_height = math.floor(abs_cave * ceiling_mult + median + ceiling_displace + wave) local lava_height = math.floor(median + lava * 2) - + if y >= floor_height - 2 and y >= ceiling_height and y < ceiling_height + 2 and y <= lava_height + 2 and not mapgen_helper.buildable_to(data[vi]) then data[vi] = c_obsidian -- obsidian ceiling elseif y > floor_height and y < ceiling_height then @@ -109,7 +109,7 @@ minetest.register_on_generated(function(minp, maxp, seed) for z = minp.z + 1, maxp.z -1 do local index2d = mapgen_helper.index2d(minp, maxp, x, z) local mese_intensity = math.abs(nvals_mese[index2d]) - + local abs_cave = math.abs(nvals_cave[index2d]) -- range is from 0 to approximately 2, with 0 being connected and 2s being islands local wave = nvals_wave[index2d] * wave_mult local floor_height = math.floor(abs_cave * floor_mult + floor_displace + median + wave) @@ -117,7 +117,7 @@ minetest.register_on_generated(function(minp, maxp, seed) local lava = nvals_lavasurface[index2d] local lava_height = math.floor(median + lava * 2) - + if mese_intensity > 0.65 and ceiling_height > lava_height + 1 and ceiling_height > floor_height + 1 and ceiling_height <= maxp.y and ceiling_height >= minp.y then local vi = area:index(x, ceiling_height, z) if not mapgen_helper.buildable_to(data[vi]) then @@ -139,19 +139,19 @@ minetest.register_on_generated(function(minp, maxp, seed) end end end - - + + --send data back to voxelmanip vm:set_data(data) vm:set_param2_data(data_param2) --calc lighting vm:set_lighting({day = 0, night = 0}) vm:calc_lighting() - + vm:update_liquids() --write it to world vm:write_to_map() - + local time_taken = os.clock() - t_start -- how long this chunk took, in seconds mapgen_helper.record_time("df_caverns lava sea", time_taken) end) \ No newline at end of file diff --git a/df_caverns/level1.lua b/df_caverns/level1.lua index 617ce75..9113b5d 100644 --- a/df_caverns/level1.lua +++ b/df_caverns/level1.lua @@ -50,7 +50,7 @@ df_caverns.register_biome_check(function(pos, heat, humidity) if pos.y < df_caverns.config.level1_min or pos.y > df_caverns.config.ymax then return nil end - return get_biome(heat, humidity) + return get_biome(heat, humidity) end) local tower_cap_cavern_floor = function(abs_cracks, vert_rand, vi, area, data, data_param2) @@ -106,7 +106,7 @@ local decorate_level_1 = function(minp, maxp, seed, vm, node_arrays, area, data) local nvals_cracks = mapgen_helper.perlin2d("df_cavern:cracks", minp, maxp, df_caverns.np_cracks) local nvals_cave = node_arrays.nvals_cave local cave_area = node_arrays.cave_area - + -- Partly fill flooded caverns and warrens if minp.y <= subsea_level then for vi, x, y, z in area:iterp_yxz(area.MinEdge, area.MaxEdge) do @@ -119,14 +119,14 @@ local decorate_level_1 = function(minp, maxp, seed, vm, node_arrays, area, data) --------------------------------------------------------- -- Cavern floors - + for _, vi in ipairs(node_arrays.cavern_floor_nodes) do local vert_rand = mapgen_helper.xz_consistent_randomi(area, vi) local index2d = mapgen_helper.index2di(minp, maxp, area, vi) local biome_name = get_biome(heatmap[index2d], humiditymap[index2d]) local abs_cracks = math.abs(nvals_cracks[index2d]) local flooded_caverns = nvals_cave[vi] < 0 -- this indicates if we're in the "flooded" set of caves or not. - + if minp.y < subsea_level and area:get_y(vi) < subsea_level and flooded_caverns then -- underwater floor df_caverns.flooded_cavern_floor(abs_cracks, vert_rand, vi, area, data) @@ -145,12 +145,12 @@ local decorate_level_1 = function(minp, maxp, seed, vm, node_arrays, area, data) df_caverns.dry_cavern_floor(abs_cracks, vert_rand, vi, area, data, data_param2) if log_location then log_location("level1_barren_dry", area:position(vi)) end end - end + end end -------------------------------------- -- Cavern ceilings - + for _, vi in ipairs(node_arrays.cavern_ceiling_nodes) do local vert_rand = mapgen_helper.xz_consistent_randomi(area, vi) local index2d = mapgen_helper.index2di(minp, maxp, area, vi) @@ -176,7 +176,7 @@ local decorate_level_1 = function(minp, maxp, seed, vm, node_arrays, area, data) df_caverns.glow_worm_cavern_ceiling(abs_cracks, vert_rand, vi, area, data, data_param2) end end - + ---------------------------------------------- -- Tunnel floors @@ -186,7 +186,7 @@ local decorate_level_1 = function(minp, maxp, seed, vm, node_arrays, area, data) local flooded_caverns = nvals_cave[vi] < 0 -- this indicates if we're in the "flooded" set of caves or not. if not (flooded_caverns and minp.y < subsea_level and area:get_y(vi) < subsea_level) then - if flooded_caverns or biome_name ~= "barren" then + if flooded_caverns or biome_name ~= "barren" then -- we're in flooded areas or are not barren df_caverns.tunnel_floor(minp, maxp, area, vi, nvals_cracks, data, data_param2, true) else @@ -194,17 +194,17 @@ local decorate_level_1 = function(minp, maxp, seed, vm, node_arrays, area, data) end end end - + ------------------------------------------------------ -- Tunnel ceiling - + for _, vi in ipairs(node_arrays.tunnel_ceiling_nodes) do local index2d = mapgen_helper.index2di(minp, maxp, area, vi) local biome_name = get_biome(heatmap[index2d], humiditymap[index2d]) local flooded_caverns = nvals_cave[vi] < 0 -- this indicates if we're in the "flooded" set of caves or not. if not (flooded_caverns and minp.y < subsea_level and area:get_y(vi) < subsea_level) then - if flooded_caverns or biome_name ~= "barren" then + if flooded_caverns or biome_name ~= "barren" then -- we're in flooded areas or are not barren df_caverns.tunnel_ceiling(minp, maxp, area, vi, nvals_cracks, data, data_param2, true) else @@ -219,13 +219,13 @@ local decorate_level_1 = function(minp, maxp, seed, vm, node_arrays, area, data) if cracks > 0.7 and data[vi-ystride*2] == c_water then data[vi-ystride*2] = c_air end - end + end end end - + ---------------------------------------------- -- Warren floors - + for _, vi in ipairs(node_arrays.warren_floor_nodes) do local index2d = mapgen_helper.index2di(minp, maxp, area, vi) local biome_name = get_biome(heatmap[index2d], humiditymap[index2d]) @@ -239,13 +239,13 @@ local decorate_level_1 = function(minp, maxp, seed, vm, node_arrays, area, data) end if not (flooded_caverns and minp.y < subsea_level and area:get_y(vi) < subsea_level) then - if flooded_caverns or biome_name ~= "barren" then + if flooded_caverns or biome_name ~= "barren" then -- we're in flooded areas or are not barren df_caverns.tunnel_floor(minp, maxp, area, vi, nvals_cracks, data, data_param2, true) else df_caverns.tunnel_floor(minp, maxp, area, vi, nvals_cracks, data, data_param2, false, c_gravel) end - + if biome_name ~= "barren" then local cracks = nvals_cracks[index2d] if cracks > 0.25 then @@ -267,7 +267,7 @@ local decorate_level_1 = function(minp, maxp, seed, vm, node_arrays, area, data) end end end - + ------------------------------------------------------ -- Warren ceiling @@ -277,7 +277,7 @@ local decorate_level_1 = function(minp, maxp, seed, vm, node_arrays, area, data) local flooded_caverns = nvals_cave[vi] < 0 -- this indicates if we're in the "flooded" set of caves or not. if not (flooded_caverns and minp.y < subsea_level and area:get_y(vi) < subsea_level) then - if flooded_caverns or biome_name ~= "barren" then + if flooded_caverns or biome_name ~= "barren" then -- we're in flooded areas or are not barren df_caverns.tunnel_ceiling(minp, maxp, area, vi, nvals_cracks, data, data_param2, true) else @@ -289,7 +289,7 @@ local decorate_level_1 = function(minp, maxp, seed, vm, node_arrays, area, data) ---------------------------------------------- -- Column material override for dry biome - + for _, vi in ipairs(node_arrays.column_nodes) do local index2d = mapgen_helper.index2di(minp, maxp, area, vi) local biome_name = get_biome(heatmap[index2d], humiditymap[index2d]) @@ -298,7 +298,7 @@ local decorate_level_1 = function(minp, maxp, seed, vm, node_arrays, area, data) if dry and data[vi] == c_wet_flowstone then data[vi] = c_dry_flowstone end - + if chasms_path then local pos = area:position(vi) if chasms.is_in_chasm_without_taper(pos) then diff --git a/df_caverns/level2.lua b/df_caverns/level2.lua index 72e3e9f..011258c 100644 --- a/df_caverns/level2.lua +++ b/df_caverns/level2.lua @@ -51,7 +51,7 @@ df_caverns.register_biome_check(function(pos, heat, humidity) if pos.y < df_caverns.config.level2_min or pos.y >= df_caverns.config.level1_min then return nil end - return get_biome(heat, humidity) + return get_biome(heat, humidity) end) local goblin_cap_shrublist @@ -71,7 +71,7 @@ if minetest.get_modpath("df_farming") then df_farming.spawn_cave_wheat_vm, df_farming.spawn_dead_fungus_vm, df_farming.spawn_cavern_fungi_vm, - } + } spore_tree_shrublist = { df_farming.spawn_pig_tail_vm, df_farming.spawn_pig_tail_vm, @@ -102,7 +102,7 @@ local goblin_cap_cavern_floor = function(abs_cracks, vert_rand, vi, area, data, end -local spore_tree_cavern_floor = function(abs_cracks, vert_rand, vi, area, data, data_param2) +local spore_tree_cavern_floor = function(abs_cracks, vert_rand, vi, area, data, data_param2) local ystride = area.ystride if abs_cracks < 0.1 then df_caverns.stalagmites(abs_cracks, vert_rand, vi, area, data, data_param2, true) @@ -150,10 +150,10 @@ local decorate_level_2 = function(minp, maxp, seed, vm, node_arrays, area, data) local nvals_cave = node_arrays.nvals_cave local cave_area = node_arrays.cave_area local cavern_def = node_arrays.cavern_def - + local vein_noise local vein_area - + -- Partly fill flooded caverns and warrens for vi, x, y, z in area:iterp_yxz(area.MinEdge, area.MaxEdge) do local cave_val = nvals_cave[vi] @@ -162,7 +162,7 @@ local decorate_level_2 = function(minp, maxp, seed, vm, node_arrays, area, data) local index2d = mapgen_helper.index2di(minp, maxp, area, vi) local biome_name = get_biome(heatmap[index2d], humiditymap[index2d]) local cave_threshold = cavern_def.cave_threshold - + --check if we're just inside the boundary of the (negazone) cavern threshold if biome_name == "barren" and cave_val < -cave_threshold and cave_val > -cave_threshold - 0.01 then -- add giant rooty structures to the flooded barren caverns @@ -179,18 +179,18 @@ local decorate_level_2 = function(minp, maxp, seed, vm, node_arrays, area, data) data[vi] = c_water -- otherwise, fill air with water when below sea level end end - end - + end + --------------------------------------------------------- -- Cavern floors - + for _, vi in ipairs(node_arrays.cavern_floor_nodes) do local vert_rand = mapgen_helper.xz_consistent_randomi(area, vi) local index2d = mapgen_helper.index2di(minp, maxp, area, vi) local biome_name = get_biome(heatmap[index2d], humiditymap[index2d]) local abs_cracks = math.abs(nvals_cracks[index2d]) local flooded_caverns = nvals_cave[vi] < 0 -- this indicates if we're in the "flooded" set of caves or not. - + if minp.y < subsea_level and area:get_y(vi) < subsea_level and flooded_caverns then -- underwater floor df_caverns.flooded_cavern_floor(abs_cracks, vert_rand, vi, area, data) @@ -207,7 +207,7 @@ local decorate_level_2 = function(minp, maxp, seed, vm, node_arrays, area, data) goblin_cap_cavern_floor(abs_cracks, vert_rand, vi, area, data, data_param2) if log_location then log_location("level2_goblincap", area:position(vi)) end elseif biome_name == "sporetree" then - spore_tree_cavern_floor(abs_cracks, vert_rand, vi, area, data, data_param2) + spore_tree_cavern_floor(abs_cracks, vert_rand, vi, area, data, data_param2) if log_location then log_location("level2_sporetree", area:position(vi)) end elseif biome_name == "tunneltube" then tunnel_tube_cavern_floor(abs_cracks, vert_rand, vi, area, data, data_param2) @@ -217,7 +217,7 @@ local decorate_level_2 = function(minp, maxp, seed, vm, node_arrays, area, data) -------------------------------------- -- Cavern ceilings - + for _, vi in ipairs(node_arrays.cavern_ceiling_nodes) do local vert_rand = mapgen_helper.xz_consistent_randomi(area, vi) local index2d = mapgen_helper.index2di(minp, maxp, area, vi) @@ -243,22 +243,22 @@ local decorate_level_2 = function(minp, maxp, seed, vm, node_arrays, area, data) if abs_cracks * y_proportional > 0.3 and math.random() < 0.005 * y_proportional then df_mapitems.place_big_crystal_cluster(area, data, data_param2, vi, math.random(0,1), true) end - end + end else -- all the other biomes df_caverns.glow_worm_cavern_ceiling(abs_cracks, vert_rand, vi, area, data, data_param2) end end - + ---------------------------------------------- -- Tunnel floors - + for _, vi in ipairs(node_arrays.tunnel_floor_nodes) do local index2d = mapgen_helper.index2di(minp, maxp, area, vi) local biome_name = get_biome(heatmap[index2d], humiditymap[index2d]) local flooded_caverns = nvals_cave[vi] < 0 -- this indicates if we're in the "flooded" set of caves or not. if not (flooded_caverns and minp.y < subsea_level and area:get_y(vi) < subsea_level) then - if flooded_caverns or biome_name ~= "barren" then + if flooded_caverns or biome_name ~= "barren" then -- we're in flooded areas or are not barren df_caverns.tunnel_floor(minp, maxp, area, vi, nvals_cracks, data, data_param2, true) else @@ -266,10 +266,10 @@ local decorate_level_2 = function(minp, maxp, seed, vm, node_arrays, area, data) end end end - + ------------------------------------------------------ -- Tunnel ceiling - + for _, vi in ipairs(node_arrays.tunnel_ceiling_nodes) do local index2d = mapgen_helper.index2di(minp, maxp, area, vi) local biome_name = get_biome(heatmap[index2d], humiditymap[index2d]) @@ -295,20 +295,19 @@ local decorate_level_2 = function(minp, maxp, seed, vm, node_arrays, area, data) end else -- air pockets - local ystride = area.ystride local cracks = nvals_cracks[index2d] if cracks > 0.4 and data[vi-ystride] == c_water then data[vi-ystride] = c_air if cracks > 0.6 and data[vi-ystride*2] == c_water then data[vi-ystride*2] = c_air end - end + end end end ---------------------------------------------- -- Warren floors - + for _, vi in ipairs(node_arrays.warren_floor_nodes) do local index2d = mapgen_helper.index2di(minp, maxp, area, vi) local biome_name = get_biome(heatmap[index2d], humiditymap[index2d]) @@ -319,9 +318,9 @@ local decorate_level_2 = function(minp, maxp, seed, vm, node_arrays, area, data) if flooded_caverns then flood_name = "_flooded" end log_location("level2_warren_"..biome_name..flood_name, area:position(vi)) end - + if not (flooded_caverns and minp.y < subsea_level and area:get_y(vi) < subsea_level) then - if flooded_caverns or biome_name ~= "barren" then + if flooded_caverns or biome_name ~= "barren" then -- we're in flooded areas or are not barren df_caverns.tunnel_floor(minp, maxp, area, vi, nvals_cracks, data, data_param2, true) else @@ -329,7 +328,7 @@ local decorate_level_2 = function(minp, maxp, seed, vm, node_arrays, area, data) end end end - + ------------------------------------------------------ -- Warren ceiling @@ -340,7 +339,7 @@ local decorate_level_2 = function(minp, maxp, seed, vm, node_arrays, area, data) local ystride = area.ystride if not (flooded_caverns and minp.y < subsea_level and area:get_y(vi) < subsea_level) then - if flooded_caverns or biome_name ~= "barren" then + if flooded_caverns or biome_name ~= "barren" then -- we're in flooded areas or are not barren df_caverns.tunnel_ceiling(minp, maxp, area, vi, nvals_cracks, data, data_param2, true) else @@ -365,14 +364,14 @@ local decorate_level_2 = function(minp, maxp, seed, vm, node_arrays, area, data) if cracks > 0.6 and data[vi-ystride*2] == c_water then data[vi-ystride*2] = c_air end - end + end end end ---------------------------------------------- -- Column material override for dry biome - + for _, vi in ipairs(node_arrays.column_nodes) do local index2d = mapgen_helper.index2di(minp, maxp, area, vi) local biome_name = get_biome(heatmap[index2d], humiditymap[index2d]) @@ -381,7 +380,7 @@ local decorate_level_2 = function(minp, maxp, seed, vm, node_arrays, area, data) if dry and data[vi] == c_wet_flowstone then data[vi] = c_dry_flowstone end - + if chasms_path then local pos = area:position(vi) if chasms.is_in_chasm_without_taper(pos) then diff --git a/df_caverns/level3.lua b/df_caverns/level3.lua index 5972c9d..652c6a1 100644 --- a/df_caverns/level3.lua +++ b/df_caverns/level3.lua @@ -98,7 +98,7 @@ local black_cap_cavern_floor = function(abs_cracks, vert_rand, vi, area, data, d else data[vi] = c_cobble_fungus end - + if abs_cracks < 0.1 then df_caverns.stalagmites(abs_cracks, vert_rand, vi, area, data, data_param2, false) elseif abs_cracks < 0.15 and math.random() < 0.3 then @@ -127,7 +127,7 @@ local nether_cap_cavern_floor = function(cracks, abs_cracks, vert_rand, vi, area end end end - + if cracks < -0.3 then data[vi] = c_silver_sand if math.random() < 0.025 then @@ -149,7 +149,7 @@ local nether_cap_cavern_floor = function(cracks, abs_cracks, vert_rand, vi, area data[vi + 2*ystride] = c_ice end end - end + end end local nether_cap_cavern_ceiling = function(abs_cracks, vert_rand, vi, area, data, data_param2) @@ -166,7 +166,7 @@ local nether_cap_cavern_ceiling = function(abs_cracks, vert_rand, vi, area, data subterrane.stalactite(vi-ystride, area, data, data_param2, param2, math.floor(height*0.5), df_mapitems.dry_stalagmite_ids) end end - end + end if c_sprite and abs_cracks < 0.5 and math.random() < 0.02 then local sprite_vi = vi-ystride*math.random(1,5) if data[sprite_vi] == c_air and area:containsi(sprite_vi) then @@ -221,7 +221,7 @@ local decorate_level_3 = function(minp, maxp, seed, vm, node_arrays, area, data) local nvals_cave = node_arrays.nvals_cave local cave_area = node_arrays.cave_area local cavern_def = node_arrays.cavern_def - + -- Partly fill flooded caverns and warrens if minp.y <= subsea_level then for vi, x, y, z in area:iterp_yxz(area.MinEdge, area.MaxEdge) do @@ -230,8 +230,8 @@ local decorate_level_3 = function(minp, maxp, seed, vm, node_arrays, area, data) if data[vi] == c_air and y <= subsea_level then data[vi] = c_water end - - if (mapgen_helper.is_pos_within_box({x=x, y=y, z=z}, minp, maxp)) then + + if (mapgen_helper.is_pos_within_box({x=x, y=y, z=z}, minp, maxp)) then local index2d = mapgen_helper.index2di(minp, maxp, area, vi) local biome_name = get_biome(heatmap[index2d], humiditymap[index2d]) if biome_name == "blackcap" then @@ -249,10 +249,10 @@ local decorate_level_3 = function(minp, maxp, seed, vm, node_arrays, area, data) end end end - + --------------------------------------------------------- -- Cavern floors - + for _, vi in ipairs(node_arrays.cavern_floor_nodes) do local vert_rand = mapgen_helper.xz_consistent_randomi(area, vi) local index2d = mapgen_helper.index2di(minp, maxp, area, vi) @@ -293,15 +293,15 @@ local decorate_level_3 = function(minp, maxp, seed, vm, node_arrays, area, data) if log_location then log_location("level3_blackcap", area:position(vi)) end elseif biome_name == "bloodnether" then if flooded_caverns then - nether_cap_cavern_floor(cracks, abs_cracks, vert_rand, vi, area, data, data_param2) + nether_cap_cavern_floor(cracks, abs_cracks, vert_rand, vi, area, data, data_param2) if log_location then log_location("level3_nethercap", area:position(vi)) end else - blood_thorn_cavern_floor(abs_cracks, vert_rand, vi, area, data, data_param2) + blood_thorn_cavern_floor(abs_cracks, vert_rand, vi, area, data, data_param2) if log_location then log_location("level3_bloodthorn", area:position(vi)) end end end end - + -------------------------------------- -- Cavern ceilings @@ -318,7 +318,7 @@ local decorate_level_3 = function(minp, maxp, seed, vm, node_arrays, area, data) elseif biome_name == "blackcap" then if abs_cracks < 0.1 then df_caverns.stalactites(abs_cracks, vert_rand, vi, area, data, data_param2, false) - end + end if math.random() < 0.25 then data[vi] = c_stone_with_coal end @@ -363,7 +363,7 @@ local decorate_level_3 = function(minp, maxp, seed, vm, node_arrays, area, data) end end end - + ---------------------------------------------- -- Tunnel floors @@ -374,7 +374,7 @@ local decorate_level_3 = function(minp, maxp, seed, vm, node_arrays, area, data) local flooded_caverns = nvals_cave[vi] < 0 -- this indicates if we're in the "flooded" set of caves or not. if not (flooded_caverns and minp.y < subsea_level and area:get_y(vi) < subsea_level) then - if flooded_caverns or biome_name == "blackcap" then + if flooded_caverns or biome_name == "blackcap" then -- we're in flooded areas or are not barren df_caverns.tunnel_floor(minp, maxp, area, vi, nvals_cracks, data, data_param2, true) else @@ -382,17 +382,17 @@ local decorate_level_3 = function(minp, maxp, seed, vm, node_arrays, area, data) end end end - + ------------------------------------------------------ -- Tunnel ceiling - + for _, vi in ipairs(node_arrays.tunnel_ceiling_nodes) do local index2d = mapgen_helper.index2di(minp, maxp, area, vi) local humidity = humiditymap[index2d] local biome_name = get_biome(heatmap[index2d], humidity) local flooded_caverns = nvals_cave[vi] < 0 -- this indicates if we're in the "flooded" set of caves or not. local ystride = area.ystride - + if not (flooded_caverns and minp.y < subsea_level and area:get_y(vi) < subsea_level) then if flooded_caverns or biome_name == "blackcap" then -- we're in flooded areas or are not barren @@ -415,11 +415,11 @@ local decorate_level_3 = function(minp, maxp, seed, vm, node_arrays, area, data) if cracks > 0.7 and data[vi-ystride*2] == c_water then data[vi-ystride*2] = c_air end - end + end end end - + ------------------------------------------------------ -- Warren ceiling @@ -427,13 +427,13 @@ local decorate_level_3 = function(minp, maxp, seed, vm, node_arrays, area, data) local index2d = mapgen_helper.index2di(minp, maxp, area, vi) local biome_name = get_biome(heatmap[index2d], humiditymap[index2d]) local flooded_caverns = nvals_cave[vi] < 0 -- this indicates if we're in the "flooded" set of caves or not. - + if log_location then local flood_name = "" if flooded_caverns then flood_name = "_flooded" end log_location("level3_warren_"..biome_name..flood_name, area:position(vi)) end - + if flooded_caverns and minp.y < subsea_level and area:get_y(vi) < subsea_level then -- underwater ceiling, do nothing elseif biome_name == "bloodnether" and flooded_caverns then @@ -466,12 +466,12 @@ local decorate_level_3 = function(minp, maxp, seed, vm, node_arrays, area, data) ---------------------------------------------- -- Warren floors - + for _, vi in ipairs(node_arrays.warren_floor_nodes) do local index2d = mapgen_helper.index2di(minp, maxp, area, vi) local biome_name = get_biome(heatmap[index2d], humiditymap[index2d]) local flooded_caverns = nvals_cave[vi] < 0 -- this indicates if we're in the "flooded" set of caves or not. - + if minp.y < subsea_level and area:get_y(vi) < subsea_level and flooded_caverns then -- underwater floor, do nothing elseif biome_name == "bloodnether" and flooded_caverns then @@ -506,7 +506,7 @@ local decorate_level_3 = function(minp, maxp, seed, vm, node_arrays, area, data) end end end - + ---------------------------------------------- -- Column material override for dry and icy biomes for _, vi in ipairs(node_arrays.column_nodes) do @@ -540,7 +540,7 @@ local decorate_level_3 = function(minp, maxp, seed, vm, node_arrays, area, data) elseif biome_name == "barren" and not flooded_caverns and data[vi] == c_wet_flowstone then data[vi] = c_dry_flowstone end - + if chasms_path then local pos = area:position(vi) if chasms.is_in_chasm_without_taper(pos) then @@ -552,7 +552,7 @@ local decorate_level_3 = function(minp, maxp, seed, vm, node_arrays, area, data) end end - + end vm:set_param2_data(data_param2) diff --git a/df_caverns/lorebooks.lua b/df_caverns/lorebooks.lua index b2cf3ee..865c867 100644 --- a/df_caverns/lorebooks.lua +++ b/df_caverns/lorebooks.lua @@ -6,15 +6,15 @@ minetest.register_on_generated(function(minp, maxp, blockseed) if maxp.y > 0 or maxp.y < df_caverns.config.primordial_min then return end -- using after so that all other mapgen should be finished fiddling with stuff by the time this runs - minetest.after(1, function(minp, maxp) - local middle = vector.divide(vector.add(minp, maxp), 2) + minetest.after(1, function(minp_after, maxp_after) + local middle = vector.divide(vector.add(minp_after, maxp_after), 2) if collectible_lore.are_cairns_close_to_pos(middle) then return end -- quick and dirty check to discard mapblocks close to other cairns - local possibles = minetest.find_nodes_in_area_under_air(minp, maxp, foundations) + local possibles = minetest.find_nodes_in_area_under_air(minp_after, maxp_after, foundations) if next(possibles) then local target = possibles[math.random(#possibles)] target.y=target.y+1 collectible_lore.place_cairn(target) - end + end end, minp, maxp) end) \ No newline at end of file diff --git a/df_caverns/oil_sea.lua b/df_caverns/oil_sea.lua index 7123b2d..b295789 100644 --- a/df_caverns/oil_sea.lua +++ b/df_caverns/oil_sea.lua @@ -62,10 +62,10 @@ minetest.register_on_generated(function(minp, maxp, seed) local t_start = os.clock() local vm, data, area = mapgen_helper.mapgen_vm_data() - + local nvals_cave = mapgen_helper.perlin2d("df_caverns:oil_cave", minp, maxp, perlin_cave) local nvals_wave = mapgen_helper.perlin2d("df_caverns:oil_wave", minp, maxp, perlin_wave) - + if c_lava_set == nil then c_lava_set = {} for name, def in pairs(minetest.registered_nodes) do @@ -74,16 +74,16 @@ minetest.register_on_generated(function(minp, maxp, seed) end end end - + for vi, x, y, z in area:iterp_yxz(minp, maxp) do local index2d = mapgen_helper.index2d(minp, maxp, x, z) local abs_cave = math.abs(nvals_cave[index2d]) -- range is from 0 to approximately 2, with 0 being connected and 2s being islands local wave = nvals_wave[index2d] * wave_mult - + local floor_height = math.floor(abs_cave * floor_mult + floor_displace + median + wave) local ceiling_height = math.floor(abs_cave * ceiling_mult + median + ceiling_displace + wave) - + if y > floor_height - 5 and y < ceiling_height + 5 then if c_lava_set[data[vi]] then data[vi] = c_obsidian @@ -101,20 +101,20 @@ minetest.register_on_generated(function(minp, maxp, seed) if log_location then log_location("oil_sea", area:position(vi)) end end end - + end - + --send data back to voxelmanip vm:set_data(data) --calc lighting vm:set_lighting({day = 0, night = 0}) vm:calc_lighting() - + vm:update_liquids() --write it to world vm:write_to_map() - + local time_taken = os.clock() - t_start -- how long this chunk took, in seconds mapgen_helper.record_time("df_caverns oil sea", time_taken) end) diff --git a/df_caverns/primordial.lua b/df_caverns/primordial.lua index d72f708..6097354 100644 --- a/df_caverns/primordial.lua +++ b/df_caverns/primordial.lua @@ -164,7 +164,7 @@ local c_fireflies = df_caverns.node_id.fireflies local jungle_cavern_floor = function(abs_cracks, humidity, vi, area, data, data_param2) local ystride = area.ystride local humidityfactor = humidity/100 - + if log_location then local pos = area:position(vi) log_location("primordial_jungle", pos) @@ -189,7 +189,7 @@ local jungle_cavern_floor = function(abs_cracks, humidity, vi, area, data, data_ elseif rand < 0.3 then data[vi+ystride] = jungle_plants[math.random(1,#jungle_plants)] end - + if c_fireflies and math.random() < 0.01 then local firefly_vi = vi + ystride * math.random(1, 5) if data[firefly_vi] == c_air then @@ -258,7 +258,7 @@ local jungle_warren_floor = function(abs_cracks, vi, area, data, data_param2) elseif abs_cracks < 1 then data[vi] = c_dirt end - + if c_fireflies and math.random() < 0.005 then local firefly_vi = vi + ystride * math.random(1, 5) if data[firefly_vi] == c_air then @@ -277,20 +277,20 @@ local decorate_primordial = function(minp, maxp, seed, vm, node_arrays, area, da local nvals_cracks = mapgen_helper.perlin2d("df_cavern:cracks", minp, maxp, df_caverns.np_cracks) local cave_area = node_arrays.cave_area local nvals_cave = node_arrays.nvals_cave - + local humiditymap = minetest.get_mapgen_object("humiditymap") - + --------------------------------------------------------- -- Cavern floors - + for _, vi in ipairs(node_arrays.cavern_floor_nodes) do local index2d = mapgen_helper.index2di(minp, maxp, area, vi) local cracks = nvals_cracks[index2d] local abs_cracks = math.abs(cracks) local humidity = humiditymap[index2d] local jungle = nvals_cave[vi] < 0 - + if jungle then jungle_cavern_floor(abs_cracks, humidity, vi, area, data, data_param2) else @@ -298,7 +298,7 @@ local decorate_primordial = function(minp, maxp, seed, vm, node_arrays, area, da if log_location then log_location("primordial_mushrooms", area:position(vi)) end end end - + -------------------------------------- -- Cavern ceilings @@ -314,19 +314,19 @@ local decorate_primordial = function(minp, maxp, seed, vm, node_arrays, area, da mushroom_cavern_ceiling(abs_cracks, humidity, vi, area, data, data_param2) end end - + ---------------------------------------------- -- Tunnel floors - + -- for _, vi in ipairs(node_arrays.tunnel_floor_nodes) do -- end - + ------------------------------------------------------ -- Tunnel ceiling - + -- for _, vi in ipairs(node_arrays.tunnel_ceiling_nodes) do -- end - + ------------------------------------------------------ -- Warren ceiling @@ -335,7 +335,7 @@ local decorate_primordial = function(minp, maxp, seed, vm, node_arrays, area, da local cracks = nvals_cracks[index2d] local abs_cracks = math.abs(cracks) local jungle = nvals_cave[vi] < 0 - + if jungle then jungle_warren_ceiling(abs_cracks, vi, area, data, data_param2) else @@ -346,13 +346,13 @@ local decorate_primordial = function(minp, maxp, seed, vm, node_arrays, area, da ---------------------------------------------- -- Warren floors - + for _, vi in ipairs(node_arrays.warren_floor_nodes) do local index2d = mapgen_helper.index2di(minp, maxp, area, vi) local cracks = nvals_cracks[index2d] local abs_cracks = math.abs(cracks) local jungle = nvals_cave[vi] < 0 - + if jungle then jungle_warren_floor(abs_cracks, vi, area, data, data_param2) if log_location then log_location("primordial_jungle_warren", area:position(vi)) end @@ -377,7 +377,7 @@ local decorate_primordial = function(minp, maxp, seed, vm, node_arrays, area, da if data[rand_vi] == c_air then data[rand_vi] = c_giant_mycelium minetest.get_node_timer(area:position(rand_vi)):start(math.random(1,giant_mycelium_timer_spread)) - end + end end end end diff --git a/df_caverns/schematics/lamppost.lua b/df_caverns/schematics/lamppost.lua index 5565469..e5d9b3a 100644 --- a/df_caverns/schematics/lamppost.lua +++ b/df_caverns/schematics/lamppost.lua @@ -44,6 +44,6 @@ return { n5, n5, n5, n5, n5, n5, n5, n11, n5, - n5, n5, n5, + n5, n5, n5, } } diff --git a/df_caverns/schematics/medium_building.lua b/df_caverns/schematics/medium_building.lua index 1385364..0a56ff1 100644 --- a/df_caverns/schematics/medium_building.lua +++ b/df_caverns/schematics/medium_building.lua @@ -25,91 +25,91 @@ return { size = {x = 15, y = 12, z = 8}, center_pos = {x = 10, y = 6, z = 3}, data = { - n1, n1, n1, n1, n1, n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, - n1, n1, n1, n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, - n1, n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n1, n1, - n1, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n1, n1, n1, n2, - n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, - n3, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n3, n4, n4, n4, n4, - n4, n4, n3, n1, n1, n1, n1, n1, n1, n1, n3, n4, n4, n4, n4, n4, n4, - n3, n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n1, - n1, n1, n1, n1, n1, n1, n3, n4, n4, n4, n4, n4, n4, n3, n1, n1, n1, - n1, n1, n1, n1, n3, n4, n4, n4, n4, n4, n4, n3, n1, n1, n1, n1, n1, - n1, n1, n5, n6, n6, n6, n6, n6, n6, n7, n1, n1, n1, n1, n1, n1, n1, - n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n1, n1, n1, n2, n2, - n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n1, n1, n1, n2, n2, n2, n2, - n2, n2, n2, n2, n1, n1, n1, n1, n1, n1, n1, n2, n2, n2, n2, n2, n2, - n2, n2, n1, n1, n1, n1, n1, n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, - n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, - n1, n1, n1, n1, n8, n4, n8, n8, n8, n8, n8, n8, n4, n1, n1, n1, n1, - n1, n1, n8, n4, n8, n8, n8, n8, n8, n8, n4, n1, n1, n1, n1, n1, n1, - n1, n3, n9, n9, n9, n9, n9, n9, n3, n1, n1, n1, n1, n1, n1, n1, n4, - n8, n8, n8, n8, n8, n8, n4, n1, n1, n1, n1, n1, n1, n1, n4, n8, n8, - n8, n8, n8, n8, n4, n1, n1, n1, n1, n1, n1, n1, n10, n9, n9, n9, n9, - n9, n9, n11, n12, n12, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, - n2, n2, n1, n12, n12, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, - n1, n1, n12, n12, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, - n1, n12, n12, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, - n12, n12, n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n1, - n12, n12, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, - n12, n3, n8, n8, n8, n8, n8, n8, n4, n1, n1, n1, n1, n1, n1, n8, n3, - n8, n8, n8, n8, n8, n8, n4, n1, n1, n1, n1, n1, n1, n1, n3, n9, n9, - n9, n9, n9, n9, n3, n1, n1, n1, n1, n1, n1, n1, n4, n8, n8, n8, n8, - n8, n8, n4, n1, n1, n1, n1, n1, n1, n1, n4, n8, n8, n8, n8, n8, n8, - n4, n1, n1, n1, n1, n1, n1, n1, n10, n9, n9, n9, n9, n9, n9, n11, n1, - n13, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n13, - n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n13, n2, - n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n13, n2, n2, - n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n1, n13, n2, n2, n2, - n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n1, n1, n13, n3, n3, n3, n3, - n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n8, n8, n8, n8, n8, n8, n8, - n8, n4, n1, n1, n1, n1, n1, n1, n8, n8, n8, n8, n8, n8, n8, n8, n4, - n1, n1, n1, n1, n1, n1, n1, n3, n9, n9, n9, n9, n9, n9, n3, n1, n1, - n1, n1, n1, n1, n1, n4, n8, n8, n8, n8, n8, n8, n4, n1, n1, n1, n1, - n1, n1, n1, n4, n8, n8, n8, n8, n8, n8, n4, n1, n1, n1, n1, n1, n1, - n1, n10, n9, n9, n9, n9, n9, n9, n11, n1, n13, n2, n2, n2, n2, n2, - n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n13, n2, n2, n2, n2, n2, n2, - n2, n2, n2, n2, n2, n2, n1, n1, n1, n13, n2, n2, n2, n2, n2, n2, n2, - n2, n2, n2, n2, n1, n1, n1, n1, n13, n2, n2, n2, n2, n2, n2, n2, n2, - n2, n2, n1, n1, n1, n1, n1, n13, n2, n2, n2, n2, n2, n2, n2, n2, n2, - n1, n1, n1, n1, n1, n1, n13, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, - n1, n1, n1, n1, n8, n8, n8, n8, n8, n8, n8, n8, n4, n1, n1, n1, n1, - n1, n1, n8, n8, n8, n8, n8, n8, n8, n8, n4, n1, n1, n1, n1, n1, n1, - n1, n3, n9, n9, n9, n9, n9, n9, n3, n1, n1, n1, n1, n1, n1, n1, n4, - n8, n8, n8, n8, n8, n8, n4, n1, n1, n1, n1, n1, n1, n1, n4, n8, n8, - n8, n8, n8, n8, n4, n1, n1, n1, n1, n1, n1, n1, n10, n9, n9, n9, n9, - n9, n9, n11, n12, n12, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, - n2, n2, n1, n12, n12, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, - n1, n1, n12, n12, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, - n1, n12, n12, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, - n12, n12, n12, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n1, - n12, n12, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, - n12, n3, n8, n8, n8, n8, n8, n8, n4, n1, n1, n1, n1, n1, n1, n8, n3, - n8, n8, n8, n8, n8, n8, n4, n1, n1, n1, n1, n1, n1, n1, n3, n9, n9, - n9, n9, n9, n9, n3, n1, n1, n1, n1, n1, n1, n1, n4, n8, n8, n8, n8, - n8, n8, n4, n1, n1, n1, n1, n1, n1, n1, n4, n8, n8, n8, n8, n8, n8, - n4, n1, n1, n1, n1, n1, n1, n1, n10, n9, n9, n9, n9, n9, n9, n11, n1, - n1, n1, n1, n1, n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, - n1, n1, n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n1, - n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n1, n1, n1, - n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n1, n1, n1, n2, n2, - n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, - n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n8, n4, n8, n8, n14, n11, n8, - n8, n4, n1, n1, n1, n1, n1, n1, n8, n4, n8, n14, n11, n8, n8, n8, n4, - n1, n1, n1, n1, n1, n1, n1, n3, n14, n11, n8, n8, n8, n9, n3, n1, n1, - n1, n1, n1, n1, n1, n4, n8, n8, n8, n8, n8, n8, n4, n1, n1, n1, n1, - n1, n1, n1, n4, n8, n8, n8, n8, n8, n8, n4, n1, n1, n1, n1, n1, n1, - n1, n10, n9, n9, n9, n9, n9, n9, n11, n1, n1, n1, n1, n1, n1, n1, n2, - n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n1, n1, n1, n2, n2, n2, - n2, n2, n2, n2, n2, n1, n1, n1, n1, n1, n1, n1, n2, n2, n2, n2, n2, - n2, n2, n2, n1, n1, n1, n1, n1, n1, n1, n2, n2, n2, n2, n2, n2, n2, - n2, n1, n1, n1, n1, n1, n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, n1, - n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, - n1, n1, n1, n1, n3, n4, n4, n4, n4, n4, n4, n3, n1, n1, n1, n1, n1, - n1, n1, n3, n4, n4, n4, n4, n4, n4, n3, n1, n1, n1, n1, n1, n1, n1, - n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n3, n4, - n4, n4, n4, n4, n4, n3, n1, n1, n1, n1, n1, n1, n1, n3, n4, n4, n4, - n4, n4, n4, n3, n1, n1, n1, n1, n1, n1, n1, n15, n16, n16, n16, n16, - n16, n16, n17, + n1, n1, n1, n1, n1, n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, + n1, n1, n1, n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, + n1, n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n1, n1, + n1, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n1, n1, n1, n2, + n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, + n3, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n3, n4, n4, n4, n4, + n4, n4, n3, n1, n1, n1, n1, n1, n1, n1, n3, n4, n4, n4, n4, n4, n4, + n3, n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n1, + n1, n1, n1, n1, n1, n1, n3, n4, n4, n4, n4, n4, n4, n3, n1, n1, n1, + n1, n1, n1, n1, n3, n4, n4, n4, n4, n4, n4, n3, n1, n1, n1, n1, n1, + n1, n1, n5, n6, n6, n6, n6, n6, n6, n7, n1, n1, n1, n1, n1, n1, n1, + n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n1, n1, n1, n2, n2, + n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n1, n1, n1, n2, n2, n2, n2, + n2, n2, n2, n2, n1, n1, n1, n1, n1, n1, n1, n2, n2, n2, n2, n2, n2, + n2, n2, n1, n1, n1, n1, n1, n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, + n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, + n1, n1, n1, n1, n8, n4, n8, n8, n8, n8, n8, n8, n4, n1, n1, n1, n1, + n1, n1, n8, n4, n8, n8, n8, n8, n8, n8, n4, n1, n1, n1, n1, n1, n1, + n1, n3, n9, n9, n9, n9, n9, n9, n3, n1, n1, n1, n1, n1, n1, n1, n4, + n8, n8, n8, n8, n8, n8, n4, n1, n1, n1, n1, n1, n1, n1, n4, n8, n8, + n8, n8, n8, n8, n4, n1, n1, n1, n1, n1, n1, n1, n10, n9, n9, n9, n9, + n9, n9, n11, n12, n12, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, + n2, n2, n1, n12, n12, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, + n1, n1, n12, n12, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, + n1, n12, n12, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, + n12, n12, n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n1, + n12, n12, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, + n12, n3, n8, n8, n8, n8, n8, n8, n4, n1, n1, n1, n1, n1, n1, n8, n3, + n8, n8, n8, n8, n8, n8, n4, n1, n1, n1, n1, n1, n1, n1, n3, n9, n9, + n9, n9, n9, n9, n3, n1, n1, n1, n1, n1, n1, n1, n4, n8, n8, n8, n8, + n8, n8, n4, n1, n1, n1, n1, n1, n1, n1, n4, n8, n8, n8, n8, n8, n8, + n4, n1, n1, n1, n1, n1, n1, n1, n10, n9, n9, n9, n9, n9, n9, n11, n1, + n13, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n13, + n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n13, n2, + n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n13, n2, n2, + n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n1, n13, n2, n2, n2, + n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n1, n1, n13, n3, n3, n3, n3, + n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n8, n8, n8, n8, n8, n8, n8, + n8, n4, n1, n1, n1, n1, n1, n1, n8, n8, n8, n8, n8, n8, n8, n8, n4, + n1, n1, n1, n1, n1, n1, n1, n3, n9, n9, n9, n9, n9, n9, n3, n1, n1, + n1, n1, n1, n1, n1, n4, n8, n8, n8, n8, n8, n8, n4, n1, n1, n1, n1, + n1, n1, n1, n4, n8, n8, n8, n8, n8, n8, n4, n1, n1, n1, n1, n1, n1, + n1, n10, n9, n9, n9, n9, n9, n9, n11, n1, n13, n2, n2, n2, n2, n2, + n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n13, n2, n2, n2, n2, n2, n2, + n2, n2, n2, n2, n2, n2, n1, n1, n1, n13, n2, n2, n2, n2, n2, n2, n2, + n2, n2, n2, n2, n1, n1, n1, n1, n13, n2, n2, n2, n2, n2, n2, n2, n2, + n2, n2, n1, n1, n1, n1, n1, n13, n2, n2, n2, n2, n2, n2, n2, n2, n2, + n1, n1, n1, n1, n1, n1, n13, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, + n1, n1, n1, n1, n8, n8, n8, n8, n8, n8, n8, n8, n4, n1, n1, n1, n1, + n1, n1, n8, n8, n8, n8, n8, n8, n8, n8, n4, n1, n1, n1, n1, n1, n1, + n1, n3, n9, n9, n9, n9, n9, n9, n3, n1, n1, n1, n1, n1, n1, n1, n4, + n8, n8, n8, n8, n8, n8, n4, n1, n1, n1, n1, n1, n1, n1, n4, n8, n8, + n8, n8, n8, n8, n4, n1, n1, n1, n1, n1, n1, n1, n10, n9, n9, n9, n9, + n9, n9, n11, n12, n12, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, + n2, n2, n1, n12, n12, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, + n1, n1, n12, n12, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, + n1, n12, n12, n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, + n12, n12, n12, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n1, + n12, n12, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, + n12, n3, n8, n8, n8, n8, n8, n8, n4, n1, n1, n1, n1, n1, n1, n8, n3, + n8, n8, n8, n8, n8, n8, n4, n1, n1, n1, n1, n1, n1, n1, n3, n9, n9, + n9, n9, n9, n9, n3, n1, n1, n1, n1, n1, n1, n1, n4, n8, n8, n8, n8, + n8, n8, n4, n1, n1, n1, n1, n1, n1, n1, n4, n8, n8, n8, n8, n8, n8, + n4, n1, n1, n1, n1, n1, n1, n1, n10, n9, n9, n9, n9, n9, n9, n11, n1, + n1, n1, n1, n1, n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, + n1, n1, n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n1, + n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n1, n1, n1, + n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n1, n1, n1, n2, n2, + n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, + n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n8, n4, n8, n8, n14, n11, n8, + n8, n4, n1, n1, n1, n1, n1, n1, n8, n4, n8, n14, n11, n8, n8, n8, n4, + n1, n1, n1, n1, n1, n1, n1, n3, n14, n11, n8, n8, n8, n9, n3, n1, n1, + n1, n1, n1, n1, n1, n4, n8, n8, n8, n8, n8, n8, n4, n1, n1, n1, n1, + n1, n1, n1, n4, n8, n8, n8, n8, n8, n8, n4, n1, n1, n1, n1, n1, n1, + n1, n10, n9, n9, n9, n9, n9, n9, n11, n1, n1, n1, n1, n1, n1, n1, n2, + n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n1, n1, n1, n2, n2, n2, + n2, n2, n2, n2, n2, n1, n1, n1, n1, n1, n1, n1, n2, n2, n2, n2, n2, + n2, n2, n2, n1, n1, n1, n1, n1, n1, n1, n2, n2, n2, n2, n2, n2, n2, + n2, n1, n1, n1, n1, n1, n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, n1, + n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, + n1, n1, n1, n1, n3, n4, n4, n4, n4, n4, n4, n3, n1, n1, n1, n1, n1, + n1, n1, n3, n4, n4, n4, n4, n4, n4, n3, n1, n1, n1, n1, n1, n1, n1, + n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n3, n4, + n4, n4, n4, n4, n4, n3, n1, n1, n1, n1, n1, n1, n1, n3, n4, n4, n4, + n4, n4, n4, n3, n1, n1, n1, n1, n1, n1, n1, n15, n16, n16, n16, n16, + n16, n16, n17, } } diff --git a/df_caverns/schematics/oubliette.lua b/df_caverns/schematics/oubliette.lua index 99c7d51..4e364ad 100644 --- a/df_caverns/schematics/oubliette.lua +++ b/df_caverns/schematics/oubliette.lua @@ -15,10 +15,10 @@ return { size = {x = 3, y = 9, z = 3}, center_pos = {x = 1, y = 7, z = 1}, data = { - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n2, n3, n4, n1, n1, n1, n1, n5, n1, n1, - n5, n1, n1, n5, n1, n1, n5, n1, n1, n5, n1, n1, n5, n1, n1, n6, n1, - n7, n5, n8, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n9, n10, n11, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n2, n3, n4, n1, n1, n1, n1, n5, n1, n1, + n5, n1, n1, n5, n1, n1, n5, n1, n1, n5, n1, n1, n5, n1, n1, n6, n1, + n7, n5, n8, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n9, n10, n11, }, } diff --git a/df_caverns/schematics/small_building.lua b/df_caverns/schematics/small_building.lua index a819b48..b82745b 100644 --- a/df_caverns/schematics/small_building.lua +++ b/df_caverns/schematics/small_building.lua @@ -27,48 +27,48 @@ return { size = {x = 11, y = 9, z = 7}, center_pos = {x = 7, y = 5, z = 3}, data = { - n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n2, n2, n2, n2, - n2, n2, n2, n2, n2, n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, - n1, n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n2, n2, n2, - n2, n2, n2, n2, n1, n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, - n1, n1, n3, n4, n4, n4, n4, n4, n3, n1, n1, n1, n1, n3, n4, n4, n4, - n4, n4, n3, n1, n1, n1, n1, n5, n6, n6, n6, n6, n6, n7, n1, n1, n2, - n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n2, n2, n2, n2, n2, n2, n2, - n2, n2, n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n8, n2, - n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n9, n2, n2, n2, n2, n2, n2, - n2, n1, n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, n10, n4, - n10, n10, n10, n10, n10, n4, n1, n1, n1, n10, n4, n10, n10, n10, n10, - n10, n4, n1, n1, n1, n1, n11, n12, n12, n12, n12, n12, n13, n1, n1, - n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n2, n2, n2, n2, n2, n2, - n2, n2, n2, n1, n1, n8, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, - n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n2, n2, n2, n2, n2, n2, - n2, n2, n1, n1, n1, n9, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, n10, - n3, n10, n10, n10, n10, n10, n4, n1, n1, n1, n10, n3, n10, n10, n10, - n10, n10, n4, n1, n1, n1, n1, n11, n12, n12, n12, n12, n12, n13, n14, - n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n14, n2, n2, n2, n2, n2, - n2, n2, n2, n2, n1, n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, - n1, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n2, n2, n2, n2, n2, - n2, n2, n2, n1, n1, n1, n2, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, - n10, n10, n10, n10, n10, n10, n18, n4, n1, n1, n1, n10, n10, n10, - n10, n10, n10, n10, n4, n1, n1, n1, n1, n11, n12, n12, n12, n12, n12, - n13, n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n2, n2, n2, - n2, n2, n2, n2, n2, n2, n1, n1, n9, n2, n2, n2, n2, n2, n2, n2, n2, - n1, n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n2, n2, n2, - n2, n2, n2, n2, n2, n1, n1, n1, n8, n3, n3, n3, n3, n3, n3, n3, n1, - n1, n1, n10, n3, n10, n10, n10, n10, n10, n4, n1, n1, n1, n10, n3, - n10, n10, n10, n10, n10, n4, n1, n1, n1, n1, n11, n12, n12, n12, n12, - n12, n13, n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n2, n2, - n2, n2, n2, n2, n2, n2, n2, n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, - n2, n1, n1, n9, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n8, n2, - n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, - n1, n1, n1, n10, n4, n10, n10, n10, n10, n10, n4, n1, n1, n1, n10, - n4, n10, n10, n10, n10, n10, n4, n1, n1, n1, n1, n11, n12, n12, n12, - n12, n12, n13, n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, - n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n2, n2, n2, n2, n2, n2, - n2, n2, n2, n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, - n1, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n3, n3, n3, n3, n3, - n3, n3, n1, n1, n1, n1, n3, n4, n4, n4, n4, n4, n3, n1, n1, n1, n1, - n3, n4, n4, n4, n4, n4, n3, n1, n1, n1, n1, n15, n16, n16, n16, n16, - n16, n17, + n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n2, n2, n2, n2, + n2, n2, n2, n2, n2, n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, + n1, n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n2, n2, n2, + n2, n2, n2, n2, n1, n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, + n1, n1, n3, n4, n4, n4, n4, n4, n3, n1, n1, n1, n1, n3, n4, n4, n4, + n4, n4, n3, n1, n1, n1, n1, n5, n6, n6, n6, n6, n6, n7, n1, n1, n2, + n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n2, n2, n2, n2, n2, n2, n2, + n2, n2, n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n8, n2, + n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n9, n2, n2, n2, n2, n2, n2, + n2, n1, n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, n10, n4, + n10, n10, n10, n10, n10, n4, n1, n1, n1, n10, n4, n10, n10, n10, n10, + n10, n4, n1, n1, n1, n1, n11, n12, n12, n12, n12, n12, n13, n1, n1, + n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n2, n2, n2, n2, n2, n2, + n2, n2, n2, n1, n1, n8, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, + n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n2, n2, n2, n2, n2, n2, + n2, n2, n1, n1, n1, n9, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, n10, + n3, n10, n10, n10, n10, n10, n4, n1, n1, n1, n10, n3, n10, n10, n10, + n10, n10, n4, n1, n1, n1, n1, n11, n12, n12, n12, n12, n12, n13, n14, + n2, n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n14, n2, n2, n2, n2, n2, + n2, n2, n2, n2, n1, n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, + n1, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n2, n2, n2, n2, n2, + n2, n2, n2, n1, n1, n1, n2, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, + n10, n10, n10, n10, n10, n10, n18, n4, n1, n1, n1, n10, n10, n10, + n10, n10, n10, n10, n4, n1, n1, n1, n1, n11, n12, n12, n12, n12, n12, + n13, n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n2, n2, n2, + n2, n2, n2, n2, n2, n2, n1, n1, n9, n2, n2, n2, n2, n2, n2, n2, n2, + n1, n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n2, n2, n2, + n2, n2, n2, n2, n2, n1, n1, n1, n8, n3, n3, n3, n3, n3, n3, n3, n1, + n1, n1, n10, n3, n10, n10, n10, n10, n10, n4, n1, n1, n1, n10, n3, + n10, n10, n10, n10, n10, n4, n1, n1, n1, n1, n11, n12, n12, n12, n12, + n12, n13, n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n2, n2, + n2, n2, n2, n2, n2, n2, n2, n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, + n2, n1, n1, n9, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n8, n2, + n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, + n1, n1, n1, n10, n4, n10, n10, n10, n10, n10, n4, n1, n1, n1, n10, + n4, n10, n10, n10, n10, n10, n4, n1, n1, n1, n1, n11, n12, n12, n12, + n12, n12, n13, n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, + n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n2, n2, n2, n2, n2, n2, + n2, n2, n2, n1, n1, n2, n2, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, + n1, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, n1, n3, n3, n3, n3, n3, + n3, n3, n1, n1, n1, n1, n3, n4, n4, n4, n4, n4, n3, n1, n1, n1, n1, + n3, n4, n4, n4, n4, n4, n3, n1, n1, n1, n1, n15, n16, n16, n16, n16, + n16, n17, } } diff --git a/df_caverns/schematics/small_slab.lua b/df_caverns/schematics/small_slab.lua index 91c46c4..3db9708 100644 --- a/df_caverns/schematics/small_slab.lua +++ b/df_caverns/schematics/small_slab.lua @@ -11,6 +11,6 @@ return { size = {y = 2, x = 2, z = 3}, center_pos = {x = 1, y = 1, z = 1}, data = { - n1, n1, n2, n3, n1, n1, n4, n4, n1, n1, n5, n6, + n1, n1, n2, n3, n1, n1, n4, n4, n1, n1, n5, n6, } } \ No newline at end of file diff --git a/df_caverns/shared.lua b/df_caverns/shared.lua index 18c9050..42fa440 100644 --- a/df_caverns/shared.lua +++ b/df_caverns/shared.lua @@ -84,15 +84,15 @@ df_caverns.stalagmites = function(abs_cracks, vert_rand, vi, area, data, data_pa stalagmite_ids = df_mapitems.wet_stalagmite_ids else flowstone = c_dry_flowstone - stalagmite_ids = df_mapitems.dry_stalagmite_ids + stalagmite_ids = df_mapitems.dry_stalagmite_ids end - + local height_mult = 1 local ystride = area.ystride if reverse_sign then ystride = - ystride height_mult = -1 - end + end if vert_rand < 0.004 then if reverse_sign then @@ -132,14 +132,14 @@ df_caverns.flooded_cavern_floor = function(abs_cracks, vert_rand, vi, area, data data[vi] = c_sand_scum end end - + -- put in only the large stalagmites that won't get in the way of the water if abs_cracks < 0.1 then if vert_rand < 0.004 then subterrane.big_stalagmite(vi+ystride, area, data, 6, 15, c_wet_flowstone, c_wet_flowstone, c_wet_flowstone) end end - + end df_caverns.dry_cavern_floor = function(abs_cracks, vert_rand, vi, area, data, data_param2) @@ -198,7 +198,7 @@ df_caverns.tunnel_floor = function(minp, maxp, area, vi, nvals_cracks, data, dat subterrane.stalagmite(vi+ystride, area, data, data_param2, param2, height, df_mapitems.wet_stalagmite_ids) data[vi] = c_wet_flowstone elseif dirt_node and abs_cracks > 0.5 and data[vi-ystride] ~= c_air then - data[vi] = dirt_node + data[vi] = dirt_node end else if abs_cracks < 0.025 and data[vi+ystride] == c_air and not dont_build_speleothems_on[data[vi]] then -- make sure data[vi] is not already flowstone. Stalagmites from lower levels are acting as base for further stalagmites @@ -220,7 +220,7 @@ df_caverns.tunnel_ceiling = function(minp, maxp, area, vi, nvals_cracks, data, d local index2d = mapgen_helper.index2di(minp, maxp, area, vi) local cracks = nvals_cracks[index2d] local abs_cracks = math.abs(cracks) - + if wet then if abs_cracks < 0.05 and data[vi-ystride] == c_air and not dont_build_speleothems_on[data[vi]] then -- make sure data[vi] is not already flowstone. Stalagmites from lower levels are acting as base for further stalagmites local param2 = abs_cracks*1000000 - math.floor(abs_cracks*1000000/4)*4 @@ -272,7 +272,7 @@ df_caverns.place_shrub = function(vi, area, data, param2_data, shrub_list) if shrub_list == nil then return end - + local shrub = shrub_list[math.random(#shrub_list)] shrub(vi, area, data, param2_data) end diff --git a/df_caverns/sunless_sea.lua b/df_caverns/sunless_sea.lua index 607d91f..b5bd646 100644 --- a/df_caverns/sunless_sea.lua +++ b/df_caverns/sunless_sea.lua @@ -199,22 +199,22 @@ local decorate_sunless_sea = function(minp, maxp, seed, vm, node_arrays, area, d local minp_below = minp.y <= sea_level local maxp_above = maxp.y > sea_level - + local nvals_cave = mapgen_helper.perlin2d("df_caverns:sunless_sea", minp, maxp, perlin_cave_rivers) --cave noise for structure local nvals_wave = mapgen_helper.perlin2d("df_caverns:sunless_sea_wave", minp, maxp, perlin_wave_rivers) --cave noise for structure - + local skip_next = false -- mapgen is proceeding upward on the y axis, --if this is true it skips a step to allow for things to be placed above the floor - + -- creates "river" caverns for vi, x, y, z in area:iterp_yxz(minp, maxp) do - if not skip_next then + if not skip_next then if y < y_max_river and y > y_min_river then local index2d = mapgen_helper.index2d(minp, maxp, x, z) local abs_cave = math.abs(nvals_cave[index2d]) local wave = nvals_wave[index2d] * wave_mult local cracks = nvals_cracks[index2d] - + local ripple = cracks * ((y - y_min_river) / (y_max_river - y_min_river)) * ripple_mult -- above floor and below ceiling @@ -225,7 +225,7 @@ local decorate_sunless_sea = function(minp, maxp, seed, vm, node_arrays, area, d if y <= floor_height and y > floor_height - 3 and y < sea_level + 5 and data[vi] == c_lava then data[vi] = c_obsidian end - + if y == floor_height and y < sea_level and not mapgen_helper.buildable_to(data[vi]) then if cracks > 0.2 then data[vi] = c_sand @@ -243,7 +243,7 @@ local decorate_sunless_sea = function(minp, maxp, seed, vm, node_arrays, area, d df_caverns.glow_worm_cavern_ceiling(math.abs(cracks), mapgen_helper.xz_consistent_randomi(area, vi), vi, area, data, data_param2) end - + -- Deal with lava if y >= ceiling_height and y < ceiling_height + 5 and y > sea_level - 5 and data[vi] == c_lava then data[vi] = c_obsidian @@ -253,7 +253,7 @@ local decorate_sunless_sea = function(minp, maxp, seed, vm, node_arrays, area, d skip_next = false end end - + if minp.y <= sea_level then for vi, x, y, z in area:iterp_yxz(area.MinEdge, area.MaxEdge) do -- convert all air below sea level into water @@ -263,10 +263,10 @@ local decorate_sunless_sea = function(minp, maxp, seed, vm, node_arrays, area, d end end - + --------------------------------------------------------- -- Cavern floors - + for _, vi in ipairs(node_arrays.cavern_floor_nodes) do local index2d = mapgen_helper.index2di(minp, maxp, area, vi) local heat = heatmap[index2d] @@ -274,7 +274,7 @@ local decorate_sunless_sea = function(minp, maxp, seed, vm, node_arrays, area, d local abs_cracks = math.abs(cracks) local vert_rand = mapgen_helper.xz_consistent_randomi(area, vi) local y = area:get_y(vi) - + -- The vertically squished aspect of these caverns produces too many very thin shelves, this blunts them if mapgen_helper.buildable_to(data[vi-area.ystride]) then if y <= sea_level then @@ -282,8 +282,8 @@ local decorate_sunless_sea = function(minp, maxp, seed, vm, node_arrays, area, d else data[vi] = c_air end - end - + end + -- extra test is needed because the rivers can remove nodes that Subterrane marked as floor. if not mapgen_helper.buildable_to(data[vi]) then if y >= sea_level then @@ -317,7 +317,7 @@ local decorate_sunless_sea = function(minp, maxp, seed, vm, node_arrays, area, d end end end - + -------------------------------------- -- Cavern ceilings @@ -328,7 +328,7 @@ local decorate_sunless_sea = function(minp, maxp, seed, vm, node_arrays, area, d local abs_cracks = math.abs(cracks) local vert_rand = mapgen_helper.xz_consistent_randomi(area, vi) local y = area:get_y(vi) - + if y > sea_level and not mapgen_helper.buildable_to(data[vi]) then if heat > hot_zone_boundary then hot_zone_ceiling(abs_cracks, vert_rand, vi, area, data, data_param2) @@ -340,19 +340,19 @@ local decorate_sunless_sea = function(minp, maxp, seed, vm, node_arrays, area, d end end - + ---------------------------------------------- -- Tunnel floors - + for _, vi in ipairs(node_arrays.tunnel_floor_nodes) do if area:get_y(vi) >= sea_level and not mapgen_helper.buildable_to(data[vi]) then df_caverns.tunnel_floor(minp, maxp, area, vi, nvals_cracks, data, data_param2, true) end end - + ------------------------------------------------------ -- Tunnel ceiling - + for _, vi in ipairs(node_arrays.tunnel_ceiling_nodes) do if area:get_y(vi) > sea_level and not mapgen_helper.buildable_to(data[vi]) then df_caverns.tunnel_ceiling(minp, maxp, area, vi, nvals_cracks, data, data_param2, true) @@ -366,10 +366,10 @@ local decorate_sunless_sea = function(minp, maxp, seed, vm, node_arrays, area, d if cracks > 0.8 and data[vi-ystride*2] == c_water then data[vi-ystride*2] = c_air end - end + end end end - + ------------------------------------------------------ -- Warren ceiling @@ -386,13 +386,13 @@ local decorate_sunless_sea = function(minp, maxp, seed, vm, node_arrays, area, d if cracks > 0.8 and data[vi-ystride*2] == c_water then data[vi-ystride*2] = c_air end - end + end end end ---------------------------------------------- -- Warren floors - + for _, vi in ipairs(node_arrays.warren_floor_nodes) do if area:get_y(vi) >= sea_level and not mapgen_helper.buildable_to(data[vi]) then df_caverns.tunnel_floor(minp, maxp, area, vi, nvals_cracks, data, data_param2, true) @@ -414,7 +414,7 @@ local decorate_sunless_sea = function(minp, maxp, seed, vm, node_arrays, area, d data_param2[vi] = math.random(1,4)-1 minetest.get_node_timer(area:position(vi)):start(math.random(10, 60)) end - + if chasms_path then local pos = area:position(vi) if chasms.is_in_chasm(pos) then diff --git a/df_caverns/surface_tunnels.lua b/df_caverns/surface_tunnels.lua index 0335748..1e358bf 100644 --- a/df_caverns/surface_tunnels.lua +++ b/df_caverns/surface_tunnels.lua @@ -10,8 +10,8 @@ minetest.register_on_generated(function(minp, maxp, seed) --if out of range of cave definition limits, abort if minp.y > y_max or maxp.y < y_min then return - end - + end + local t_start = os.clock() local vm, data, data_param2, area = mapgen_helper.mapgen_vm_data_param2() @@ -21,18 +21,18 @@ minetest.register_on_generated(function(minp, maxp, seed) local emaxp = {x=maxp.x, y=area.MaxEdge.y, z=maxp.z} local minp_y = minp.y local maxp_y = maxp.y - + local humiditymap = minetest.get_mapgen_object("humiditymap") local nvals_cracks = mapgen_helper.perlin2d("df_cavern:cracks", minp, maxp, df_caverns.np_cracks) local previous_y = eminp.y-1 - + local previous_potential_floor_vi local previous_potential_floor_y local previous_node - + for vi, x, y, z in area:iterp_yxz(eminp, emaxp) do - + if y < previous_y then -- we've started a new column, initialize everything previous_potential_floor_vi = nil @@ -40,7 +40,7 @@ minetest.register_on_generated(function(minp, maxp, seed) previous_node = nil end previous_y = y - + local current_node = data[vi] if previous_node and y < y_max then if current_node == c_air and previous_node == c_stone then @@ -66,9 +66,9 @@ minetest.register_on_generated(function(minp, maxp, seed) end end previous_node = current_node - + end - + if data_changed then --send data back to voxelmanip vm:set_data(data) @@ -76,12 +76,12 @@ minetest.register_on_generated(function(minp, maxp, seed) --calc lighting vm:set_lighting({day = 0, night = 0}) vm:calc_lighting() - + vm:update_liquids() --write it to world vm:write_to_map() end - + local time_taken = os.clock() - t_start -- how long this chunk took, in seconds mapgen_helper.record_time("df_caverns surface tunnels", time_taken) end) diff --git a/df_caverns/underworld.lua b/df_caverns/underworld.lua index bdd32f0..0c782c7 100644 --- a/df_caverns/underworld.lua +++ b/df_caverns/underworld.lua @@ -38,7 +38,7 @@ if named_waypoints_path then local setting_item_required = minetest.settings:get("dfcaverns_underworld_hud_item_required") if setting_item_required == nil or setting_item_required == "" then setting_item_required = "map:mapping_kit" - end + end item_required = setting_item_required end @@ -47,8 +47,8 @@ if named_waypoints_path then default_color = 0xFF88FF, discovery_volume_radius = tonumber(minetest.settings:get("dfcaverns_pit_discovery_range")) or 60, visibility_requires_item = item_required, - } - + } + if minetest.settings:get_bool("dfcaverns_show_pits_in_hud", true) then pit_waypoint_def.visibility_volume_radius = tonumber(minetest.settings:get("dfcaverns_pit_visibility_range")) or 500 pit_waypoint_def.on_discovery = named_waypoints.default_discovery_popup @@ -70,14 +70,14 @@ if named_waypoints_path then if name_generator_path then name_generator.parse_lines(io.lines(modpath.."/underworld_names.cfg")) - + name_pit = function() return name_generator.generate("glowing_pits") end name_ruin = function() return name_generator.generate("underworld_ruins") end - + local underworld_ruin_def = { default_name = S("Ancient ruin"), discovery_volume_radius = tonumber(minetest.settings:get("dfcaverns_ruin_discovery_range")) or 40, @@ -171,10 +171,10 @@ local get_buildings = function(emin, emax, nvals_zone) local buildings = {} for x = emin.x, emax.x do for z = emin.z, emax.z do - + local index2d = mapgen_helper.index2d(emin, emax, x, z) local zone = math.abs(nvals_zone[index2d]) - + if zone > oubliette_threshold and zone < town_threshold then -- oubliette zone --zone = (zone - oubliette_threshold)/(town_threshold-oubliette_threshold) -- turn this into a 0-1 spread @@ -195,7 +195,7 @@ local get_buildings = function(emin, emax, nvals_zone) building_type = building_type, bounding_box = {minpos={x=x-2, z=z-2}, maxpos={x=x+2, z=z+2}}, priority = math.floor(building_val * 10000000) % 1000, -- indended to allow for deterministic removal of overlapping buildings - } + } ) end elseif zone > town_threshold then @@ -203,12 +203,12 @@ local get_buildings = function(emin, emax, nvals_zone) local building_val = local_random(x, z) if building_val > 0.9925 then building_val = (building_val - 0.9925)/0.0075 - + local building_type local bounding_box local priority = math.floor(building_val * 10000000) % 1000 local rotation = (priority % 4) * 90 - + if building_val < 0.75 then building_type = "small building" local boundmin, boundmax = mapgen_helper.get_schematic_bounding_box({x=x, y=0, z=z}, small_building_schematic, rotation) @@ -216,13 +216,13 @@ local get_buildings = function(emin, emax, nvals_zone) elseif building_val < 0.85 then building_type = "medium building" local boundmin, boundmax = mapgen_helper.get_schematic_bounding_box({x=x, y=0, z=z}, medium_building_schematic, rotation) - bounding_box = {minpos=boundmin, maxpos=boundmax} + bounding_box = {minpos=boundmin, maxpos=boundmax} else building_type = "small slab" local boundmin, boundmax = mapgen_helper.get_schematic_bounding_box({x=x, y=0, z=z}, small_slab_schematic, rotation) - bounding_box = {minpos=boundmin, maxpos=boundmax} + bounding_box = {minpos=boundmin, maxpos=boundmax} end - + table.insert(buildings, { pos = {x=x, y=0, z=z}, -- y to be determined later @@ -236,7 +236,7 @@ local get_buildings = function(emin, emax, nvals_zone) end end end - + -- eliminate overlapping buildings local building_count = table.getn(buildings) local overlap_count = 0 @@ -249,7 +249,7 @@ local get_buildings = function(emin, emax, nvals_zone) curr_building.bounding_box.maxpos, test_building.bounding_box.minpos, test_building.bounding_box.maxpos) then - + if curr_building.priority < test_building.priority then -- this makes elimination of overlapping buildings deterministic buildings[i] = nil j=building_count+1 @@ -260,19 +260,19 @@ local get_buildings = function(emin, emax, nvals_zone) end end end - + if building_count > 50 and overlap_count > building_count * 2/3 then minetest.log("warning", "[df_caverns] underworld mapgen generated " .. tostring(building_count) .. " buildings and " .. tostring(overlap_count) .. " were eliminated as overlapping, if this happens a lot consider reducing building" .. " generation probability to improve efficiency.") end - + local compacted_buildings = {} for _, building in pairs(buildings) do compacted_buildings[minetest.hash_node_position(building.pos)] = building end - + return compacted_buildings end @@ -314,7 +314,7 @@ local get_pit = function(pos) local variance_multiplier = math.random() local radius = variance_multiplier * (radius_pit_max - 15) + 15 local variance = radius_pit_variance/2 + radius_pit_variance*variance_multiplier/2 - local depth = math.random(plasma_depth_min, plasma_depth_max) + local depth = math.random(plasma_depth_min, plasma_depth_max) math.randomseed(next_seed) return {location = location, radius = radius, variance = variance, depth = depth} end @@ -364,27 +364,27 @@ minetest.register_on_generated(function(minp, maxp, seed) local vm, data, data_param2, area = mapgen_helper.mapgen_vm_data_param2() local emin = area.MinEdge local emax = area.MaxEdge - + local nvals_cave = mapgen_helper.perlin2d("df_caverns:underworld_cave", emin, emax, perlin_cave) --cave noise for structure local nvals_wave = mapgen_helper.perlin2d("df_caverns:underworld_wave", emin, emax, perlin_wave) --cave noise for structure local nvals_zone = mapgen_helper.perlin2d("df_caverns:underworld_zone", emin, emax, perlin_zone) --building zones - + local pit = get_pit(minp) --minetest.chat_send_all(minetest.pos_to_string(pit.location)) local buildings = get_buildings(emin, emax, nvals_zone) - + local pit_uninitialized = true local nvals_pit, area_pit - + for vi, x, y, z in area:iterp_yxz(minp, maxp) do if y > y_min then local index2d = mapgen_helper.index2d(emin, emax, x, z) local abs_cave = math.abs(nvals_cave[index2d]) -- range is from 0 to approximately 2, with 0 being connected and 2s being islands local wave = nvals_wave[index2d] * wave_mult - + local floor_height = math.floor(abs_cave * floor_mult + median + floor_displace + wave) - + if named_waypoints_path and floor_height == y and pit and pit.location.x == x and pit.location.z == z then named_waypoints.add_waypoint("glowing_pits", {x=x, y=y, z=z}, {name=name_pit()}) end @@ -393,7 +393,7 @@ minetest.register_on_generated(function(minp, maxp, seed) local ceiling_height = math.floor(abs_cave * ceiling_mult + median + ceiling_displace + wave) if (y == underside_height or y == underside_height - 1) and (x % 8 == 0 or z % 8 == 0) then data[vi] = c_air - elseif y < floor_height and y > underside_height then + elseif y < floor_height and y > underside_height then data[vi] = c_slade if pit and pit.location.x - radius_pit_max - radius_pit_variance < maxp.x and @@ -439,7 +439,7 @@ minetest.register_on_generated(function(minp, maxp, seed) local wave = nvals_wave[index2d] * wave_mult local floor_height = math.floor(abs_cave * floor_mult + median + floor_displace + wave) local ceiling_height = math.floor(abs_cave * ceiling_mult + median + ceiling_displace + wave) - + if ceiling_height > floor_height + 5 and ceiling_height < maxp.y and ceiling_height > minp.y then local vi = area:index(x, ceiling_height, z) if ( @@ -457,7 +457,7 @@ minetest.register_on_generated(function(minp, maxp, seed) -- buildings for x = emin.x + 5, emax.x - 5 do for z = emin.z + 5, emax.z - 5 do - + local skip = false if pit and pit.location.x - radius_pit_max - radius_pit_variance < x and @@ -476,7 +476,7 @@ minetest.register_on_generated(function(minp, maxp, seed) local wave = nvals_wave[index2d] * wave_mult local floor_height = math.floor(abs_cave * floor_mult + median + floor_displace + wave) local ceiling_height = math.floor(abs_cave * ceiling_mult + median + ceiling_displace + wave) - + if ceiling_height > floor_height and floor_height <= maxp.y and floor_height >= minp.y then local building = buildings[minetest.hash_node_position({x=x,y=0,z=z})] if building ~= nil then @@ -506,7 +506,7 @@ minetest.register_on_generated(function(minp, maxp, seed) local def = minetest.registered_nodes["df_underworld_items:puzzle_chest_closed"] def.can_dig(puzzle_chest) -- initializes the inventory df_caverns.populate_puzzle_chest(puzzle_chest) - end + end end) elseif building.building_type == "medium building" then mapgen_helper.place_schematic_on_data(data, data_param2, area, building.pos, medium_building_schematic, building.rotation) @@ -522,18 +522,18 @@ minetest.register_on_generated(function(minp, maxp, seed) minetest.log("error", "unrecognized underworld building type: " .. tostring(building.building_type)) end end - end + end end end end - + -- puzzle seal - local puzzle_seal = nil + local puzzle_seal = nil if pit_uninitialized and math.random() < 0.05 then local index2d = mapgen_helper.index2d(emin, emax, minp.x + 3, minp.z + 3) local abs_cave = math.abs(nvals_cave[index2d]) -- range is from 0 to approximately 2, with 0 being connected and 2s being islands local wave = nvals_wave[index2d] * wave_mult - + local floor_height = math.floor(abs_cave * floor_mult + median + floor_displace + wave) local underside_height = math.floor(y_min + math.abs(wave) / 5) @@ -556,7 +556,7 @@ minetest.register_on_generated(function(minp, maxp, seed) vm:update_liquids() --write it to world vm:write_to_map() - + if puzzle_seal ~= nil then if named_waypoints_path then named_waypoints.add_waypoint("puzzle_seals", puzzle_seal) @@ -567,7 +567,7 @@ minetest.register_on_generated(function(minp, maxp, seed) local node_def = minetest.registered_nodes[node_name] node_def.on_construct(puzzle_seal) end - + if bones_loot_path then for i = 1, 30 do local x = math.random(minp.x, maxp.x) @@ -601,7 +601,7 @@ minetest.register_on_generated(function(minp, maxp, seed) end end end - + if hunters_enabled then local x = math.random(minp.x, maxp.x) local z = math.random(minp.z, maxp.z) @@ -620,9 +620,9 @@ minetest.register_on_generated(function(minp, maxp, seed) end end end - + end - + local time_taken = os.clock() - t_start -- how long this chunk took, in seconds mapgen_helper.record_time("df_caverns underworld", time_taken) end) diff --git a/df_dependencies/config.lua b/df_dependencies/config.lua index f3a484f..338793d 100644 --- a/df_dependencies/config.lua +++ b/df_dependencies/config.lua @@ -19,10 +19,10 @@ local function setting(stype, name, default, description) value = default end config[name] = value - + if print_settingtypes then minetest.debug(CONFIG_FILE_PREFIX..name.." ("..description..") "..stype.." "..tostring(default)) - end + end end --Caverns diff --git a/df_dependencies/helper_functions.lua b/df_dependencies/helper_functions.lua index ffc8bfa..9b1681a 100644 --- a/df_dependencies/helper_functions.lua +++ b/df_dependencies/helper_functions.lua @@ -55,7 +55,7 @@ local node_name_to_stair_properties = function(name, override_def) local node_def = minetest.registered_nodes[mod..":"..name] override_def = override_def or {} - + local node_copy = deep_copy(node_def) for index, value in pairs(override_def) do node_copy[index] = value @@ -98,11 +98,11 @@ df_dependencies.register_all_fences = function (name, override_def) local mod, node_def = node_name_to_stair_properties(name, override_def) override_def = override_def or {} - + local material = override_def.material or mod..":"..name local burntime = override_def.burntime local texture = override_def.texture or node_def.tiles[1] - + if minetest.get_modpath("default") then if default.register_fence then default.register_fence(material .. "_fence", { @@ -120,7 +120,7 @@ df_dependencies.register_all_fences = function (name, override_def) }) end end - + if default.register_fence_rail then default.register_fence_rail(material .. "_fence_rail", { description = S("@1 Fence Rail", node_def.description), @@ -148,7 +148,7 @@ df_dependencies.register_all_fences = function (name, override_def) }) end end - + if minetest.get_modpath("doors") and doors.register_fencegate then doors.register_fencegate(material .. "_fence_gate", { description = S("@1 Fence Gate", node_def.description), @@ -157,7 +157,7 @@ df_dependencies.register_all_fences = function (name, override_def) groups = deep_copy(node_def.groups or {}), -- the default register_fence_rail function modifies the groups table passed in, so send a copy instead to be on the safe side. sounds = node_def.sounds }) - + if burntime then minetest.register_craft({ type = "fuel", @@ -166,11 +166,11 @@ df_dependencies.register_all_fences = function (name, override_def) }) end end - + if minetest.get_modpath("mcl_fences") and mcl_fences.register_fence_and_fence_gate then local groups = deep_copy(node_def.groups or {}) groups.fence_wood = 1 - mcl_fences.register_fence_and_fence_gate(name .. "_fence", + mcl_fences.register_fence_and_fence_gate(name .. "_fence", S("@1 Fence", node_def.description), S("@1 Fence Gate", node_def.description), texture, @@ -205,7 +205,7 @@ df_dependencies.get_itemslot_bg = function(X,Y,W,H) return "" end df_dependencies.get_itemslot_bg_padded = function(X,Y,W,H) return "" end if minetest.get_modpath("mcl_formspec") then df_dependencies.get_itemslot_bg = mcl_formspec.get_itemslot_bg - + df_dependencies.get_itemslot_bg_padded = function(x,y,w,h, padding) local out = "" for i = 0, w - 1, 1 do diff --git a/df_dependencies/mapgen.lua b/df_dependencies/mapgen.lua index f6f2d1a..40c99b8 100644 --- a/df_dependencies/mapgen.lua +++ b/df_dependencies/mapgen.lua @@ -48,7 +48,7 @@ local extend_ores = function() local wherein_stonelike = {"mcl_core:stone"} local localseed = 12345 - + local stone_blobs = { wherein = wherein_stonelike, clust_scarcity = 1000, @@ -72,7 +72,7 @@ local extend_ores = function() scale = 1 }, } - + local register_blob = function(ore, cluster_size, cluster_scarcity_cuberoot, ymin, ymax) localseed = localseed + 1 -- increment this every time it's called to ensure different distributions local blob_copy = deep_copy(stone_blobs) @@ -157,21 +157,21 @@ local extend_ores = function() register_blob("mcl_core:stone_with_coal", 80, 10, config.oil_sea_level-200, config.oil_sea_level+200) -- tons of coal in the oil sea end end - + if ores_registered["mcl_core:stone_with_lapis"] then register_scattered("mcl_core:stone_with_lapis", 3, 25, config.sunless_sea_min, config.level3_min) -- Lapis is an ocean gem, I decided if config.enable_primordial then register_scattered("mcl_core:stone_with_lapis", 3, 25, config.primordial_min, config.primordial_max) end end - + if ores_registered["mcl_core:stone_with_redstone"] then register_scattered("mcl_core:stone_with_redstone", 3, 15, config.level3_min, config.level2_min) -- Level 3 is the most magical, scatter redstone there if config.enable_lava_sea then register_scattered("mcl_core:stone_with_redstone", 4, 15, config.lava_sea_level-200, config.lava_sea_level+100) -- and of course plenty of redstone in the lava sea end end - + if ores_registered["mcl_core:stone_with_diamond"] then register_scattered("mcl_core:stone_with_diamond", 2, 18, config.sunless_sea_min, config.level2_min) if config.enable_oil_sea then @@ -181,7 +181,7 @@ local extend_ores = function() register_scattered("mcl_core:stone_with_diamond", 3, 15, config.primordial_min, config.primordial_max) end end - + if ores_registered["mcl_core:stone_with_gold"] then register_scattered("mcl_core:stone_with_gold", 2, 18) if config.enable_primordial then @@ -210,9 +210,9 @@ local extend_ores = function() end if minetest.get_modpath("mcl_init") then -- Mineclone 2 - + old_overworld_min = mcl_vars.mg_overworld_min -- remember this for weather control - + mcl_vars.mg_overworld_min = lowest_elevation mcl_vars.mg_bedrock_overworld_min = mcl_vars.mg_overworld_min mcl_vars.mg_lava_overworld_max = mcl_vars.mg_overworld_min + 10 @@ -229,7 +229,7 @@ if minetest.get_modpath("mcl_init") then -- Mineclone 2 --if minetest.get_modpath("mcl_structures") and minetest.get_modpath("mcl_strongholds") then -- local elevation_delta = old_overworld_min - lowest_elevation -- local strongholds = mcl_structures.get_structure_data("stronghold") - -- mcl_structures.register_structure_data("stronghold", strongholds) + -- mcl_structures.register_structure_data("stronghold", strongholds) --end end if minetest.get_modpath("mcl_compatibility") then -- Mineclone 5 @@ -253,7 +253,7 @@ if minetest.get_modpath("mcl_mapgen") then -- Mineclone 5 mcl_mapgen.overworld.lava_max = mcl_mapgen.overworld.min+6 mcl_mapgen.overworld.railcorridors_height_min = -50 mcl_mapgen.overworld.railcorridors_height_max = -2 - + mcl_mapgen.end_.max = mcl_mapgen.overworld.min - 2000 mcl_mapgen.realm_barrier_overworld_end_max = mcl_mapgen.end_.max mcl_mapgen.realm_barrier_overworld_end_min = mcl_mapgen.end_.max - 11 @@ -265,7 +265,7 @@ if minetest.get_modpath("mcl_mapgen") then -- Mineclone 5 .."does not have an mcl_mapgen.on_settings_changed method. This will likely result in " .."altitudes below the original bedrock being inaccessible to players.") end - + extend_ores() end if minetest.get_modpath("mcl_worlds") then diff --git a/df_dependencies/nodes.lua b/df_dependencies/nodes.lua index b40b442..adc4297 100644 --- a/df_dependencies/nodes.lua +++ b/df_dependencies/nodes.lua @@ -32,7 +32,7 @@ minetest.after(0, function() table.insert(problem_nodes, node_name) end end - + assert(#problem_nodes == 0, "Nodes " .. table.concat(problem_nodes, ", ") .. " were returned by a selection call but are not registered.") end) diff --git a/df_farming/cave_wheat.lua b/df_farming/cave_wheat.lua index 3040c4a..89972ae 100644 --- a/df_farming/cave_wheat.lua +++ b/df_farming/cave_wheat.lua @@ -30,7 +30,7 @@ local register_cave_wheat = function(number) on_timer = function(pos, elapsed) df_farming.grow_underground_plant(pos, name, elapsed) end, - + drop = { max_items = 1, items = { @@ -48,11 +48,11 @@ local register_cave_wheat = function(number) }, }, }, - + _mcl_blast_resistance = 0.2, _mcl_hardness = 0.2, } - + if number < 8 then def._dfcaverns_next_stage_time = wheat_grow_time def._dfcaverns_next_stage = "df_farming:cave_wheat_"..tostring(number+1) @@ -215,7 +215,7 @@ if minetest.get_modpath("footprints") then _mcl_blast_resistance = 0.5, _mcl_hardness = 0.5, }) - + footprints.register_trample_node("df_farming:cave_wheat_5", { trampled_node_name = "df_farming:wheat_trampled", randomize_trampled_param2 = true, diff --git a/df_farming/config.lua b/df_farming/config.lua index b0223cc..dd23fd6 100644 --- a/df_farming/config.lua +++ b/df_farming/config.lua @@ -17,10 +17,10 @@ local function setting(stype, name, default, description) value = default end df_farming.config[name] = value - + if print_settingtypes then minetest.debug(CONFIG_FILE_PREFIX..name.." ("..description..") "..stype.." "..tostring(default)) - end + end end local plants = { diff --git a/df_farming/dimple_cup.lua b/df_farming/dimple_cup.lua index 71adedd..d291557 100644 --- a/df_farming/dimple_cup.lua +++ b/df_farming/dimple_cup.lua @@ -26,11 +26,11 @@ local register_dimple_cup = function(number) {-8/16, -8/16, -8/16, 8/16, -8/16 + 4*number/16, 8/16}, }, }, - + on_timer = function(pos, elapsed) df_farming.grow_underground_plant(pos, name, elapsed) end, - + drop = { max_items = 1, items = { @@ -47,12 +47,12 @@ local register_dimple_cup = function(number) _mcl_blast_resistance = 0.2, _mcl_hardness = 0.2, } - + if number < 4 then def._dfcaverns_next_stage_time = dimple_grow_time def._dfcaverns_next_stage = "df_farming:dimple_cup_"..tostring(number+1) end - + minetest.register_node(name, def) end diff --git a/df_farming/pig_tail.lua b/df_farming/pig_tail.lua index d5dcc62..840361c 100644 --- a/df_farming/pig_tail.lua +++ b/df_farming/pig_tail.lua @@ -26,11 +26,11 @@ local register_pig_tail = function(number) {-8/16, -8/16, -8/16, 8/16, -8/16 + 2*number/16, 8/16}, }, }, - + on_timer = function(pos, elapsed) df_farming.grow_underground_plant(pos, name, elapsed) end, - + drop = { max_items = 1, items = { @@ -51,12 +51,12 @@ local register_pig_tail = function(number) _mcl_blast_resistance = 0.2, _mcl_hardness = 0.2, } - + if number < 8 then def._dfcaverns_next_stage_time = pig_tail_grow_time def._dfcaverns_next_stage = "df_farming:pig_tail_"..tostring(number+1) end - + minetest.register_node(name, def) end @@ -143,7 +143,7 @@ if minetest.get_modpath("footprints") then _mcl_blast_resistance = 0.2, _mcl_hardness = 0.2, }) - + footprints.register_trample_node("df_farming:pig_tail_5", { trampled_node_name = "df_farming:pig_tail_trampled", randomize_trampled_param2 = true, diff --git a/df_farming/plants.lua b/df_farming/plants.lua index f416fd4..5d55028 100644 --- a/df_farming/plants.lua +++ b/df_farming/plants.lua @@ -80,7 +80,7 @@ end df_farming.plant_timer = function(pos, plantname, elapsed) local next_stage_time = minetest.registered_nodes[plantname]._dfcaverns_next_stage_time if not next_stage_time then return end - + local growable_factor = df_farming.growth_factor(plantname, pos) or 1 if growable_factor == true then growable_factor = 1 end -- backwards compatibility in case other mods are overriding growth factor to "true/false" @@ -141,7 +141,7 @@ local place_seed = function(itemstack, placer, pointed_thing, plantname) if not minetest.registered_nodes[above.name].buildable_to then return itemstack end - + -- if the plant can't grow here, don't permit the seed to be placed local growth_permitted_function = df_farming.growth_permitted[plantname] if not growth_permitted_function or not growth_permitted_function(pt.above) then @@ -153,7 +153,7 @@ local place_seed = function(itemstack, placer, pointed_thing, plantname) local oldnode= above minetest.add_node(pt.above, {name = plantname, param2 = 1}) df_farming.plant_timer(pt.above, plantname) - + -- Run script hook local take_item = true for _, callback in ipairs(core.registered_on_placenodes) do @@ -165,8 +165,8 @@ local place_seed = function(itemstack, placer, pointed_thing, plantname) if callback(place_to_copy, newnode_copy, placer, oldnode_copy, itemstack, pointed_thing_copy) then take_item = false end - end - + end + if not minetest.is_creative_enabled(placer:get_player_name()) then itemstack:take_item() end @@ -196,21 +196,21 @@ df_farming.register_seed = function(name, description, image, stage_one, grow_ti fixed = {-0.5, -0.5, -0.5, 0.5, -5/16, 0.5}, }, _mcl_blast_resistance = 0.2, - _mcl_hardness = 0.2, - + _mcl_hardness = 0.2, + on_place = function(itemstack, placer, pointed_thing) return place_seed(itemstack, placer, pointed_thing, "df_farming:"..name) end, - + on_timer = function(pos, elapsed) df_farming.grow_underground_plant(pos, "df_farming:"..name, elapsed) end, - + on_destruct = function(pos) minetest.get_node_timer(pos):stop() end, } - + minetest.register_node("df_farming:"..name, def) minetest.register_craft({ type = "fuel", @@ -248,10 +248,10 @@ if df_farming.config.light_kills_fungus then end local node_def = minetest.registered_nodes[node.name] local light_sensitive_fungus_level = node_def.groups.light_sensitive_fungus - + -- This should never be the case, but I've received a report of it happening anyway in the ABM so guarding against it. if not light_sensitive_fungus_level then return false end - + local dead_node = node_def._dfcaverns_dead_node or "df_farming:dead_fungus" -- 11 is the value adjacent to a torch local light_level = minetest.get_node_light(pos, 0.5) -- check at 0.5 to get how bright it would be here at noon, diff --git a/df_farming/plump_helmet.lua b/df_farming/plump_helmet.lua index 004b7f8..2d7ddeb 100644 --- a/df_farming/plump_helmet.lua +++ b/df_farming/plump_helmet.lua @@ -59,7 +59,7 @@ local plump_helmet_on_place = function(itemstack, placer, pointed_thing, plantn local newnode= {name = plantname, param2 = new_param2, param1=0} local oldnode= minetest.get_node(pt.above) minetest.add_node(pt.above, newnode) - + local growth_permitted_function = df_farming.growth_permitted["df_farming:plump_helmet_spawn"] -- use the same permitted function for all plump helmets if not growth_permitted_function or growth_permitted_function(pt.above) then df_farming.plant_timer(pt.above, plantname) @@ -108,16 +108,16 @@ minetest.register_node("df_farming:plump_helmet_spawn", { } }, _mcl_blast_resistance = 0.2, - _mcl_hardness = 0.2, - + _mcl_hardness = 0.2, + on_place = function(itemstack, placer, pointed_thing) return plump_helmet_on_place(itemstack, placer, pointed_thing, "df_farming:plump_helmet_spawn") end, - + on_timer = function(pos, elapsed) df_farming.grow_underground_plant(pos, "df_farming:plump_helmet_spawn", elapsed) end, - + on_destruct = function(pos) minetest.get_node_timer(pos):stop() end, @@ -162,7 +162,7 @@ minetest.register_node("df_farming:plump_helmet_1", { } }, _mcl_blast_resistance = 0.3, - _mcl_hardness = 0.3, + _mcl_hardness = 0.3, on_place = function(itemstack, placer, pointed_thing) return plump_helmet_on_place(itemstack, placer, pointed_thing, "df_farming:plump_helmet_1") @@ -206,12 +206,12 @@ minetest.register_node("df_farming:plump_helmet_2", { } }, _mcl_blast_resistance = 0.4, - _mcl_hardness = 0.4, - + _mcl_hardness = 0.4, + on_place = function(itemstack, placer, pointed_thing) return plump_helmet_on_place(itemstack, placer, pointed_thing, "df_farming:plump_helmet_2") end, - + on_use = minetest.item_eat(2), _hunger_ng = {satiates = 2}, _mcl_saturation = 0.7, @@ -254,7 +254,7 @@ minetest.register_node("df_farming:plump_helmet_3", { on_place = function(itemstack, placer, pointed_thing) return plump_helmet_on_place(itemstack, placer, pointed_thing, "df_farming:plump_helmet_3") end, - + on_use = minetest.item_eat(3), _hunger_ng = {satiates = 3}, _mcl_saturation = 0.9, @@ -317,7 +317,7 @@ minetest.register_node("df_farming:plump_helmet_4", { on_place = function(itemstack, placer, pointed_thing) return plump_helmet_on_place(itemstack, placer, pointed_thing, "df_farming:plump_helmet_4") end, - + on_use = minetest.item_eat(4), _hunger_ng = {satiates = 4}, _mcl_saturation = 1, @@ -363,7 +363,7 @@ minetest.register_node("df_farming:plump_helmet_4_picked", { on_place = function(itemstack, placer, pointed_thing) return plump_helmet_on_place(itemstack, placer, pointed_thing, "df_farming:plump_helmet_4_picked") end, - + on_use = minetest.item_eat(4), _hunger_ng = {satiates = 4}, _mcl_saturation = 1, diff --git a/df_farming/sweet_pod.lua b/df_farming/sweet_pod.lua index 5417217..e2b1c2c 100644 --- a/df_farming/sweet_pod.lua +++ b/df_farming/sweet_pod.lua @@ -31,7 +31,7 @@ local register_sweet_pod = function(number) }, _mcl_blast_resistance = 0.2, _mcl_hardness = 0.2, - + on_timer = function(pos, elapsed) df_farming.grow_underground_plant(pos, name, elapsed) end, @@ -54,12 +54,12 @@ local register_sweet_pod = function(number) }, }, } - + if number < 6 then def._dfcaverns_next_stage = "df_farming:sweet_pod_"..tostring(number+1) def._dfcaverns_next_stage_time = sweet_pod_grow_time end - + minetest.register_node(name, def) end @@ -195,7 +195,7 @@ if df_dependencies.bucket_register_liquid then _mcl_blast_resistance = 100, _mcl_hardness = -1, }) - + minetest.register_node("df_farming:dwarven_syrup_flowing", { description = S("Flowing Dwarven Syrup"), _doc_items_longdesc = df_farming.doc.sweet_pod_syrup_desc, @@ -254,7 +254,7 @@ if df_dependencies.bucket_register_liquid then "dfcaverns_bucket_dwarven_syrup.png", S("Dwarven Syrup Bucket") ) - + if minetest.get_modpath("crafting") then simplecrafting_lib.register("furnace", { input = { @@ -271,7 +271,7 @@ if df_dependencies.bucket_register_liquid then recipe = {df_dependencies.node_name_bucket_empty, "df_farming:sugar", "df_farming:sugar", "df_farming:sugar"}, }) end - + if minetest.get_modpath("dynamic_liquid") then dynamic_liquid.liquid_abm("df_farming:dwarven_syrup_source", "df_farming:dwarven_syrup_flowing", 5) end diff --git a/df_lorebooks/ecology_trees.lua b/df_lorebooks/ecology_trees.lua index 61da714..e1e646b 100644 --- a/df_lorebooks/ecology_trees.lua +++ b/df_lorebooks/ecology_trees.lua @@ -7,7 +7,7 @@ collectible_lore.register_lorebook({ id = "rose fungiwood", title = S("Fungiwood"), text = S([[Today we came across a truly extraordinary discovery. As we were exploring one of the deeper caverns, we stumbled upon a forest of enormous fungi. These towering structures, which I have named Fungiwood, stood at least twenty to thirty feet tall, with a central stalk that was incredibly strong and fine-grained. The spore-producing 'shelves' that surrounded the stalk were thin and irregular, but not particularly useful for either building or as a food source. - + However, the central stalk proved to be an invaluable discovery. When cut, it produces smooth yellow-tinted lumber that is perfect for crafting. It is no wonder that so many carved wooden objects from the deeps are made from this Fungiwood. I have collected samples of the lumber and will study it further to see if it has any other unique properties. This discovery opens up a whole new realm of possibilities for subterranean exploration and commerce. Sincerely, @@ -23,7 +23,7 @@ collectible_lore.register_lorebook({ When harvested the central stalk of a blood thorn can be cut into planks and used as wood. It has a purple-red hue that may or may not appeal, depending on one's artistic tastes. Despite their fearsome reputation, I must admit, I was struck by the tenacity of these plants. The spikes can remain living even after they're severed from the parent stalk, continuing to drain anything they come into contact with. Even if killed by bright light they can still cause damage to creatures that fall on them. - + But as I took notes and observed the blood thorns, I found it difficult to appreciate this species of plant. Its ruthless nature and actively harmful spines left me feeling uneasy, and I couldn't help but walk cautiously in its presence. Sincerely, @@ -123,7 +123,7 @@ collectible_lore.register_lorebook({ id = "banks tunnel tube", title = S("Tunnel Tube Resources"), text = S([[I have been conducting experiments on the Tunnel Tubes, a species of fungi that can be found growing deep underground in the caverns. I have successfully harvested the fruiting bodies of the Tunnel Tubes and have been experimenting with refining a gunpowder-like explosive from them. This explosive has shown great potential in mining and construction, but I must note that my experiments were cut short due to several casualties among my crew caused by careless detonations. - + In addition to the explosive potential of the Tunnel Tubes, I have also discovered that the wood produced from their trunks has a unique cross-grained texture that makes it incredibly strong and flexible. This could have a wide range of uses in construction and carpentry. However, I must mention that the purple hue of the wood is unfortunately unpleasant and I have yet to devise a way to bleach the wood to make it more appealing. Overall, the Tunnel Tubes have a lot of potential for industrial use, but we must be careful in handling them and make sure to take proper safety precautions when working with them. I will continue my experiments and report any further findings. diff --git a/df_lorebooks/geology_the_great_caverns.lua b/df_lorebooks/geology_the_great_caverns.lua index ad7c937..84adb9c 100644 --- a/df_lorebooks/geology_the_great_caverns.lua +++ b/df_lorebooks/geology_the_great_caverns.lua @@ -65,7 +65,7 @@ I must stress the importance of caution when exploring these sinkholes, as the w Signed, Dr. Theodore Banks]]), - sort = base + 3, + sort = base + 3, }) --Chasms @@ -112,7 +112,7 @@ Additionally, mine gas mixed with breathable air can explode violently when expo Signed, Dr. Theodore Banks]]), - sort = base + 6, + sort = base + 6, }) --gas wisps diff --git a/df_mapitems/castle_coral.lua b/df_mapitems/castle_coral.lua index dc2beac..576b555 100644 --- a/df_mapitems/castle_coral.lua +++ b/df_mapitems/castle_coral.lua @@ -41,7 +41,7 @@ minetest.register_node("df_mapitems:castle_coral_skeleton", { local c_coral = minetest.get_content_id("df_mapitems:castle_coral") local c_coral_skeleton = minetest.get_content_id("df_mapitems:castle_coral_skeleton") - + local c_stone = minetest.get_content_id(df_dependencies.node_name_stone) local c_water = minetest.get_content_id(df_dependencies.node_name_water_source) @@ -76,7 +76,7 @@ df_mapitems.spawn_castle_coral = function(area, data, vi, iterations) local newiterations = iterations - 1 if newiterations == 0 then return end - + if math.random() > 0.5 then df_mapitems.spawn_castle_coral(area, data, index + 1 - ystride, newiterations) df_mapitems.spawn_castle_coral(area, data, index - 1 - ystride, newiterations) diff --git a/df_mapitems/config.lua b/df_mapitems/config.lua index 5ebf388..36c5a7b 100644 --- a/df_mapitems/config.lua +++ b/df_mapitems/config.lua @@ -17,10 +17,10 @@ local function setting(stype, name, default, description) value = default end df_mapitems.config[name] = value - + if print_settingtypes then minetest.debug(CONFIG_FILE_PREFIX..name.." ("..description..") "..stype.." "..tostring(default)) - end + end end setting("float", "glow_worm_delay_multiplier", 10.0, "glow worm growth delay multiplier") diff --git a/df_mapitems/crystals_ruby.lua b/df_mapitems/crystals_ruby.lua index b6fec2f..a6e0471 100644 --- a/df_mapitems/crystals_ruby.lua +++ b/df_mapitems/crystals_ruby.lua @@ -318,7 +318,7 @@ end df_mapitems.place_big_crystal_cluster = function(area, data, data_param2, vi, radius, ceiling) local y if ceiling then y = -1 else y = 1 end - local pos = area:position(vi) + local pos = area:position(vi) for li in area:iterp(vector.add(pos, -radius), vector.add(pos, radius)) do local adjacent = li + y*area.ystride if math.random() > 0.5 and data[li] == c_stone and data[adjacent] == c_air then diff --git a/df_mapitems/glow_worms.lua b/df_mapitems/glow_worms.lua index 3b28501..09527cd 100644 --- a/df_mapitems/glow_worms.lua +++ b/df_mapitems/glow_worms.lua @@ -34,7 +34,7 @@ minetest.register_node("df_mapitems:glow_worm", { visual_scale = 1.0, _mcl_blast_resistance = 0.2, _mcl_hardness = 0.2, - after_place_node = function(pos, placer) + after_place_node = function(pos, placer) if df_mapitems.config.glow_worm_delay_multiplier > 0 then minetest.get_node_timer(pos):start(math.random( df_mapitems.config.glow_worm_delay_multiplier * growth_multiplier * 0.75, @@ -48,7 +48,7 @@ minetest.register_node("df_mapitems:glow_worm", { if math.random() > 0.5 then minetest.get_node_timer(below):start(math.random( df_mapitems.config.glow_worm_delay_multiplier * growth_multiplier * 0.75, - df_mapitems.config.glow_worm_delay_multiplier * growth_multiplier * 1.25)) + df_mapitems.config.glow_worm_delay_multiplier * growth_multiplier * 1.25)) end end end, diff --git a/df_mapitems/ground_cover.lua b/df_mapitems/ground_cover.lua index 531d8de..e7ef47f 100644 --- a/df_mapitems/ground_cover.lua +++ b/df_mapitems/ground_cover.lua @@ -38,7 +38,7 @@ minetest.register_node("df_mapitems:dirt_with_cave_moss", { description = S("Dirt with Cave Moss"), _doc_items_longdesc = df_mapitems.doc.cave_moss_desc, _doc_items_usagehelp = df_mapitems.doc.cave_moss_usage, - tiles = {dirt_texture .. "^dfcaverns_cave_moss.png", dirt_texture, + tiles = {dirt_texture .. "^dfcaverns_cave_moss.png", dirt_texture, {name = dirt_texture .. "^(dfcaverns_cave_moss.png^[mask:dfcaverns_ground_cover_side_mask.png)", tileable_vertical = false}}, drop = dirt_node, @@ -66,7 +66,7 @@ minetest.register_node("df_mapitems:sand_scum", { description = S("Sand Scum"), _doc_items_longdesc = df_mapitems.doc.sand_scum_desc, _doc_items_usagehelp = df_mapitems.doc.sand_scum_usage, - tiles = {"dfcaverns_ground_cover_sand_scum.png", sand_texture, + tiles = {"dfcaverns_ground_cover_sand_scum.png", sand_texture, {name = sand_texture .. "^(dfcaverns_ground_cover_sand_scum.png^[mask:dfcaverns_ground_cover_side_mask.png)", tileable_vertical = false}}, drop = sand_node, @@ -89,7 +89,7 @@ minetest.register_node("df_mapitems:dirt_with_pebble_fungus", { description = S("Dirt with Pebble Fungus"), _doc_items_longdesc = df_mapitems.doc.pebble_fungus_desc, _doc_items_usagehelp = df_mapitems.doc.pebble_fungus_usage, - tiles = {"dfcaverns_ground_cover_pebble_fungus.png", dirt_texture, + tiles = {"dfcaverns_ground_cover_pebble_fungus.png", dirt_texture, {name = dirt_texture .. "^(dfcaverns_ground_cover_pebble_fungus.png^[mask:dfcaverns_ground_cover_side_mask.png)", tileable_vertical = false}}, drop = dirt_node, @@ -117,7 +117,7 @@ minetest.register_node("df_mapitems:dirt_with_stillworm", { description = S("Dirt with Stillworm"), _doc_items_longdesc = df_mapitems.doc.stillworm_desc, _doc_items_usagehelp = df_mapitems.doc.stillworm_usage, - tiles = {dirt_texture .. "^dfcaverns_ground_cover_stillworm.png", dirt_texture, + tiles = {dirt_texture .. "^dfcaverns_ground_cover_stillworm.png", dirt_texture, {name = dirt_texture .. "^(dfcaverns_ground_cover_stillworm.png^[mask:dfcaverns_ground_cover_side_mask.png)", tileable_vertical = false}}, drop = dirt_node, @@ -165,7 +165,7 @@ minetest.register_node("df_mapitems:rock_rot", { description = S("Rock Rot"), _doc_items_longdesc = df_mapitems.doc.rock_rot_desc, _doc_items_usagehelp = df_mapitems.doc.rock_rot_usage, - tiles = {df_dependencies.texture_stone .. "^dfcaverns_ground_cover_rock_rot.png", df_dependencies.texture_stone, + tiles = {df_dependencies.texture_stone .. "^dfcaverns_ground_cover_rock_rot.png", df_dependencies.texture_stone, {name = df_dependencies.texture_stone .. "^(dfcaverns_ground_cover_rock_rot.png^[mask:dfcaverns_ground_cover_side_mask.png)", tileable_vertical = false}}, drop = df_dependencies.node_name_cobble, diff --git a/df_mapitems/snareweed.lua b/df_mapitems/snareweed.lua index 1b8dc22..764f89a 100644 --- a/df_mapitems/snareweed.lua +++ b/df_mapitems/snareweed.lua @@ -19,7 +19,7 @@ minetest.register_node("df_mapitems:snareweed", { if df_mapitems.config.snareweed_damage then local timer = 0 - + minetest.register_globalstep(function(dtime) timer = timer + dtime if timer >= 1 then @@ -39,7 +39,7 @@ if df_mapitems.config.snareweed_damage then end end end - end) + end) end @@ -64,7 +64,7 @@ df_mapitems.place_snareweed = function(area, data, bi, param2_data) end df_mapitems.place_snareweed_patch = function(area, data, bi, param2_data, radius) - local pos = area:position(bi) + local pos = area:position(bi) for li in area:iterp(vector.add(pos, -radius), vector.add(pos, radius)) do local adjacent = li + area.ystride local node_type = data[li] diff --git a/df_mapitems/util.lua b/df_mapitems/util.lua index a4723d3..bc44cf0 100644 --- a/df_mapitems/util.lua +++ b/df_mapitems/util.lua @@ -10,7 +10,7 @@ df_mapitems.place_against_surface = function(itemstack, placer, pointed_thing) if pointed_thing.type ~= "node" then return itemstack end - + local under_pos = pointed_thing.under local above_pos = pointed_thing.above @@ -26,7 +26,7 @@ df_mapitems.place_against_surface = function(itemstack, placer, pointed_thing) local above_name = above_node.name local under_def = minetest.registered_nodes[under_name] local above_def = minetest.registered_nodes[above_name] - + -- return if any of the nodes is not registered if not under_def or not above_def then return itemstack @@ -90,7 +90,7 @@ local is_valid_mounting_node = function(c_node) return false end ---facing +x: 16, 17, 18, 19, +--facing +x: 16, 17, 18, 19, --facing -x: 12, 13, 14, 15 --facing +z: 8, 9, 10, 11 --facing -z: 4, 5, 6, 7 diff --git a/df_primordial_items/ceiling_fungus.lua b/df_primordial_items/ceiling_fungus.lua index 4b590e2..09d8146 100644 --- a/df_primordial_items/ceiling_fungus.lua +++ b/df_primordial_items/ceiling_fungus.lua @@ -64,7 +64,7 @@ df_primordial_items.spawn_ceiling_spire_vm = function(vi, area, data) local ystride = area.ystride local zstride = area.zstride - + for i = 0, spire_height do if data[vi-i*ystride] == c_air then data[vi-i*ystride] = c_stalk @@ -74,7 +74,7 @@ df_primordial_items.spawn_ceiling_spire_vm = function(vi, area, data) if data[bottom] == c_air then data[bottom] = c_node end - + if spire_height > 4 then -- thicken it all up for i = 0, math.floor(spire_height/2) do local current_vi = vi-i*ystride @@ -91,7 +91,7 @@ df_primordial_items.spawn_ceiling_spire_vm = function(vi, area, data) data[current_vi-zstride] = c_stalk end end - + if spire_height > 7 then bottom = bottom-ystride if data[bottom] == c_air then @@ -113,5 +113,5 @@ df_primordial_items.spawn_ceiling_spire_vm = function(vi, area, data) data[bottom-zstride] = c_node end end - end + end end \ No newline at end of file diff --git a/df_primordial_items/fungal_nodes.lua b/df_primordial_items/fungal_nodes.lua index 6cda843..2d468a9 100644 --- a/df_primordial_items/fungal_nodes.lua +++ b/df_primordial_items/fungal_nodes.lua @@ -170,5 +170,5 @@ if minetest.get_modpath("footprints") then hard_pack_node_name = "footprints:trail", hard_pack_probability = HARDPACK_PROBABILITY, hard_pack_count = HARDPACK_COUNT, - }) + }) end diff --git a/df_primordial_items/giant_fern.lua b/df_primordial_items/giant_fern.lua index 863b0e8..528bc3b 100644 --- a/df_primordial_items/giant_fern.lua +++ b/df_primordial_items/giant_fern.lua @@ -237,9 +237,9 @@ local fern_4_nodes_tall = { size = {y = 4, x = 3, z = 4}, center_pos = {y = 0, x = 1, z = 3}, data = { - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, - n1, n2, n1, n2, n1, n1, n1, n1, n1, n1, n2, n3, n2, n1, n4, n1, n1, - n1, n1, n1, n6, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, + n1, n2, n1, n2, n1, n1, n1, n1, n1, n1, n2, n3, n2, n1, n4, n1, n1, + n1, n1, n1, n6, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, } } @@ -247,10 +247,10 @@ local fern_5_nodes_tall = { size = {y = 5, x = 3, z = 4}, center_pos = {y = 0, x = 1, z = 3}, data = { - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n2, n1, n2, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n2, n3, n2, n1, n4, n1, n1, n1, n1, n1, n5, n1, n2, n6, n2, - n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n2, n1, n2, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n2, n3, n2, n1, n4, n1, n1, n1, n1, n1, n5, n1, n2, n6, n2, + n1, n1, n1, n1, n1, n1, n1, n1, n1, } } @@ -258,14 +258,14 @@ local fern_6_nodes_tall = { size = {y = 6, x = 5, z = 4}, center_pos = {y = 0, x = 2, z = 3}, data = { - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n2, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n2, n2, n3, n2, n2, n1, n1, n4, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n2, n5, n2, n1, n2, n2, - n6, n2, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n2, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n2, n2, n3, n2, n2, n1, n1, n4, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n2, n5, n2, n1, n2, n2, + n6, n2, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, } } @@ -273,20 +273,20 @@ local fern_9_nodes_tall = { size = {y = 9, x = 5, z = 5}, center_pos = {y = 0, x = 2, z = 4}, data = { - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n2, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n2, n2, n3, n2, n2, n1, n1, n4, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n2, n2, n3, n2, n2, n2, n2, n6, n2, n2, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n1, - n5, n1, n1, n1, n2, n5, n2, n1, n1, n2, n6, n2, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n2, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n2, n2, n3, n2, n2, n1, n1, n4, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n2, n2, n3, n2, n2, n2, n2, n6, n2, n2, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n1, + n5, n1, n1, n1, n2, n5, n2, n1, n1, n2, n6, n2, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, } } diff --git a/df_primordial_items/giant_mycelium.lua b/df_primordial_items/giant_mycelium.lua index d41c577..34d32b0 100644 --- a/df_primordial_items/giant_mycelium.lua +++ b/df_primordial_items/giant_mycelium.lua @@ -125,7 +125,7 @@ local find_mycelium_growth_targets = function(pos) local pos_x = pos.x local pos_y = pos.y local pos_z = pos.z - + for x = -1, 1 do for y = -1, 1 do for z = -1, 1 do @@ -267,7 +267,7 @@ local find_mycelium_growth_targets = function(pos) then table.insert(valid_targets, {x=pos_x, y=pos_y, z=pos_z+1}) end - + return valid_targets end @@ -275,11 +275,11 @@ local grow_mycelium = function(pos, meristem_name) local new_meristems = {} -- Can we grow? If so, pick a random direction and add a new meristem there local targets = find_mycelium_growth_targets(pos) - + if targets == nil then return nil -- We hit the edge of the known world, pause! end - + local target_count = #targets if target_count > 0 then local target = targets[math.random(1,target_count)] @@ -337,7 +337,7 @@ minetest.register_node("df_primordial_items:giant_hypha_apical_meristem", { if df_farming and df_farming.kill_if_sunlit(pos) then return end - + if elapsed > max_growth_delay then -- We've been unloaded for a while, need to do multiple growth iterations. local iterations = math.floor(elapsed / avg_growth_delay) -- the number of iterations we've missed @@ -373,14 +373,14 @@ minetest.register_node("df_primordial_items:giant_hypha_apical_meristem", { minetest.get_node_timer(newpos):start(math.random(min_growth_delay,max_growth_delay)) end end - end + end end, }) -- this version grows instantly, it is meant for mapgen usage. -local grow_mycelium_immediately = function(pos) - local stack = {pos} +local grow_mycelium_immediately = function(pos_spawn) + local stack = {pos_spawn} while #stack > 0 do local pos = table.remove(stack) if not (df_farming and df_farming.kill_if_sunlit(pos)) then @@ -394,7 +394,7 @@ local grow_mycelium_immediately = function(pos) minetest.get_node_timer(pos):start(math.random(10,60)) end end - end + end end minetest.register_node("df_primordial_items:giant_hypha_apical_mapgen", { diff --git a/df_primordial_items/jungle_mushroom.lua b/df_primordial_items/jungle_mushroom.lua index 4841a17..9be6785 100644 --- a/df_primordial_items/jungle_mushroom.lua +++ b/df_primordial_items/jungle_mushroom.lua @@ -127,7 +127,7 @@ minetest.register_node("df_primordial_items:jungle_mushroom_sapling", { on_destruct = function(pos) minetest.get_node_timer(pos):stop() end, - + on_timer = function(pos) if df_farming and df_farming.kill_if_sunlit(pos) then return @@ -147,14 +147,14 @@ df_primordial_items.spawn_jungle_mushroom = function(pos) local stem_height = math.random(1,3) local cap_radius = math.random(2,3) local maxy = y + stem_height + 3 - + local c_cap if math.random() > 0.5 then c_cap = c_cap_1 else c_cap = c_cap_2 end - + local vm = minetest.get_voxel_manip() local minp, maxp = vm:read_from_map( {x = x - cap_radius, y = y, z = z - cap_radius}, @@ -164,7 +164,7 @@ df_primordial_items.spawn_jungle_mushroom = function(pos) local data = vm:get_data() subterrane.giant_mushroom(area:indexp(pos), area, data, c_stem, c_cap, c_air, stem_height, cap_radius) - + vm:set_data(data) vm:write_to_map() vm:update_map() diff --git a/df_primordial_items/jungle_nodes.lua b/df_primordial_items/jungle_nodes.lua index a44569c..ae3189e 100644 --- a/df_primordial_items/jungle_nodes.lua +++ b/df_primordial_items/jungle_nodes.lua @@ -366,7 +366,7 @@ if minetest.get_modpath("footprints") then hard_pack_node_name = "footprints:trail", hard_pack_probability = HARDPACK_PROBABILITY, hard_pack_count = HARDPACK_COUNT, - }) + }) footprints.register_trample_node("df_primordial_items:plant_matter", { trampled_node_def_override = {description = S("Primordial Plant Matter with Footprint"),}, footprint_opacity = 128, @@ -458,10 +458,10 @@ minetest.register_node("df_primordial_items:jungle_thorns", { }) --- TODO I had an idea to make thorns grow into mazes naturally using cellular automata rules, but it turned out to be +-- TODO I had an idea to make thorns grow into mazes naturally using cellular automata rules, but it turned out to be -- complicated and probably not worth it right now. Deal with it later. ---local thorn_dir = +--local thorn_dir = --{ -- {x=1,y=0,z=1}, -- {x=-1,y=0,z=-1}, @@ -494,7 +494,7 @@ minetest.register_node("df_primordial_items:jungle_thorns", { -- end -- return -- end --- +-- -- local dir = thorn_dir[math.random(#thorn_dir)] -- local target_pos = vector.add(dir, pos) -- -- This gets the corners of the target zone diff --git a/df_primordial_items/jungle_tree.lua b/df_primordial_items/jungle_tree.lua index 73c3477..9064b2f 100644 --- a/df_primordial_items/jungle_tree.lua +++ b/df_primordial_items/jungle_tree.lua @@ -140,7 +140,7 @@ local c_trunk_glow = minetest.get_content_id("df_primordial_items:jungle_tree_gl df_primordial_items.spawn_jungle_tree = function(pos) local x, y, z = pos.x, pos.y, pos.z local height = math.random(8,14) - + local vm = minetest.get_voxel_manip() local minp, maxp = vm:read_from_map( {x = x - 2, y = y - 2, z = z - 2}, @@ -149,9 +149,9 @@ df_primordial_items.spawn_jungle_tree = function(pos) local area = VoxelArea:new({MinEdge = minp, MaxEdge = maxp}) local data = vm:get_data() local vi = area:indexp(pos) - + df_primordial_items.spawn_jungle_tree_vm(height, vi, area, data) - + vm:set_data(data) vm:write_to_map() vm:update_map() @@ -187,7 +187,7 @@ df_primordial_items.spawn_jungle_tree_vm = function(height, vi, area, data) end roots_done[root_column] = true end - + -- puts a trunk node in the center and surrounds it with leaves local branch = function(bi, glow) local trunknode, leafnode @@ -210,7 +210,7 @@ df_primordial_items.spawn_jungle_tree_vm = function(height, vi, area, data) end end end - + for i = 0, height-2 do local y_index = vi + i * ystride if buildable_to(data[y_index]) then @@ -220,10 +220,10 @@ df_primordial_items.spawn_jungle_tree_vm = function(height, vi, area, data) end if i > 4 then local branch_index = y_index + math.random(-1,1) + math.random(-1,1)*zstride - branch(branch_index) + branch(branch_index) end end - branch(vi + (height-1)*ystride) -- topper + branch(vi + (height-1)*ystride) -- topper end minetest.register_node("df_primordial_items:jungletree_sapling", { diff --git a/df_primordial_items/primordial_mushroom.lua b/df_primordial_items/primordial_mushroom.lua index 10e3dac..ba7fc55 100644 --- a/df_primordial_items/primordial_mushroom.lua +++ b/df_primordial_items/primordial_mushroom.lua @@ -279,452 +279,452 @@ local bc_mushroom_21 = { size = {y = 21, x = 19, z = 19}, center_pos = {x=9, y=0, z=9}, data = { - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, n2, n3, - n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, - n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, - n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n5, n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n3, n3, n5, n5, n5, n5, n2, n3, n3, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n3, n3, n3, n3, n5, n3, n3, n3, n3, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, n3, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n2, n1, n1, n2, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n2, n1, n1, n2, n1, n5, n2, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n2, n1, n5, n2, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n2, n1, n5, n2, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, n2, n1, n1, n2, n1, n5, - n2, n3, n3, n3, n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, n2, n5, n2, - n2, n5, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n3, n3, - n3, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, - n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, - n5, n1, n5, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n5, n1, n2, n2, - n1, n1, n5, n1, n5, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n5, n1, - n2, n2, n1, n1, n5, n1, n5, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, - n5, n1, n2, n2, n1, n2, n5, n1, n5, n1, n1, n1, n1, n1, n1, n1, n3, - n5, n2, n5, n1, n2, n2, n1, n2, n5, n2, n5, n3, n1, n1, n1, n1, n1, - n1, n3, n3, n3, n5, n2, n2, n2, n5, n2, n5, n3, n3, n3, n1, n1, n1, - n1, n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, n3, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n2, n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n2, n1, n1, n1, n1, n2, n2, n2, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n5, n1, n2, n1, n1, n1, n2, n2, n2, n2, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n5, n1, n2, n1, n1, n1, n2, n2, n2, n2, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n5, n1, n2, n1, n1, n1, n2, n2, n2, n2, - n1, n1, n1, n1, n1, n1, n3, n3, n2, n5, n1, n2, n1, n1, n1, n2, n2, - n2, n2, n3, n3, n1, n1, n1, n1, n3, n3, n3, n5, n2, n2, n5, n5, n2, - n2, n2, n2, n3, n3, n3, n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, n4, - n4, n4, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n3, n3, - n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, n2, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, - n2, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n2, n1, - n2, n1, n2, n1, n1, n1, n1, n1, n1, n2, n1, n1, n2, n1, n1, n1, n2, - n2, n1, n2, n5, n2, n1, n1, n1, n1, n1, n1, n2, n1, n1, n2, n1, n1, - n1, n2, n2, n2, n2, n5, n2, n1, n1, n1, n1, n1, n1, n2, n1, n1, n2, - n1, n1, n1, n2, n2, n2, n2, n5, n2, n1, n1, n1, n1, n3, n3, n2, n1, - n1, n2, n1, n1, n5, n2, n2, n2, n2, n5, n2, n3, n3, n1, n1, n3, n3, - n3, n2, n2, n2, n2, n5, n4, n2, n2, n2, n2, n5, n3, n3, n3, n1, n1, - n1, n1, n3, n3, n3, n3, n4, n4, n4, n4, n4, n3, n3, n3, n3, n1, n1, - n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, - n1, n1, n1, n1, n5, n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n2, n1, n1, n1, n1, n5, n5, n1, n1, n1, n1, n2, n5, n1, n1, n1, - n1, n1, n1, n2, n1, n1, n1, n1, n5, n5, n1, n1, n1, n1, n2, n5, n1, - n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n5, n5, n1, n2, n1, n1, n2, - n5, n1, n1, n1, n3, n2, n1, n2, n1, n1, n1, n2, n4, n5, n1, n2, n1, - n1, n2, n5, n3, n1, n1, n3, n3, n2, n2, n5, n5, n2, n4, n4, n4, n2, - n2, n2, n2, n2, n3, n3, n1, n1, n1, n3, n3, n3, n3, n4, n4, n4, n4, - n4, n4, n4, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, - n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n3, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n4, n4, n4, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n4, n4, n4, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n4, n4, n4, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n4, n4, n4, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n4, n4, n4, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n4, n4, n4, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n4, - n4, n4, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n4, n4, n4, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n4, n4, n4, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n4, n4, n4, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n4, n4, n4, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n4, n4, n4, n2, n2, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n1, n4, n4, n4, n2, n2, n2, - n1, n1, n2, n1, n1, n1, n1, n5, n5, n1, n1, n1, n1, n4, n4, n4, n2, - n2, n2, n1, n1, n2, n1, n1, n1, n1, n5, n5, n1, n1, n5, n2, n4, n4, - n4, n2, n2, n2, n1, n1, n2, n1, n1, n1, n1, n5, n5, n1, n1, n5, n2, - n4, n4, n4, n2, n2, n2, n1, n5, n2, n1, n1, n3, n3, n5, n5, n1, n1, - n5, n2, n4, n4, n4, n2, n2, n2, n1, n5, n2, n3, n3, n3, n3, n3, n5, - n5, n2, n5, n4, n4, n4, n4, n4, n2, n2, n2, n5, n3, n3, n3, n1, n1, - n3, n3, n3, n4, n4, n4, n4, n4, n4, n4, n4, n4, n3, n3, n3, n1, n1, - n1, n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n4, n4, n4, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n4, n4, n4, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n4, - n4, n4, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n4, n4, n4, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n4, n4, n4, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n4, n4, n4, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n4, n4, n4, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n4, n4, n4, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n4, n4, n4, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n4, n4, n4, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n4, n4, - n4, n1, n1, n1, n1, n1, n1, n2, n1, n1, n2, n1, n1, n1, n1, n1, n5, - n4, n4, n4, n1, n1, n1, n1, n1, n1, n2, n1, n1, n2, n1, n1, n1, n5, - n1, n5, n4, n4, n4, n2, n1, n1, n1, n1, n1, n2, n1, n1, n2, n1, n1, - n1, n5, n1, n5, n4, n4, n4, n2, n1, n1, n1, n2, n1, n2, n1, n1, n2, - n1, n1, n1, n5, n1, n5, n4, n4, n4, n2, n1, n1, n1, n2, n1, n2, n1, - n1, n2, n1, n1, n1, n5, n1, n5, n4, n4, n4, n2, n1, n1, n1, n2, n1, - n2, n1, n3, n2, n1, n1, n1, n5, n2, n4, n4, n4, n4, n4, n5, n1, n1, - n2, n1, n2, n3, n3, n3, n2, n2, n5, n5, n4, n4, n4, n4, n4, n4, n4, - n2, n2, n2, n2, n3, n3, n1, n1, n3, n3, n3, n4, n4, n4, n4, n4, n4, - n4, n4, n4, n3, n3, n3, n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, n3, - n3, n3, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n3, - n3, n3, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n4, n4, n4, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n4, n4, n4, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n4, n4, n4, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n4, n4, n4, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n4, n4, n4, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n4, n4, n4, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n4, n4, - n4, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n4, n4, n4, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n4, n4, n4, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n4, n4, n4, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n4, n4, n4, n5, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n4, n4, n4, n5, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n4, n4, n4, n5, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, n2, n4, n4, n4, n5, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, n2, n4, n4, n4, - n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, n2, n4, - n4, n4, n5, n1, n1, n1, n1, n1, n1, n1, n3, n3, n2, n2, n1, n1, n1, - n2, n4, n4, n4, n5, n1, n1, n1, n1, n2, n3, n3, n3, n3, n3, n2, n2, - n5, n5, n4, n4, n4, n4, n4, n2, n5, n5, n2, n3, n3, n3, n1, n1, n3, - n3, n3, n4, n4, n4, n4, n4, n4, n4, n4, n4, n3, n3, n3, n1, n1, n1, - n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n2, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n2, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n5, n2, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n5, n2, n1, n1, n1, n1, n1, n1, n5, n1, - n1, n1, n3, n5, n1, n1, n1, n1, n1, n5, n4, n2, n1, n1, n1, n1, n1, - n5, n3, n1, n1, n3, n3, n5, n5, n2, n5, n2, n4, n4, n4, n2, n2, n2, - n2, n5, n3, n3, n1, n1, n1, n3, n3, n3, n3, n4, n4, n4, n4, n4, n4, - n4, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, n3, n3, - n3, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n3, - n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n5, n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n1, n1, n1, n1, n5, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n1, n1, n1, - n5, n5, n1, n1, n1, n1, n1, n1, n1, n1, n3, n3, n5, n1, n1, n1, n1, - n1, n2, n5, n5, n1, n1, n1, n5, n3, n3, n1, n1, n3, n3, n3, n5, n2, - n5, n2, n2, n4, n5, n5, n2, n2, n5, n3, n3, n3, n1, n1, n1, n1, n3, - n3, n3, n3, n4, n4, n4, n4, n4, n3, n3, n3, n3, n1, n1, n1, n1, n1, - n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, - n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, - n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n2, n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n2, n5, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n2, n5, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n2, n5, n1, n2, n2, n1, n1, n1, n1, n1, n1, - n1, n1, n3, n3, n2, n1, n1, n1, n2, n5, n2, n2, n2, n1, n2, n3, n3, - n1, n1, n1, n1, n3, n3, n3, n5, n2, n5, n2, n5, n2, n2, n2, n5, n3, - n3, n3, n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, n4, n4, n4, n3, n3, - n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, n3, n3, - n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, - n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n5, n1, n1, n1, n2, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n5, n1, n5, n1, n2, n1, n2, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n5, n1, n5, n1, n2, n1, n2, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n5, n1, n5, n1, n2, n1, n2, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n5, n1, n2, n1, n2, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n5, n1, n2, n2, - n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n3, n2, n5, n1, n5, n1, - n2, n2, n2, n1, n5, n5, n3, n1, n1, n1, n1, n1, n1, n3, n3, n3, n2, - n5, n2, n2, n2, n2, n5, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n3, - n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n3, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, - n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n2, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n2, n5, n2, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n3, n3, n3, n2, n5, n2, n2, n1, n1, n2, n3, n3, n3, n1, n1, - n1, n1, n1, n1, n3, n3, n3, n3, n5, n2, n2, n5, n5, n3, n3, n3, n3, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n5, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, - n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, - n1, n1, n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n5, n1, n1, n1, n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n5, n1, n1, n1, n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n5, n1, n1, n1, n5, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n5, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n5, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n5, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n5, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n3, n3, n5, n5, n1, - n2, n5, n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, - n3, n2, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n3, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n3, n3, n3, n2, n3, n3, n3, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n3, - n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, n2, n3, + n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, + n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, + n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n5, n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n3, n3, n5, n5, n5, n5, n2, n3, n3, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n3, n3, n3, n3, n5, n3, n3, n3, n3, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, n3, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n2, n1, n1, n2, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n2, n1, n1, n2, n1, n5, n2, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n2, n1, n5, n2, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n2, n1, n5, n2, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, n2, n1, n1, n2, n1, n5, + n2, n3, n3, n3, n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, n2, n5, n2, + n2, n5, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n3, n3, + n3, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, + n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, + n5, n1, n5, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n5, n1, n2, n2, + n1, n1, n5, n1, n5, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n5, n1, + n2, n2, n1, n1, n5, n1, n5, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, + n5, n1, n2, n2, n1, n2, n5, n1, n5, n1, n1, n1, n1, n1, n1, n1, n3, + n5, n2, n5, n1, n2, n2, n1, n2, n5, n2, n5, n3, n1, n1, n1, n1, n1, + n1, n3, n3, n3, n5, n2, n2, n2, n5, n2, n5, n3, n3, n3, n1, n1, n1, + n1, n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, n3, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n2, n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n2, n1, n1, n1, n1, n2, n2, n2, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n5, n1, n2, n1, n1, n1, n2, n2, n2, n2, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n5, n1, n2, n1, n1, n1, n2, n2, n2, n2, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n5, n1, n2, n1, n1, n1, n2, n2, n2, n2, + n1, n1, n1, n1, n1, n1, n3, n3, n2, n5, n1, n2, n1, n1, n1, n2, n2, + n2, n2, n3, n3, n1, n1, n1, n1, n3, n3, n3, n5, n2, n2, n5, n5, n2, + n2, n2, n2, n3, n3, n3, n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, n4, + n4, n4, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n3, n3, + n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, n2, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, + n2, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n2, n1, + n2, n1, n2, n1, n1, n1, n1, n1, n1, n2, n1, n1, n2, n1, n1, n1, n2, + n2, n1, n2, n5, n2, n1, n1, n1, n1, n1, n1, n2, n1, n1, n2, n1, n1, + n1, n2, n2, n2, n2, n5, n2, n1, n1, n1, n1, n1, n1, n2, n1, n1, n2, + n1, n1, n1, n2, n2, n2, n2, n5, n2, n1, n1, n1, n1, n3, n3, n2, n1, + n1, n2, n1, n1, n5, n2, n2, n2, n2, n5, n2, n3, n3, n1, n1, n3, n3, + n3, n2, n2, n2, n2, n5, n4, n2, n2, n2, n2, n5, n3, n3, n3, n1, n1, + n1, n1, n3, n3, n3, n3, n4, n4, n4, n4, n4, n3, n3, n3, n3, n1, n1, + n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, + n1, n1, n1, n1, n5, n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n2, n1, n1, n1, n1, n5, n5, n1, n1, n1, n1, n2, n5, n1, n1, n1, + n1, n1, n1, n2, n1, n1, n1, n1, n5, n5, n1, n1, n1, n1, n2, n5, n1, + n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n5, n5, n1, n2, n1, n1, n2, + n5, n1, n1, n1, n3, n2, n1, n2, n1, n1, n1, n2, n4, n5, n1, n2, n1, + n1, n2, n5, n3, n1, n1, n3, n3, n2, n2, n5, n5, n2, n4, n4, n4, n2, + n2, n2, n2, n2, n3, n3, n1, n1, n1, n3, n3, n3, n3, n4, n4, n4, n4, + n4, n4, n4, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, + n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n3, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n4, n4, n4, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n4, n4, n4, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n4, n4, n4, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n4, n4, n4, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n4, n4, n4, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n4, n4, n4, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n4, + n4, n4, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n4, n4, n4, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n4, n4, n4, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n4, n4, n4, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n4, n4, n4, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n4, n4, n4, n2, n2, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n1, n4, n4, n4, n2, n2, n2, + n1, n1, n2, n1, n1, n1, n1, n5, n5, n1, n1, n1, n1, n4, n4, n4, n2, + n2, n2, n1, n1, n2, n1, n1, n1, n1, n5, n5, n1, n1, n5, n2, n4, n4, + n4, n2, n2, n2, n1, n1, n2, n1, n1, n1, n1, n5, n5, n1, n1, n5, n2, + n4, n4, n4, n2, n2, n2, n1, n5, n2, n1, n1, n3, n3, n5, n5, n1, n1, + n5, n2, n4, n4, n4, n2, n2, n2, n1, n5, n2, n3, n3, n3, n3, n3, n5, + n5, n2, n5, n4, n4, n4, n4, n4, n2, n2, n2, n5, n3, n3, n3, n1, n1, + n3, n3, n3, n4, n4, n4, n4, n4, n4, n4, n4, n4, n3, n3, n3, n1, n1, + n1, n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n4, n4, n4, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n4, n4, n4, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n4, + n4, n4, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n4, n4, n4, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n4, n4, n4, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n4, n4, n4, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n4, n4, n4, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n4, n4, n4, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n4, n4, n4, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n4, n4, n4, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n4, n4, + n4, n1, n1, n1, n1, n1, n1, n2, n1, n1, n2, n1, n1, n1, n1, n1, n5, + n4, n4, n4, n1, n1, n1, n1, n1, n1, n2, n1, n1, n2, n1, n1, n1, n5, + n1, n5, n4, n4, n4, n2, n1, n1, n1, n1, n1, n2, n1, n1, n2, n1, n1, + n1, n5, n1, n5, n4, n4, n4, n2, n1, n1, n1, n2, n1, n2, n1, n1, n2, + n1, n1, n1, n5, n1, n5, n4, n4, n4, n2, n1, n1, n1, n2, n1, n2, n1, + n1, n2, n1, n1, n1, n5, n1, n5, n4, n4, n4, n2, n1, n1, n1, n2, n1, + n2, n1, n3, n2, n1, n1, n1, n5, n2, n4, n4, n4, n4, n4, n5, n1, n1, + n2, n1, n2, n3, n3, n3, n2, n2, n5, n5, n4, n4, n4, n4, n4, n4, n4, + n2, n2, n2, n2, n3, n3, n1, n1, n3, n3, n3, n4, n4, n4, n4, n4, n4, + n4, n4, n4, n3, n3, n3, n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, n3, + n3, n3, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n3, + n3, n3, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n4, n4, n4, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n4, n4, n4, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n4, n4, n4, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n4, n4, n4, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n4, n4, n4, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n4, n4, n4, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n4, n4, + n4, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n4, n4, n4, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n4, n4, n4, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n4, n4, n4, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n4, n4, n4, n5, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n4, n4, n4, n5, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n4, n4, n4, n5, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, n2, n4, n4, n4, n5, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, n2, n4, n4, n4, + n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, n2, n4, + n4, n4, n5, n1, n1, n1, n1, n1, n1, n1, n3, n3, n2, n2, n1, n1, n1, + n2, n4, n4, n4, n5, n1, n1, n1, n1, n2, n3, n3, n3, n3, n3, n2, n2, + n5, n5, n4, n4, n4, n4, n4, n2, n5, n5, n2, n3, n3, n3, n1, n1, n3, + n3, n3, n4, n4, n4, n4, n4, n4, n4, n4, n4, n3, n3, n3, n1, n1, n1, + n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n2, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n2, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n5, n2, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n5, n2, n1, n1, n1, n1, n1, n1, n5, n1, + n1, n1, n3, n5, n1, n1, n1, n1, n1, n5, n4, n2, n1, n1, n1, n1, n1, + n5, n3, n1, n1, n3, n3, n5, n5, n2, n5, n2, n4, n4, n4, n2, n2, n2, + n2, n5, n3, n3, n1, n1, n1, n3, n3, n3, n3, n4, n4, n4, n4, n4, n4, + n4, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, n3, n3, + n3, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n3, + n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n5, n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n1, n1, n1, n1, n5, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n1, n1, n1, + n5, n5, n1, n1, n1, n1, n1, n1, n1, n1, n3, n3, n5, n1, n1, n1, n1, + n1, n2, n5, n5, n1, n1, n1, n5, n3, n3, n1, n1, n3, n3, n3, n5, n2, + n5, n2, n2, n4, n5, n5, n2, n2, n5, n3, n3, n3, n1, n1, n1, n1, n3, + n3, n3, n3, n4, n4, n4, n4, n4, n3, n3, n3, n3, n1, n1, n1, n1, n1, + n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, + n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, + n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n2, n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n2, n5, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n2, n5, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n2, n5, n1, n2, n2, n1, n1, n1, n1, n1, n1, + n1, n1, n3, n3, n2, n1, n1, n1, n2, n5, n2, n2, n2, n1, n2, n3, n3, + n1, n1, n1, n1, n3, n3, n3, n5, n2, n5, n2, n5, n2, n2, n2, n5, n3, + n3, n3, n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, n4, n4, n4, n3, n3, + n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, n3, n3, + n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, + n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n5, n1, n1, n1, n2, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n5, n1, n5, n1, n2, n1, n2, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n5, n1, n5, n1, n2, n1, n2, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n5, n1, n5, n1, n2, n1, n2, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n5, n1, n2, n1, n2, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n5, n1, n2, n2, + n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n3, n2, n5, n1, n5, n1, + n2, n2, n2, n1, n5, n5, n3, n1, n1, n1, n1, n1, n1, n3, n3, n3, n2, + n5, n2, n2, n2, n2, n5, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n3, + n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n3, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, + n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n2, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n2, n5, n2, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n3, n3, n3, n2, n5, n2, n2, n1, n1, n2, n3, n3, n3, n1, n1, + n1, n1, n1, n1, n3, n3, n3, n3, n5, n2, n2, n5, n5, n3, n3, n3, n3, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n5, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, + n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, + n1, n1, n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n5, n1, n1, n1, n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n5, n1, n1, n1, n5, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n5, n1, n1, n1, n5, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n5, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n5, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n5, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n5, n1, n1, n1, n5, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n3, n3, n5, n5, n1, + n2, n5, n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, + n3, n2, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n3, n3, n3, n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n2, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n3, n3, n3, n2, n3, n3, n3, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n3, n3, n3, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n3, + n3, n3, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, } } diff --git a/df_trees/black_cap.lua b/df_trees/black_cap.lua index 7567350..de7d571 100644 --- a/df_trees/black_cap.lua +++ b/df_trees/black_cap.lua @@ -58,7 +58,7 @@ minetest.register_node("df_trees:black_cap_gills", { df_dependencies.register_leafdecay({ trunks = {"df_trees:black_cap"}, -- don't need stem nodes here leaves = {"df_trees:black_cap_gills"}, - radius = 1, + radius = 1, }) -- Wood @@ -170,7 +170,7 @@ minetest.register_node("df_trees:black_cap_sapling", { on_destruct = function(pos) minetest.get_node_timer(pos):stop() end, - + on_timer = function(pos) if df_farming and df_farming.kill_if_sunlit(pos) then return @@ -199,7 +199,7 @@ df_trees.spawn_black_cap = function(pos) local data = vm:get_data() subterrane.giant_mushroom(area:indexp(pos), area, data, c_stem, c_cap, c_gills, stem_height, cap_radius) - + vm:set_data(data) vm:write_to_map() vm:update_map() @@ -208,7 +208,7 @@ end df_trees.spawn_black_cap_vm = function(vi, area, data) local stem_height = math.random(1,5) local cap_radius = math.random(2,3) - + subterrane.giant_mushroom(vi, area, data, c_stem, c_cap, c_gills, stem_height, cap_radius) end diff --git a/df_trees/blood_thorn.lua b/df_trees/blood_thorn.lua index 1a7ff6a..6832603 100644 --- a/df_trees/blood_thorn.lua +++ b/df_trees/blood_thorn.lua @@ -63,7 +63,7 @@ minetest.register_node("df_trees:blood_thorn", { below_node = minetest.get_node(below) end end, - + on_timer = function(pos, elapsed) while elapsed > blood_thorn_max_delay do -- catch up if the block was unloaded for a long time @@ -76,7 +76,7 @@ minetest.register_node("df_trees:blood_thorn", { minetest.get_node_timer(pos):start(math.random(blood_thorn_min_delay, blood_thorn_max_delay)) end end, - + }) minetest.register_node("df_trees:blood_thorn_dead", { @@ -231,12 +231,12 @@ function df_trees.grow_blood_thorn(pos, node) if df_farming and df_farming.kill_if_sunlit(pos) then return end - + -- node is tipped over if node.param2 >= 4 then return end - + local height = 0 local max_height = max_bloodthorn_height(pos) while node.name == "df_trees:blood_thorn" and height < max_height do @@ -249,7 +249,7 @@ function df_trees.grow_blood_thorn(pos, node) end minetest.set_node(pos, {name = "df_trees:blood_thorn"}) - + local dir = spike_directions[math.random(1,4)] local spike_pos = vector.add(pos, dir.dir) if minetest.get_node(spike_pos).name == "air" then @@ -320,8 +320,8 @@ df_trees.spawn_blood_thorn_vm = function(vi, area, data, data_param2, height) local node_id = data[vi] if node_id == c_air or node_id == c_ignore then data[vi] = c_blood_thorn - - for i = 1, 2 do + + for j = 1, 2 do local facedir = math.random(1,4)-1 local spike_vi = vi + facedir_to_increment(facedir, area) if data[spike_vi] == c_air or data[spike_vi] == c_ignore then @@ -335,8 +335,3 @@ df_trees.spawn_blood_thorn_vm = function(vi, area, data, data_param2, height) vi = vi + area.ystride end end - - - - - diff --git a/df_trees/config.lua b/df_trees/config.lua index 41f4f86..39d1f34 100644 --- a/df_trees/config.lua +++ b/df_trees/config.lua @@ -17,10 +17,10 @@ local function setting(stype, name, default, description) value = default end df_trees.config[name] = value - + if print_settingtypes then minetest.debug(CONFIG_FILE_PREFIX..name.." ("..description..") "..stype.." "..tostring(default)) - end + end end local trees = { diff --git a/df_trees/fungiwood.lua b/df_trees/fungiwood.lua index ea7be80..7b11822 100644 --- a/df_trees/fungiwood.lua +++ b/df_trees/fungiwood.lua @@ -2,7 +2,7 @@ -- Fungiwood -- fine grain --- Max trunk height 8 +-- Max trunk height 8 -- depth 1-2 local S = minetest.get_translator(minetest.get_current_modname()) @@ -140,7 +140,7 @@ minetest.register_node("df_trees:fungiwood_sapling", { on_destruct = function(pos) minetest.get_node_timer(pos):stop() end, - + on_timer = function(pos) if df_farming and df_farming.kill_if_sunlit(pos) then return @@ -175,14 +175,14 @@ function df_trees.spawn_fungiwood(pos) vm:update_map() end -df_trees.spawn_fungiwood_vm = function(vi, area, data, height) +df_trees.spawn_fungiwood_vm = function(vi_spawn, area, data, height) if height == nil then height = math.random(6, 10) end - local pos = area:position(vi) + local pos = area:position(vi_spawn) local x = pos.x local y = pos.y local z = pos.z local maxy = y + height -- Trunk top - + -- Upper branches layer local dev = 3 for yy = maxy - 2, maxy do diff --git a/df_trees/goblin_cap.lua b/df_trees/goblin_cap.lua index 3932f54..a501e0d 100644 --- a/df_trees/goblin_cap.lua +++ b/df_trees/goblin_cap.lua @@ -64,7 +64,7 @@ minetest.register_node("df_trees:goblin_cap_gills", { df_dependencies.register_leafdecay({ trunks = {"df_trees:goblin_cap"}, -- don't need stem nodes here leaves = {"df_trees:goblin_cap_gills"}, - radius = 1, + radius = 1, }) --Wood @@ -235,7 +235,7 @@ minetest.register_node("df_trees:goblin_cap_sapling", { on_destruct = function(pos) minetest.get_node_timer(pos):stop() end, - + on_timer = function(pos) if df_farming and df_farming.kill_if_sunlit(pos) then return @@ -270,11 +270,11 @@ df_trees.spawn_goblin_cap = function(pos) end local x, y, z = pos.x, pos.y, pos.z - + local stem_height = math.random(1,3) local cap_radius = math.random(3,6) local maxy = y + stem_height + 3 - + local vm = minetest.get_voxel_manip() local minp, maxp = vm:read_from_map( {x = x - cap_radius, y = y, z = z - cap_radius}, @@ -284,7 +284,7 @@ df_trees.spawn_goblin_cap = function(pos) local data = vm:get_data() subterrane.giant_mushroom(area:indexp(pos), area, data, c_stem, c_cap, c_gills, stem_height, cap_radius) - + vm:set_data(data) vm:write_to_map() vm:update_map() diff --git a/df_trees/nether_cap.lua b/df_trees/nether_cap.lua index 0470225..b77212f 100644 --- a/df_trees/nether_cap.lua +++ b/df_trees/nether_cap.lua @@ -61,7 +61,7 @@ minetest.register_node("df_trees:nether_cap_gills", { df_dependencies.register_leafdecay({ trunks = {"df_trees:nether_cap"}, -- don't need stem nodes here leaves = {"df_trees:nether_cap_gills"}, - radius = 1, + radius = 1, }) --Wood @@ -130,7 +130,7 @@ minetest.register_node("df_trees:nether_cap_sapling", { on_destruct = function(pos) minetest.get_node_timer(pos):stop() end, - + on_timer = function(pos) if df_farming and df_farming.kill_if_sunlit(pos) then return @@ -150,7 +150,7 @@ df_trees.spawn_nether_cap = function(pos) local stem_height = math.random(1,3) local cap_radius = math.random(2,3) local maxy = y + stem_height + 3 - + local vm = minetest.get_voxel_manip() local minp, maxp = vm:read_from_map( {x = x - cap_radius, y = y, z = z - cap_radius}, @@ -160,7 +160,7 @@ df_trees.spawn_nether_cap = function(pos) local data = vm:get_data() subterrane.giant_mushroom(area:indexp(pos), area, data, c_stem, c_cap, c_gills, stem_height, cap_radius) - + vm:set_data(data) vm:write_to_map() vm:update_map() diff --git a/df_trees/schematics/goblin_cap_big.lua b/df_trees/schematics/goblin_cap_big.lua index 181b979..6142db2 100644 --- a/df_trees/schematics/goblin_cap_big.lua +++ b/df_trees/schematics/goblin_cap_big.lua @@ -9,212 +9,212 @@ return { center_pos = {x=5, y=2, z=5}, data = { -- z=0, y=0 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=0, y=1 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=0, y=2 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=0, y=3 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=0, y=4 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=0, y=5 - n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, -- z=0, y=6 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=0, y=7 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=0, y=8 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=1, y=0 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=1, y=1 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=1, y=2 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=1, y=3 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=1, y=4 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=1, y=5 - n1, n1, n2, n2, n2, n4, n2, n2, n2, n1, n1, + n1, n1, n2, n2, n2, n4, n2, n2, n2, n1, n1, -- z=1, y=6 - n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, -- z=1, y=7 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=1, y=8 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=2, y=0 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=2, y=1 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=2, y=2 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=2, y=3 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=2, y=4 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=2, y=5 - n1, n2, n2, n4, n4, n4, n4, n4, n2, n2, n1, + n1, n2, n2, n4, n4, n4, n4, n4, n2, n2, n1, -- z=2, y=6 - n1, n1, n1, n2, n2, n2, n2, n2, n1, n1, n1, + n1, n1, n1, n2, n2, n2, n2, n2, n1, n1, n1, -- z=2, y=7 - n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, -- z=2, y=8 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=3, y=0 - n1, n1, n1, n1, n6, n6, n6, n1, n1, n1, n1, + n1, n1, n1, n1, n6, n6, n6, n1, n1, n1, n1, -- z=3, y=1 - n1, n1, n1, n1, n6, n6, n6, n1, n1, n1, n1, + n1, n1, n1, n1, n6, n6, n6, n1, n1, n1, n1, -- z=3, y=2 - n1, n1, n1, n1, n6, n6, n6, n1, n1, n1, n1, + n1, n1, n1, n1, n6, n6, n6, n1, n1, n1, n1, -- z=3, y=3 - n1, n1, n1, n1, n6, n6, n6, n1, n1, n1, n1, + n1, n1, n1, n1, n6, n6, n6, n1, n1, n1, n1, -- z=3, y=4 - n1, n1, n1, n1, n6, n6, n6, n1, n1, n1, n1, + n1, n1, n1, n1, n6, n6, n6, n1, n1, n1, n1, -- z=3, y=5 - n1, n2, n4, n4, n6, n6, n6, n4, n4, n2, n1, + n1, n2, n4, n4, n6, n6, n6, n4, n4, n2, n1, -- z=3, y=6 - n1, n1, n2, n2, n2, n2, n2, n2, n2, n1, n1, + n1, n1, n2, n2, n2, n2, n2, n2, n2, n1, n1, -- z=3, y=7 - n1, n1, n1, n2, n2, n2, n2, n2, n1, n1, n1, + n1, n1, n1, n2, n2, n2, n2, n2, n1, n1, n1, -- z=3, y=8 - n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, -- z=4, y=0 - n1, n1, n1, n6, n6, n6, n6, n6, n1, n1, n1, + n1, n1, n1, n6, n6, n6, n6, n6, n1, n1, n1, -- z=4, y=1 - n1, n1, n1, n6, n6, n6, n6, n6, n1, n1, n1, + n1, n1, n1, n6, n6, n6, n6, n6, n1, n1, n1, -- z=4, y=2 - n1, n1, n1, n6, n6, n6, n6, n6, n1, n1, n1, + n1, n1, n1, n6, n6, n6, n6, n6, n1, n1, n1, -- z=4, y=3 - n1, n1, n1, n6, n6, n6, n6, n6, n1, n1, n1, + n1, n1, n1, n6, n6, n6, n6, n6, n1, n1, n1, -- z=4, y=4 - n1, n1, n1, n6, n6, n6, n6, n6, n1, n1, n1, + n1, n1, n1, n6, n6, n6, n6, n6, n1, n1, n1, -- z=4, y=5 - n1, n2, n4, n6, n6, n6, n6, n6, n4, n2, n1, + n1, n2, n4, n6, n6, n6, n6, n6, n4, n2, n1, -- z=4, y=6 - n1, n1, n2, n2, n6, n6, n6, n2, n2, n1, n1, + n1, n1, n2, n2, n6, n6, n6, n2, n2, n1, n1, -- z=4, y=7 - n1, n1, n1, n2, n2, n2, n2, n2, n1, n1, n1, + n1, n1, n1, n2, n2, n2, n2, n2, n1, n1, n1, -- z=4, y=8 - n1, n1, n1, n1, n2, n2, n2, n1, n1, n1, n1, + n1, n1, n1, n1, n2, n2, n2, n1, n1, n1, n1, -- z=5, y=0 - n1, n1, n1, n6, n6, n6, n6, n6, n1, n1, n1, + n1, n1, n1, n6, n6, n6, n6, n6, n1, n1, n1, -- z=5, y=1 - n1, n1, n1, n6, n6, n6, n6, n6, n1, n1, n1, + n1, n1, n1, n6, n6, n6, n6, n6, n1, n1, n1, -- z=5, y=2 - n1, n1, n1, n6, n6, n6, n6, n6, n1, n1, n1, + n1, n1, n1, n6, n6, n6, n6, n6, n1, n1, n1, -- z=5, y=3 - n1, n1, n1, n6, n6, n6, n6, n6, n1, n1, n1, + n1, n1, n1, n6, n6, n6, n6, n6, n1, n1, n1, -- z=5, y=4 - n1, n1, n1, n6, n6, n6, n6, n6, n1, n1, n1, + n1, n1, n1, n6, n6, n6, n6, n6, n1, n1, n1, -- z=5, y=5 - n2, n4, n4, n6, n6, n6, n6, n6, n4, n4, n2, + n2, n4, n4, n6, n6, n6, n6, n6, n4, n4, n2, -- z=5, y=6 - n1, n2, n2, n2, n6, n6, n6, n2, n2, n2, n1, + n1, n2, n2, n2, n6, n6, n6, n2, n2, n2, n1, -- z=5, y=7 - n1, n1, n2, n2, n2, n6, n2, n2, n2, n1, n1, + n1, n1, n2, n2, n2, n6, n2, n2, n2, n1, n1, -- z=5, y=8 - n1, n1, n1, n2, n2, n2, n2, n2, n1, n1, n1, + n1, n1, n1, n2, n2, n2, n2, n2, n1, n1, n1, -- z=6, y=0 - n1, n1, n1, n6, n6, n6, n6, n6, n1, n1, n1, + n1, n1, n1, n6, n6, n6, n6, n6, n1, n1, n1, -- z=6, y=1 - n1, n1, n1, n6, n6, n6, n6, n6, n1, n1, n1, + n1, n1, n1, n6, n6, n6, n6, n6, n1, n1, n1, -- z=6, y=2 - n1, n1, n1, n6, n6, n6, n6, n6, n1, n1, n1, + n1, n1, n1, n6, n6, n6, n6, n6, n1, n1, n1, -- z=6, y=3 - n1, n1, n1, n6, n6, n6, n6, n6, n1, n1, n1, + n1, n1, n1, n6, n6, n6, n6, n6, n1, n1, n1, -- z=6, y=4 - n1, n1, n1, n6, n6, n6, n6, n6, n1, n1, n1, + n1, n1, n1, n6, n6, n6, n6, n6, n1, n1, n1, -- z=6, y=5 - n1, n2, n4, n6, n6, n6, n6, n6, n4, n2, n1, + n1, n2, n4, n6, n6, n6, n6, n6, n4, n2, n1, -- z=6, y=6 - n1, n1, n2, n2, n6, n6, n6, n2, n2, n1, n1, + n1, n1, n2, n2, n6, n6, n6, n2, n2, n1, n1, -- z=6, y=7 - n1, n1, n1, n2, n2, n2, n2, n2, n1, n1, n1, + n1, n1, n1, n2, n2, n2, n2, n2, n1, n1, n1, -- z=6, y=8 - n1, n1, n1, n1, n2, n2, n2, n1, n1, n1, n1, + n1, n1, n1, n1, n2, n2, n2, n1, n1, n1, n1, -- z=7, y=0 - n1, n1, n1, n1, n6, n6, n6, n1, n1, n1, n1, + n1, n1, n1, n1, n6, n6, n6, n1, n1, n1, n1, -- z=7, y=1 - n1, n1, n1, n1, n6, n6, n6, n1, n1, n1, n1, + n1, n1, n1, n1, n6, n6, n6, n1, n1, n1, n1, -- z=7, y=2 - n1, n1, n1, n1, n6, n6, n6, n1, n1, n1, n1, + n1, n1, n1, n1, n6, n6, n6, n1, n1, n1, n1, -- z=7, y=3 - n1, n1, n1, n1, n6, n6, n6, n1, n1, n1, n1, + n1, n1, n1, n1, n6, n6, n6, n1, n1, n1, n1, -- z=7, y=4 - n1, n1, n1, n1, n6, n6, n6, n1, n1, n1, n1, + n1, n1, n1, n1, n6, n6, n6, n1, n1, n1, n1, -- z=7, y=5 - n1, n2, n4, n4, n6, n6, n6, n4, n4, n2, n1, + n1, n2, n4, n4, n6, n6, n6, n4, n4, n2, n1, -- z=7, y=6 - n1, n1, n2, n2, n2, n2, n2, n2, n2, n1, n1, + n1, n1, n2, n2, n2, n2, n2, n2, n2, n1, n1, -- z=7, y=7 - n1, n1, n1, n2, n2, n2, n2, n2, n1, n1, n1, + n1, n1, n1, n2, n2, n2, n2, n2, n1, n1, n1, -- z=7, y=8 - n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, -- z=8, y=0 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=8, y=1 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=8, y=2 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=8, y=3 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=8, y=4 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=8, y=5 - n1, n2, n2, n4, n4, n4, n4, n4, n2, n2, n1, + n1, n2, n2, n4, n4, n4, n4, n4, n2, n2, n1, -- z=8, y=6 - n1, n1, n1, n2, n2, n2, n2, n2, n1, n1, n1, + n1, n1, n1, n2, n2, n2, n2, n2, n1, n1, n1, -- z=8, y=7 - n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, -- z=8, y=8 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=9, y=0 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=9, y=1 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=9, y=2 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=9, y=3 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=9, y=4 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=9, y=5 - n1, n1, n2, n2, n2, n4, n2, n2, n2, n1, n1, + n1, n1, n2, n2, n2, n4, n2, n2, n2, n1, n1, -- z=9, y=6 - n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, -- z=9, y=7 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=9, y=8 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=10, y=0 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=10, y=1 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=10, y=2 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=10, y=3 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=10, y=4 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=10, y=5 - n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, -- z=10, y=6 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=10, y=7 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=10, y=8 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, } } diff --git a/df_trees/schematics/goblin_cap_big_hut.lua b/df_trees/schematics/goblin_cap_big_hut.lua index a63c2bf..ebcd148 100644 --- a/df_trees/schematics/goblin_cap_big_hut.lua +++ b/df_trees/schematics/goblin_cap_big_hut.lua @@ -37,213 +37,213 @@ local schematic = { center_pos = {x=5, y=2, z=5}, data = { -- z=0, y=0 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=0, y=1 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=0, y=2 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=0, y=3 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=0, y=4 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=0, y=5 - n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, -- z=0, y=6 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=0, y=7 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=0, y=8 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=1, y=0 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=1, y=1 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=1, y=2 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=1, y=3 - n1, n1, n1, n1, n1, n11, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n11, n1, n1, n1, n1, n1, -- z=1, y=4 - n1, n1, n1, n1, n1, n11, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n11, n1, n1, n1, n1, n1, -- z=1, y=5 - n1, n1, n2, n2, n2, n4, n2, n2, n2, n1, n1, + n1, n1, n2, n2, n2, n4, n2, n2, n2, n1, n1, -- z=1, y=6 - n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, -- z=1, y=7 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=1, y=8 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=2, y=0 - n1, n1, n1, n22, n1, n1, n1, n22, n1, n1, n1, + n1, n1, n1, n22, n1, n1, n1, n22, n1, n1, n1, -- z=2, y=1 - n1, n1, n1, n1, n20, n1, n21, n1, n1, n1, n1, + n1, n1, n1, n1, n20, n1, n21, n1, n1, n1, n1, -- z=2, y=2 - n1, n1, n1, n1, n1, n3, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n3, n1, n1, n1, n1, n1, -- z=2, y=3 - n1, n1, n1, n1, n1, n11, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n11, n1, n1, n1, n1, n1, -- z=2, y=4 - n1, n1, n1, n1, n1, n11, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n11, n1, n1, n1, n1, n1, -- z=2, y=5 - n1, n2, n2, n4, n4, n4, n4, n4, n2, n2, n1, + n1, n2, n2, n4, n4, n4, n4, n4, n2, n2, n1, -- z=2, y=6 - n1, n1, n1, n2, n2, n2, n2, n2, n1, n1, n1, + n1, n1, n1, n2, n2, n2, n2, n2, n1, n1, n1, -- z=2, y=7 - n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, -- z=2, y=8 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=3, y=0 - n1, n1, n1, n3, n19, n19, n19, n3, n1, n1, n1, + n1, n1, n1, n3, n19, n19, n19, n3, n1, n1, n1, -- z=3, y=1 - n1, n1, n1, n1, n19, n19, n19, n1, n1, n1, n1, + n1, n1, n1, n1, n19, n19, n19, n1, n1, n1, n1, -- z=3, y=2 - n1, n1, n1, n1, n6, n7, n6, n1, n1, n1, n1, + n1, n1, n1, n1, n6, n7, n6, n1, n1, n1, n1, -- z=3, y=3 - n1, n1, n1, n1, n6, n8, n6, n1, n1, n1, n1, + n1, n1, n1, n1, n6, n8, n6, n1, n1, n1, n1, -- z=3, y=4 - n1, n1, n1, n1, n6, n9, n6, n1, n1, n1, n1, + n1, n1, n1, n1, n6, n9, n6, n1, n1, n1, n1, -- z=3, y=5 - n1, n2, n4, n4, n6, n6, n6, n4, n4, n2, n1, + n1, n2, n4, n4, n6, n6, n6, n4, n4, n2, n1, -- z=3, y=6 - n1, n1, n2, n2, n2, n2, n2, n2, n2, n1, n1, + n1, n1, n2, n2, n2, n2, n2, n2, n2, n1, n1, -- z=3, y=7 - n1, n1, n1, n2, n2, n2, n2, n2, n1, n1, n1, + n1, n1, n1, n2, n2, n2, n2, n2, n1, n1, n1, -- z=3, y=8 - n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, -- z=4, y=0 - n1, n1, n1, n19, n19, n19, n19, n19, n1, n1, n1, + n1, n1, n1, n19, n19, n19, n19, n19, n1, n1, n1, -- z=4, y=1 - n1, n1, n1, n19, n19, n19, n19, n19, n1, n1, n1, + n1, n1, n1, n19, n19, n19, n19, n19, n1, n1, n1, -- z=4, y=2 - n1, n1, n1, n6, n7, n7, n7, n6, n1, n1, n1, + n1, n1, n1, n6, n7, n7, n7, n6, n1, n1, n1, -- z=4, y=3 - n1, n1, n1, n6, n10, n11, n11, n6, n1, n1, n1, + n1, n1, n1, n6, n10, n11, n11, n6, n1, n1, n1, -- z=4, y=4 - n1, n1, n1, n6, n11, n11, n11, n6, n1, n1, n1, + n1, n1, n1, n6, n11, n11, n11, n6, n1, n1, n1, -- z=4, y=5 - n1, n2, n4, n6, n11, n11, n11, n6, n4, n2, n1, + n1, n2, n4, n6, n11, n11, n11, n6, n4, n2, n1, -- z=4, y=6 - n1, n1, n2, n2, n6, n6, n6, n2, n2, n1, n1, + n1, n1, n2, n2, n6, n6, n6, n2, n2, n1, n1, -- z=4, y=7 - n1, n1, n1, n2, n2, n2, n2, n2, n1, n1, n1, + n1, n1, n1, n2, n2, n2, n2, n2, n1, n1, n1, -- z=4, y=8 - n1, n1, n1, n1, n2, n2, n2, n1, n1, n1, n1, + n1, n1, n1, n1, n2, n2, n2, n1, n1, n1, n1, -- z=5, y=0 - n1, n1, n1, n19, n19, n19, n19, n19, n1, n1, n1, + n1, n1, n1, n19, n19, n19, n19, n19, n1, n1, n1, -- z=5, y=1 - n1, n1, n1, n19, n19, n19, n19, n19, n1, n1, n1, + n1, n1, n1, n19, n19, n19, n19, n19, n1, n1, n1, -- z=5, y=2 - n1, n1, n1, n6, n7, n7, n7, n6, n1, n1, n1, + n1, n1, n1, n6, n7, n7, n7, n6, n1, n1, n1, -- z=5, y=3 - n1, n1, n1, n6, n11, n11, n12, n6, n1, n1, n1, + n1, n1, n1, n6, n11, n11, n12, n6, n1, n1, n1, -- z=5, y=4 - n1, n1, n1, n13, n11, n11, n11, n13, n1, n1, n1, + n1, n1, n1, n13, n11, n11, n11, n13, n1, n1, n1, -- z=5, y=5 - n2, n4, n4, n6, n11, n11, n11, n6, n4, n4, n2, + n2, n4, n4, n6, n11, n11, n11, n6, n4, n4, n2, -- z=5, y=6 - n1, n2, n2, n2, n6, n11, n6, n2, n2, n2, n1, + n1, n2, n2, n2, n6, n11, n6, n2, n2, n2, n1, -- z=5, y=7 - n1, n1, n2, n2, n2, n6, n2, n2, n2, n1, n1, + n1, n1, n2, n2, n2, n6, n2, n2, n2, n1, n1, -- z=5, y=8 - n1, n1, n1, n2, n2, n2, n2, n2, n1, n1, n1, + n1, n1, n1, n2, n2, n2, n2, n2, n1, n1, n1, -- z=6, y=0 - n1, n1, n1, n19, n19, n19, n19, n19, n1, n1, n1, + n1, n1, n1, n19, n19, n19, n19, n19, n1, n1, n1, -- z=6, y=1 - n1, n1, n1, n19, n19, n19, n19, n19, n1, n1, n1, + n1, n1, n1, n19, n19, n19, n19, n19, n1, n1, n1, -- z=6, y=2 - n1, n1, n1, n6, n7, n7, n7, n6, n1, n1, n1, + n1, n1, n1, n6, n7, n7, n7, n6, n1, n1, n1, -- z=6, y=3 - n1, n1, n1, n6, n16, n11, n17, n6, n1, n1, n1, + n1, n1, n1, n6, n16, n11, n17, n6, n1, n1, n1, -- z=6, y=4 - n1, n1, n1, n6, n18, n11, n11, n6, n1, n1, n1, + n1, n1, n1, n6, n18, n11, n11, n6, n1, n1, n1, -- z=6, y=5 - n1, n2, n4, n6, n11, n11, n11, n6, n4, n2, n1, + n1, n2, n4, n6, n11, n11, n11, n6, n4, n2, n1, -- z=6, y=6 - n1, n1, n2, n2, n6, n6, n6, n2, n2, n1, n1, + n1, n1, n2, n2, n6, n6, n6, n2, n2, n1, n1, -- z=6, y=7 - n1, n1, n1, n2, n2, n2, n2, n2, n1, n1, n1, + n1, n1, n1, n2, n2, n2, n2, n2, n1, n1, n1, -- z=6, y=8 - n1, n1, n1, n1, n2, n2, n2, n1, n1, n1, n1, + n1, n1, n1, n1, n2, n2, n2, n1, n1, n1, n1, -- z=7, y=0 - n1, n1, n1, n1, n19, n19, n19, n1, n1, n1, n1, + n1, n1, n1, n1, n19, n19, n19, n1, n1, n1, n1, -- z=7, y=1 - n1, n1, n1, n1, n19, n19, n19, n1, n1, n1, n1, + n1, n1, n1, n1, n19, n19, n19, n1, n1, n1, n1, -- z=7, y=2 - n1, n1, n1, n1, n6, n6, n6, n1, n1, n1, n1, + n1, n1, n1, n1, n6, n6, n6, n1, n1, n1, n1, -- z=7, y=3 - n1, n1, n1, n1, n6, n6, n6, n1, n1, n1, n1, + n1, n1, n1, n1, n6, n6, n6, n1, n1, n1, n1, -- z=7, y=4 - n1, n1, n1, n1, n6, n13, n6, n1, n1, n1, n1, + n1, n1, n1, n1, n6, n13, n6, n1, n1, n1, n1, -- z=7, y=5 - n1, n2, n4, n4, n6, n6, n6, n4, n4, n2, n1, + n1, n2, n4, n4, n6, n6, n6, n4, n4, n2, n1, -- z=7, y=6 - n1, n1, n2, n2, n2, n2, n2, n2, n2, n1, n1, + n1, n1, n2, n2, n2, n2, n2, n2, n2, n1, n1, -- z=7, y=7 - n1, n1, n1, n2, n2, n2, n2, n2, n1, n1, n1, + n1, n1, n1, n2, n2, n2, n2, n2, n1, n1, n1, -- z=7, y=8 - n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, -- z=8, y=0 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=8, y=1 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=8, y=2 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=8, y=3 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=8, y=4 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=8, y=5 - n1, n2, n2, n4, n4, n4, n4, n4, n2, n2, n1, + n1, n2, n2, n4, n4, n4, n4, n4, n2, n2, n1, -- z=8, y=6 - n1, n1, n1, n2, n2, n2, n2, n2, n1, n1, n1, + n1, n1, n1, n2, n2, n2, n2, n2, n1, n1, n1, -- z=8, y=7 - n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, -- z=8, y=8 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=9, y=0 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=9, y=1 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=9, y=2 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=9, y=3 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=9, y=4 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=9, y=5 - n1, n1, n2, n2, n2, n4, n2, n2, n2, n1, n1, + n1, n1, n2, n2, n2, n4, n2, n2, n2, n1, n1, -- z=9, y=6 - n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, -- z=9, y=7 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=9, y=8 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=10, y=0 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=10, y=1 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=10, y=2 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=10, y=3 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=10, y=4 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=10, y=5 - n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n2, n1, n1, n1, n1, n1, -- z=10, y=6 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=10, y=7 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=10, y=8 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, } } diff --git a/df_trees/schematics/goblin_cap_bigger.lua b/df_trees/schematics/goblin_cap_bigger.lua index 70b7cb0..5528b26 100644 --- a/df_trees/schematics/goblin_cap_bigger.lua +++ b/df_trees/schematics/goblin_cap_bigger.lua @@ -9,276 +9,276 @@ return { center_pos = {x=6, y=2, z=6}, data = { -- z=0, y=0 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=0, y=1 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=0, y=2 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=0, y=3 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=0, y=4 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=0, y=5 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=0, y=6 - n1, n1, n1, n1, n1, n1, n3, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n3, n1, n1, n1, n1, n1, n1, -- z=0, y=7 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=0, y=8 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=0, y=9 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=1, y=0 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=1, y=1 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=1, y=2 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=1, y=3 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=1, y=4 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=1, y=5 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=1, y=6 - n1, n1, n1, n3, n3, n3, n4, n3, n3, n3, n1, n1, n1, + n1, n1, n1, n3, n3, n3, n4, n3, n3, n3, n1, n1, n1, -- z=1, y=7 - n1, n1, n1, n1, n1, n1, n3, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n3, n1, n1, n1, n1, n1, n1, -- z=1, y=8 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=1, y=9 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=2, y=0 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=2, y=1 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=2, y=2 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=2, y=3 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=2, y=4 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=2, y=5 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=2, y=6 - n1, n1, n3, n4, n4, n4, n4, n4, n4, n4, n3, n1, n1, + n1, n1, n3, n4, n4, n4, n4, n4, n4, n4, n3, n1, n1, -- z=2, y=7 - n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, + n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, -- z=2, y=8 - n1, n1, n1, n1, n1, n1, n3, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n3, n1, n1, n1, n1, n1, n1, -- z=2, y=9 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=3, y=0 - n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, -- z=3, y=1 - n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, -- z=3, y=2 - n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, -- z=3, y=3 - n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, -- z=3, y=4 - n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, -- z=3, y=5 - n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, -- z=3, y=6 - n1, n3, n4, n4, n4, n4, n5, n4, n4, n4, n4, n3, n1, + n1, n3, n4, n4, n4, n4, n5, n4, n4, n4, n4, n3, n1, -- z=3, y=7 - n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, + n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, -- z=3, y=8 - n1, n1, n1, n1, n3, n3, n3, n3, n3, n1, n1, n1, n1, + n1, n1, n1, n1, n3, n3, n3, n3, n3, n1, n1, n1, n1, -- z=3, y=9 - n1, n1, n1, n1, n1, n1, n3, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n3, n1, n1, n1, n1, n1, n1, -- z=4, y=0 - n1, n1, n1, n1, n5, n5, n5, n5, n5, n1, n1, n1, n1, + n1, n1, n1, n1, n5, n5, n5, n5, n5, n1, n1, n1, n1, -- z=4, y=1 - n1, n1, n1, n1, n5, n5, n5, n5, n5, n1, n1, n1, n1, + n1, n1, n1, n1, n5, n5, n5, n5, n5, n1, n1, n1, n1, -- z=4, y=2 - n1, n1, n1, n1, n5, n5, n5, n5, n5, n1, n1, n1, n1, + n1, n1, n1, n1, n5, n5, n5, n5, n5, n1, n1, n1, n1, -- z=4, y=3 - n1, n1, n1, n1, n5, n5, n5, n5, n5, n1, n1, n1, n1, + n1, n1, n1, n1, n5, n5, n5, n5, n5, n1, n1, n1, n1, -- z=4, y=4 - n1, n1, n1, n1, n5, n5, n5, n5, n5, n1, n1, n1, n1, + n1, n1, n1, n1, n5, n5, n5, n5, n5, n1, n1, n1, n1, -- z=4, y=5 - n1, n1, n1, n1, n5, n5, n5, n5, n5, n1, n1, n1, n1, + n1, n1, n1, n1, n5, n5, n5, n5, n5, n1, n1, n1, n1, -- z=4, y=6 - n1, n3, n4, n4, n4, n5, n5, n5, n4, n4, n4, n3, n1, + n1, n3, n4, n4, n4, n5, n5, n5, n4, n4, n4, n3, n1, -- z=4, y=7 - n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, + n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, -- z=4, y=8 - n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, + n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, -- z=4, y=9 - n1, n1, n1, n1, n3, n3, n3, n3, n3, n1, n1, n1, n1, + n1, n1, n1, n1, n3, n3, n3, n3, n3, n1, n1, n1, n1, -- z=5, y=0 - n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, + n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, -- z=5, y=1 - n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, + n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, -- z=5, y=2 - n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, + n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, -- z=5, y=3 - n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, + n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, -- z=5, y=4 - n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, + n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, -- z=5, y=5 - n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, + n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, -- z=5, y=6 - n1, n3, n4, n4, n5, n5, n5, n5, n5, n4, n4, n3, n1, + n1, n3, n4, n4, n5, n5, n5, n5, n5, n4, n4, n3, n1, -- z=5, y=7 - n1, n1, n3, n3, n3, n5, n5, n5, n3, n3, n3, n1, n1, + n1, n1, n3, n3, n3, n5, n5, n5, n3, n3, n3, n1, n1, -- z=5, y=8 - n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, + n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, -- z=5, y=9 - n1, n1, n1, n1, n3, n3, n3, n3, n3, n1, n1, n1, n1, + n1, n1, n1, n1, n3, n3, n3, n3, n3, n1, n1, n1, n1, -- z=6, y=0 - n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, + n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, -- z=6, y=1 - n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, + n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, -- z=6, y=2 - n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, + n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, -- z=6, y=3 - n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, + n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, -- z=6, y=4 - n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, + n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, -- z=6, y=5 - n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, + n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, -- z=6, y=6 - n3, n4, n4, n5, n5, n5, n5, n5, n5, n5, n4, n4, n3, + n3, n4, n4, n5, n5, n5, n5, n5, n5, n5, n4, n4, n3, -- z=6, y=7 - n1, n3, n3, n3, n3, n5, n5, n5, n3, n3, n3, n3, n1, + n1, n3, n3, n3, n3, n5, n5, n5, n3, n3, n3, n3, n1, -- z=6, y=8 - n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, + n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, -- z=6, y=9 - n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, + n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, -- z=7, y=0 - n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, + n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, -- z=7, y=1 - n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, + n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, -- z=7, y=2 - n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, + n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, -- z=7, y=3 - n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, + n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, -- z=7, y=4 - n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, + n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, -- z=7, y=5 - n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, + n1, n1, n1, n5, n5, n5, n5, n5, n5, n5, n1, n1, n1, -- z=7, y=6 - n1, n3, n4, n4, n5, n5, n5, n5, n5, n4, n4, n3, n1, + n1, n3, n4, n4, n5, n5, n5, n5, n5, n4, n4, n3, n1, -- z=7, y=7 - n1, n1, n3, n3, n3, n5, n5, n5, n3, n3, n3, n1, n1, + n1, n1, n3, n3, n3, n5, n5, n5, n3, n3, n3, n1, n1, -- z=7, y=8 - n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, + n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, -- z=7, y=9 - n1, n1, n1, n1, n3, n3, n3, n3, n3, n1, n1, n1, n1, + n1, n1, n1, n1, n3, n3, n3, n3, n3, n1, n1, n1, n1, -- z=8, y=0 - n1, n1, n1, n1, n5, n5, n5, n5, n5, n1, n1, n1, n1, + n1, n1, n1, n1, n5, n5, n5, n5, n5, n1, n1, n1, n1, -- z=8, y=1 - n1, n1, n1, n1, n5, n5, n5, n5, n5, n1, n1, n1, n1, + n1, n1, n1, n1, n5, n5, n5, n5, n5, n1, n1, n1, n1, -- z=8, y=2 - n1, n1, n1, n1, n5, n5, n5, n5, n5, n1, n1, n1, n1, + n1, n1, n1, n1, n5, n5, n5, n5, n5, n1, n1, n1, n1, -- z=8, y=3 - n1, n1, n1, n1, n5, n5, n5, n5, n5, n1, n1, n1, n1, + n1, n1, n1, n1, n5, n5, n5, n5, n5, n1, n1, n1, n1, -- z=8, y=4 - n1, n1, n1, n1, n5, n5, n5, n5, n5, n1, n1, n1, n1, + n1, n1, n1, n1, n5, n5, n5, n5, n5, n1, n1, n1, n1, -- z=8, y=5 - n1, n1, n1, n1, n5, n5, n5, n5, n5, n1, n1, n1, n1, + n1, n1, n1, n1, n5, n5, n5, n5, n5, n1, n1, n1, n1, -- z=8, y=6 - n1, n3, n4, n4, n4, n5, n5, n5, n4, n4, n4, n3, n1, + n1, n3, n4, n4, n4, n5, n5, n5, n4, n4, n4, n3, n1, -- z=8, y=7 - n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, + n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, -- z=8, y=8 - n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, + n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, -- z=8, y=9 - n1, n1, n1, n1, n3, n3, n3, n3, n3, n1, n1, n1, n1, + n1, n1, n1, n1, n3, n3, n3, n3, n3, n1, n1, n1, n1, -- z=9, y=0 - n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, -- z=9, y=1 - n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, -- z=9, y=2 - n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, -- z=9, y=3 - n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, -- z=9, y=4 - n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, -- z=9, y=5 - n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, -- z=9, y=6 - n1, n3, n4, n4, n4, n4, n5, n4, n4, n4, n4, n3, n1, + n1, n3, n4, n4, n4, n4, n5, n4, n4, n4, n4, n3, n1, -- z=9, y=7 - n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, + n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, -- z=9, y=8 - n1, n1, n1, n1, n3, n3, n3, n3, n3, n1, n1, n1, n1, + n1, n1, n1, n1, n3, n3, n3, n3, n3, n1, n1, n1, n1, -- z=9, y=9 - n1, n1, n1, n1, n1, n1, n3, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n3, n1, n1, n1, n1, n1, n1, -- z=10, y=0 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=10, y=1 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=10, y=2 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=10, y=3 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=10, y=4 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=10, y=5 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=10, y=6 - n1, n1, n3, n4, n4, n4, n4, n4, n4, n3, n3, n1, n1, + n1, n1, n3, n4, n4, n4, n4, n4, n4, n3, n3, n1, n1, -- z=10, y=7 - n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, + n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, -- z=10, y=8 - n1, n1, n1, n1, n1, n1, n3, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n3, n1, n1, n1, n1, n1, n1, -- z=10, y=9 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=11, y=0 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=11, y=1 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=11, y=2 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=11, y=3 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=11, y=4 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=11, y=5 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=11, y=6 - n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, + n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, -- z=11, y=7 - n1, n1, n1, n1, n1, n1, n3, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n3, n1, n1, n1, n1, n1, n1, -- z=11, y=8 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=11, y=9 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=12, y=0 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=12, y=1 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=12, y=2 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=12, y=3 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=12, y=4 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=12, y=5 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=12, y=6 - n1, n1, n1, n1, n1, n1, n3, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n3, n1, n1, n1, n1, n1, n1, -- z=12, y=7 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=12, y=8 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=12, y=9 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, } } diff --git a/df_trees/schematics/goblin_cap_bigger_hut.lua b/df_trees/schematics/goblin_cap_bigger_hut.lua index 43bfe8b..369e85e 100644 --- a/df_trees/schematics/goblin_cap_bigger_hut.lua +++ b/df_trees/schematics/goblin_cap_bigger_hut.lua @@ -33,277 +33,277 @@ local schematic = { center_pos = {x=6, y=2, z=6}, data = { -- z=0, y=0 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=0, y=1 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=0, y=2 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=0, y=3 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=0, y=4 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=0, y=5 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=0, y=6 - n1, n1, n1, n1, n1, n1, n3, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n3, n1, n1, n1, n1, n1, n1, -- z=0, y=7 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=0, y=8 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=0, y=9 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=1, y=0 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=1, y=1 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=1, y=2 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=1, y=3 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=1, y=4 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=1, y=5 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=1, y=6 - n1, n1, n1, n3, n3, n3, n4, n3, n3, n3, n1, n1, n1, + n1, n1, n1, n3, n3, n3, n4, n3, n3, n3, n1, n1, n1, -- z=1, y=7 - n1, n1, n1, n1, n1, n1, n3, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n3, n1, n1, n1, n1, n1, n1, -- z=1, y=8 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=1, y=9 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=2, y=0 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=2, y=1 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=2, y=2 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=2, y=3 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=2, y=4 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=2, y=5 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=2, y=6 - n1, n1, n3, n4, n4, n4, n4, n4, n4, n4, n3, n1, n1, + n1, n1, n3, n4, n4, n4, n4, n4, n4, n4, n3, n1, n1, -- z=2, y=7 - n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, + n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, -- z=2, y=8 - n1, n1, n1, n1, n1, n1, n3, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n3, n1, n1, n1, n1, n1, n1, -- z=2, y=9 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=3, y=0 - n1, n1, n1, n1, n1, n2, n2, n2, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n2, n2, n2, n1, n1, n1, n1, n1, -- z=3, y=1 - n1, n1, n1, n1, n1, n2, n2, n2, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n2, n2, n2, n1, n1, n1, n1, n1, -- z=3, y=2 - n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, -- z=3, y=3 - n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, -- z=3, y=4 - n1, n1, n1, n1, n1, n5, n6, n5, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n5, n6, n5, n1, n1, n1, n1, n1, -- z=3, y=5 - n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, -- z=3, y=6 - n1, n3, n4, n4, n4, n4, n5, n4, n4, n4, n4, n3, n1, + n1, n3, n4, n4, n4, n4, n5, n4, n4, n4, n4, n3, n1, -- z=3, y=7 - n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, + n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, -- z=3, y=8 - n1, n1, n1, n1, n3, n3, n3, n3, n3, n1, n1, n1, n1, + n1, n1, n1, n1, n3, n3, n3, n3, n3, n1, n1, n1, n1, -- z=3, y=9 - n1, n1, n1, n1, n1, n1, n3, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n3, n1, n1, n1, n1, n1, n1, -- z=4, y=0 - n1, n1, n1, n1, n2, n2, n2, n2, n2, n12, n22, n1, n1, + n1, n1, n1, n1, n2, n2, n2, n2, n2, n12, n22, n1, n1, -- z=4, y=1 - n1, n1, n1, n1, n2, n2, n2, n2, n2, n1, n1, n1, n1, + n1, n1, n1, n1, n2, n2, n2, n2, n2, n1, n1, n1, n1, -- z=4, y=2 - n1, n1, n1, n1, n5, n7, n7, n7, n5, n1, n1, n1, n1, + n1, n1, n1, n1, n5, n7, n7, n7, n5, n1, n1, n1, n1, -- z=4, y=3 - n1, n1, n1, n1, n5, n8, n9, n9, n5, n1, n1, n1, n1, + n1, n1, n1, n1, n5, n8, n9, n9, n5, n1, n1, n1, n1, -- z=4, y=4 - n1, n1, n1, n1, n5, n10, n9, n9, n5, n1, n1, n1, n1, + n1, n1, n1, n1, n5, n10, n9, n9, n5, n1, n1, n1, n1, -- z=4, y=5 - n1, n1, n1, n1, n5, n5, n9, n5, n5, n1, n1, n1, n1, + n1, n1, n1, n1, n5, n5, n9, n5, n5, n1, n1, n1, n1, -- z=4, y=6 - n1, n3, n4, n4, n4, n5, n5, n5, n4, n4, n4, n3, n1, + n1, n3, n4, n4, n4, n5, n5, n5, n4, n4, n4, n3, n1, -- z=4, y=7 - n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, + n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, -- z=4, y=8 - n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, + n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, -- z=4, y=9 - n1, n1, n1, n1, n3, n3, n3, n3, n3, n1, n1, n1, n1, + n1, n1, n1, n1, n3, n3, n3, n3, n3, n1, n1, n1, n1, -- z=5, y=0 - n1, n1, n1, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, + n1, n1, n1, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, -- z=5, y=1 - n1, n1, n1, n2, n2, n2, n2, n2, n2, n2, n20, n1, n1, + n1, n1, n1, n2, n2, n2, n2, n2, n2, n2, n20, n1, n1, -- z=5, y=2 - n1, n1, n1, n5, n7, n7, n7, n7, n7, n5, n1, n1, n1, + n1, n1, n1, n5, n7, n7, n7, n7, n7, n5, n1, n1, n1, -- z=5, y=3 - n1, n1, n1, n5, n9, n9, n9, n9, n9, n5, n1, n1, n1, + n1, n1, n1, n5, n9, n9, n9, n9, n9, n5, n1, n1, n1, -- z=5, y=4 - n1, n1, n1, n5, n9, n9, n9, n9, n9, n5, n1, n1, n1, + n1, n1, n1, n5, n9, n9, n9, n9, n9, n5, n1, n1, n1, -- z=5, y=5 - n1, n1, n1, n5, n5, n9, n9, n9, n5, n5, n1, n1, n1, + n1, n1, n1, n5, n5, n9, n9, n9, n5, n5, n1, n1, n1, -- z=5, y=6 - n1, n3, n4, n4, n5, n9, n9, n9, n5, n4, n4, n3, n1, + n1, n3, n4, n4, n5, n9, n9, n9, n5, n4, n4, n3, n1, -- z=5, y=7 - n1, n1, n3, n3, n3, n5, n5, n5, n3, n3, n3, n1, n1, + n1, n1, n3, n3, n3, n5, n5, n5, n3, n3, n3, n1, n1, -- z=5, y=8 - n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, + n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, -- z=5, y=9 - n1, n1, n1, n1, n3, n3, n3, n3, n3, n1, n1, n1, n1, + n1, n1, n1, n1, n3, n3, n3, n3, n3, n1, n1, n1, n1, -- z=6, y=0 n1, n1, n1, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, -- z=6, y=1 - n1, n1, n1, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, + n1, n1, n1, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, -- z=6, y=2 - n1, n1, n1, n5, n7, n7, n7, n7, n7, n7, n12, n1, n1, + n1, n1, n1, n5, n7, n7, n7, n7, n7, n7, n12, n1, n1, -- z=6, y=3 - n1, n1, n1, n5, n9, n9, n9, n9, n9, n13, n9, n9, n1, + n1, n1, n1, n5, n9, n9, n9, n9, n9, n13, n9, n9, n1, -- z=6, y=4 - n1, n1, n1, n6, n9, n9, n9, n9, n9, n14, n9, n9, n1, + n1, n1, n1, n6, n9, n9, n9, n9, n9, n14, n9, n9, n1, -- z=6, y=5 - n1, n1, n1, n5, n9, n9, n9, n9, n9, n5, n1, n1, n1, + n1, n1, n1, n5, n9, n9, n9, n9, n9, n5, n1, n1, n1, -- z=6, y=6 - n3, n4, n4, n5, n5, n9, n9, n9, n5, n5, n4, n4, n3, + n3, n4, n4, n5, n5, n9, n9, n9, n5, n5, n4, n4, n3, -- z=6, y=7 - n1, n3, n3, n3, n3, n5, n5, n5, n3, n3, n3, n3, n1, + n1, n3, n3, n3, n3, n5, n5, n5, n3, n3, n3, n3, n1, -- z=6, y=8 - n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, + n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, -- z=6, y=9 - n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, + n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, -- z=7, y=0 - n1, n1, n1, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, + n1, n1, n1, n2, n2, n2, n2, n2, n2, n2, n1, n1, n1, -- z=7, y=1 - n1, n1, n1, n2, n2, n2, n2, n2, n2, n2, n21, n1, n1, + n1, n1, n1, n2, n2, n2, n2, n2, n2, n2, n21, n1, n1, -- z=7, y=2 - n1, n1, n1, n5, n7, n7, n7, n7, n7, n5, n1, n1, n1, + n1, n1, n1, n5, n7, n7, n7, n7, n7, n5, n1, n1, n1, -- z=7, y=3 - n1, n1, n1, n5, n15, n9, n9, n9, n9, n5, n1, n1, n1, + n1, n1, n1, n5, n15, n9, n9, n9, n9, n5, n1, n1, n1, -- z=7, y=4 - n1, n1, n1, n5, n9, n9, n9, n9, n9, n5, n1, n1, n1, + n1, n1, n1, n5, n9, n9, n9, n9, n9, n5, n1, n1, n1, -- z=7, y=5 - n1, n1, n1, n5, n5, n9, n9, n9, n5, n5, n1, n1, n1, + n1, n1, n1, n5, n5, n9, n9, n9, n5, n5, n1, n1, n1, -- z=7, y=6 - n1, n3, n4, n4, n5, n9, n9, n9, n5, n4, n4, n3, n1, + n1, n3, n4, n4, n5, n9, n9, n9, n5, n4, n4, n3, n1, -- z=7, y=7 - n1, n1, n3, n3, n3, n5, n5, n5, n3, n3, n3, n1, n1, + n1, n1, n3, n3, n3, n5, n5, n5, n3, n3, n3, n1, n1, -- z=7, y=8 - n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, + n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, -- z=7, y=9 - n1, n1, n1, n1, n3, n3, n3, n3, n3, n1, n1, n1, n1, + n1, n1, n1, n1, n3, n3, n3, n3, n3, n1, n1, n1, n1, -- z=8, y=0 - n1, n1, n1, n1, n2, n2, n2, n2, n2, n12, n22, n1, n1, + n1, n1, n1, n1, n2, n2, n2, n2, n2, n12, n22, n1, n1, -- z=8, y=1 - n1, n1, n1, n1, n2, n2, n2, n2, n2, n1, n1, n1, n1, + n1, n1, n1, n1, n2, n2, n2, n2, n2, n1, n1, n1, n1, -- z=8, y=2 - n1, n1, n1, n1, n5, n7, n7, n7, n5, n1, n1, n1, n1, + n1, n1, n1, n1, n5, n7, n7, n7, n5, n1, n1, n1, n1, -- z=8, y=3 - n1, n1, n1, n1, n5, n16, n17, n18, n5, n1, n1, n1, n1, + n1, n1, n1, n1, n5, n16, n17, n18, n5, n1, n1, n1, n1, -- z=8, y=4 - n1, n1, n1, n1, n5, n9, n9, n19, n5, n1, n1, n1, n1, + n1, n1, n1, n1, n5, n9, n9, n19, n5, n1, n1, n1, n1, -- z=8, y=5 - n1, n1, n1, n1, n5, n5, n9, n5, n5, n1, n1, n1, n1, + n1, n1, n1, n1, n5, n5, n9, n5, n5, n1, n1, n1, n1, -- z=8, y=6 - n1, n3, n4, n4, n4, n5, n5, n5, n4, n4, n4, n3, n1, + n1, n3, n4, n4, n4, n5, n5, n5, n4, n4, n4, n3, n1, -- z=8, y=7 - n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, + n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, -- z=8, y=8 - n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, + n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, -- z=8, y=9 - n1, n1, n1, n1, n3, n3, n3, n3, n3, n1, n1, n1, n1, + n1, n1, n1, n1, n3, n3, n3, n3, n3, n1, n1, n1, n1, -- z=9, y=0 - n1, n1, n1, n1, n1, n2, n2, n2, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n2, n2, n2, n1, n1, n1, n1, n1, -- z=9, y=1 - n1, n1, n1, n1, n1, n2, n2, n2, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n2, n2, n2, n1, n1, n1, n1, n1, -- z=9, y=2 - n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, -- z=9, y=3 - n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, -- z=9, y=4 - n1, n1, n1, n1, n1, n5, n6, n5, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n5, n6, n5, n1, n1, n1, n1, n1, -- z=9, y=5 - n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n5, n5, n5, n1, n1, n1, n1, n1, -- z=9, y=6 - n1, n3, n4, n4, n4, n4, n5, n4, n4, n4, n4, n3, n1, + n1, n3, n4, n4, n4, n4, n5, n4, n4, n4, n4, n3, n1, -- z=9, y=7 - n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, + n1, n1, n3, n3, n3, n3, n3, n3, n3, n3, n3, n1, n1, -- z=9, y=8 - n1, n1, n1, n1, n3, n3, n3, n3, n3, n1, n1, n1, n1, + n1, n1, n1, n1, n3, n3, n3, n3, n3, n1, n1, n1, n1, -- z=9, y=9 - n1, n1, n1, n1, n1, n1, n3, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n3, n1, n1, n1, n1, n1, n1, -- z=10, y=0 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=10, y=1 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=10, y=2 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=10, y=3 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=10, y=4 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=10, y=5 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=10, y=6 - n1, n1, n3, n4, n4, n4, n4, n4, n4, n3, n3, n1, n1, + n1, n1, n3, n4, n4, n4, n4, n4, n4, n3, n3, n1, n1, -- z=10, y=7 - n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, + n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, -- z=10, y=8 - n1, n1, n1, n1, n1, n1, n3, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n3, n1, n1, n1, n1, n1, n1, -- z=10, y=9 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=11, y=0 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=11, y=1 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=11, y=2 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=11, y=3 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=11, y=4 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=11, y=5 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=11, y=6 - n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, + n1, n1, n1, n3, n3, n3, n3, n3, n3, n3, n1, n1, n1, -- z=11, y=7 - n1, n1, n1, n1, n1, n1, n3, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n3, n1, n1, n1, n1, n1, n1, -- z=11, y=8 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=11, y=9 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=12, y=0 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=12, y=1 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=12, y=2 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=12, y=3 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=12, y=4 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=12, y=5 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=12, y=6 - n1, n1, n1, n1, n1, n1, n3, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n3, n1, n1, n1, n1, n1, n1, -- z=12, y=7 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=12, y=8 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, -- z=12, y=9 - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, } } diff --git a/df_trees/spindlestem.lua b/df_trees/spindlestem.lua index a37b52e..f2bc2d4 100644 --- a/df_trees/spindlestem.lua +++ b/df_trees/spindlestem.lua @@ -56,7 +56,7 @@ local stem_on_place = function(itemstack, placer, pointed_thing) local newnode= {name = itemstack:get_name(), param2 = new_param2, param1=0} local oldnode= minetest.get_node(pt.above) minetest.add_node(pt.above, newnode) - + -- Run script hook local take_item = true for _, callback in ipairs(core.registered_on_placenodes) do @@ -69,7 +69,7 @@ local stem_on_place = function(itemstack, placer, pointed_thing) take_item = false end end - + if not minetest.is_creative_enabled(placer:get_player_name()) and take_item then itemstack:take_item() end @@ -119,7 +119,7 @@ minetest.register_craft({ local register_spindlestem_type = function(item_suffix, colour_name, colour_code, light_level, extract_color_group) local cap_item = "df_trees:spindlestem_cap_"..item_suffix local cap_item_harvested = "df_trees:spindlestem_cap_harvested_"..item_suffix - + local cap_def = { description = S("@1 Spindlestem Cap", colour_name), is_ground_content = false, @@ -151,7 +151,7 @@ local register_spindlestem_type = function(item_suffix, colour_name, colour_code }, _mcl_blast_resistance = 2, _mcl_hardness = 2, - + drop = { -- Maximum number of items to drop max_items = 1, @@ -175,7 +175,7 @@ local register_spindlestem_type = function(item_suffix, colour_name, colour_code }, }, }, - + on_place = stem_on_place, on_timer = function(pos, elapsed) local meta = minetest.get_meta(pos) @@ -185,7 +185,7 @@ local register_spindlestem_type = function(item_suffix, colour_name, colour_code delay = growth_delay() -- compatibility code to ensure no crash for previous version end local node = minetest.get_node(pos) - + while height > 0 and elapsed >= delay do elapsed = elapsed - delay local this_pos = pos @@ -200,7 +200,7 @@ local register_spindlestem_type = function(item_suffix, colour_name, colour_code minetest.set_node(pos, {name=cap_item, param2 = node.param2}) height = height - 1 end - + if height > 0 then meta = minetest.get_meta(pos) meta:set_int("spindlestem_to_grow", height) @@ -209,7 +209,7 @@ local register_spindlestem_type = function(item_suffix, colour_name, colour_code end end, } - + local cap_def_harvested = {} for key, val in pairs(cap_def) do cap_def_harvested[key] = val @@ -221,7 +221,7 @@ local register_spindlestem_type = function(item_suffix, colour_name, colour_code cap_def_harvested.drop = nil -- harvested caps shouldn't drop spawn cap_def_harvested.on_timer = nil -- harvested caps shouldn't grow, just in case a timer and node metadata are set up where it's placed cap_def_harvested.groups.not_in_creative_inventory = nil - + minetest.register_node(cap_item, cap_def) minetest.register_node(cap_item_harvested, cap_def_harvested) @@ -230,16 +230,16 @@ local register_spindlestem_type = function(item_suffix, colour_name, colour_code recipe = cap_item_harvested, burntime = 10, }) - + if glass_bottle and light_level > 0 then local tex = "dfcaverns_vessels_glowing_liquid.png^[multiply:#"..colour_code.."^"..df_dependencies.texture_glass_bottle local new_light = light_level + math.floor((minetest.LIGHT_MAX-light_level)/2) - + local groups = {vessel = 1, dig_immediate = 3, attached_node = 1, material_glass = 1, destroy_by_lava_flow=1} if extract_color_group then groups[extract_color_group] = 1 end - + minetest.register_node("df_trees:glowing_bottle_"..item_suffix, { description = S("@1 Spindlestem Extract", colour_name), drawtype = "plantlike", @@ -261,7 +261,7 @@ local register_spindlestem_type = function(item_suffix, colour_name, colour_code _mcl_blast_resistance = 0.5, _mcl_hardness = 0.5, }) - + minetest.register_craft( { output = "df_trees:glowing_bottle_"..item_suffix.." 3", type = "shapeless", @@ -305,7 +305,7 @@ minetest.register_node("df_trees:spindlestem_seedling", { }, _mcl_blast_resistance = 0.2, _mcl_hardness = 0.2, - + on_place = stem_on_place, on_construct = function(pos) if df_trees.spindlestem_growth_permitted(pos) then @@ -315,7 +315,7 @@ minetest.register_node("df_trees:spindlestem_seedling", { on_destruct = function(pos) minetest.get_node_timer(pos):stop() end, - + on_timer = function(pos, elapsed) if df_farming and df_farming.kill_if_sunlit(pos) then return @@ -328,8 +328,8 @@ df_trees.spawn_spindlestem = function(pos) local cap_item = minetest.get_name_from_content_id(get_spindlestem_cap_type(pos)) local node = minetest.get_node(pos) minetest.set_node(pos, {name=cap_item, param2 = node.param2}) - local disp = {x=3, y=3, z=3} - local nearby = minetest.find_nodes_in_area(vector.add(pos, disp), vector.subtract(pos, disp), {"group:spindlestem"}) + local range = {x=3, y=3, z=3} + local nearby = minetest.find_nodes_in_area(vector.add(pos, range), vector.subtract(pos, range), {"group:spindlestem"}) local count = #nearby local height = math.random(1,3) if count > 10 then height = height + 2 end -- if there are a lot of nearby spindlestems, grow taller @@ -353,12 +353,12 @@ local c_stem = minetest.get_content_id("df_trees:spindlestem_stem") df_trees.spawn_spindlestem_vm = function(vi, area, data, data_param2, c_cap) if data[vi] ~= c_air then return end - + if c_cap == nil then -- note: this won't account for rock removed by subterrane, so may not be entirely accurate. Good enough! c_cap = get_spindlestem_cap_type(area:position(vi)) end - + local stem_height = math.random(1,3) local param2 = math.random(1,4)-1 local i = 0 @@ -396,7 +396,7 @@ get_spindlestem_cap_type = function(pos) if minetest.find_node_near(pos, 15, "group:goblin_cap") then return c_red end - + local iron = minetest.find_node_near(pos, 5, iron_nodes) local copper = minetest.find_node_near(pos, 5, copper_nodes) local mese = minetest.find_node_near(pos, 5, mese_nodes) @@ -411,5 +411,5 @@ get_spindlestem_cap_type = function(pos) else local pick = math.random(1, #possibilities) return possibilities[pick] - end + end end diff --git a/df_trees/spore_tree.lua b/df_trees/spore_tree.lua index dd8dd93..f0ab31e 100644 --- a/df_trees/spore_tree.lua +++ b/df_trees/spore_tree.lua @@ -83,7 +83,7 @@ minetest.register_node("df_trees:spore_tree_hyphae", { groups = {snappy = 3, leafdecay = 3, flammable = 2, leaves = 1, spore_tree_hyphae = 1,handy=1, hoey=1, shearsy=1, swordy=1, deco_block=1, dig_by_piston=1, fire_encouragement=15, fire_flammability=30, compostability=30}, walkable = false, climbable = true, - + drawtype = "nodebox", paramtype = "light", node_box = { @@ -114,19 +114,19 @@ minetest.register_node("df_trees:spore_tree_fruiting_body", { climbable = true, _mcl_blast_resistance = 0.7, _mcl_hardness = 0.7, - + drawtype = "nodebox", paramtype = "light", node_box = { type = "fixed", fixed = { - {-0.0625, -0.5, -0.0625, 0.0625, 0.5, 0.0625}, - {-0.0625, -0.0625, -0.5, 0.0625, 0.0625, 0.5}, - {-0.5, -0.0625, -0.0625, 0.5, 0.0625, 0.0625}, + {-0.0625, -0.5, -0.0625, 0.0625, 0.5, 0.0625}, + {-0.0625, -0.0625, -0.5, 0.0625, 0.0625, 0.5}, + {-0.5, -0.0625, -0.0625, 0.5, 0.0625, 0.0625}, {-0.25, -0.25, -0.25, 0.25, 0.25, 0.25}, } }, - + drop = { max_items = 1, items = { @@ -148,7 +148,7 @@ minetest.register_node("df_trees:spore_tree_fruiting_body", { df_dependencies.register_leafdecay({ trunks = {"df_trees:spore_tree"}, leaves = {"df_trees:spore_tree_hyphae", "df_trees:spore_tree_fruiting_body"}, - radius = 3, + radius = 3, }) minetest.register_node("df_trees:spore_tree_sapling", { @@ -185,7 +185,7 @@ minetest.register_node("df_trees:spore_tree_sapling", { on_destruct = function(pos) minetest.get_node_timer(pos):stop() end, - + on_timer = function(pos) if df_farming and df_farming.kill_if_sunlit(pos) then return @@ -201,16 +201,14 @@ local c_spore_pod = minetest.get_content_id("df_trees:spore_tree_fruiting_body") local c_tree = minetest.get_content_id("df_trees:spore_tree") local c_spore_frond = minetest.get_content_id("df_trees:spore_tree_hyphae") -df_trees.spawn_spore_tree_vm = function(vi, area, data, data_param2, height, size, iters, has_fruiting_bodies) +df_trees.spawn_spore_tree_vm = function(vi_spawn, area, data, data_param2, height, size, iters, has_fruiting_bodies) if height == nil then height = math.random(3,6) end if size == nil then size = 2 end if iters == nil then iters = 10 end if has_fruiting_bodies == nil then has_fruiting_bodies = math.random() < 0.5 end - local pos = area:position(vi) + local pos = area:position(vi_spawn) local x, y, z = pos.x, pos.y, pos.z - - local has_fruiting_bodies = true -- Trunk for yy = y, y + height - 1 do diff --git a/df_trees/torchspine.lua b/df_trees/torchspine.lua index 0f28da0..e23d2de 100644 --- a/df_trees/torchspine.lua +++ b/df_trees/torchspine.lua @@ -57,7 +57,7 @@ local stal_on_place = function(itemstack, placer, pointed_thing) local newnode= {name = itemstack:get_name(), param2 = new_param2, param1=0} local oldnode= minetest.get_node(pt.above) minetest.add_node(pt.above, {name = itemstack:get_name(), param2 = new_param2}) - + -- Run script hook local take_item = true for _, callback in ipairs(core.registered_on_placenodes) do @@ -70,7 +70,7 @@ local stal_on_place = function(itemstack, placer, pointed_thing) take_item = false end end - + if not minetest.is_creative_enabled(placer:get_player_name()) and take_item then itemstack:take_item() end @@ -85,11 +85,11 @@ local stal_box_4 = {{-0.375+x_disp, -0.5, -0.375+z_disp, 0.375+x_disp, 0.5, 0.37 local torchspine_list = {"df_trees:torchspine_1","df_trees:torchspine_2","df_trees:torchspine_3","df_trees:torchspine_4"} local grow_torchspine = function(pos) local param2 = minetest.get_node(pos).param2 - + if param2 > 3 then return -- tipped over, don't grow end - + local node_above = minetest.get_node({x=pos.x, y=pos.y+1, z=pos.z}) local node_above_def = minetest.registered_nodes[node_above.name] if not node_above_def.buildable_to then @@ -151,7 +151,7 @@ minetest.register_node("df_trees:torchspine_1", { minetest.swap_node(pos, {name = "df_trees:torchspine_1_lit", param2 = node.param2}) end end, - + on_timer = function(pos) local above_def = minetest.registered_nodes[minetest.get_node({x=pos.x, y=pos.y+1, z=pos.z}).name] if above_def and above_def.buildable_to then @@ -160,7 +160,7 @@ minetest.register_node("df_trees:torchspine_1", { end minetest.get_node_timer(pos):start(math.random(torchspine_min_delay, torchspine_max_delay)) end, - + on_destruct = function(pos) minetest.get_node_timer(pos):stop() end, @@ -186,11 +186,11 @@ minetest.register_node("df_trees:torchspine_1_lit", { _mcl_hardness = 2, on_place = stal_on_place, - + on_timer = function(pos) grow_torchspine(pos) end, - + on_destruct = function(pos) minetest.get_node_timer(pos):stop() end, @@ -322,7 +322,7 @@ minetest.register_node("df_trees:torchspine_ember", { _mcl_hardness = 1, on_place = stal_on_place, - + on_construct = function(pos) if df_trees.torchspine_growth_permitted(pos) then minetest.get_node_timer(pos):start(math.random(torchspine_min_delay, torchspine_max_delay)) @@ -331,7 +331,7 @@ minetest.register_node("df_trees:torchspine_ember", { on_destruct = function(pos) minetest.get_node_timer(pos):stop() end, - + on_timer = function(pos) minetest.swap_node(pos, {name="df_trees:torchspine_1", param2=minetest.get_node(pos).param2}) minetest.get_node_timer(pos):start(math.random(torchspine_min_delay, torchspine_max_delay)) @@ -346,14 +346,15 @@ df_trees.spawn_torchspine = function(pos) local vm = minetest.get_voxel_manip() local minp, maxp = vm:read_from_map( {x = x, y = y, z = z}, - {x = x, y = y+height-1, z = z} + {x = x, y = y+stem_height-1, z = z} ) local area = VoxelArea:new({MinEdge = minp, MaxEdge = maxp}) local data = vm:get_data() local data_param2 = vm:get_param2_data() + local vi = area:index(pos) + + df_trees.spawn_torchspine_vm(vi, area, data, data_param2, stem_height) - df_trees.spawn_torchspine_vm(vi, area, data, data_param2, height) - vm:set_data(data) vm:write_to_map() vm:update_map() @@ -380,20 +381,20 @@ df_trees.spawn_torchspine_vm = function(vi, area, data, data_param2, height, lit local param2 = math.random(0,3) local list if lit then list = torchspine_lit_c else list = torchspine_c end - + for i = 0, height-1 do if not minetest.registered_nodes[minetest.get_name_from_content_id(data[vi + area.ystride*i])].buildable_to then height = i break end end - + for i = 0, height-1 do local index = vi + area.ystride*i data[index] = list[height-i] data_param2[index] = param2 end - + local pos = area:position(vi) pos.y = pos.y+height-1 local node = minetest.get_node(pos) diff --git a/df_trees/tower_cap.lua b/df_trees/tower_cap.lua index c39200d..33b97d9 100644 --- a/df_trees/tower_cap.lua +++ b/df_trees/tower_cap.lua @@ -57,7 +57,7 @@ minetest.register_node("df_trees:tower_cap_gills", { df_dependencies.register_leafdecay({ trunks = {"df_trees:tower_cap"}, -- don't need stem nodes here leaves = {"df_trees:tower_cap_gills"}, - radius = 1, + radius = 1, }) --Wood @@ -145,7 +145,7 @@ minetest.register_node("df_trees:tower_cap_sapling", { on_destruct = function(pos) minetest.get_node_timer(pos):stop() end, - + on_timer = function(pos) if df_farming and df_farming.kill_if_sunlit(pos) then return @@ -164,7 +164,7 @@ df_trees.spawn_tower_cap = function(pos) local stem_height = math.random(4,10) local cap_radius = math.random(4,6) local maxy = y + stem_height + 3 - + local vm = minetest.get_voxel_manip() local minp, maxp = vm:read_from_map( {x = x - cap_radius, y = y, z = z - cap_radius}, @@ -174,7 +174,7 @@ df_trees.spawn_tower_cap = function(pos) local data = vm:get_data() subterrane.giant_mushroom(area:indexp(pos), area, data, c_stem, c_cap, c_gills, stem_height, cap_radius) - + vm:set_data(data) vm:write_to_map() vm:update_map() diff --git a/df_trees/tunnel_tube.lua b/df_trees/tunnel_tube.lua index 07369e6..e1c36b9 100644 --- a/df_trees/tunnel_tube.lua +++ b/df_trees/tunnel_tube.lua @@ -22,7 +22,7 @@ minetest.register_node("df_trees:tunnel_tube", { on_place = minetest.rotate_node, _mcl_blast_resistance = 2, _mcl_hardness = 2, - + node_box = { type = "fixed", fixed = { @@ -190,7 +190,7 @@ if df_trees.config.enable_tnt then local tnt_radius = tonumber(minetest.settings:get("tnt_radius") or 3) * 2/3 local tnt_def = {radius = tnt_radius, damage_radius = tnt_radius * 2} local torch_item = df_dependencies.node_name_torch - + local drop_items = { max_items = 1, items = { @@ -216,7 +216,7 @@ if df_trees.config.enable_tnt then minetest.swap_node(pos, {name = "df_trees:tunnel_tube_fruiting_body_burning"}) minetest.registered_nodes["df_trees:tunnel_tube_fruiting_body_burning"].on_construct(pos) end - + minetest.register_node("df_trees:tunnel_tube_fruiting_body", { description = S("Tunnel Tube Fruiting Body"), _doc_items_longdesc = df_trees.doc.tunnel_tube_desc, @@ -230,7 +230,7 @@ if df_trees.config.enable_tnt then drop = drop_items, _mcl_blast_resistance = 12, _mcl_hardness = 2, - + on_punch = function(pos, node, puncher) if puncher:get_wielded_item():get_name() == torch_item then minetest.swap_node(pos, {name = "df_trees:tunnel_tube_fruiting_body_burning"}) @@ -256,7 +256,7 @@ if df_trees.config.enable_tnt then on_ignite = on_burn, _on_burn = on_burn, }) - + minetest.register_node("df_trees:tunnel_tube_fruiting_body_burning", { description = S("Tunnel Tube Fruiting Body"), _doc_items_longdesc = df_trees.doc.tunnel_tube_desc, @@ -297,7 +297,7 @@ else on_place = minetest.rotate_node, _mcl_blast_resistance = 12, _mcl_hardness = 2, - + drop = { max_items = 3, items = { @@ -354,7 +354,7 @@ minetest.register_node("df_trees:tunnel_tube_sapling", { on_destruct = function(pos) minetest.get_node_timer(pos):stop() end, - + on_timer = function(pos) if df_farming and df_farming.kill_if_sunlit(pos) then return @@ -398,7 +398,7 @@ df_trees.spawn_tunnel_tube = function(pos) vm:set_data(data) vm:set_param2_data(param2_data) vm:write_to_map() - vm:update_map() + vm:update_map() end local c_air = minetest.get_content_id("air") diff --git a/df_underworld_items/config.lua b/df_underworld_items/config.lua index 4129a5c..ea00606 100644 --- a/df_underworld_items/config.lua +++ b/df_underworld_items/config.lua @@ -17,10 +17,10 @@ local function setting(stype, name, default, description) value = default end df_underworld_items.config[name] = value - + if print_settingtypes then minetest.debug(CONFIG_FILE_PREFIX..name.." ("..description..") "..stype.." "..tostring(default)) - end + end end setting("bool", "invulnerable_slade", true, "Slade is invulnerable to players") diff --git a/df_underworld_items/crystals_amethyst.lua b/df_underworld_items/crystals_amethyst.lua index c64898d..4bd3a31 100644 --- a/df_underworld_items/crystals_amethyst.lua +++ b/df_underworld_items/crystals_amethyst.lua @@ -35,7 +35,7 @@ df_underworld_items.underworld_shard = function(data, area, vi, x_slant, z_slant if z_slant == nil then z_slant = math.random(-1,1) end if rotated == nil then rotated = math.random() > 0.5 end if length == nil then length = math.random(4, 12) end - + length = math.ceil(length/2) * 2 -- make it an even multiple of 2 local xstride, ystride, zstride @@ -47,16 +47,16 @@ df_underworld_items.underworld_shard = function(data, area, vi, x_slant, z_slant xstride = 1 zstride = area.zstride end - + -- bottom end safe_write(data, area, vi, c_amethyst) safe_write(data, area, vi+xstride, c_amethyst) - + for i = 1, length do vi = vi + ystride - + safe_write(data, area, vi-xstride, c_amethyst) - + safe_write(data, area, vi+zstride, c_amethyst) safe_write(data, area, vi, c_amethyst) safe_write(data, area, vi-zstride, c_amethyst) @@ -73,7 +73,7 @@ df_underworld_items.underworld_shard = function(data, area, vi, x_slant, z_slant end vi = vi + ystride - + safe_write(data, area, vi, c_amethyst) safe_write(data, area, vi+xstride, c_amethyst) end \ No newline at end of file diff --git a/df_underworld_items/glow_stone.lua b/df_underworld_items/glow_stone.lua index f3699ea..419ced6 100644 --- a/df_underworld_items/glow_stone.lua +++ b/df_underworld_items/glow_stone.lua @@ -32,7 +32,7 @@ if tnt_boom then glowstone_def.on_dig = function(pos, node, digger) if minetest.node_dig(pos, node, digger) then tnt_boom(pos, {radius=3}) - end + end end end minetest.register_node("df_underworld_items:glowstone", glowstone_def) \ No newline at end of file diff --git a/df_underworld_items/glowing_pit_plasma.lua b/df_underworld_items/glowing_pit_plasma.lua index f12af38..1a598ae 100644 --- a/df_underworld_items/glowing_pit_plasma.lua +++ b/df_underworld_items/glowing_pit_plasma.lua @@ -18,7 +18,7 @@ minetest.register_node("df_underworld_items:pit_plasma", { }, }, }, - + groups={pit_plasma=1, pit_plasma_resistant=1,destroys_items=1, set_on_fire=15, fire_damage=1, liquid=1}, walkable = false, pointable = false, @@ -161,7 +161,7 @@ if df_underworld_items.config.destructive_pit_plasma then end if sparkle_pos then sparkle(sparkle_pos) - end + end end, }) end diff --git a/df_underworld_items/puzzle_chest.lua b/df_underworld_items/puzzle_chest.lua index 2579f98..3c977ca 100644 --- a/df_underworld_items/puzzle_chest.lua +++ b/df_underworld_items/puzzle_chest.lua @@ -7,7 +7,7 @@ end local initialize = function(pos, meta) if not meta:contains("key") then local inv = meta:get_inventory() - inv:set_size("main", 8) + inv:set_size("main", 8) local next_seed = math.random() * 2^21 math.randomseed(pos.x + pos.y^8 + pos.z^16) -- Key is consistent with location @@ -66,9 +66,9 @@ local show_formspec = function(pos, node, clicker, itemstack, pointed_thing) .. "container[3,0]" .. formspec_dial("dial2", state[2]) .. "container_end[]" .. "container[0,1.5]" .. formspec_dial("dial3", state[3]) .. "container_end[]" .. "container[3,1.5]" .. formspec_dial("dial4", state[4]) .. "container_end[]" - .. "container[6.1,0]" .. formspec_bar(true, state_sum[1], key_sum[1]) .. "container_end[]" - .. "container[6.1,1.5]" .. formspec_bar(true, state_sum[2], key_sum[2]) .. "container_end[]" - .. "container[1,2.75]" .. formspec_bar(false, state_sum[3], key_sum[3]) .. "container_end[]" + .. "container[6.1,0]" .. formspec_bar(true, state_sum[1], key_sum[1]) .. "container_end[]" + .. "container[6.1,1.5]" .. formspec_bar(true, state_sum[2], key_sum[2]) .. "container_end[]" + .. "container[1,2.75]" .. formspec_bar(false, state_sum[3], key_sum[3]) .. "container_end[]" .. "container[4,2.75]" .. formspec_bar(false, state_sum[4], key_sum[4]) .. "container_end[]" .. "container_end[]" .. itemslot_bg(0.6,6.7,8,4,0.25) @@ -139,7 +139,7 @@ minetest.register_node("df_underworld_items:puzzle_chest_closed", { sounds = df_dependencies.sound_stone({ footstep = { name = "bedrock2_step", gain = 1 } }), _mcl_blast_resistance = 1200, _mcl_hardness = 50, - + on_rightclick = show_formspec, can_dig = puzzle_chest_can_dig, }) @@ -166,7 +166,7 @@ minetest.register_node("df_underworld_items:puzzle_chest_opened", { sounds = df_dependencies.sound_stone({ footstep = { name = "bedrock2_step", gain = 1 } }), _mcl_blast_resistance = 1200, _mcl_hardness = 50, - + on_rightclick = show_formspec, can_dig = puzzle_chest_can_dig, }) diff --git a/df_underworld_items/puzzle_seal.lua b/df_underworld_items/puzzle_seal.lua index 28cd619..bc08dea 100644 --- a/df_underworld_items/puzzle_seal.lua +++ b/df_underworld_items/puzzle_seal.lua @@ -40,7 +40,7 @@ local ensure_meta = function(pos) meta:set_string("key", minetest.serialize(key)) meta:mark_as_private("key") end - + local timer = minetest.get_node_timer(pos) if not timer:is_started() then timer:start(4) @@ -76,7 +76,7 @@ local cull_colour_groups = function() table.insert(culled_colour_groups, new_set) end colour_groups = culled_colour_groups - + -- collect a list of all items with useful colour groups -- to be used for treasure generation local colour_item_set = {} @@ -109,7 +109,7 @@ local test_key = function(pos, player) if not meta:contains("key") then return false end - + local keystring = meta:get_string("key") local key = minetest.deserialize(keystring) local inv = meta:get_inventory() @@ -150,7 +150,7 @@ end local formspec_prefix = "df_underworld_items_puzzle_seal:" local itemslot_bg = df_dependencies.get_itemslot_bg local get_formspec = function(pos, unlocked) - local formspec = + local formspec = "size[8,8]" .."image[0,0;2.5,4;dfcaverns_puzzle_inscription_background.png^dfcaverns_puzzle_inscription_1.png]" .."image[5.8,0;2.5,4;dfcaverns_puzzle_inscription_background.png^[transformR180^dfcaverns_puzzle_inscription_2.png]" @@ -176,7 +176,7 @@ local get_formspec = function(pos, unlocked) else formspec = formspec .. "image[1.25,1.25;1,1;dfcaverns_seal.png]" end - + formspec = formspec .."container_end[]" -- .."container[5,0.5]" @@ -277,7 +277,7 @@ local puzzle_seal_def = { ensure_meta(pos) refresh_formspec(pos, clicker) end, - on_timer = function(pos, elapsed) + on_timer = function(pos, elapsed) local meta = minetest.get_meta(pos) local unlocked = meta:get_int("unlocked") if unlocked > 0 then @@ -352,7 +352,7 @@ local digging_seal_def = { gain = 1.0, max_hear_distance = 32, }) - + local minpos = vector.add(pos, {x=0, y=-1, z=0}) minetest.add_particlespawner({ amount = 100, @@ -372,7 +372,7 @@ local digging_seal_def = { collision_removal = true, glow = 15, }) - + if minetest.get_item_group(below_node.name, "slade") == 0 then if df_underworld_items.config.enable_slade_drill then minetest.set_node(pos, {name="air"}) @@ -385,7 +385,7 @@ local digging_seal_def = { end return end - + local rot = node.param2 if rot == 0 then minetest.place_schematic({x=pos.x-3, y=pos.y-2, z=pos.z-3}, df_underworld_items.seal_stair_schem, 0, {}, true) @@ -420,7 +420,7 @@ minetest.register_on_player_receive_fields(function(player, formname, fields) if formname:sub(1,prefix_len) ~= formspec_prefix or not fields.open then return end - local pos_string = formname:sub(prefix_len+1) + local pos_string = formname:sub(prefix_len+1) local pos = minetest.string_to_pos(pos_string) if test_key(pos) then if named_waypoints_path then @@ -525,7 +525,7 @@ df_dependencies.register_stairs("slade_block") if invulnerable then for name, def in pairs(minetest.registered_nodes) do - if (name:sub(1,7) == "stairs:" and name:sub(-11) == "slade_block") or + if (name:sub(1,7) == "stairs:" and name:sub(-11) == "slade_block") or name:sub(1,11) == "mcl_stairs:" and name:sub(-11) == "slade_block" then minetest.override_item(name, {can_dig = can_dig}) end @@ -540,7 +540,7 @@ if df_dependencies.node_name_stair_slade_block then n11 = { name = df_dependencies.node_name_slab_slade_block, param2 = 1 } n10 = { name = df_dependencies.node_name_slab_slade_block, param2 = 21 } - if df_dependencies.node_name_slab_slade_block_top then + if df_dependencies.node_name_slab_slade_block_top then -- Mineclone slabs don't support full rotation, this is how to flip them over n10.name = df_dependencies.node_name_slab_slade_block_top n10.param2 = 1 @@ -551,35 +551,35 @@ end df_underworld_items.seal_temple_schem = { size = {y = 6, x = 7, z = 7}, data = { - n15, n2, n3, n3, n3, n4, n14, n14, n3, n3, n3, n3, n3, n15, n13, n3, n3, - n3, n3, n3, n13, n16, n3, n3, n3, n3, n3, n16, n6, n6, n6, n6, n6, n6, - n6, n6, n6, n6, n6, n6, n6, n6, n7, n3, n3, n3, n3, n3, n7, n3, n3, - n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, - n3, n3, n6, n3, n3, n3, n3, n3, n6, n6, n6, n6, n6, n6, n6, n6, n3, - n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, - n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n6, n3, n3, n3, n3, n3, n6, - n6, n6, n3, n3, n3, n6, n6, n3, n3, n3, n8, n3, n3, n3, n3, n3, n3, - n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, - n3, n6, n3, n3, n3, n3, n3, n6, n6, n6, n3, n3, n3, n6, n6, n3, n3, - n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, - n3, n3, n3, n3, n3, n3, n3, n3, n3, n6, n3, n3, n3, n3, n3, n6, n6, - n6, n3, n3, n3, n6, n6, n9, n3, n3, n3, n3, n3, n9, n3, n3, n3, n3, - n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, - n6, n3, n3, n3, n3, n3, n6, n6, n6, n6, n6, n6, n6, n6, n12, n2, n3, - n3, n3, n4, n12, n14, n3, n3, n3, n3, n3, n15, n13, n3, n3, n3, n3, n3, - n12, n16, n3, n3, n3, n3, n3, n16, n6, n6, n6, n6, n6, n6, n6, n6, n6, - n6, n6, n6, n6, n6, + n15, n2, n3, n3, n3, n4, n14, n14, n3, n3, n3, n3, n3, n15, n13, n3, n3, + n3, n3, n3, n13, n16, n3, n3, n3, n3, n3, n16, n6, n6, n6, n6, n6, n6, + n6, n6, n6, n6, n6, n6, n6, n6, n7, n3, n3, n3, n3, n3, n7, n3, n3, + n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, + n3, n3, n6, n3, n3, n3, n3, n3, n6, n6, n6, n6, n6, n6, n6, n6, n3, + n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, + n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n6, n3, n3, n3, n3, n3, n6, + n6, n6, n3, n3, n3, n6, n6, n3, n3, n3, n8, n3, n3, n3, n3, n3, n3, + n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, + n3, n6, n3, n3, n3, n3, n3, n6, n6, n6, n3, n3, n3, n6, n6, n3, n3, + n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, + n3, n3, n3, n3, n3, n3, n3, n3, n3, n6, n3, n3, n3, n3, n3, n6, n6, + n6, n3, n3, n3, n6, n6, n9, n3, n3, n3, n3, n3, n9, n3, n3, n3, n3, + n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, n3, + n6, n3, n3, n3, n3, n3, n6, n6, n6, n6, n6, n6, n6, n6, n12, n2, n3, + n3, n3, n4, n12, n14, n3, n3, n3, n3, n3, n15, n13, n3, n3, n3, n3, n3, + n12, n16, n3, n3, n3, n3, n3, n16, n6, n6, n6, n6, n6, n6, n6, n6, n6, + n6, n6, n6, n6, n6, } } df_underworld_items.seal_stair_schem = { size = {y = 2, x = 7, z = 7}, data = { - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n10, - n3, n3, n3, n1, n1, n3, n11, n1, n10, n3, n1, n1, n11, n3, n3, n3, n3, - n1, n1, n3, n3, n3, n3, n3, n1, n1, n3, n3, n3, n3, n3, n1, n1, n3, - n3, n3, n3, n3, n1, n1, n3, n3, n3, n3, n3, n1, n1, n3, n3, n3, n3, - n3, n1, n1, n3, n3, n3, n3, n3, n1, n1, n3, n3, n3, n3, n3, n1, n1, - n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n10, + n3, n3, n3, n1, n1, n3, n11, n1, n10, n3, n1, n1, n11, n3, n3, n3, n3, + n1, n1, n3, n3, n3, n3, n3, n1, n1, n3, n3, n3, n3, n3, n1, n1, n3, + n3, n3, n3, n3, n1, n1, n3, n3, n3, n3, n3, n1, n1, n3, n3, n3, n3, + n3, n1, n1, n3, n3, n3, n3, n3, n1, n1, n3, n3, n3, n3, n3, n1, n1, + n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, n1, } } \ No newline at end of file diff --git a/df_underworld_items/slade.lua b/df_underworld_items/slade.lua index 87adb7c..4456a54 100644 --- a/df_underworld_items/slade.lua +++ b/df_underworld_items/slade.lua @@ -171,9 +171,9 @@ df_dependencies.register_stairs("slade_brick") if invulnerable then for name, def in pairs(minetest.registered_nodes) do - if (name:sub(1,7) == "stairs:" and name:sub(-11) == "slade_block") or + if (name:sub(1,7) == "stairs:" and name:sub(-11) == "slade_block") or name:sub(1,11) == "mcl_stairs:" and name:sub(-11) == "slade_brick" then - minetest.override_item(name, {can_dig = server_diggable_only}) + minetest.override_item(name, {can_dig = server_diggable_only}) end end end diff --git a/df_underworld_items/slade_drill.lua b/df_underworld_items/slade_drill.lua index f3f7dc7..b884a6a 100644 --- a/df_underworld_items/slade_drill.lua +++ b/df_underworld_items/slade_drill.lua @@ -57,7 +57,7 @@ local slade_drill_def = { drill_particles(pointed_thing.above) return itemstack end - end + end end, } diff --git a/hunter_statue/init.lua b/hunter_statue/init.lua index a14fa09..87fa53b 100644 --- a/hunter_statue/init.lua +++ b/hunter_statue/init.lua @@ -39,13 +39,13 @@ local test_array = { -- damage = 8 -- knockback = 16 -- tnt_vulnerable = false --- tnt_debris = +-- tnt_debris = -- hunters_allowed_here = -- function(pos) --- other_overrides = +-- other_overrides = --} hunter_statue.register_hunter_statue = function(node_name, statue_def) - + local def = { description = statue_def.description or S("Hunter Statue"), -- _doc_items_longdesc = long_description, @@ -60,7 +60,7 @@ hunter_statue.register_hunter_statue = function(node_name, statue_def) groups = statue_def.groups or {falling_node = 1}, sounds = statue_def.sounds or default_sounds, } - + if statue_def.tnt_vulnerable then def.on_blast = function(pos, intensity) if intensity >= 1.0 then @@ -69,19 +69,19 @@ hunter_statue.register_hunter_statue = function(node_name, statue_def) end end end - + if statue_def.other_overrides then for k, v in pairs(statue_def.other_overrides) do def[k] = v end end - + local knockback = statue_def.knockback or 16 local damage = statue_def.damage or 8 local hunters_allowed_here = statue_def.hunters_allowed_here - + minetest.register_node(node_name, def) - + minetest.register_abm({ label = node_name .. " ABM", nodenames = {node_name}, @@ -109,9 +109,9 @@ hunter_statue.register_hunter_statue = function(node_name, statue_def) nearest_player = player nearest_pos = player_pos end - end + end end - + if nearest_player then if nearest_distance < 2 then local armour_multiplier = 1 diff --git a/ice_sprites/init.lua b/ice_sprites/init.lua index 38a3ba1..38e3ad3 100644 --- a/ice_sprites/init.lua +++ b/ice_sprites/init.lua @@ -19,9 +19,9 @@ if minetest.get_modpath("doc") then end ice_sprite_bottle_desc = S("A bottle containing a captured ice sprite.") ice_sprite_bottle_usage = S("Ice sprites radiate both light and freezing cold.") - end + end end - + minetest.register_node("ice_sprites:ice_sprite", { description = S("Ice Sprite"), _doc_items_longdesc = ice_sprite_desc, diff --git a/looped_node_sound/init.lua b/looped_node_sound/init.lua index 3feb267..13035c0 100644 --- a/looped_node_sound/init.lua +++ b/looped_node_sound/init.lua @@ -7,13 +7,13 @@ looped_node_sound = {} -- cycle_time =, -- gain_per_node =, -- max_gain =, --- max_hear_distance =, +-- max_hear_distance =, --}) looped_node_sound.register = function(def) local handles = {} local timer = 0 - + -- Parameters local radius = def.radius or 8 -- node search radius around player local cycle = def.cycle_time or 3 -- Cycle time for sound updates diff --git a/mine_gas/init.lua b/mine_gas/init.lua index c946879..9c7f155 100644 --- a/mine_gas/init.lua +++ b/mine_gas/init.lua @@ -16,7 +16,7 @@ if minetest.get_modpath("doc") then if minetest.get_modpath("tnt") then gas_usage = gas_usage .. " " .. S("When exposed to air and an ignition source it can produce a deadly explosion.") end - + seep_desc = S("Some coal deposits have cracks that seep a steady flow of mine gas.") seep_usage = S("Mining out such a deposit seals the crack.") end @@ -98,11 +98,11 @@ minetest.register_abm({ next_node = minetest.get_node(next_pos) if next_node.name == "air" then minetest.swap_node(next_pos, gas_node) - minetest.swap_node(pos, next_node) + minetest.swap_node(pos, next_node) else local dir = directions[math.random(1,4)] - local next_pos = vector.add(pos, dir) - local next_node = minetest.get_node(next_pos) + next_pos = vector.add(pos, dir) + next_node = minetest.get_node(next_pos) if next_node.name == "air" or minetest.get_item_group(next_node.name, "liquid") > 0 then if next_node.name == "air" or math.random() < 0.5 then -- gas never "climbs" above air. minetest.swap_node(next_pos, gas_node) @@ -143,7 +143,7 @@ minetest.register_abm({ soundfile_cool_lava, {pos = pos, max_hear_distance = 16, gain = 0.1} ) - end + end end, }) @@ -164,7 +164,7 @@ if tnt_boom then if math.random() < 0.01 then minetest.set_node(pos, {name="mine_gas:gas_wisp"}) end - end + end end, }) end @@ -210,6 +210,6 @@ minetest.register_abm({ {pos = pos, max_hear_distance = 8, gain = 0.05} ) end - end + end end, }) \ No newline at end of file diff --git a/oil/init.lua b/oil/init.lua index 0a6cf8c..78aab1d 100644 --- a/oil/init.lua +++ b/oil/init.lua @@ -167,11 +167,11 @@ if minetest.get_modpath("dynamic_liquid") then minetest.swap_node(pos, next_node) end end - end + end end end, }) - + -- If oil is wandering around on top of a layer of water that isn't full, drop it down -- into the water layer. This helps drive the system toward a more static state with a flat-looking surface. minetest.register_abm({ @@ -208,7 +208,7 @@ if df_dependencies.bucket_register_liquid then burntime = 370, -- same as coalblock replacements = {{"oil:oil_bucket", bucket_empty}}, }) - + if minetest.get_modpath("basic_materials") then minetest.register_craft({ type = "cooking", diff --git a/pit_caves/init.lua b/pit_caves/init.lua index 46d291f..ffbeab5 100644 --- a/pit_caves/init.lua +++ b/pit_caves/init.lua @@ -67,7 +67,7 @@ local get_pit = function(pos) local location = scatter_2d(corner_xz, pit_region_size, 0) local depth = math.floor(math.random() * (max_depth - min_depth) + min_depth) local top = math.floor(math.random() * (max_top - min_top) + min_top) - + math.randomseed(next_seed) return {location = location, depth = depth, top = top} end @@ -90,24 +90,24 @@ minetest.register_on_generated(function(minp, maxp, seed) end local pit = get_pit(minp) - + if pit == nil then return -- no pit in this map region end - + local location_x = pit.location.x local location_z = pit.location.z - + -- early out if the pit is too far away to matter -- The plus 20 is because the noise being added will generally be in the 0-20 range, see the "distance" calculation below - if location_x - 20 > maxp.x or - location_x + 20 < minp.x or + if location_x - 20 > maxp.x or + location_x + 20 < minp.x or location_z - 20 > maxp.z or location_z + 20 < minp.z then return end - + local top = pit.top local depth = pit.depth @@ -128,7 +128,7 @@ minetest.register_on_generated(function(minp, maxp, seed) end local nvals_perlin = mapgen_helper.perlin3d("pit_caves:pit", emin, emax, perlin_params) - + for vi, x, y, z in area:iterp_xyz(emin, emax) do if not (ignore and ignore(data[vi])) then local distance_perturbation = (nvals_perlin[vi]+1)*10 @@ -140,7 +140,7 @@ minetest.register_on_generated(function(minp, maxp, seed) -- taper the top end distance = distance - ((taper_min - y)/2) end - + if distance < pit_radius then if y < depth + 20 and data[vi] ~= c_air then data[vi] = c_gravel @@ -152,7 +152,7 @@ minetest.register_on_generated(function(minp, maxp, seed) end end end - + --send data back to voxelmanip vm:set_data(data) --calc lighting @@ -166,14 +166,6 @@ end) ---------------------------------------------------------------------------------------------- -- Debugging and sightseeing commands -function round(val, decimal) - if (decimal) then - return math.floor( (val * 10^decimal) + 0.5) / (10^decimal) - else - return math.floor(val+0.5) - end -end - local send_pit_state = function(pos, name) local pit = get_pit(pos) if pit == nil then