diff --git a/mods/rgt_player/textures/rgt_heart.png b/mods/rgt_player/textures/rgt_heart.png new file mode 100644 index 0000000..c4b6e38 Binary files /dev/null and b/mods/rgt_player/textures/rgt_heart.png differ diff --git a/mods/rgt_towns/rgt_towns_core/items.lua b/mods/rgt_towns/rgt_towns_core/items.lua index 95ae85d..b0921f6 100644 --- a/mods/rgt_towns/rgt_towns_core/items.lua +++ b/mods/rgt_towns/rgt_towns_core/items.lua @@ -72,7 +72,7 @@ function ns.check_recipe(inv, plot) end minetest.register_node(":rgt_towns:constructor", { - tiles = {"[fill:16x16:#8af"}, + tiles = {"rgt_towns_constructor_top.png", "rgt_towns_constructor_bottom.png", "rgt_towns_constructor_side.png"}, on_construct = function(pos) local inv = minetest.get_meta(pos):get_inventory() inv:set_size("main", 9) diff --git a/mods/rgt_towns/rgt_towns_core/plots.lua b/mods/rgt_towns/rgt_towns_core/plots.lua index ae1627b..9ac16d2 100644 --- a/mods/rgt_towns/rgt_towns_core/plots.lua +++ b/mods/rgt_towns/rgt_towns_core/plots.lua @@ -149,20 +149,15 @@ function ns.can_build_plot(box, grid) for name, grid2 in pairs(ns.grids) do local i = aabb_intersects_sphere(box, grid2.origin, grid2.radius) if name == grid or i then - ns.add_cube(box.min, box.max, {color = "#fff"}) -- Translate box to grid2 local space and compute candidate cell range local min = vector.floor((box.min -grid2.origin) /15) local max = vector.ceil((box.max -grid2.origin) /15) - - ns.add_cube(min *15 +grid2.origin, max *15 +grid2.origin) - + if grid2.type == "3d" then -- TODO: implement else for x = min.x, max.x do for z = min.z, max.z do - ns.add_point(vector.new(x,0,z) *15 +grid2.origin) --- print("Box: "..dump(box).."; min: "..min:to_string().."; max: "..max:to_string()) local plot = db:get("plot:"..name.."_"..x.."_0_"..z) if plot then plot = minetest.parse_json(plot) diff --git a/mods/rgt_towns/rgt_towns_core/textures/rgt_towns_constructor_bottom.png b/mods/rgt_towns/rgt_towns_core/textures/rgt_towns_constructor_bottom.png new file mode 100644 index 0000000..4f9f343 Binary files /dev/null and b/mods/rgt_towns/rgt_towns_core/textures/rgt_towns_constructor_bottom.png differ diff --git a/mods/rgt_towns/rgt_towns_core/textures/rgt_towns_constructor_side.png b/mods/rgt_towns/rgt_towns_core/textures/rgt_towns_constructor_side.png new file mode 100644 index 0000000..6078788 Binary files /dev/null and b/mods/rgt_towns/rgt_towns_core/textures/rgt_towns_constructor_side.png differ diff --git a/mods/rgt_towns/rgt_towns_core/textures/rgt_towns_constructor_top.png b/mods/rgt_towns/rgt_towns_core/textures/rgt_towns_constructor_top.png new file mode 100644 index 0000000..9444da1 Binary files /dev/null and b/mods/rgt_towns/rgt_towns_core/textures/rgt_towns_constructor_top.png differ diff --git a/mods/rgt_world/init.lua b/mods/rgt_world/init.lua index 96cee96..ac8f3c9 100644 --- a/mods/rgt_world/init.lua +++ b/mods/rgt_world/init.lua @@ -1,4 +1,14 @@ +local function rep(tx, size) + local out = "[combine:"..(size *16).."x"..(size *16) + for x = 0, size -1 do + for y = 0, size -1 do + out = out..":"..(x *16)..","..(y *16).."="..tx + end + end + return out +end + rgt.register_node("stone", { tiles = {"rgt_stone.png"}, groups = {dig_immediate = 3} @@ -20,6 +30,62 @@ rgt.register_node("dirt_grass", { groups = {dig_immediate = 3} }) +rgt.register_node("path_grass", { + drawtype = "nodebox", + node_box = { + type = "fixed", + fixed = { + -0.5, -0.5, -0.5, + 0.5, 7/16, 0.5 + } + }, + tiles = {"rgt_path_grass_top.png", "rgt_dirt.png", "rgt_dirt.png^rgt_path_grass_side.png"}, +-- tiles = {"[fill:16x16:0,0:#3e7e7b^[fill:14x14:1,1:#326764"}, + paramtype = "light", + sunlight_propagates = false, + groups = {dig_immediate = 3} +}) + + + +rgt.register_node("oak_planks", { + tiles = {"rgt_oak_planks.png"}, + groups = {dig_immediate = 3} +}) + +rgt.register_node("dark_planks", { + tiles = {"rgt_dark_planks.png"}, + groups = {dig_immediate = 3} +}) + +rgt.register_node("spruce_planks", { + tiles = {"rgt_spruce_planks.png"}, + groups = {dig_immediate = 3} +}) + +rgt.register_node("acacia_planks", { + tiles = {"rgt_acacia_planks.png"}, + groups = {dig_immediate = 3} +}) + +rgt.register_node("redwood_planks", { + tiles = {"rgt_redwood_planks.png"}, + groups = {dig_immediate = 3} +}) + +rgt.register_node("birch_planks", { + tiles = {"rgt_birch_planks.png"}, + groups = {dig_immediate = 3} +}) + +--minetest.register_decoration { +-- deco_type = "simple", +-- place_on = "dirt_grass", +-- fill_ratio = 0.5, +-- decoration = {"red_glazed_terracotta:oak_planks", "red_glazed_terracotta:spruce_planks", "red_glazed_terracotta:dark_planks", "red_glazed_terracotta:redwood_planks", "red_glazed_terracotta:acacia_planks", "red_glazed_terracotta:birch_planks"} +--} + + rgt.register_node("water", { tiles = {"[fill:16x16:0,0:#2d5a7c77^[fill:14x14:1,1:#2d5a7c33"}, groups = {dig_immediate = 3}, diff --git a/mods/rgt_world/textures/rgt_acacia_planks.png b/mods/rgt_world/textures/rgt_acacia_planks.png new file mode 100644 index 0000000..f6b6c65 Binary files /dev/null and b/mods/rgt_world/textures/rgt_acacia_planks.png differ diff --git a/mods/rgt_world/textures/rgt_birch_planks.png b/mods/rgt_world/textures/rgt_birch_planks.png new file mode 100644 index 0000000..7fead27 Binary files /dev/null and b/mods/rgt_world/textures/rgt_birch_planks.png differ diff --git a/mods/rgt_world/textures/rgt_dark_planks.png b/mods/rgt_world/textures/rgt_dark_planks.png new file mode 100644 index 0000000..c123de5 Binary files /dev/null and b/mods/rgt_world/textures/rgt_dark_planks.png differ diff --git a/mods/rgt_world/textures/rgt_oak_planks.png b/mods/rgt_world/textures/rgt_oak_planks.png new file mode 100644 index 0000000..d5e0b4a Binary files /dev/null and b/mods/rgt_world/textures/rgt_oak_planks.png differ diff --git a/mods/rgt_world/textures/rgt_oak_planks_alt.png b/mods/rgt_world/textures/rgt_oak_planks_alt.png new file mode 100644 index 0000000..7efa3b8 Binary files /dev/null and b/mods/rgt_world/textures/rgt_oak_planks_alt.png differ diff --git a/mods/rgt_world/textures/rgt_path_grass.png b/mods/rgt_world/textures/rgt_path_grass.png new file mode 100644 index 0000000..988796a Binary files /dev/null and b/mods/rgt_world/textures/rgt_path_grass.png differ diff --git a/mods/rgt_world/textures/rgt_path_grass_side.png b/mods/rgt_world/textures/rgt_path_grass_side.png new file mode 100644 index 0000000..1c81745 Binary files /dev/null and b/mods/rgt_world/textures/rgt_path_grass_side.png differ diff --git a/mods/rgt_world/textures/rgt_path_grass_top.png b/mods/rgt_world/textures/rgt_path_grass_top.png new file mode 100644 index 0000000..5232e4c Binary files /dev/null and b/mods/rgt_world/textures/rgt_path_grass_top.png differ diff --git a/mods/rgt_world/textures/rgt_redwood_planks.png b/mods/rgt_world/textures/rgt_redwood_planks.png new file mode 100644 index 0000000..d197eda Binary files /dev/null and b/mods/rgt_world/textures/rgt_redwood_planks.png differ diff --git a/mods/rgt_world/textures/rgt_spruce_planks.png b/mods/rgt_world/textures/rgt_spruce_planks.png new file mode 100644 index 0000000..7efa3b8 Binary files /dev/null and b/mods/rgt_world/textures/rgt_spruce_planks.png differ