Compare commits

..

5 Commits

Author SHA1 Message Date
Sys Quatre 00187d7ff6 Corrige crash si objet non supporté à recycler dans scie circulaire 2019-05-05 22:43:06 +02:00
sys4-fr 6a6a22f699 Version 1.2.0
-----BEGIN PGP SIGNATURE-----
 
 iQEcBAABAgAGBQJb+X8mAAoJEDno+L4wsKScmCsIAJcLflaVreRB4Hyqef7s5jUO
 xVOm0T8Pm4L1PLuXPItofLFo/Gd13Hz0TleHZsRhLnk82zhBuU31j7Ha2Wk9tDEb
 70P25UCiiEJRAOlwA2F6OaitdOTK6Mn/sm557z7K/B3xpXqA7IgvkbvucvMmXRyV
 f5QhHzEWBQkh4lQR+KkpJXw5il8DGvkLaXnjYVfxUOOwbLjn+Eov/r2OQgixNQnW
 VI1TmJJJRuXmp+Do0qYq3nstCEl0mgMU3EZofFvxxjx2CtqcjHWU5KiQZXh1BBtx
 N41AB12Nwkk97ptrRA2ilS8nlRZ2rUeqpnVUlM578hR8mffs0V8n5isqAA80PPw=
 =XYQj
 -----END PGP SIGNATURE-----

Merge tag 'v1.2.0' into nalc

Version 1.2.0

# gpg: Signature faite le sam. 24 nov. 2018 17:41:10 CET
# gpg:                avec la clef RSA 39E8F8BE30B0A49C
# gpg: Impossible de vérifier la signature : Pas de clef publique
2018-12-31 16:46:03 +01:00
sys4-fr 88726c5913 Merge branch 'ice-stairs' into fix-node-orientation 2018-09-16 16:17:49 +02:00
sys4-fr cd0d527c8f Add ice and snowblock support with stairsplus. 2018-09-16 16:16:16 +02:00
sys4-fr 3cbc708742 Workaround to fix node orientation (minetest >= 0.4.17.1) 2018-08-24 18:55:14 +02:00
84 changed files with 856 additions and 1698 deletions

View File

@ -1,13 +0,0 @@
root = true
[*]
charset = utf-8
end_of_line = lf
indent_style = space
indent_size = 2
insert_final_newline = true
trim_trailing_whitespace = true
[*.{lua,luacheckrc}]
indent_style = tab
indent_size = 4

View File

@ -1,24 +0,0 @@
name: build
on: [push, pull_request]
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- uses: actions/setup-python@master
- run: |
sudo apt-get update -qq
sudo apt-get install -qqq luarocks
- name: Install pre-commit
run: pip3 install pre-commit
- name: Install LuaCheck
run: luarocks install --local luacheck
- name: Run LuaCheck using pre-commit
run: |
pre-commit run --all-files
$HOME/.luarocks/bin/luacheck .

View File

@ -1,34 +1,14 @@
std = "lua51+minetest"
unused_args = false
allow_defined_top = true
max_line_length = 999
stds.minetest = {
read_globals = {
"DIR_DELIM",
"minetest",
"core",
"dump",
"vector",
"nodeupdate",
"VoxelManip",
"VoxelArea",
"PseudoRandom",
"ItemStack",
"default",
table = {
fields = {
"copy",
},
},
}
}
read_globals = {
"protector",
"isprotect",
"IsPlayerNodeOwner",
"HasOwner",
"getLastOwner",
"GetNodeOwnerName",
"DIR_DELIM",
"minetest", "core",
"dump",
"vector", "nodeupdate",
"VoxelManip", "VoxelArea",
"PseudoRandom", "ItemStack",
"intllib",
"default",
}

View File

@ -1,10 +0,0 @@
repos:
- repo: https://github.com/pre-commit/pre-commit-hooks
rev: v3.3.0
hooks:
- id: fix-byte-order-marker
- id: end-of-file-fixer
- id: trailing-whitespace
- id: mixed-line-ending
args: [--fix=lf]

View File

@ -7,80 +7,6 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
## [Unreleased]
## [2.2.0] - 2021-06-28
### Changed
- Refactored recipe override mechanism to avoid re-coding recipes
when we only want to change the amount produced.
- [Realigned rail recipe to the changes made in Minetest Game.](https://github.com/minetest-mods/moreblocks/pull/169)
- All rail recipes (standard, power, break) were boosted by 50%.
### Fixed
- [Shapeless crafting recipes are now handled in redefinitions.](https://github.com/minetest-mods/moreblocks/pull/171)
- [Aliases are now resolved in Stairs+ circular saw cost calculation.](https://github.com/minetest-mods/moreblocks/pull/175)
- [Fixed strange placement behavior for non-default Stairs+ nodes.](https://github.com/minetest-mods/moreblocks/pull/168)
- [Fixed stairs placement over oddly-shaped nodes.](https://github.com/minetest-mods/moreblocks/pull/166)
## [2.1.0] - 2020-12-14
### Added
- Clean Glass versions of Trap and (Super) Glowing Glass.
- Compressed desert cobblestone.
### Changed
- Revised placing strategy that takes into account which side of the face
(top/bottom for horizontal, left/right for vertical placement) is being clicked.
Aux (sprint/special, default E) key can be used to place the node with the orientation
it would have if placed from the other side.
When placing nodes next to nodes of the same gategory (e.g.slab to slab) the other
node's orientation is copied, flipping it placing on top or below an upright or
upside-down node. In this case the aux key will disable the special processing of
same-category nodes.
### Fixed
- Revised minetest_game crafting recipe overrides to match Minetest 5.0.0 and later.
### Removed
- Legacy Stairs+ conversion code.
- It was only required to import worlds last edited before Q3 2013.
## [2.0.0] - 2019-11-25
### Added
- Stairs+ nodes for ice.
- `settingtypes.txt` file to allow configuring settings in the main menu.
- Polish translation.
### Changed
- The minimum supported Minetest version is now 5.0.0.
- Stairs+ nodes now emit one light level less compared to full nodes to make up
for their smaller visual size.
### Fixed
- Fixed a recipe conflict that made Centered Wooden Tiles impossible to craft.
## [1.3.0] - 2019-03-23
### Changed
- Stairs+ are now displayed in the creative inventory by default.
- Localization files now use the gettext `.po` format.
- Updated intllib support to avoid using deprecated functions.
### Fixed
- Node rotation now works correctly when placing Stairs+ nodes.
- Stairs+ glasslike nodes' textures are now easier to see.
## [1.2.0] - 2018-11-24
### Added
@ -101,13 +27,12 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
### Changed
- New crafting recipes for:
- New craft for:
- Stone Tile
- Circle Stone Bricks
- Stairs+:
- Moved definitions to `stairsplus.defs` table into a separate file.
- Moved recipe definitions to `stairsplus.register_recipes` function
into a separate file.
- Move definitions to `stairsplus.defs` table in a separate file
- Move recipe definitions to `stairsplus.register_recipes` function in a separate file
## [1.1.0] - 2017-10-04
@ -127,16 +52,12 @@ and this project adheres to [Semantic Versioning](http://semver.org/spec/v2.0.0.
- Straw
- Tin Block
- Wool (all colors)
- Other mods can now get a list of all the defined Stairs+ shapes.
- Other mods can now get a list of all the defined Stairs+ shapes
## 1.0.0 - 2017-02-19
- Initial versioned release.
[Unreleased]: https://github.com/minetest-mods/moreblocks/compare/v2.2.0...HEAD
[2.2.0]: https://github.com/minetest-mods/moreblocks/compare/v2.1.0...v2.2.0
[2.1.0]: https://github.com/minetest-mods/moreblocks/compare/v2.0.0...v2.1.0
[2.0.0]: https://github.com/minetest-mods/moreblocks/compare/v1.3.0...v2.0.0
[1.3.0]: https://github.com/minetest-mods/moreblocks/compare/v1.2.0...v1.3.0
[Unreleased]: https://github.com/minetest-mods/moreblocks/compare/v1.2.0...HEAD
[1.2.0]: https://github.com/minetest-mods/moreblocks/compare/v1.1.0...v1.2.0
[1.1.0]: https://github.com/minetest-mods/moreblocks/compare/v1.0.0...v1.1.0

View File

@ -1,6 +1,6 @@
# zlib license
Copyright © 2011-2020 Hugo Locurcio and contributors
Copyright (c) 2011-2018 Hugo Locurcio and contributors
**This software is provided 'as-is', without any express or implied warranty. In no event will the authors be held liable for any damages arising from the use of this software.**

View File

@ -1,4 +1,4 @@
# More Blocks [![Build status](https://github.com/minetest-mods/moreblocks/workflows/build/badge.svg)](https://github.com/minetest-mods/moreblocks/actions)
# More Blocks
More Blocks for [Minetest](https://www.minetest.net/), a free and open source infinite
world block sandbox game.
@ -12,13 +12,15 @@ world block sandbox game.
To install More Blocks, clone this Git repository into your Minetest's `mods/`
directory:
```bash
```
git clone https://github.com/minetest-mods/moreblocks.git
```
You can also
[download a ZIP archive](https://github.com/minetest-mods/moreblocks/archive/master.zip)
of More Blocks.
of More Blocks. If you do so, you will need to extract the archive, then rename
the resulting folder from `moreblocks-master` to `moreblocks` this is
**absolutely** necessary to do, else, it won't work!
### Enable the mod
@ -41,30 +43,29 @@ This is the easiest way to enable More Blocks when playing in singleplayer
This is the recommended way to enable the mod on a server without using a GUI.
1. Make sure Minetest is not currently running (otherwise, it will overwrite
1. Make sure Minetest is not currently running (else, it will overwrite
the changes when exiting).
2. Open the world's `world.mt` file using a text editor.
3. Add the following line at the end of the file:
```text
```
load_mod_moreblocks = true
```
If the line is already present in the file, then replace `false` with `true`
on that line.
If the line is already present in the file, then replace `false` with `true` on that line.
4. Save the file, then start a game on the world you enabled More Blocks on.
5. More Blocks should now be running on your world.
## Version compatibility
More Blocks is currently primarily tested with Minetest 5.3.0.
More Blocks is currently primarily tested with Minetest 0.4.16.
It may or may not work with newer or older versions. Issues arising in older
versions than 5.0.0 will generally not be fixed.
versions than 0.4.16 will generally not be fixed.
## License
Copyright © 2011-2020 Hugo Locurcio and contributors
Copyright © 2011-2018 Hugo Locurcio and contributors
- More Blocks code is licensed under the zlib license, see
[`LICENSE.md`](LICENSE.md) for details.

View File

@ -1,7 +1,7 @@
--[[
More Blocks: alias definitions
Copyright © 2011-2020 Hugo Locurcio and contributors.
Copyright (c) 2011-2018 Hugo Locurcio and contributors.
Licensed under the zlib license. See LICENSE.md for more information.
--]]

View File

@ -1,19 +1,19 @@
--[[
More Blocks: circular saw
Copyright © 2011-2020 Hugo Locurcio, Sokomine and contributors.
Copyright (c) 2011-2018 Hugo Locurcio, Sokomine and contributors.
Licensed under the zlib license. See LICENSE.md for more information.
--]]
local S = moreblocks.S
local F = minetest.formspec_escape
local S = moreblocks.intllib
circular_saw = {}
circular_saw.known_stairs = setmetatable({}, {
__newindex = function(k, v)
local modname = minetest.get_current_modname()
print(("WARNING: mod %s tried to add node %s to the circular saw manually."):format(modname, v))
print(("WARNING: mod %s tried to add node %s to the circular saw"
.. " manually."):format(modname, v))
end,
})
@ -88,9 +88,8 @@ circular_saw.names = {
}
function circular_saw:get_cost(inv, stackname)
local name = minetest.registered_aliases[stackname] or stackname
for i, item in pairs(inv:get_list("output")) do
if item:get_name() == name then
if item:get_name() == stackname then
return circular_saw.cost_in_microblocks[i]
end
end
@ -127,20 +126,15 @@ end
function circular_saw:reset(pos)
local meta = minetest.get_meta(pos)
local inv = meta:get_inventory()
local owned_by = meta:get_string("owner")
if owned_by and owned_by ~= "" then
owned_by = (" ("..S("owned by @1", meta:get_string("owner"))..")")
else
owned_by = ""
end
inv:set_list("input", {})
inv:set_list("micro", {})
inv:set_list("output", {})
meta:set_int("anz", 0)
meta:set_string("infotext", S("Circular Saw is empty") .. owned_by)
meta:set_string("infotext",
S("Circular Saw is empty (owned by %s)")
:format(meta:get_string("owner") or ""))
end
@ -152,7 +146,7 @@ function circular_saw:update_inventory(pos, amount)
amount = meta:get_int("anz") + amount
-- The material is recycled automatically.
-- The material is recycled automaticly.
inv:set_list("recycle", {})
if amount < 1 then -- If the last block is taken out.
@ -170,17 +164,9 @@ function circular_saw:update_inventory(pos, amount)
end
local node_name = stack:get_name() or ""
local node_def = stack:get_definition()
local name_parts = circular_saw.known_nodes[node_name] or ""
local modname = name_parts[1] or ""
local material = name_parts[2] or ""
local owned_by = meta:get_string("owner")
if owned_by and owned_by ~= "" then
owned_by = (" ("..S("owned by @1", meta:get_string("owner"))..")")
else
owned_by = ""
end
inv:set_list("input", { -- Display as many full blocks as possible:
node_name.. " " .. math.floor(amount / 8)
@ -205,10 +191,8 @@ function circular_saw:update_inventory(pos, amount)
meta:set_int("anz", amount)
meta:set_string("infotext",
S("Circular Saw is working on @1",
node_def and node_def.description or material
) .. owned_by
)
S("Circular Saw is working on %s (owned by %s)")
:format(material, meta:get_string("owner") or ""))
end
@ -246,7 +230,7 @@ function circular_saw.allow_metadata_inventory_put(
local stackname = stack:get_name()
local count = stack:get_count()
-- Only allow those items that are offered in the output inventory to be recycled:
-- Only alow those items that are offered in the output inventory to be recycled:
if listname == "recycle" then
if not inv:contains_item("output", stackname) then
return 0
@ -258,6 +242,7 @@ function circular_saw.allow_metadata_inventory_put(
local incost = (incount * 8) + microstack:get_count()
local maxcost = (stackmax * 8) + 7
local cost = circular_saw:get_cost(inv, stackname)
if not cost then return 0 end -- NALC Fix crash if cost == nil
if (incost + cost) > maxcost then
return math.max((maxcost - incost) / cost, 0)
end
@ -336,10 +321,6 @@ function circular_saw.on_metadata_inventory_take(
local input_stack = inv:get_stack(listname, index)
if not input_stack:is_empty() and input_stack:get_name()~=stack:get_name() then
local player_inv = player:get_inventory()
-- Prevent arbitrary item duplication.
inv:remove_item(listname, input_stack)
if player_inv:room_for_item("main", input_stack) then
player_inv:add_item("main", input_stack)
end
@ -349,7 +330,7 @@ function circular_saw.on_metadata_inventory_take(
end
-- If it is one of the offered stairs: find out how many
-- microblocks have to be subtracted:
-- microblocks have to be substracted:
if listname == "output" then
-- We do know how much each block at each position costs:
local cost = circular_saw.cost_in_microblocks[index]
@ -366,26 +347,19 @@ function circular_saw.on_metadata_inventory_take(
-- The recycle field plays no role here since it is processed immediately.
end
local has_default_mod = minetest.get_modpath("default")
function circular_saw.on_construct(pos)
local meta = minetest.get_meta(pos)
local fancy_inv = ""
if has_default_mod then
-- prepend background and slot styles from default if available
fancy_inv = default.gui_bg..default.gui_bg_img..default.gui_slots
end
local fancy_inv = default.gui_bg..default.gui_bg_img..default.gui_slots
meta:set_string(
--FIXME Not work with @n in this part bug in minetest/minetest#7450.
"formspec", "size[11,10]"..fancy_inv..
"label[0,0;" ..S("Input material").. "]" ..
"list[current_name;input;1.7,0;1,1;]" ..
"label[0,1;" ..F(S("Left-over")).. "]" ..
"list[current_name;micro;1.7,1;1,1;]" ..
"label[0,2;" ..F(S("Recycle output")).. "]" ..
"list[current_name;recycle;1.7,2;1,1;]" ..
"field[0.3,3.5;1,1;max_offered;" ..F(S("Max")).. ":;${max_offered}]" ..
"button[1,3.2;1.7,1;Set;" ..F(S("Set")).. "]" ..
"label[0,0;" ..S("Input\nmaterial").. "]" ..
"list[current_name;input;1.5,0;1,1;]" ..
"label[0,1;" ..S("Left-over").. "]" ..
"list[current_name;micro;1.5,1;1,1;]" ..
"label[0,2;" ..S("Recycle\noutput").. "]" ..
"list[current_name;recycle;1.5,2;1,1;]" ..
"field[0.3,3.5;1,1;max_offered;" ..S("Max").. ":;${max_offered}]" ..
"button[1,3.2;1,1;Set;" ..S("Set").. "]" ..
"list[current_name;output;2.8,0;8,6;]" ..
"list[current_player;main;1.5,6.25;8,4;]" ..
"listring[current_name;output]" ..
@ -447,21 +421,17 @@ minetest.register_node("moreblocks:circular_saw", {
sunlight_propagates = true,
paramtype2 = "facedir",
groups = {choppy = 2,oddly_breakable_by_hand = 2},
sounds = moreblocks.node_sound_wood_defaults(),
sounds = default.node_sound_wood_defaults(),
on_construct = circular_saw.on_construct,
can_dig = circular_saw.can_dig,
-- Set the owner of this circular saw.
after_place_node = function(pos, placer)
local meta = minetest.get_meta(pos)
local owner = placer and placer:get_player_name() or ""
local owned_by = owner
if owner ~= "" then
owned_by = (" (%s)"):format(S("owned by @1", owner))
end
meta:set_string("owner", owner)
meta:set_string("infotext", S("Circular Saw is empty") .. owned_by)
meta:set_string("infotext",
S("Circular Saw is empty (owned by %s)")
:format(owner))
end,
-- The amount of items offered per shape can be configured:

View File

@ -1,7 +1,7 @@
--[[
More Blocks: configuration handling
Copyright © 2011-2020 Hugo Locurcio and contributors.
Copyright (c) 2011-2018 Hugo Locurcio and contributors.
Licensed under the zlib license. See LICENSE.md for more information.
--]]
@ -26,4 +26,4 @@ local function setting(settingtype, name, default)
end
-- Show stairs/slabs/panels/microblocks in creative inventory (true or false):
setting("bool", "stairsplus_in_creative_inventory", true)
setting("bool", "stairsplus_in_creative_inventory", false)

View File

@ -1,7 +1,7 @@
--[[
More Blocks: crafting recipes
Copyright © 2011-2020 Hugo Locurcio and contributors.
Copyright (c) 2011-2018 Hugo Locurcio and contributors.
Licensed under the zlib license. See LICENSE.md for more information.
--]]
@ -35,17 +35,6 @@ minetest.register_craft({
recipe = {"default:junglegrass", "default:cobble"},
})
minetest.register_craft({
output = "moreblocks:wood_tile 9",
recipe = {
{"group:wood", "group:wood", "group:wood"},
{"group:wood", "group:wood", "group:wood"},
{"group:wood", "group:wood", "group:wood"},
}
})
-- This must be registered after `moreblocks:wood_tile` to avoid recipe conflicts,
-- since `moreblocks:wood_tile` is part of `group:wood`
minetest.register_craft({
output = "moreblocks:wood_tile_center 9",
recipe = {
@ -55,6 +44,15 @@ minetest.register_craft({
}
})
minetest.register_craft({
output = "moreblocks:wood_tile 9",
recipe = {
{"group:wood", "group:wood", "group:wood"},
{"group:wood", "group:wood", "group:wood"},
{"group:wood", "group:wood", "group:wood"},
}
})
minetest.register_craft({
type = "shapeless",
output = "moreblocks:wood_tile",
@ -348,36 +346,12 @@ minetest.register_craft({
recipe = {"moreblocks:sweeper", "default:glass"},
})
minetest.register_craft({
output = "moreblocks:trap_clean_glass",
type = "shapeless",
recipe = {"default:mese_crystal_fragment", "moreblocks:clean_glass"},
})
minetest.register_craft({
output = "moreblocks:trap_clean_glass",
type = "shapeless",
recipe = {"moreblocks:sweeper", "moreblocks:trap_glass"},
})
minetest.register_craft({
output = "moreblocks:glow_glass",
type = "shapeless",
recipe = {"default:torch", "default:glass"},
})
minetest.register_craft({
output = "moreblocks:clean_glow_glass",
type = "shapeless",
recipe = {"default:torch", "moreblocks:clean_glass"},
})
minetest.register_craft({
output = "moreblocks:clean_glow_glass",
type = "shapeless",
recipe = {"moreblocks:sweeper", "moreblocks:glow_glass"},
})
minetest.register_craft({
output = "moreblocks:trap_glow_glass",
type = "shapeless",
@ -390,26 +364,6 @@ minetest.register_craft({
recipe = {"default:mese_crystal_fragment", "moreblocks:glow_glass"},
})
-- several recipes are possible for the trap+clean+glow, we only present 3 of them
minetest.register_craft({
output = "moreblocks:trap_clean_glow_glass",
type = "shapeless",
recipe = {"default:mese_crystal_fragment", "moreblocks:clean_glow_glass"},
})
minetest.register_craft({
output = "moreblocks:trap_clean_glow_glass",
type = "shapeless",
recipe = {"default:mese_crystal_fragment", "moreblocks:clean_glass", "default:torch"},
})
minetest.register_craft({
output = "moreblocks:trap_clean_glow_glass",
type = "shapeless",
recipe = {"moreblocks:sweeper", "moreblocks:trap_glow_glass" },
})
minetest.register_craft({
output = "moreblocks:super_glow_glass",
type = "shapeless",
@ -422,24 +376,6 @@ minetest.register_craft({
recipe = {"default:torch", "moreblocks:glow_glass"},
})
minetest.register_craft({
output = "moreblocks:clean_super_glow_glass",
type = "shapeless",
recipe = {"default:torch", "default:torch", "moreblocks:clean_glass"},
})
minetest.register_craft({
output = "moreblocks:clean_super_glow_glass",
type = "shapeless",
recipe = {"default:torch", "moreblocks:clean_glow_glass"},
})
minetest.register_craft({
output = "moreblocks:clean_super_glow_glass",
type = "shapeless",
recipe = {"moreblocks:sweeper", "moreblocks:super_glow_glass"},
})
minetest.register_craft({
output = "moreblocks:trap_super_glow_glass",
@ -453,32 +389,6 @@ minetest.register_craft({
recipe = {"default:mese_crystal_fragment", "moreblocks:super_glow_glass"},
})
-- several recipes are possible for the trap+clean+glow, we only present 4 of them
minetest.register_craft({
output = "moreblocks:trap_clean_super_glow_glass",
type = "shapeless",
recipe = {"default:mese_crystal_fragment", "moreblocks:clean_super_glow_glass"},
})
minetest.register_craft({
output = "moreblocks:trap_clean_super_glow_glass",
type = "shapeless",
recipe = {"default:mese_crystal_fragment", "moreblocks:clean_glow_glass", "default:torch"},
})
minetest.register_craft({
output = "moreblocks:trap_clean_super_glow_glass",
type = "shapeless",
recipe = {"default:mese_crystal_fragment", "moreblocks:clean_glass", "default:torch", "default:torch"},
})
minetest.register_craft({
output = "moreblocks:trap_clean_super_glow_glass",
type = "shapeless",
recipe = {"moreblocks:sweeper", "moreblocks:trap_super_glow_glass" },
})
minetest.register_craft({
output = "moreblocks:coal_stone",
type = "shapeless",
@ -554,7 +464,7 @@ minetest.register_craft({
})
minetest.register_craft({
output = "moreblocks:cactus_checker 4",
output = "moreblocks:cactuschecker 4",
recipe = {
{"default:stone", "default:cactus"},
{"default:cactus", "default:stone"},
@ -600,22 +510,6 @@ minetest.register_craft({
}
})
minetest.register_craft({
output = "moreblocks:desert_cobble_compressed",
recipe = {
{"default:desert_cobble", "default:desert_cobble", "default:desert_cobble"},
{"default:desert_cobble", "default:desert_cobble", "default:desert_cobble"},
{"default:desert_cobble", "default:desert_cobble", "default:desert_cobble"},
}
})
minetest.register_craft({
output = "default:desert_cobble 9",
recipe = {
{"moreblocks:desert_cobble_compressed"},
}
})
minetest.register_craft({
type = "cooking", output = "moreblocks:tar", recipe = "default:pine_tree",
})

6
depends.txt Normal file
View File

@ -0,0 +1,6 @@
default
intllib?
stairs?
farming?
wool?
basic_materials?

1
description.txt Normal file
View File

@ -0,0 +1 @@
Adds various miscellaneous blocks to the game.

View File

@ -3,26 +3,35 @@
** More Blocks **
By Calinou, with the help of ShadowNinja and VanessaE.
Copyright © 2011-2020 Hugo Locurcio and contributors.
Copyright (c) 2011-2018 Hugo Locurcio and contributors.
Licensed under the zlib license. See LICENSE.md for more information.
=====================================================================
--]]
moreblocks = {}
local S
if minetest.global_exists("intllib") then
if intllib.make_gettext_pair then
S = intllib.make_gettext_pair()
else
S = intllib.Getter()
end
else
S = function(s) return s end
end
moreblocks.intllib = S
local modpath = minetest.get_modpath("moreblocks")
moreblocks.S = minetest.get_translator("moreblocks")
dofile(modpath .. "/config.lua")
dofile(modpath .. "/sounds.lua")
dofile(modpath .. "/circular_saw.lua")
dofile(modpath .. "/stairsplus/init.lua")
dofile(modpath .. "/nodes.lua")
dofile(modpath .. "/redefinitions.lua")
dofile(modpath .. "/crafting.lua")
dofile(modpath .. "/aliases.lua")
if minetest.get_modpath("default") then
dofile(modpath .. "/nodes.lua")
dofile(modpath .. "/crafting.lua")
dofile(modpath .. "/aliases.lua")
if minetest.settings:get_bool("log_mods") then
minetest.log("action", S("[moreblocks] loaded."))
end
minetest.log("action", "[moreblocks] loaded.")

67
locale/de.txt Normal file
View File

@ -0,0 +1,67 @@
# Translation by Xanthin
###init.lua###
[moreblocks] loaded. = [moreblocks] geladen.
###nodes.lua###
Jungle Wood Fence = Tropenholzzaun
Empty Bookshelf = Leeres Buecherregal
Clean Glass = Klares Glas
Plankstone = Brettstein
Wooden Tile = Holzfliese
Full Wooden Tile = Vollholzfliese
Centered Wooden Tile = Holzfliese mittig
Up Wooden Tile = Holzfliese oben
Down Wooden Tile = Holzfliese unten
Left Wooden Tile = Holzfliese links
Right Wooden Tile = Holzfliese rechts
Circle Stone Bricks = Kreissteinziegel
Stone Tile = Steinfliese
Split Stone Tile = Geteilte Steinfliese
Glow Glass = Leuchtglas
Super Glow Glass = Superleuchtglas
Coal Glass = Kohleglas
Iron Glass = Eisenglas
Coal Checker = Karierte Kohle
Iron Checker = Kariertes Eisen
Trap Stone = Steinfalle
Trap Glass = Glasfalle
Trap Glow Glass = Leuchtglasfalle
Trap Super Glow Glass = Superleuchtglasfalle
Coal Stone = Kohlestein
Iron Stone = Eisenstein
Coal Stone Bricks = Kohlesteinziegel
Iron Stone Bricks = Eisensteinziegel
Cactus Checker = Karierter Kaktus
Cactus Brick = Kaktusziegel
Sweeper = Besen
Jungle Stick = Tropenholzstock
Rope = Seil
All-faces Tree = Baumscheibenstamm
###circular_saw.lua###
Circular Saw = Kreissaege
Circular saw, empty (owned by %s) = Kreissaege, leer (gehoert %s)
Circular saw, working with %s (owned by %s) = Kreissaege, arbeitet mit %s (gehoert %s)
Circular saw, empty = Kreissaege, leer
Circular saw is empty (owned by %s) = Kreissaege ist leer (gehoert %s)
Input\nmaterial = Ausgangs-\nmaterial
Left-over = Rest
Max = Anzahl
Set = Ok
Recycle\noutput = Wiederver-\nwerten
###./stairsplus/*###
%s Stairs = %streppe
%s Slab = %sstufe
%s Panel = %spaneel
%s Microblock = %smikroblock
%s Pane = %sscheibe
%s Fence = %szaun
###ownership.lua###
someone = jemand
Sorry, %s owns that spot. = Tut mir leid, %s gehoert diese Stelle.

52
locale/es.txt Normal file
View File

@ -0,0 +1,52 @@
# Translation by kaeza
[moreblocks] loaded. = [moreblocks] cargado.
Jungle Wooden Planks = Tablones de madera de jungla
Empty Bookshelf = Estante para libros vacío
Clean Glass = Cristal Limpio
Plankstone = Tablones de piedra
Wooden Tile = Parquet
Full Wooden Tile = Parquet Completo
Centered Wooden Tile = Parquet Centrado
Up Wooden Tile = Parquet Superior
Down Wooden Tile = Parquet Inferior
Left Wooden Tile = Parquet Izquierdo
Right Wooden Tile = Parquet Derecho
Circle Stone Bricks = Bloques de Piedra Circulares
Stone Tile = Baldosa de Piedra
Split Stone Tile = Baldosas de Piedra Partida
Glow Glass = Cristal Brillante
Super Glow Glass = Cristal Súper Brillante
Coal Glass = Cristal con Carbón
Iron Glass = Cristal con Hierro
Coal Checker = Cuadros de Carbón
Iron Checker = Cuadros de Hierro
Trap Stone = Piedra Trampa
Trap Glass = Cristal Trampa
Coal Stone = Carbón y Piedra
Iron Stone = Hierro y Piedra
Cactus Checker = Cuadros de Cactus
Cactus Brick = Ladrillos de Cactus
Sweeper = Limpiador
Jungle Stick = Varita de Madera de Jungla
Horizontal Tree = Tronco de árbol horizontal
Horizontal Jungle Tree = Tronco de árbol de la jungla horizontal
Rope = Soga
All-faces Tree = Tronco de Árbol
%s Stairs = Escalera de %s
%s Slab = Losa de %s
%s Panel = Panel de %s
%s Microblock = Microbloque de %s
Wooden = Madera
Papyrus = Papiro
Dry Shrub = Arbusto Desértico
Sapling = Brote de Árbol
Wooden Planks = Tablones de Madera
Ladder = Escalera de Mano
Glass = Cristal
%s Pane = Panel de %s
%s Fence = Valla de %s

72
locale/fr.txt Normal file
View File

@ -0,0 +1,72 @@
# Translation by Calinou
###init.lua###
[moreblocks] loaded. = [moreblocks] a été chargé.
Jungle Wooden Planks = Planches de bois de jungle
Empty Bookshelf = Ètagère vide
Clean Glass = Verre propre
Plankstone = Pierre-bois
Wooden Tile = Dalle en bois
Full Wooden Tile = Dalle en bois complète
Centered Wooden Tile = Dalle en bois centrée
Up Wooden Tile = Dalle en bois vers le haut
Down Wooden Tile = Dalle en bois vers le bas
Left Wooden Tile = Dalle en bois vers la gauche
Right Wooden Tile = Dalle en bois vers la droite
Circle Stone Bricks = Briques en pierre circulaires
Stone Tile = Dalle en pierre
Split Stone Tile = Dalle en pierre découpée
Glow Glass = Verre brillant
Super Glow Glass = Verre très brillant
Coal Glass = Verre de charbon
Iron Glass = Verre de fer
Coal Checker = Damier en charbon
Iron Checker = Damier en fer
Trap Stone = Pierre traversable
Trap Glass = Verre traversable
Trap Glow Glass = Verre brillant traversable
Trap Super Glow Glass = Verre très brillant traversable
Coal Stone = Pierre de charbon
Iron Stone = Pierre de fer
Coal Stone Bricks = Briques en pierre de charbon
Iron Stone Bricks = Briques en pierre de fer
Cactus Checker = Damier en cactus
Cactus Brick = Briques de cactus
Sweeper = Balai
Jungle Stick = Bâton en bois de jungle
Horizontal Tree = Tronc d'arbre horizontal
Horizontal Jungle Tree = Tronc d'arbre de jungle horizontal
Rope = Corde
All-faces Tree = Tronc d'arbre
###redefinition.lua###
Wooden = bois
Papyrus = Papyrus
Dry Shrub = Buisson mort
Sapling = Pousse d'arbre
Wooden Planks = Planches de bois
Ladder = Échelle
Glass = Verre
###circular_saw.lua###
Circular Saw = Scie circulaire
Circular saw, empty (owned by %s) = Scie circulaire, vide (propriété de %s)
Circular saw, working with %s (owned by %s) = Scie circulaire, manipule %s (propriété de %s)
Circular saw, empty = Scie circulaire, vide
Circular saw is empty (owned by %s) = Scie circulaire est vide (propriété de %s)
Input material = Entrée du matériel
Rest/microblocks = Reste/microbloc
Max: = Max:
Set = Fixer
Recycle output = Recyclage
###./stairsplus/*###
%s Stairs = Escaliers en %s
%s Slab = Demi-dalle en %s
%s Panel = Barre en %s
%s Microblock = Microbloc en %s
%s Pane = Panneau en %s
%s Fence = Barrière en %s

70
locale/it.txt Normal file
View File

@ -0,0 +1,70 @@
#
# Italian translation
# Translator: Emon
#
###init.lua###
[moreblocks] loaded. = [moreblocks] caricato.
###nodes.lua###
Jungle Wood Fence = Recinzione in legno della giungla
Empty Bookshelf = Libreria vuota
Clean Glass = Vetro pulito
Plankstone = Pietra e legno
Wooden Tile = Mattonella in legno
Full Wooden Tile = Mattonella in legno pieno
Centered Wooden Tile = Mattonella in legno centrata
Up Wooden Tile = Mattonella in legno verso l'alto
Down Wooden Tile = Mattonella in legno verso il basso
Left Wooden Tile = Mattonella in legno verso sinistra
Right Wooden Tile = Mattonella in legno verso destra
Circle Stone Bricks = Mattoni concentrici in pietra
Stone Tile = Mattonella in pietra
Split Stone Tile = Mattonella in pietra divisa
Glow Glass = Vetro luminoso
Super Glow Glass = Super vetro luminoso
Coal Glass = Vetro e carbone
Iron Glass = Vetro e ferro
Coal Checker = Scacchiera in carbone
Iron Checker = Scacchiera in ferro
Trap Stone = Pietra trappola
Trap Glass = Vetro trappola
Trap Glow Glass = Vetro luminoso trappola
Trap Super Glow Glass = Super vetro luminoso trappola
Coal Stone = Pietra in carbone
Iron Stone = Pietra in ferro
Coal Stone Bricks = Mattoni di pietra in carbone
Iron Stone Bricks = Mattoni di pietra in ferro
Cactus Checker = Scacchiera in cactus
Cactus Brick = Mattoni di cactus
Sweeper = Spazzola
Jungle Stick = Bastone in legno della giungla
Rope = Corda
All-faces Tree = Albero su ogni lato
###circular_saw.lua###
Circular Saw = Sega circolare
Circular saw, empty (owned by %s) = Sega circolare, vuota (di proprietà di %s)
Circular saw, working with %s (owned by %s) = Sega circolare, in funzione su %s (di proprietà di %s)
Circular saw, empty = Sega circolare, vuota
Circular saw is empty (owned by %s) = La sega circolare è vuota (di proprietà di %s)
Input\nmaterial = Materiale\niniziale
Left-over = Scarto
Max = Max.
Set = Imp.
Recycle\noutput = Ricicla\nfinale
###ownership.lua###
someone = qualcuno
Sorry, %s owns that spot. = Spiacente, quel punto è di proprietà di %s
###./stairsplus/*###
%s Stairs = Scale - %s
%s Slab = Lastra - %s
%s Panel = Pannello - %s
%s Microblock = Microblocco %s
%s Pane = Pannello - %s
%s Fence = Recinzione - %s

View File

@ -1,92 +0,0 @@
# textdomain: moreblocks
# German translation for More Blocks.
# Copyright © 2011-2020 Hugo Locurcio and contributors
# This file is distributed under the same license as the More Blocks package.
# Xanthin, 2014.
# CodeXP <codexp@gmx.net>, 2018.
#: circular_saw.lua
Circular Saw=Kreissäge
Input material=Ausgangs-@nmaterial
Left-over=Rest
Max=Anzahl
Recycle output=Wiederver-@nwerten
Set=Ok
owned by @1=gehört @1
Circular Saw is empty=Kreissäge ist leer
Circular Saw is working on @1=Kreissäge arbeitet mit @1
#: init.lua
[moreblocks] loaded.=[moreblocks] geladen.
#: nodes.lua
Deprecated=veraltet
All-faces Acacia Tree=allseitiger Akazienbaumstamm
All-faces Aspen Tree=allseitiger Espenbaumstamm
All-faces Jungle Tree=allseitiger Tropenbaumstamm
All-faces Pine Tree=allseitiger Kieferbaumstamm
All-faces Tree=allseitiger Baumstamm
Cactus Brick=Kaktusziegel
Cactus Checker=Kaktus-Mosaik
Centered Wooden Tile=Holzfliese mittig
Checker Stone Tile=Stein-Mosaik
Circle Stone Bricks=Kreissteinziegel
Clean Glass=Klares Glas
Coal Checker=Kohlen-Mosaik
Coal Glass=Kohleglas
Clean Super Glow Glass=
Trap Clean Super Glow Glass=
Trap Clean Glass=
Clean Glow Glass=
Trap Clean Glow Glass=
Coal Stone=Kohlestein
Coal Stone Bricks=Kohlesteinziegel
Compressed Cobblestone=Gepresster Kopfsteinpflaster
Compressed Desert Cobblestone=
Compressed Dirt=Gepresste Erde
Copper Patina Block=Kupfer Edelrostblock
Empty Shelf=Leeres Regal
Full Wooden Tile=Vollholzfliese
Glow Glass=Leuchtglas
Iron Checker=Metall-Mosaik
Iron Glass=metallisiertes Glas
Iron Stone=Eisenstein
Iron Stone Bricks=Eisensteinziegel
Plankstone=Brettstein
Rope=Seil
Split Stone Tile=Geteilte Steinfliese
Stone Bricks=Steinziegel
Stone Tile=Steinfliese
Super Glow Glass=Superleuchtglas
Sweeper=Besen
Tar=Teer
Trap Desert Stone=Wüstensteinfalle
Trap Glass=Glasfalle
Trap Glow Glass=Leuchtglasfalle
Trap Obsidian=Obsidianfalle
Trap Obsidian Glass=Obsidianglasfalle
Trap Sandstone=Sandsteinfalle
Trap Stone=Steinfalle
Trap Super Glow Glass=Superleuchtglasfalle
Wooden Tile=Holzfliese
Offset Wooden Tile=Holzfliese versetzt
Downwards Wooden Tile=Holzfliese unten
Leftwards Wooden Tile=Holzfliese links
Rightwards Wooden Tile=Holzfliese rechts
#: ownership.lua
Sorry, @1 owns that spot.=Tut mir leid, dieser Bereich gehört @1.
someone=jemand
#: stairsplus/common.lua
@1 Microblock=@1mikroblock
@1 Slab=@1platte
@1 Slope=@1neigung
@1 Panel=@1paneel
@1 Stairs=@1treppe

View File

@ -1,96 +0,0 @@
# textdomain: moreblocks
# Spanish translation for More Blocks.
# Copyright © 2011-2020 Hugo Locurcio and contributors
# This file is distributed under the same license as the More Blocks package.
# kaeza, 2013.
# CodeXP <codexp@gmx.net>, 2018.
# Carlos Barraza 2020.
#: circular_saw.lua
Circular Saw=Sierra circular
Input material=Material de@nentrada
Left-over=Sobrante
Max=Maximo
Recycle output=Reciclar@nsalida
Set=Establecer
owned by @1=protegido por @1
Circular Saw is empty=La sierra circular está vacia
Circular Saw is working on @1=Sierra circular trabajando en @1
#: nodes.lua
Deprecated=Obsoleto
All-faces Acacia Tree=Árbol de Acacia, todas las caras
All-faces Aspen Tree=Álamo temblón, todas las caras
All-faces Jungle Tree=Árbol de Selva, todas las caras
All-faces Pine Tree=Pino, todas las caras
All-faces Tree=Tronco de Árbol
Cactus Brick=Ladrillos de Cactus
Cactus Checker=Cuadros de Cactus
Centered Wooden Tile=Parqué Centrado
Checker Stone Tile=Cuadros de Baldosa de Piedra
Circle Stone Bricks=Bloques de Piedra Circulares
Clean Glass=Cristal Limpio
Coal Checker=Cuadros de Carbón
Coal Glass=Cristal con Carbón
Clean Super Glow Glass=Cristal Súper Brillante Limpio
Trap Clean Super Glow Glass=Cristal Súper Brillante Limpio Falso
Trap Clean Glass=Cristal Limpio Falso
Clean Glow Glass=Cristal Brillante Limpio
Trap Clean Glow Glass=Cristal Brillante Limpio Falso
Coal Stone=Carbón y Piedra
Coal Stone Bricks=Ladrillos de Piedra de Carbon
Compressed Cobblestone=Adoquín Comprimido
Compressed Desert Cobblestone=Adoquín del Desierto Comprimido
Compressed Dirt=Tierra Comprimida
Copper Patina Block=Bloque de Pátina de Cobre
Empty Shelf=Estante vacio
Full Wooden Tile=Parqué Completo
Glow Glass=Cristal Brillante
Iron Checker=Cuadros de Hierro
Iron Glass=Cristal con Hierro
Iron Stone=Hierro y Piedra
Iron Stone Bricks=Ladrillo de Piedra de Hierro
Plankstone=Tablones de piedra
Rope=Soga
Split Stone Tile=Baldosas de Piedra Partida
Stone Bricks=Ladrillos de Piedra
Stone Tile=Baldosa de Piedra
Super Glow Glass=Cristal Súper Brillante
Sweeper=Limpiador
Tar=Alquitrán
Trap Desert Stone=Piedra del Desierto Falsa
Trap Glass=Cristal Falso
Trap Glow Glass=Cristal Brillante Falso
Trap Obsidian=Obsidiana Falsa
Trap Obsidian Glass=Vidrio de Obsidiana Falso
Trap Sandstone=Arenisca Falsa
Trap Stone=Piedra Falsa
Trap Super Glow Glass=Cristal Súper Brillante Falso
Wooden Tile=Parqué
Offset Wooden Tile=Parqué Ajustado
Downwards Wooden Tile=Parqué hacia Abajo
Leftwards Wooden Tile=Parqué hacia la Izquierda
Rightwards Wooden Tile=Parqué hacia la Derecha
#: ownership.lua
Sorry, @1 owns that spot.=Lo siento, @1 es dueño de ese lugar.
someone=alguien
#: stairsplus/common.lua
@1 Microblock=Microbloque de @1
@1 Slab=Losa de @1
@1 Slope=Pendiente de @1
@1 Panel=Panel de @1
@1 Stairs=Escalera de @1
#: stairsplus/registrations.lua
Concrete=Concreto
Cement=Cemento
Brass Block=Bloque de latón

View File

@ -1,93 +0,0 @@
# textdomain: moreblocks
# French translation for More Blocks.
# Copyright © 2011-2020 Hugo Locurcio and contributors
# This file is distributed under the same license as the More Blocks package.
# Hugo Locurcio <hugo.locurcio@hugo.pro>, 2013-2019.
# Jat15, 2013.
# CodeXP <codexp@gmx.net>, 2018.
#: circular_saw.lua
Circular Saw=Scie circulaire
Input material=Matériau@nd'entrée
Left-over=Reste
Max=Max
Recycle output=Sortie à@nrecycler
Set=Définir
owned by @1=propriété de @1
Circular Saw is empty=Scie circulaire vide
Circular Saw is working on @1=Scie circulaire manipulant @1
#: init.lua
[moreblocks] loaded.=[moreblocks] a été chargé.
#: nodes.lua
Deprecated=déprécié
All-faces Acacia Tree=Tronc d'arbre d'acacia (toutes faces)
All-faces Aspen Tree=Tronc d'arbre de peuplier (toutes faces)
All-faces Jungle Tree=Tronc d'arbre de jungle (toutes faces)
All-faces Pine Tree=Tronc d'arbre de pin (toutes faces)
All-faces Tree=Tronc d'arbre (toutes faces)
Cactus Brick=Briques de cactus
Cactus Checker=Damier en cactus
Centered Wooden Tile=Dalle en bois centrée
Checker Stone Tile=Damier de dalle en pierre
Circle Stone Bricks=Briques en pierre circulaires
Clean Glass=Verre propre
Coal Checker=Damier en charbon
Coal Glass=Verre de charbon
Clean Super Glow Glass=
Trap Clean Super Glow Glass=
Trap Clean Glass=
Clean Glow Glass=
Trap Clean Glow Glass=
Coal Stone=Pierre de charbon
Coal Stone Bricks=Briques en pierre de charbon
Compressed Cobblestone=Pierre taillée compressée
Compressed Desert Cobblestone=
Compressed Dirt=Terre compressée
Copper Patina Block=Bloc de patine de cuivre
Empty Shelf=Étagère vide
Full Wooden Tile=Dalle en bois complète
Glow Glass=Verre brillant
Iron Checker=Damier de fer
Iron Glass=Verre de fer
Iron Stone=Pierre de fer
Iron Stone Bricks=Briques en pierre de fer
Plankstone=Pierre-bois
Rope=Corde
Split Stone Tile=Dalle en pierre découpée
Stone Bricks=Briques en pierre
Stone Tile=Dalle en pierre
Super Glow Glass=Verre très brillant
Sweeper=Balai
Tar=Bitume
Trap Desert Stone=Pierre du désert traversable
Trap Glass=Verre traversable
Trap Glow Glass=Verre brillant traversable
Trap Obsidian=Obsidienne traversable
Trap Obsidian Glass=Verre d'obsidienne traversable
Trap Sandstone=Grès traversable
Trap Stone=Pierre traversable
Trap Super Glow Glass=Verre très brillant traversable
Wooden Tile=Dalle en bois
Offset Wooden Tile=Dalle en bois décalée
Downwards Wooden Tile=Dalle en bois vers le bas
Leftwards Wooden Tile=Dalle en bois vers la gauche
Rightwards Wooden Tile=Dalle en bois vers la droite
#: ownership.lua
Sorry, @1 owns that spot.=Désolé, @1 possède cet endroit.
someone=quelqu'un
#: stairsplus/common.lua
@1 Microblock=Microbloc en @1
@1 Slab=Demi-dalle en @1
@1 Slope=Pente en @1
@1 Panel=Barre en @1
@1 Stairs=Escaliers en @1

View File

@ -1,92 +0,0 @@
# textdomain: moreblocks
# Italian translation for More Blocks.
# Copyright © 2011-2020 Hugo Locurcio and contributors
# This file is distributed under the same license as the More Blocks package.
# Emon, 2016.
# CodeXP <codexp@gmx.net>, 2018.
#: circular_saw.lua
Circular Saw=Sega circolare
Input material=Materiale@niniziale
Left-over=Scarto
Max=Max.
Recycle output=Ricicla@nfinale
Set=Imp.
owned by @1=
Circular Saw is empty=Sega circolare, vuota
Circular Saw is working on @1=Sega circolare, in funzione su @1
#: init.lua
[moreblocks] loaded.=[moreblocks] caricato.
#: nodes.lua
Deprecated=
All-faces Acacia Tree=
All-faces Aspen Tree=
All-faces Jungle Tree=
All-faces Pine Tree=
All-faces Tree=Albero su ogni lato
Cactus Brick=Mattoni di cactus
Cactus Checker=Scacchiera in cactus
Centered Wooden Tile=Mattonella in legno centrata
Checker Stone Tile=
Circle Stone Bricks=Mattoni concentrici in pietra
Clean Glass=Vetro pulito
Coal Checker=Scacchiera in carbone
Coal Glass=Vetro e carbone
Clean Super Glow Glass=
Trap Clean Super Glow Glass=
Trap Clean Glass=
Clean Glow Glass=
Trap Clean Glow Glass=
Coal Stone=Pietra in carbone
Coal Stone Bricks=Mattoni di pietra in carbone
Compressed Cobblestone=
Compressed Desert Cobblestone=
Compressed Dirt=
Copper Patina Block=
Empty Shelf=Scaffale Vuoto
Full Wooden Tile=Mattonella in legno pieno
Glow Glass=Vetro luminoso
Iron Checker=Scacchiera in ferro
Iron Glass=Vetro e ferro
Iron Stone=Pietra in ferro
Iron Stone Bricks=Mattoni di pietra in ferro
Plankstone=Pietra e legno
Rope=Corda
Split Stone Tile=Mattonella in pietra divisa
Stone Bricks=
Stone Tile=Mattonella in pietra
Super Glow Glass=Super vetro luminoso
Sweeper=Spazzola
Tar=
Trap Desert Stone=
Trap Glass=Vetro trappola
Trap Glow Glass=Vetro luminoso trappola
Trap Obsidian=
Trap Obsidian Glass=
Trap Sandstone=
Trap Stone=Pietra trappola
Trap Super Glow Glass=Super vetro luminoso trappola
Wooden Tile=Mattonella in legno
Offset Wooden Tile=
Downwards Wooden Tile=
Leftwards Wooden Tile=
Rightwards Wooden Tile=
#: ownership.lua
Sorry, @1 owns that spot.=Spiacente, quel punto è di proprietà di @1
someone=qualcuno
#: stairsplus/common.lua
@1 Microblock=Microblocco @1
@1 Slab=Lastra - @1
@1 Slope=
@1 Panel=Pannello - @1
@1 Stairs=Scale - @1

View File

@ -1,93 +0,0 @@
# textdomain: moreblocks
# Polish translation for More Blocks.
# Copyright © 2011-2020 Hugo Locurcio and contributors
# This file is distributed under the same license as the More Blocks package.
# mat9117, 2019
# CodeXP <codexp@gmx.net>, 2018.
#: circular_saw.lua
Circular Saw=Piła tarczowa
Input material=wejście@nmateriał
Left-over=Resztki
Max=Maks
Recycle output=Przetwarzanie@nWyjście
Set=Ustaw
owned by @1=Należy do @1
Circular Saw is empty=Piła tarczowa jest pusta
Circular Saw is working on @1=Piła tarczowa pracuje na @1
#: init.lua
[moreblocks] loaded.=[moreblocks] załadowane.
#: nodes.lua
Deprecated=Przestarzałe
All-faces Acacia Tree=Wielostronna tekstura akacji
All-faces Aspen Tree=Wielostronna tekstura osiki
All-faces Jungle Tree=Wielostronna tekstura drzewa dżunglowego
All-faces Pine Tree=Wielostronna tekstura sosny
All-faces Tree=Wielostronna tekstura drzewa
Cactus Brick=Kaktusowa cegła
Cactus Checker=Kaktusowa szachownica
Centered Wooden Tile=Wyśrodkowany drewniany kafelek
Checker Stone Tile=Kamienna szachownica
Circle Stone Bricks=Okrągłe kamienne cegły
Clean Glass=Czyste szkło
Coal Checker=Węglowa szachownica
Coal Glass=Szkło węglowe
Clean Super Glow Glass=
Trap Clean Super Glow Glass=
Trap Clean Glass=
Clean Glow Glass=
Trap Clean Glow Glass=
Coal Stone=Kamień węglowy
Coal Stone Bricks=Węglowe kamienne cegły
Compressed Cobblestone=Skompresowany bruk
Compressed Desert Cobblestone=
Compressed Dirt=Skompresowana ziemia
Copper Patina Block=Blok patynowanej miedzi
Empty Shelf=Pusta półka
Full Wooden Tile=Pełny drewniany kafelek
Glow Glass=Świecące szkło
Iron Checker=Żelazna szachownica
Iron Glass=Żelazne szkło
Iron Stone=Żelazny kamień
Iron Stone Bricks=Żelazne kamienne cegły
Plankstone=Deskokamień
Rope=Lina
Split Stone Tile=Kamienny blok kafelkowy
Stone Bricks=Kamienne cegły
Stone Tile=Kamienny kafelek
Super Glow Glass=Super świecące szkło
Sweeper=Miotła
Tar=Smoła
Trap Desert Stone=Pułapka z pustynnego kamienia
Trap Glass=Szklana pułapka
Trap Glow Glass=Pułapka ze świecącego szkłą
Trap Obsidian=Obsydianowa pułapka
Trap Obsidian Glass=Pułapka z obsydianowego szkła
Trap Sandstone=Pułapka z piaskowca
Trap Stone=Kamienna pułapka
Trap Super Glow Glass=Pułapka z super świecącego szkła
Wooden Tile=Drewniany kafelek
Offset Wooden Tile=
Downwards Wooden Tile=Dolny drewniany kafelek
# @deprecated
Leftwards Wooden Tile=Lewy drewniany kafelek
# @deprecated
Rightwards Wooden Tile=Prawy drewniany kafelek
#: ownership.lua
Sorry, @1 owns that spot.=Przykro mi, to miejsce należy do @1
someone=ktoś
#: stairsplus/common.lua
@1 Microblock=@1 Mikroblok
@1 Slab=@1 Płyta
@1 Slope=@1 Spad
@1 Panel=@1 Panel
@1 Stairs=@1 Schody

View File

@ -1,94 +0,0 @@
# textdomain: moreblocks
# Portuguese_Brazil translation for More Blocks.
# Copyright © 2011-2020 Hugo Locurcio and contributors
# This file is distributed under the same license as the More Blocks package.
# Jose Anastacio 2020.
#: circular_saw.lua
Circular Saw=Serra Circular
Input material=Material de entrada
Left-over=Sobra
Max=Máximo
Recycle output=Saida reciclagem
Set=Defina
owned by @1=propriedade de @1
Circular Saw is empty=Serra Circular está vazia
Circular Saw is working on @1=Serra Circular está trabalhando em @1
#: nodes.lua
Deprecated=Descontinuado
All-faces Acacia Tree=Árvore de Acácia multifacetada
All-faces Aspen Tree=Árvore Aspen multifacetada
All-faces Jungle Tree=Árvore da Selva multifacetada
All-faces Pine Tree=Pinheiro multifacetado
All-faces Tree=Tronco de árvore
Cactus Brick=Tijolos de Cacto
Cactus Checker=Xadrez de Cacto
Centered Wooden Tile=Tijolos Centrado de Madeira
Checker Stone Tile=Xadrez Centrado de Pedra
Circle Stone Bricks=Tijolos de Pedra Cricular
Clean Glass=Vidro Limpo
Coal Checker=Xadrez de Carvão
Coal Glass=Vidro com Carvao
Clean Super Glow Glass=Cristal Limpo Super brilhante
Trap Clean Super Glow Glass=Vidro Limpo Super brilhante
Trap Clean Glass=Cristal Falso Limpo
Clean Glow Glass=Cristal Brillante Limpo
Trap Clean Glow Glass=Cristal Brillante Limpo Falso
Coal Stone=Pedra de carvão
Coal Stone Bricks=Tijolos de Carvão
Compressed Cobblestone=Pedregulho Comprimido
Compressed Desert Cobblestone=Pedregulho do Deserto Comprimido
Compressed Dirt=Terra Comprimida
Copper Patina Block=Bloco pátina de cobre
Empty Shelf=Prateleira Vazia
Full Wooden Tile=Xadrez de Madeira completo
Glow Glass=Vidro brilhante
Iron Checker=Xadrez de Ferro
Iron Glass=Cristal com ferro
Iron Stone=Ferro e Pedra
Iron Stone Bricks=Tijolos de Ferro
Plankstone=Prancha de Pedra
Rope=Corda
Split Stone Tile=Xadrez de Pedra Dividido
Stone Bricks=Tijolos de Pedra
Stone Tile=Xadrez de Pedra
Super Glow Glass=Cristal Súper Brillante
Sweeper=Limpiador
Tar=Alquitrán
Trap Desert Stone=Pedra del Desierto Falsa
Trap Glass=Cristal Falso
Trap Glow Glass=Cristal Brillante Falso
Trap Obsidian=Obsidiana Falsa
Trap Obsidian Glass=Vidrio de Obsidiana Falso
Trap Sandstone=Arenisca Falsa
Trap Stone=Piedra Falsa
Trap Super Glow Glass=Cristal Súper Brillante Falso
Wooden Tile=Xadrez de Madeira
Offset Wooden Tile=Xadrez de Madeira compensada
Downwards Wooden Tile=Xadrez de Madeira para baixo
Leftwards Wooden Tile=Xadrez de Madeira para a esquerda
Rightwards Wooden Tile=Xadrez de Madeira para a direita
#: ownership.lua
Sorry, @1 owns that spot.=Desculpe, @1 é o dono desse lugar.
someone=alguem
#: stairsplus/common.lua
@1 Microblock=Microbloco de @1
@1 Slab=Laje de @1
@1 Slope=Declive de @1
@1 Painel=Panel de @1
@1 Stairs=Escadas de @1
#: stairsplus/registrations.lua
Concrete=Concreto
Cement=Cimento
Brass Block=Bloco de latão

View File

@ -1,95 +0,0 @@
# textdomain: moreblocks
# Russian translation for MOREBLOCKS minetest mod.
# Copyright (C) 2018 Hugo Locurcio and contributors
# This file is distributed under the same license as the MOREBLOCKS package.
# CodeXP <codexp@gmx.net>, 2018.
#
#, fuzzy
#: circular_saw.lua
Circular Saw=циркулярная пила
Input material=Входной@nматериал
Left-over=Остатки
Max=Кол.
Recycle output=Пере-@nобработка
Set=ОК
owned by @1=принадлежит @1
Circular Saw is empty=циркулярная пила пустая
Circular Saw is working on @1=циркулярная пила, @1 в обработке
#: init.lua
[MOD] moreblocks loaded.=[MOD] moreblocks загружен.
#: nodes.lua
Deprecated=устаревший
All-faces Acacia Tree=всестороннее бревно акации
All-faces Aspen Tree=всестороннее бревно осины
All-faces Jungle Tree=всестороннее бревно дерева джунглей
All-faces Pine Tree=всестороннее бревно сосновое
All-faces Tree=всестороннее бревно дерева
Cactus Brick=кирпич из кактуса
Cactus Checker=мозаика из кактуса
Centered Wooden Tile=деревянная мозаика (центр)
Checker Stone Tile=каменная мозаика
Circle Stone Bricks=кольцевой камень
Clean Glass=чистое стекло
Coal Checker=угольная мозаика
Coal Glass=угольное стекло
Clean Super Glow Glass=
Trap Clean Super Glow Glass=
Trap Clean Glass=
Clean Glow Glass=
Trap Clean Glow Glass=
Coal Stone=угольный камень
Coal Stone Bricks=угольно-каменный кирпич
Compressed Cobblestone=прессованный булыжник
Compressed Desert Cobblestone=
Compressed Dirt=прессованная земля
Copper Patina Block=медный патинированный блок
Empty Shelf=пустые полки
Full Wooden Tile=деревянная мозаика
Glow Glass=светящееся стекло
Iron Checker=стальная мозаика
Iron Glass=металлизированное стекло
Iron Stone=железный камень
Iron Stone Bricks=железно-каменный кирпич
Plankstone=дерево-каменная мозаика
Rope=верёвка
Split Stone Tile=каменная мозаика
Stone Bricks=каменный кирпич
Stone Tile=каменная плитка
Super Glow Glass=супер светящееся стекло
Sweeper=метёлка
Tar=смола
Trap Desert Stone=мнимый пустынный камень
Trap Glass=мнимое стекло
Trap Glow Glass=мнимое светящееся стекло
Trap Obsidian=мнимый обсидиан
Trap Obsidian Glass=мнимое обсидиановое стекло
Trap Sandstone=мнимый песчаник
Trap Stone=мнимый камень
Trap Super Glow Glass=мнимое супер светящееся стекло
Wooden Tile=деревянная мозаика
Offset Wooden Tile=деревянная мозаика (сверху)
# @deprecated
Downwards Wooden Tile=деревянная мозаика (снизу)
# @deprecated
Leftwards Wooden Tile=деревянная мозаика (слева)
# @deprecated
Rightwards Wooden Tile=деревянная мозаика (справа)
#: ownership.lua
Sorry, @1 owns that spot.=Извините, это принадлежит @1.
someone=кому-то
#: stairsplus/common.lua
@1 Microblock=@1 (микроблок)
@1 Slab=@1 (плита)
@1 Slope=@1 (наклон)
@1 Panel=@1 (панель)
@1 Stairs=@1 (лестница)

View File

@ -1,89 +0,0 @@
# textdomain: moreblocks
#: circular_saw.lua
Circular Saw=
Input material=
Left-over=
Max=
Recycle output=
Set=
owned by @1=
Circular Saw is empty=
Circular Saw is working on @1=
#: nodes.lua
Deprecated=
All-faces Acacia Tree=
All-faces Aspen Tree=
All-faces Jungle Tree=
All-faces Pine Tree=
All-faces Tree=
Cactus Brick=
Cactus Checker=
Centered Wooden Tile=
Checker Stone Tile=
Circle Stone Bricks=
Clean Glass=
Coal Checker=
Coal Glass=
Clean Super Glow Glass=
Trap Clean Super Glow Glass=
Trap Clean Glass=
Clean Glow Glass=
Trap Clean Glow Glass=
Coal Stone=
Coal Stone Bricks=
Compressed Cobblestone=
Compressed Desert Cobblestone=
Compressed Dirt=
Copper Patina Block=
Empty Shelf=
Full Wooden Tile=
Glow Glass=
Iron Checker=
Iron Glass=
Iron Stone=
Iron Stone Bricks=
Plankstone=
Rope=
Split Stone Tile=
Stone Bricks=
Stone Tile=
Super Glow Glass=
Sweeper=
Tar=
Trap Desert Stone=
Trap Glass=
Trap Glow Glass=
Trap Obsidian=
Trap Obsidian Glass=
Trap Sandstone=
Trap Stone=
Trap Super Glow Glass=
Wooden Tile=
Offset Wooden Tile=
Downwards Wooden Tile=
Leftwards Wooden Tile=
Rightwards Wooden Tile=
#: ownership.lua
Sorry, @1 owns that spot.=
someone=
#: stairsplus/common.lua
@1 Microblock=
@1 Slab=
@1 Slope=
@1 Panel=
@1 Stairs=
#: stairsplus/registrations.lua
Concrete=
Cement=
Brass Block=

View File

@ -1,94 +0,0 @@
# textdomain: moreblocks
# zh_CN translation for More Blocks.
# Copyright © 2011-2020 Hugo Locurcio and contributors
# This file is distributed under the same license as the More Blocks package.
# IFRFSX <IFRFSX@protonmail.com>, 2020.
#: circular_saw.lua
Circular Saw=圆锯
Input material=输入@n材料
Left-over=剩余材料
Max=最大值
Recycle output=回收@n输出物
Set=设置
owned by @1=属于@1所有
Circular Saw is empty=圆锯是空的
Circular Saw is working on @1=圆锯正在加工@1
#: nodes.lua
Deprecated=弃用
All-faces Acacia Tree=全切面相思树木方块
All-faces Aspen Tree=全切面白杨树木方块
All-faces Jungle Tree=全切面丛林树木方块
All-faces Pine Tree=全切面松树木方块
All-faces Tree=全切面树木方块
Cactus Brick=仙人掌砖
Cactus Checker=仙人掌棋盘方块
Centered Wooden Tile=居中的木瓦
Checker Stone Tile=棋盘石瓦
Circle Stone Bricks=圆石砖
Clean Glass=干净的玻璃
Coal Checker=棋盘煤块
Coal Glass=煤玻璃
Clean Super Glow Glass=
Trap Clean Super Glow Glass=
Trap Clean Glass=
Clean Glow Glass=
Trap Clean Glow Glass=
Coal Stone=煤炭石
Coal Stone Bricks=煤炭石砖
Compressed Cobblestone=压缩圆石
Compressed Desert Cobblestone=
Compressed Dirt=压缩土
Copper Patina Block=铜绿方块
Empty Shelf=空书架
Full Wooden Tile=全木瓦
Glow Glass=发光玻璃
Iron Checker=棋盘铁方块
Iron Glass=铁玻璃
Iron Stone=铁石
Iron Stone Bricks=铁石砖
Plankstone=板石
Rope=绳子
Split Stone Tile=裂石砖
Stone Bricks=石砖
Stone Tile=石瓦
Super Glow Glass=超级发光玻璃
Sweeper=清扫器
Tar=焦油
Trap Desert Stone=陷阱沙漠石
Trap Glass=陷阱玻璃
Trap Glow Glass=陷阱发光玻璃
Trap Obsidian=陷阱黑耀石
Trap Obsidian Glass=陷阱黑耀石玻璃
Trap Sandstone=陷阱沙石
Trap Stone=陷阱石
Trap Super Glow Glass=陷阱超级发光玻璃
Wooden Tile=木瓦
Offset Wooden Tile=胶合木瓦
Downwards Wooden Tile=向下的木瓦
Leftwards Wooden Tile=向左的木瓦
Rightwards Wooden Tile=向右的木瓦
#: ownership.lua
Sorry, @1 owns that spot.=抱歉,那个位置是@1的。
someone=某人
#: stairsplus/common.lua
@1 Microblock=@1小方块
@1 Slab=@1台阶
@1 Slope=@1斜坡
@1 Panel=@1嵌板
@1 Stairs=@1楼梯
#: stairsplus/registrations.lua
Concrete=
Cement=
Brass Block=

View File

@ -1,94 +0,0 @@
# textdomain: moreblocks
# zh_TW translation for More Blocks.
# Copyright © 2011-2020 Hugo Locurcio and contributors
# This file is distributed under the same license as the More Blocks package.
# IFRFSX <IFRFSX@protonmail.com>, 2020.
#: circular_saw.lua
Circular Saw=圓鋸
Input material=輸入@n材料
Left-over=剩餘材料
Max=最大值
Recycle output=回收@n輸出物
Set=設置
owned by @1=屬於@1所有
Circular Saw is empty=圓鋸是空的
Circular Saw is working on @1=圓鋸正在加工@1
#: nodes.lua
Deprecated=棄用
All-faces Acacia Tree=全切面相思樹木方塊
All-faces Aspen Tree=全切面白楊樹木方塊
All-faces Jungle Tree=全切面叢林樹木方塊
All-faces Pine Tree=全切面松樹木方塊
All-faces Tree=全切面樹木方塊
Cactus Brick=仙人掌磚
Cactus Checker=仙人掌棋盤方塊
Centered Wooden Tile=居中的木瓦
Checker Stone Tile=棋盤石瓦
Circle Stone Bricks=圓石磚
Clean Glass=乾淨的玻璃
Coal Checker=棋盤煤塊
Coal Glass=煤玻璃
Clean Super Glow Glass=
Trap Clean Super Glow Glass=
Trap Clean Glass=
Clean Glow Glass=
Trap Clean Glow Glass=
Coal Stone=煤炭石
Coal Stone Bricks=煤炭石磚
Compressed Cobblestone=壓縮圓石
Compressed Desert Cobblestone=
Compressed Dirt=壓縮土
Copper Patina Block=銅綠方塊
Empty Shelf=空書架
Full Wooden Tile=全木瓦
Glow Glass=發光玻璃
Iron Checker=棋盤鐵方塊
Iron Glass=鐵玻璃
Iron Stone=鐵石
Iron Stone Bricks=鐵石磚
Plankstone=板石
Rope=繩子
Split Stone Tile=裂石磚
Stone Bricks=石磚
Stone Tile=石瓦
Super Glow Glass=超級發光玻璃
Sweeper=清掃器
Tar=焦油
Trap Desert Stone=陷阱沙漠石
Trap Glass=陷阱玻璃
Trap Glow Glass=陷阱發光玻璃
Trap Obsidian=陷阱黑耀石
Trap Obsidian Glass=陷阱黑耀石玻璃
Trap Sandstone=陷阱沙石
Trap Stone=陷阱石
Trap Super Glow Glass=陷阱超級發光玻璃
Wooden Tile=木瓦
Offset Wooden Tile=膠合木瓦
Downwards Wooden Tile=向下的木瓦
Leftwards Wooden Tile=向左的木瓦
Rightwards Wooden Tile=向右的木瓦
#: ownership.lua
Sorry, @1 owns that spot.=抱歉,那個位置是@1的。
someone=某人
#: stairsplus/common.lua
@1 Microblock=@1小方塊
@1 Slab=@1臺階
@1 Slope=@1斜坡
@1 Panel=@1嵌板
@1 Stairs=@1樓梯
#: stairsplus/registrations.lua
Concrete=
Cement=
Brass Block=

64
locale/template.txt Normal file
View File

@ -0,0 +1,64 @@
###init.lua###
[moreblocks] loaded. =
###nodes.lua###
Jungle Wood Fence =
Empty Bookshelf =
Clean Glass =
Plankstone =
Wooden Tile =
Full Wooden Tile =
Centered Wooden Tile =
Up Wooden Tile =
Down Wooden Tile =
Left Wooden Tile =
Right Wooden Tile =
Circle Stone Bricks =
Stone Tile =
Split Stone Tile =
Glow Glass =
Super Glow Glass =
Coal Glass =
Iron Glass =
Coal Checker =
Iron Checker =
Trap Stone =
Trap Glass =
Trap Glow Glass =
Trap Super Glow Glass =
Coal Stone =
Iron Stone =
Coal Stone Bricks =
Iron Stone Bricks =
Cactus Checker =
Cactus Brick =
Sweeper =
Jungle Stick =
Rope =
All-faces Tree =
###circular_saw.lua###
Circular Saw =
Circular saw, empty (owned by %s) =
Circular saw, working with %s (owned by %s) =
Circular saw, empty =
Circular saw is empty (owned by %s) =
Input\nmaterial =
Left-over =
Max =
Set =
Recycle\noutput =
###ownership.lua###
someone =
Sorry, %s owns that spot. =
###./stairsplus/*###
%s Stairs =
%s Slab =
%s Panel =
%s Microblock =
%s Pane =
%s Fence =

View File

@ -1,4 +1 @@
name = moreblocks
description = Adds various miscellaneous blocks to the game.
optional_depends = default,stairs,farming,wool,basic_materials
min_minetest_version = 5.0.0

126
nodes.lua
View File

@ -1,21 +1,21 @@
--[[
More Blocks: node definitions
Copyright © 2011-2020 Hugo Locurcio and contributors.
Copyright (c) 2011-2018 Hugo Locurcio and contributors.
Licensed under the zlib license. See LICENSE.md for more information.
--]]
local S = moreblocks.S
local S = moreblocks.intllib
local sound_dirt = moreblocks.node_sound_dirt_defaults()
local sound_wood = moreblocks.node_sound_wood_defaults()
local sound_stone = moreblocks.node_sound_stone_defaults()
local sound_glass = moreblocks.node_sound_glass_defaults()
local sound_leaves = moreblocks.node_sound_leaves_defaults()
local sound_dirt = default.node_sound_dirt_defaults()
local sound_wood = default.node_sound_wood_defaults()
local sound_stone = default.node_sound_stone_defaults()
local sound_glass = default.node_sound_glass_defaults()
local sound_leaves = default.node_sound_leaves_defaults()
-- Don't break on 0.4.14 and earlier.
local sound_metal = (moreblocks.node_sound_metal_defaults
and moreblocks.node_sound_metal_defaults() or sound_stone)
local sound_metal = (default.node_sound_metal_defaults
and default.node_sound_metal_defaults() or sound_stone)
local function tile_tiles(name)
local tex = "moreblocks_" ..name.. ".png"
@ -36,7 +36,6 @@ local function wood_tile_replace(itemstack, placer, pointed_thing)
return itemstack
end
local deprecated = (" ("..S('Deprecated')..")")
local nodes = {
["wood_tile"] = {
description = S("Wooden Tile"),
@ -53,7 +52,7 @@ local nodes = {
sounds = sound_wood,
},
["wood_tile_flipped"] = {
description = S("Wooden Tile") .. deprecated,
description = S("Wooden Tile (Deprecated)"),
tiles = {"default_wood.png^moreblocks_wood_tile.png^[transformR90",
"default_wood.png^moreblocks_wood_tile.png^[transformR90",
"default_wood.png^moreblocks_wood_tile.png^[transformR90",
@ -88,19 +87,19 @@ local nodes = {
no_stairs = true,
},
["wood_tile_down"] = {
description = S("Downwards Wooden Tile") .. deprecated,
description = S("Downwards Wooden Tile (Deprecated)"),
tiles = {"default_wood.png^[transformR180^moreblocks_wood_tile_offset.png^[transformR180"},
no_stairs = true,
on_place = wood_tile_replace
},
["wood_tile_left"] = {
description = S("Leftwards Wooden Tile") .. deprecated,
description = S("Leftwards Wooden Tile (Deprecated)"),
tiles = {"default_wood.png^[transformR270^moreblocks_wood_tile_offset.png^[transformR270"},
no_stairs = true,
on_place = wood_tile_replace
},
["wood_tile_right"] = {
description = S("Rightwards Wooden Tile") .. deprecated,
description = S("Rightwards Wooden Tile (Deprecated)"),
tiles = {"default_wood.png^[transformR90^moreblocks_wood_tile_offset.png^[transformR90"},
no_stairs = true,
on_place = wood_tile_replace
@ -165,19 +164,13 @@ local nodes = {
},
["dirt_compressed"] = {
description = S("Compressed Dirt"),
groups = {crumbly=2, compressed = 1},
groups = {crumbly=2},
is_ground_content = false,
sounds = sound_dirt,
},
["cobble_compressed"] = {
description = S("Compressed Cobblestone"),
groups = {cracky = 1, compressed = 1},
is_ground_content = false,
sounds = sound_stone,
},
["desert_cobble_compressed"] = {
description = S("Compressed Desert Cobblestone"),
groups = {cracky = 1, compressed = 1},
groups = {cracky = 1},
is_ground_content = false,
sounds = sound_stone,
},
@ -194,7 +187,6 @@ local nodes = {
description = S("Iron Glass"),
drawtype = "glasslike_framed_optional",
tiles = {"default_glass.png^[colorize:#DEDEDE", "default_glass_detail.png^[colorize:#DEDEDE"},
use_texture_alpha = "clip",
paramtype = "light",
sunlight_propagates = true,
is_ground_content = false,
@ -205,7 +197,6 @@ local nodes = {
description = S("Coal Glass"),
drawtype = "glasslike_framed_optional",
tiles = {"default_glass.png^[colorize:#828282", "default_glass_detail.png^[colorize:#828282"},
use_texture_alpha = "clip",
paramtype = "light",
sunlight_propagates = true,
is_ground_content = false,
@ -216,7 +207,6 @@ local nodes = {
description = S("Clean Glass"),
drawtype = "glasslike_framed_optional",
tiles = {"moreblocks_clean_glass.png", "moreblocks_clean_glass_detail.png"},
use_texture_alpha = "clip",
paramtype = "light",
sunlight_propagates = true,
is_ground_content = false,
@ -316,7 +306,6 @@ local nodes = {
description = S("Trap Glass"),
drawtype = "glasslike_framed_optional",
tiles = {"default_glass.png^moreblocks_trap_box_glass.png", "default_glass_detail.png"},
use_texture_alpha = "clip",
paramtype = "light",
sunlight_propagates = true,
is_ground_content = false,
@ -329,7 +318,6 @@ local nodes = {
description = S("Trap Obsidian Glass"),
drawtype = "glasslike_framed_optional",
tiles = {"default_obsidian_glass.png^moreblocks_trap_box_glass.png", "default_obsidian_glass_detail.png"},
use_texture_alpha = "clip",
paramtype = "light",
sunlight_propagates = true,
is_ground_content = false,
@ -349,19 +337,6 @@ local nodes = {
sounds = sound_stone,
no_stairs = true,
},
["trap_clean_glass"] = {
description = S("Trap Clean Glass"),
drawtype = "glasslike_framed_optional",
tiles = {"moreblocks_clean_glass.png^moreblocks_trap_box_glass.png", "moreblocks_clean_glass_detail.png"},
use_texture_alpha = "clip",
paramtype = "light",
sunlight_propagates = true,
is_ground_content = false,
walkable = false,
groups = {cracky = 3, oddly_breakable_by_hand = 3},
sounds = sound_glass,
no_stairs = true,
},
["trap_sandstone"] = {
description = S("Trap Sandstone"),
drawtype = "glasslike_framed",
@ -412,19 +387,6 @@ local nodes = {
description = S("Glow Glass"),
drawtype = "glasslike_framed_optional",
tiles = {"default_glass.png^[colorize:#E9CD61", "default_glass_detail.png^[colorize:#E9CD61"},
use_texture_alpha = "clip",
paramtype = "light",
sunlight_propagates = true,
is_ground_content = false,
light_source = 11,
groups = {cracky = 3, oddly_breakable_by_hand = 3},
sounds = sound_glass,
},
["clean_glow_glass"] = {
description = S("Clean Glow Glass"),
drawtype = "glasslike_framed_optional",
tiles = {"moreblocks_clean_glass.png^[colorize:#E9CD61", "moreblocks_clean_glass_detail.png^[colorize:#E9CD61"},
use_texture_alpha = "clip",
paramtype = "light",
sunlight_propagates = true,
is_ground_content = false,
@ -436,21 +398,6 @@ local nodes = {
description = S("Trap Glow Glass"),
drawtype = "glasslike_framed_optional",
tiles = {"default_glass.png^[colorize:#E9CD61^moreblocks_trap_box_glass.png", "default_glass_detail.png^[colorize:#E9CD61"},
use_texture_alpha = "clip",
paramtype = "light",
sunlight_propagates = true,
is_ground_content = false,
light_source = 11,
walkable = false,
groups = {cracky = 3, oddly_breakable_by_hand = 3},
sounds = sound_glass,
no_stairs = true,
},
["trap_clean_glow_glass"] = {
description = S("Trap Clean Glow Glass"),
drawtype = "glasslike_framed_optional",
tiles = {"moreblocks_clean_glass.png^[colorize:#E9CD61^moreblocks_trap_box_glass.png", "moreblocks_clean_glass_detail.png^[colorize:#E9CD61"},
use_texture_alpha = "clip",
paramtype = "light",
sunlight_propagates = true,
is_ground_content = false,
@ -464,19 +411,6 @@ local nodes = {
description = S("Super Glow Glass"),
drawtype = "glasslike_framed_optional",
tiles = {"default_glass.png^[colorize:#FFFF78", "default_glass_detail.png^[colorize:#FFFF78"},
use_texture_alpha = "clip",
paramtype = "light",
sunlight_propagates = true,
is_ground_content = false,
light_source = default.LIGHT_MAX,
groups = {cracky = 3, oddly_breakable_by_hand = 3},
sounds = sound_glass,
},
["clean_super_glow_glass"] = {
description = S("Clean Super Glow Glass"),
drawtype = "glasslike_framed_optional",
tiles = {"moreblocks_clean_glass.png^[colorize:#FFFF78", "moreblocks_clean_glass_detail.png^[colorize:#FFFF78"},
use_texture_alpha = "clip",
paramtype = "light",
sunlight_propagates = true,
is_ground_content = false,
@ -488,21 +422,6 @@ local nodes = {
description = S("Trap Super Glow Glass"),
drawtype = "glasslike_framed_optional",
tiles = {"default_glass.png^[colorize:#FFFF78^moreblocks_trap_box_glass.png", "default_glass_detail.png^[colorize:#FFFF78"},
use_texture_alpha = "clip",
paramtype = "light",
sunlight_propagates = true,
is_ground_content = false,
light_source = default.LIGHT_MAX,
walkable = false,
groups = {cracky = 3, oddly_breakable_by_hand = 3},
sounds = sound_glass,
no_stairs = true,
},
["trap_clean_super_glow_glass"] = {
description = S("Trap Clean Super Glow Glass"),
drawtype = "glasslike_framed_optional",
tiles = {"moreblocks_clean_glass.png^[colorize:#FFFF78^moreblocks_trap_box_glass.png", "moreblocks_clean_glass_detail.png^[colorize:#FFFF78"},
use_texture_alpha = "clip",
paramtype = "light",
sunlight_propagates = true,
is_ground_content = false,
@ -540,21 +459,6 @@ for name, def in pairs(nodes) do
def.tiles = def.tiles or {"moreblocks_" ..name.. ".png"}
minetest.register_node("moreblocks:" ..name, def)
minetest.register_alias(name, "moreblocks:" ..name)
def_copy = table.copy(def)
-- Use the primary tile for all sides of cut glasslike nodes.
-- This makes them easier to see
if
#def_copy.tiles > 1 and
def_copy.drawtype and
def_copy.drawtype == "glasslike_framed" or
def_copy.drawtype == "glasslike_framed_optional"
then
def.tiles = {def_copy.tiles[1]}
end
if not def.no_stairs then
local groups = {}
for k, v in pairs(def.groups) do groups[k] = v end

View File

@ -1,11 +1,11 @@
--[[
More Blocks: ownership handling
Copyright © 2011-2020 Hugo Locurcio and contributors.
Copyright (c) 2011-2018 Hugo Locurcio and contributors.
Licensed under the zlib license. See LICENSE.md for more information.
--]]
local S = moreblocks.S
local S = moreblocks.gettext
function moreblocks.node_is_owned(pos, placer)
local ownername = false
@ -33,7 +33,7 @@ function moreblocks.node_is_owned(pos, placer)
end
if ownername ~= false then
minetest.chat_send_player( placer:get_player_name(), S("Sorry, @1 owns that spot.", ownername) )
minetest.chat_send_player( placer:get_player_name(), S("Sorry, %s owns that spot."):format(ownername) )
return true
else
return false

52
redefinitions.lua Normal file
View File

@ -0,0 +1,52 @@
--[[
More Blocks: redefinitions of default stuff
Copyright (c) 2011-2018 Hugo Locurcio and contributors.
Licensed under the zlib license. See LICENSE.md for more information.
--]]
-- Redefinitions of some default crafting recipes:
minetest.register_craft({
output = "default:sign_wall 4",
recipe = {
{"default:wood", "default:wood", "default:wood"},
{"default:wood", "default:wood", "default:wood"},
{"", "default:stick", ""},
}
})
minetest.register_craft({
output = "default:ladder 4",
recipe = {
{"default:stick", "", "default:stick"},
{"default:stick", "default:stick", "default:stick"},
{"default:stick", "", "default:stick"},
}
})
minetest.clear_craft({
recipe = {
{"default:papyrus", "default:papyrus", "default:papyrus"}
}
})
minetest.register_craft({
output = "default:paper 4",
recipe = {
{"default:papyrus", "default:papyrus", "default:papyrus"},
}
})
minetest.register_craft({
output = "default:rail 24",
recipe = {
{"default:steel_ingot", "", "default:steel_ingot"},
{"default:steel_ingot", "default:stick", "default:steel_ingot"},
{"default:steel_ingot", "", "default:steel_ingot"},
}
})
minetest.register_craft({
type = "toolrepair",
additional_wear = -0.10, -- Tool repair buff (10% bonus instead of 2%).
})

View File

@ -1,3 +0,0 @@
# If enabled, Stairs+ nodes will be displayed in the inventory when playing in creative mode.
# Disabling this can speed up loading times for clients as fewer nodes need to be registered in the creative inventory.
moreblocks.stairsplus_in_creative_inventory (Display Stairs+ nodes in creative inventory) bool true

View File

@ -1,20 +0,0 @@
--[[
More Blocks: sound definitions
Copyright © 2011-2021 Hugo Locurcio and contributors.
Licensed under the zlib license. See LICENSE.md for more information.
--]]
local has_default_mod = minetest.get_modpath("default")
for _, sound in ipairs({"dirt", "wood", "stone", "metal", "glass", "leaves"}) do
-- use sound-function from default if available
-- otherwise fall back to a no-op function (no sounds)
local sound_function_name = "node_sound_" .. sound .. "_defaults"
if has_default_mod then
-- use default sounds
moreblocks[sound_function_name] = default[sound_function_name]
else
-- no-op
moreblocks[sound_function_name] = function() end
end
end

View File

@ -6,11 +6,11 @@
This also registers the node with the circular saw.
Example:
```lua
stairsplus:register_all("moreblocks", "wood", "default:wood", {
stairsplus:register_all("moreblocks", "wood", "defaut:wood", {
description = "Wooden",
tiles = {"default_wood.png"},
groups = {oddly_breakabe_by_hand=1},
sounds = moreblocks.node_sound_wood_defaults(),
sounds = default.node_sound_wood_defaults(),
})
```
The following register only a particular type of microblock.
@ -79,4 +79,4 @@ The subset table should have the following format:
{ "stair", "_alt_4" },
}
```
You can remove entries as needed.
You can remove entries as needed.

70
stairsplus/aliases.lua Normal file
View File

@ -0,0 +1,70 @@
--[[
More Blocks: alias definitions
Copyright (c) 2011-2018 Hugo Locurcio and contributors.
Licensed under the zlib license. See LICENSE.md for more information.
--]]
local function register_stairsplus_alias(modname, origname, newname)
minetest.register_alias(modname.. ":slab_" ..origname, "moreblocks:slab_" ..newname)
minetest.register_alias(modname.. ":slab_" ..origname.. "_inverted", "moreblocks:slab_" ..newname.. "_inverted")
minetest.register_alias(modname.. ":slab_" ..origname.. "_wall", "moreblocks:slab_" ..newname.. "_wall")
minetest.register_alias(modname.. ":slab_" ..origname.. "_quarter", "moreblocks:slab_" ..newname.. "_quarter")
minetest.register_alias(modname.. ":slab_" ..origname.. "_quarter_inverted", "moreblocks:slab_" ..newname.. "_quarter_inverted")
minetest.register_alias(modname.. ":slab_" ..origname.. "_quarter_wall", "moreblocks:slab_" ..newname.. "_quarter_wall")
minetest.register_alias(modname.. ":slab_" ..origname.. "_three_quarter", "moreblocks:slab_" ..newname.. "_three_quarter")
minetest.register_alias(modname.. ":slab_" ..origname.. "_three_quarter_inverted", "moreblocks:slab_" ..newname.. "_three_quarter_inverted")
minetest.register_alias(modname.. ":slab_" ..origname.. "_three_quarter_wall", "moreblocks:slab_" ..newname.. "_three_quarter_wall")
minetest.register_alias(modname.. ":stair_" ..origname, "moreblocks:stair_" ..newname)
minetest.register_alias(modname.. ":stair_" ..origname.. "_inverted", "moreblocks:stair_" ..newname.. "_inverted")
minetest.register_alias(modname.. ":stair_" ..origname.. "_wall", "moreblocks:stair_" ..newname.. "_wall")
minetest.register_alias(modname.. ":stair_" ..origname.. "_wall_half", "moreblocks:stair_" ..newname.. "_wall_half")
minetest.register_alias(modname.. ":stair_" ..origname.. "_wall_half_inverted", "moreblocks:stair_" ..newname.. "_wall_half_inverted")
minetest.register_alias(modname.. ":stair_" ..origname.. "_half", "moreblocks:stair_" ..newname.. "_half")
minetest.register_alias(modname.. ":stair_" ..origname.. "_half_inverted", "moreblocks:stair_" ..newname.. "_half_inverted")
minetest.register_alias(modname.. ":stair_" ..origname.. "_right_half", "moreblocks:stair_" ..newname.. "_right_half")
minetest.register_alias(modname.. ":stair_" ..origname.. "_right_half_inverted", "moreblocks:stair_" ..newname.. "_right_half_inverted")
minetest.register_alias(modname.. ":stair_" ..origname.. "_wall_half", "moreblocks:stair_" ..newname.. "_wall_half")
minetest.register_alias(modname.. ":stair_" ..origname.. "_wall_half_inverted", "moreblocks:stair_" ..newname.. "_wall_half_inverted")
minetest.register_alias(modname.. ":stair_" ..origname.. "_inner", "moreblocks:stair_" ..newname.. "_inner")
minetest.register_alias(modname.. ":stair_" ..origname.. "_inner_inverted", "moreblocks:stair_" ..newname.. "_inner_inverted")
minetest.register_alias(modname.. ":stair_" ..origname.. "_outer", "moreblocks:stair_" ..newname.. "_outer")
minetest.register_alias(modname.. ":stair_" ..origname.. "_outer_inverted", "moreblocks:stair_" ..newname.. "_outer_inverted")
minetest.register_alias(modname.. ":panel_" ..origname.. "_bottom", "moreblocks:panel_" ..newname.. "_bottom")
minetest.register_alias(modname.. ":panel_" ..origname.. "_top", "moreblocks:panel_" ..newname.. "_top")
minetest.register_alias(modname.. ":panel_" ..origname.. "_vertical", "moreblocks:panel_" ..newname.. "_vertical")
minetest.register_alias(modname.. ":micro_" ..origname.. "_bottom", "moreblocks:micro_" ..newname.. "_bottom")
minetest.register_alias(modname.. ":micro_" ..origname.. "_top", "moreblocks:micro_" ..newname.. "_top")
end
register_stairsplus_alias("stairsplus", "stone", "stone")
register_stairsplus_alias("stairsplus", "wood", "wood")
register_stairsplus_alias("stairsplus", "pinewood", "pinewood")
register_stairsplus_alias("stairsplus", "cobble", "cobble")
register_stairsplus_alias("stairsplus", "brick", "brick")
register_stairsplus_alias("stairsplus", "sandstone", "sandstone")
register_stairsplus_alias("stairsplus", "glass", "glass")
register_stairsplus_alias("stairsplus", "tree", "tree")
register_stairsplus_alias("stairsplus", "jungletree", "jungletree")
register_stairsplus_alias("stairsplus", "pinetree", "pinetree")
register_stairsplus_alias("stairsplus", "desert_stone", "desert_stone")
register_stairsplus_alias("stairsplus", "steelblock", "steelblock")
register_stairsplus_alias("stairsplus", "mossycobble", "mossycobble")
register_stairsplus_alias("moreblocks", "coalstone", "coal_stone")
register_stairsplus_alias("moreblocks", "junglewood", "jungle_wood")
register_stairsplus_alias("moreblocks", "circlestonebrick", "circle_stone_bricks")
register_stairsplus_alias("moreblocks", "ironstone", "iron_stone")
register_stairsplus_alias("moreblocks", "coalglass", "coal_glass")
register_stairsplus_alias("moreblocks", "ironglass", "iron_glass")
register_stairsplus_alias("moreblocks", "glowglass", "glow_glass")
register_stairsplus_alias("moreblocks", "superglowglass", "super_glow_glass")
register_stairsplus_alias("moreblocks", "coalchecker", "coal_checker")
register_stairsplus_alias("moreblocks", "ironchecker", "iron_checker")
register_stairsplus_alias("moreblocks", "cactuschecker", "cactus_checker")
register_stairsplus_alias("moreblocks", "ironstonebrick", "iron_stone_bricks")
register_stairsplus_alias("moreblocks", "stonesquare", "stone_tile")
register_stairsplus_alias("moreblocks", "splitstonesquare", "split_stone_tile")
register_stairsplus_alias("moreblocks", "woodtile", "wood_tile")
register_stairsplus_alias("moreblocks", "woodtile_centered", "wood_tile_centered")
register_stairsplus_alias("moreblocks", "woodtile_full", "wood_tile_full")

View File

@ -1,158 +1,40 @@
--[[
More Blocks: registrations
Copyright © 2011-2020 Hugo Locurcio and contributors.
Copyright (c) 2011-2018 Hugo Locurcio and contributors.
Licensed under the zlib license. See LICENSE.md for more information.
--]]
local S = moreblocks.S
local S = moreblocks.intllib
local descriptions = {
["micro"] = "Microblock",
["slab"] = "Slab",
["slope"] = "Slope",
["panel"] = "Panel",
["stair"] = "Stairs",
}
-- Extends the standad rotate_node placement so that it takes into account
-- the side (top/bottom or left/right) of the face being pointed at.
-- As with the standard rotate_node, sneak can be used to force the perpendicular
-- placement (wall placement on floor/ceiling, floor/ceiling placement on walls).
-- Additionally, the aux / sprint / special key can be used to place the node
-- as if from the opposite side.
--
-- When placing a node next to one of the same category (e.g. slab to slab or
-- stair to stair), the default placement (regardless of sneak) is to copy the
-- under node's param2, flipping if placed above or below it. The aux key disable
-- this behavior.
local wall_right_dirmap = {9, 18, 7, 12}
local wall_left_dirmap = {11, 16, 5, 14}
local ceil_dirmap = {20, 23, 22, 21}
-- extract the stairsplus category from a node name
-- assumes the name is in the form mod_name:category_original_ndoe_name
local function name_to_category(name)
local colon = name:find(":") or 0
colon = colon + 1
local under = name:find("_", colon)
return name:sub(colon, under)
end
stairsplus.rotate_node_aux = function(itemstack, placer, pointed_thing)
local sneak = placer and placer:get_player_control().sneak
local aux = placer and placer:get_player_control().aux1
-- category for what we are placing
local item_prefix = name_to_category(itemstack:get_name())
-- category for what we are placing against
local under = pointed_thing.under
local under_node = minetest.get_node(under)
local under_prefix = under_node and name_to_category(under_node.name)
-- NALC Addition to avoid coloredwood/unifiedbricks crash by Sys4
local under_pmod = string.sub(under_node.name, 1, (string.find(under_node.name, ":") or 0)-1)
local same_cat = item_prefix == under_prefix
-- standard (floor) facedir, also used for sneak placement against the lower half of the wall
local p2 = placer and minetest.dir_to_facedir(placer:get_look_dir()) or 0
-- check which face and which quadrant we are interested in
-- this is used both to check if we're handling parallel placement in the same-category case,
-- and in general for sneak placement
local face_pos = minetest.pointed_thing_to_face_pos(placer, pointed_thing)
local face_off = vector.subtract(face_pos, under)
-- we cannot trust face_off to tell us the correct directionif the
-- under node has a non-standard shape, so use the distance between under and above
local wallmounted = minetest.dir_to_wallmounted(vector.subtract(pointed_thing.above, under))
if same_cat and (under_pmod ~= "coloredwood" and under_pmod ~= "unifiedbricks")
and not aux then
p2 = under_node.param2
-- flip if placing above or below an upright or upside-down node
-- TODO should we also flip when placing next to a side-mounted node?
if wallmounted < 2 then
if p2 < 4 then
p2 = (p2 + 2) % 4
p2 = ceil_dirmap[p2 + 1]
elseif p2 > 19 then
p2 = ceil_dirmap[p2 - 19] - 20
p2 = (p2 + 2) % 4
end
end
else
-- for same-cat placement, aux is used to disable param2 copying
if same_cat then
aux = not aux
end
local remap = nil
-- standard placement against the wall
local use_wallmap = (wallmounted > 1 and not sneak) or (wallmounted < 2 and sneak)
-- standard placement against the ceiling, or sneak placement against the upper half of the wall
local use_ceilmap = wallmounted == 1 and not sneak
use_ceilmap = use_ceilmap or (wallmounted > 1 and sneak and face_off.y > 0)
if use_wallmap then
local left = (p2 == 0 and face_off.x < 0) or
(p2 == 1 and face_off.z > 0) or
(p2 == 2 and face_off.x > 0) or
(p2 == 3 and face_off.z < 0)
if aux then
left = not left
end
remap = left and wall_left_dirmap or wall_right_dirmap
elseif use_ceilmap then
remap = ceil_dirmap
end
if aux then
p2 = (p2 + 2) % 4
end
if remap then
p2 = remap[p2 + 1]
end
end
return minetest.item_place(itemstack, placer, pointed_thing, p2)
end
stairsplus.register_single = function(category, alternate, info, modname, subname, recipeitem, fields)
local src_def = minetest.registered_nodes[recipeitem] or {}
local desc_base = S("@1 "..descriptions[category], fields.description)
local descriptions = {
["micro"] = "Microblock",
["slab"] = "Slab",
["slope"] = "Slope",
["panel"] = "Panel",
["stair"] = "Stairs",
}
local def = {}
if category ~= "slab" then
def = table.copy(info)
end
-- copy fields to def
for k, v in pairs(fields) do
def[k] = v
end
def.drawtype = "nodebox"
if category == "slope" then
def.drawtype = "mesh"
end
def.paramtype = "light"
def.paramtype2 = def.paramtype2 or "facedir"
if def.use_texture_alpha == nil then
def.use_texture_alpha = src_def.use_texture_alpha
end
-- This makes node rotation work on placement
def.place_param2 = nil
-- Darken light sources slightly to make up for their smaller visual size
def.light_source = math.max(0, (def.light_source or 0) - 1)
def.on_place = stairsplus.rotate_node_aux
def.groups = stairsplus:prepare_groups(fields.groups)
if category == "slab" then
def.on_place = minetest.rotate_node
if category ~= "slab" then
def.description = S("%s " .. descriptions[category]):format(fields.description)
else
local desc_base = S("%s " .. descriptions[category]):format(fields.description)
if type(info) ~= "table" then
def.node_box = {
type = "fixed",
@ -166,19 +48,14 @@ stairsplus.register_single = function(category, alternate, info, modname, subnam
}
def.description = desc_base .. alternate:gsub("_", " "):gsub("(%a)(%S*)", function(a, b) return a:upper() .. b end)
end
else
def.description = desc_base
if category == "slope" then
def.drawtype = "mesh"
elseif category == "stair" and alternate == "" then
def.groups.stair = 1
end
end
if fields.drop and (type(fields.drop) ~= "table") then
def.groups = stairsplus:prepare_groups(fields.groups)
if category == "stair" and alternate == "" then
def.groups.stair = 1
end
if fields.drop and not (type(fields.drop) == "table") then
def.drop = modname.. ":" .. category .. "_" .. fields.drop .. alternate
end
minetest.register_node(":" ..modname.. ":" .. category .. "_" .. subname .. alternate, def)
stairsplus.register_recipes(category, alternate, modname, subname, recipeitem)
end
end

139
stairsplus/conversion.lua Normal file
View File

@ -0,0 +1,139 @@
--[[
More Blocks: conversion
Copyright (c) 2011-2018 Hugo Locurcio and contributors.
Licensed under the zlib license. See LICENSE.md for more information.
--]]
-- Function to convert all stairs/slabs/etc nodes from
-- inverted, wall, etc to regular + 6d facedir
local dirs1 = {21, 20, 23, 22, 21}
local dirs2 = {15, 8, 17, 6, 15}
local dirs3 = {14, 11, 16, 5, 14}
function stairsplus:register_6dfacedir_conversion(modname, material)
--print("Register stairsplus 6d facedir conversion")
--print('ABM for '..modname..' "'..material..'"')
local objects_list1 = {
modname.. ":slab_" ..material.. "_inverted",
modname.. ":slab_" ..material.. "_quarter_inverted",
modname.. ":slab_" ..material.. "_three_quarter_inverted",
modname.. ":stair_" ..material.. "_inverted",
modname.. ":stair_" ..material.. "_wall",
modname.. ":stair_" ..material.. "_wall_half",
modname.. ":stair_" ..material.. "_wall_half_inverted",
modname.. ":stair_" ..material.. "_half_inverted",
modname.. ":stair_" ..material.. "_right_half_inverted",
modname.. ":panel_" ..material.. "_vertical",
modname.. ":panel_" ..material.. "_top",
}
local objects_list2 = {
modname.. ":slab_" ..material.. "_wall",
modname.. ":slab_" ..material.. "_quarter_wall",
modname.. ":slab_" ..material.. "_three_quarter_wall",
modname.. ":stair_" ..material.. "_inner_inverted",
modname.. ":stair_" ..material.. "_outer_inverted",
modname.. ":micro_" ..material.. "_top"
}
for _, object in pairs(objects_list1) do
local flip_upside_down = false
local flip_to_wall = false
local dest_object = object
if string.find(dest_object, "_inverted") then
flip_upside_down = true
dest_object = string.gsub(dest_object, "_inverted", "")
end
if string.find(object, "_top") then
flip_upside_down = true
dest_object = string.gsub(dest_object, "_top", "")
end
if string.find(dest_object, "_wall") then
flip_to_wall = true
dest_object = string.gsub(dest_object, "_wall", "")
end
if string.find(dest_object, "_vertical") then
flip_to_wall = true
dest_object = string.gsub(dest_object, "_vertical", "")
end
if string.find(dest_object, "_half") and not string.find(dest_object, "_right_half") then
dest_object = string.gsub(dest_object, "_half", "_right_half")
elseif string.find(dest_object, "_right_half") then
dest_object = string.gsub(dest_object, "_right_half", "_half")
end
--print(" +---> convert " ..object)
--print(" | to " ..dest_object)
minetest.register_abm({
nodenames = {object},
interval = 1,
chance = 1,
action = function(pos, node, active_object_count, active_object_count_wider)
local fdir = node.param2 or 0
local nfdir
if flip_upside_down and not flip_to_wall then
nfdir = dirs1[fdir + 2]
elseif flip_to_wall and not flip_upside_down then
nfdir = dirs2[fdir + 1]
elseif flip_to_wall and flip_upside_down then
nfdir = dirs3[fdir + 2]
end
minetest.set_node(pos, {name = dest_object, param2 = nfdir})
end
})
end
for _, object in pairs(objects_list2) do
local flip_upside_down = false
local flip_to_wall = false
local dest_object = object
if string.find(dest_object, "_inverted") then
flip_upside_down = true
dest_object = string.gsub(dest_object, "_inverted", "")
end
if string.find(dest_object, "_top") then
flip_upside_down = true
dest_object = string.gsub(dest_object, "_top", "")
end
if string.find(dest_object, "_wall") then
flip_to_wall = true
dest_object = string.gsub(dest_object, "_wall", "")
end
--print(" +---> convert " ..object)
--print(" | to " ..dest_object)
minetest.register_abm({
nodenames = {object},
interval = 1,
chance = 1,
action = function(pos, node, active_object_count, active_object_count_wider)
local fdir = node.param2
local nfdir = 20
if flip_upside_down and not flip_to_wall then
nfdir = dirs1[fdir + 1]
elseif flip_to_wall and not flip_upside_down then
nfdir = dirs2[fdir + 2]
end
minetest.set_node(pos, {name = dest_object, param2 = nfdir})
end
})
end
end

View File

@ -1,10 +1,12 @@
--[[
More Blocks: microblock definitions
Copyright © 2011-2020 Hugo Locurcio and contributors.
Copyright (c) 2011-2018 Hugo Locurcio and contributors.
Licensed under the zlib license. See LICENSE.md for more information.
--]]
local S = moreblocks.intllib
--[[
Subset table should have the following format: (You can remove entries as needed.)
@ -61,35 +63,34 @@ local subset = {
}
--]]
-- luacheck: no unused
local function register_custom_subset(subset, modname, subname, recipeitem, groups, images, description, drop, light)
function register_custom_subset(subset, modname, subname, recipeitem, groups, images, description, drop, light)
stairsplus:register_custom_subset(subset, modname, subname, recipeitem, {
groups = groups,
tiles = images,
description = description,
drop = drop,
light_source = light,
sounds = moreblocks.node_sound_stone_defaults(),
sounds = default.node_sound_stone_defaults(),
})
end
function stairsplus:register_custom_subset_alias(subset, modname_old, subname_old, modname_new, subname_new)
local subset_copy = table.copy(subset)
for k, v in pairs(subset_copy) do
local subset = table.copy(subset)
for k, v in pairs(subset) do
minetest.register_alias(modname_old .. ":" .. v[1] .. "_" .. subname_old .. v[2], modname_new .. ":" .. v[1] .. "_" .. subname_new .. v[2])
end
end
function stairsplus:register_custom_subset_alias_force(subset, modname_old, subname_old, modname_new, subname_new)
local subset_copy = table.copy(subset)
for k, v in pairs(subset_copy) do
local subset = table.copy(subset)
for k, v in pairs(subset) do
minetest.register_alias_force(modname_old .. ":" .. v[1] .. "_" .. subname_old .. v[2], modname_new .. ":" .. v[1] .. "_" .. subname_new .. v[2])
end
end
function stairsplus:register_custom_subset(subset, modname, subname, recipeitem, fields)
local subset_copy = table.copy(subset)
for k, v in pairs(subset_copy) do
local subset = table.copy(subset)
for k, v in pairs(subset) do
stairsplus.register_single(v[1], v[2], stairsplus.defs[v[1]][v[2]], modname, subname, recipeitem, fields)
end

View File

@ -1,7 +1,7 @@
--[[
More Blocks: registrations
Copyright © 2011-2020 Hugo Locurcio and contributors.
Copyright (c) 2011-2018 Hugo Locurcio and contributors.
Licensed under the zlib license. See LICENSE.md for more information.
--]]
@ -406,4 +406,4 @@ for type,a in pairs(stairsplus.defs) do
for name,b in pairs(stairsplus.defs[type]) do
table.insert(stairsplus.shapes_list, { type .. "_", name })
end
end
end

View File

@ -1,7 +1,7 @@
--[[
More Blocks: Stairs+
Copyright © 2011-2020 Hugo Locurcio and contributors.
Copyright (c) 2011-2018 Hugo Locurcio and contributors.
Licensed under the zlib license. See LICENSE.md for more information.
--]]
@ -14,10 +14,8 @@ stairsplus.expect_infinite_stacks = false
stairsplus.shapes_list = {}
if
not minetest.get_modpath("unified_inventory")
and minetest.settings:get_bool("creative_mode")
then
if not minetest.get_modpath("unified_inventory")
and minetest.settings:get_bool("creative_mode") then
stairsplus.expect_infinite_stacks = true
end
@ -25,7 +23,7 @@ function stairsplus:prepare_groups(groups)
local result = {}
if groups then
for k, v in pairs(groups) do
if k ~= "wood" and k ~= "stone" and k ~= "wool" and k ~= "tree" then
if k ~= "wood" and k ~= "stone" then
result[k] = v
end
end
@ -38,10 +36,11 @@ end
function stairsplus:register_all(modname, subname, recipeitem, fields)
self:register_stair(modname, subname, recipeitem, fields)
self:register_slab(modname, subname, recipeitem, fields)
self:register_slab (modname, subname, recipeitem, fields)
self:register_slope(modname, subname, recipeitem, fields)
self:register_panel(modname, subname, recipeitem, fields)
self:register_micro(modname, subname, recipeitem, fields)
-- self:register_6dfacedir_conversion(modname, subname) -- Not needed as of Q3 2013, uncomment to fix old maps.
end
function stairsplus:register_alias_all(modname_old, subname_old, modname_new, subname_new)
@ -59,8 +58,7 @@ function stairsplus:register_alias_force_all(modname_old, subname_old, modname_n
self:register_micro_alias_force(modname_old, subname_old, modname_new, subname_new)
end
-- luacheck: no unused
local function register_stair_slab_panel_micro(modname, subname, recipeitem, groups, images, description, drop, light)
function register_stair_slab_panel_micro(modname, subname, recipeitem, groups, images, description, drop, light)
stairsplus:register_all(modname, subname, recipeitem, {
groups = groups,
tiles = images,
@ -70,6 +68,8 @@ local function register_stair_slab_panel_micro(modname, subname, recipeitem, gro
})
end
-- dofile(modpath.. "/aliases.lua") -- Not needed as of Q2 2013, uncomment to fix old maps.
-- dofile(modpath.. "/conversion.lua") -- Not needed as of Q2 2013, uncomment to fix old maps.
dofile(modpath .. "/defs.lua")
dofile(modpath .. "/recipes.lua")
dofile(modpath .. "/common.lua")

View File

@ -1,21 +1,22 @@
--[[
More Blocks: microblock definitions
Copyright © 2011-2020 Hugo Locurcio and contributors.
Copyright (c) 2011-2018 Hugo Locurcio and contributors.
Licensed under the zlib license. See LICENSE.md for more information.
--]]
local S = moreblocks.intllib
-- Node will be called <modname>:micro_<subname>
-- luacheck: no unused
local function register_micro(modname, subname, recipeitem, groups, images, description, drop, light)
function register_micro(modname, subname, recipeitem, groups, images, description, drop, light)
stairsplus:register_micro(modname, subname, recipeitem, {
groups = groups,
tiles = images,
description = description,
drop = drop,
light_source = light,
sounds = moreblocks.node_sound_stone_defaults(),
sounds = default.node_sound_stone_defaults(),
})
end

View File

@ -1,21 +1,22 @@
--[[
More Blocks: panel definitions
Copyright © 2011-2020 Hugo Locurcio and contributors.
Copyright (c) 2011-2018 Hugo Locurcio and contributors.
Licensed under the zlib license. See LICENSE.md for more information.
--]]
local S = moreblocks.intllib
-- Node will be called <modname>:panel_<subname>
-- luacheck: no unused
local function register_panel(modname, subname, recipeitem, groups, images, description, drop, light)
function register_panel(modname, subname, recipeitem, groups, images, description, drop, light)
stairsplus:register_panel(modname, subname, recipeitem, {
groups = groups,
tiles = images,
description = description,
drop = drop,
light_source = light,
sounds = moreblocks.node_sound_stone_defaults(),
sounds = default.node_sound_stone_defaults(),
})
end

View File

@ -1,7 +1,7 @@
--[[
More Blocks: Stairs+
Copyright © 2011-2020 Hugo Locurcio and contributors.
Copyright (c) 2011-2018 Hugo Locurcio and contributors.
Licensed under the zlib license. See LICENSE.md for more information.
--]]

View File

@ -1,82 +1,86 @@
--[[
More Blocks: registrations
Copyright © 2011-2020 Hugo Locurcio and contributors.
Copyright (c) 2011-2018 Hugo Locurcio and contributors.
Licensed under the zlib license. See LICENSE.md for more information.
--]]
local S = moreblocks.S
-- default registrations
if minetest.get_modpath("default") then
local default_nodes = { -- Default stairs/slabs/panels/microblocks:
"stone",
"stone_block",
"cobble",
"mossycobble",
"brick",
"sandstone",
"steelblock",
"goldblock",
"copperblock",
"bronzeblock",
"diamondblock",
"tinblock",
"desert_stone",
"desert_stone_block",
"desert_cobble",
"meselamp",
"glass",
"tree",
"wood",
"jungletree",
"junglewood",
"pine_tree",
"pine_wood",
"acacia_tree",
"acacia_wood",
"aspen_tree",
"aspen_wood",
"obsidian",
"obsidian_block",
"obsidianbrick",
"obsidian_glass",
"stonebrick",
"desert_stonebrick",
"sandstonebrick",
"silver_sandstone",
"silver_sandstone_brick",
"silver_sandstone_block",
"desert_sandstone",
"desert_sandstone_brick",
"desert_sandstone_block",
"sandstone_block",
"coral_skeleton",
"ice",
}
local default_nodes = { -- Default stairs/slabs/panels/microblocks:
"stone",
"stone_block",
"cobble",
"mossycobble",
"brick",
"sandstone",
"steelblock",
"goldblock",
"copperblock",
"bronzeblock",
"diamondblock",
"tinblock",
"desert_stone",
"desert_stone_block",
"desert_cobble",
"meselamp",
"glass",
"tree",
"wood",
"jungletree",
"junglewood",
"pine_tree",
"pine_wood",
"acacia_tree",
"acacia_wood",
"aspen_tree",
"aspen_wood",
"obsidian",
"obsidian_block",
"obsidianbrick",
"obsidian_glass",
"stonebrick",
"desert_stonebrick",
"sandstonebrick",
"silver_sandstone",
"silver_sandstone_brick",
"silver_sandstone_block",
"desert_sandstone",
"desert_sandstone_brick",
"desert_sandstone_block",
"sandstone_block",
"coral_skeleton",
"ice",
"snowblock",
}
for _, name in pairs(default_nodes) do
local mod = "default"
local nodename = mod .. ":" .. name
local ndef = table.copy(minetest.registered_nodes[nodename])
ndef.sunlight_propagates = true
for _, name in pairs(default_nodes) do
local mod = "default"
local nodename = mod .. ":" .. name
local ndef = table.copy(minetest.registered_nodes[nodename])
ndef.sunlight_propagates = true
-- Stone and desert_stone drop cobble and desert_cobble respectively.
if type(ndef.drop) == "string" then
ndef.drop = ndef.drop:gsub(".+:", "")
end
-- Use the primary tile for all sides of cut glasslike nodes and disregard paramtype2.
if #ndef.tiles > 1 and ndef.drawtype and ndef.drawtype:find("glass") then
ndef.tiles = {ndef.tiles[1]}
ndef.paramtype2 = nil
end
mod = "moreblocks"
stairsplus:register_all(mod, name, nodename, ndef)
minetest.register_alias_force("stairs:stair_" .. name, mod .. ":stair_" .. name)
minetest.register_alias_force("stairs:stair_outer_" .. name, mod .. ":stair_" .. name .. "_outer")
minetest.register_alias_force("stairs:stair_inner_" .. name, mod .. ":stair_" .. name .. "_inner")
minetest.register_alias_force("stairs:slab_" .. name, mod .. ":slab_" .. name)
-- Workaround to fix node orientation (minetest >= 0.4.17.1)
if ndef.place_param2 == 0 then
ndef.place_param2 = nil
end
-- Stone and desert_stone drop cobble and desert_cobble respectively.
if type(ndef.drop) == "string" then
ndef.drop = ndef.drop:gsub(".+:", "")
end
-- Use the primary tile for all sides of cut glasslike nodes and disregard paramtype2.
if #ndef.tiles > 1 and ndef.drawtype and ndef.drawtype:find("glass") then
ndef.tiles = {ndef.tiles[1]}
ndef.paramtype2 = nil
end
mod = "moreblocks"
stairsplus:register_all(mod, name, nodename, ndef)
minetest.register_alias_force("stairs:stair_" .. name, mod .. ":stair_" .. name)
minetest.register_alias_force("stairs:stair_outer_" .. name, mod .. ":stair_" .. name .. "_outer")
minetest.register_alias_force("stairs:stair_inner_" .. name, mod .. ":stair_" .. name .. "_inner")
minetest.register_alias_force("stairs:slab_" .. name, mod .. ":slab_" .. name)
end
-- farming registrations
@ -108,6 +112,9 @@ if minetest.get_modpath("wool") then
local ndef = table.copy(minetest.registered_nodes[nodename])
ndef.sunlight_propagates = true
-- Prevent dye+cut wool recipy from creating a full wool block.
ndef.groups.wool = nil
stairsplus:register_all(mod, name, nodename, ndef)
end
end
@ -117,25 +124,25 @@ end
if minetest.get_modpath("basic_materials") then
stairsplus:register_all("technic","concrete","basic_materials:concrete_block",{
description = S("Concrete"),
description = "Concrete",
tiles = {"basic_materials_concrete_block.png",},
groups = {cracky=1, level=2, concrete=1},
sounds = moreblocks.node_sound_stone_defaults(),
sounds = default.node_sound_stone_defaults(),
})
minetest.register_alias("prefab:concrete_stair","technic:stair_concrete")
minetest.register_alias("prefab:concrete_slab","technic:slab_concrete")
stairsplus:register_all("gloopblocks", "cement", "basic_materials:cement_block", {
description = S("Cement"),
description = "Cement",
tiles = {"basic_materials_cement_block.png"},
groups = {cracky=2, not_in_creative_inventory=1},
sounds = moreblocks.node_sound_stone_defaults(),
sounds = default.node_sound_stone_defaults(),
sunlight_propagates = true,
})
stairsplus:register_all("technic", "brass_block", "basic_materials:brass_block", {
description= S("Brass Block"),
description="Brass Block",
groups={cracky=1, not_in_creative_inventory=1},
tiles={"basic_materials_brass_block.png"},
})
@ -158,6 +165,6 @@ minetest.register_lbm({
})
minetest.log('action', "LBM replaced " .. node.name ..
" at " .. minetest.pos_to_string(pos))
" at " .. minetest.pos_to_string(pos))
end,
})

View File

@ -1,21 +1,22 @@
--[[
More Blocks: slab definitions
Copyright © 2011-2020 Hugo Locurcio and contributors.
Copyright (c) 2011-2018 Hugo Locurcio and contributors.
Licensed under the zlib license. See LICENSE.md for more information.
--]]
local S = moreblocks.intllib
-- Node will be called <modname>:slab_<subname>
-- luacheck: no unused
local function register_slab(modname, subname, recipeitem, groups, images, description, drop, light)
function register_slab(modname, subname, recipeitem, groups, images, description, drop, light)
stairsplus:register_slab(modname, subname, recipeitem, {
groups = groups,
tiles = images,
description = description,
drop = drop,
light_source = light,
sounds = moreblocks.node_sound_stone_defaults(),
sounds = default.node_sound_stone_defaults(),
})
end
@ -35,6 +36,7 @@ end
function stairsplus:register_slab(modname, subname, recipeitem, fields)
local defs = table.copy(stairsplus.defs["slab"])
local desc_base = S("%s Slab"):format(fields.description)
for alternate, shape in pairs(defs) do
stairsplus.register_single("slab", alternate, shape, modname, subname, recipeitem, fields)
end

View File

@ -1,21 +1,22 @@
--[[
More Blocks: slope definitions
Copyright © 2011-2020 Hugo Locurcio and contributors.
Copyright (c) 2011-2018 Hugo Locurcio and contributors.
Licensed under the zlib license. See LICENSE.md for more information.
--]]
local S = moreblocks.intllib
-- Node will be called <modname>:slope_<subname>
-- luacheck: no unused
local function register_slope(modname, subname, recipeitem, groups, images, description, drop, light)
function register_slope(modname, subname, recipeitem, groups, images, description, drop, light)
stairsplus:register_slope(modname, subname, recipeitem, {
groups = groups,
tiles = images,
description = description,
drop = drop,
light_source = light,
sounds = moreblocks.node_sound_stone_defaults(),
sounds = default.node_sound_stone_defaults(),
})
end

View File

@ -1,21 +1,22 @@
--[[
More Blocks: stair definitions
Copyright © 2011-2020 Hugo Locurcio and contributors.
Copyright (c) 2011-2018 Hugo Locurcio and contributors.
Licensed under the zlib license. See LICENSE.md for more information.
--]]
local S = moreblocks.intllib
-- Node will be called <modname>:stair_<subname>
-- luacheck: no unused
local function register_stair(modname, subname, recipeitem, groups, images, description, drop, light)
function register_stair(modname, subname, recipeitem, groups, images, description, drop, light)
stairsplus:register_stair(modname, subname, recipeitem, {
groups = groups,
tiles = images,
description = description,
drop = drop,
light_source = light,
sounds = moreblocks.node_sound_stone_defaults(),
sounds = default.node_sound_stone_defaults(),
})
end

Binary file not shown.

Before

Width:  |  Height:  |  Size: 697 B

After

Width:  |  Height:  |  Size: 718 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 685 B

After

Width:  |  Height:  |  Size: 693 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 299 B

After

Width:  |  Height:  |  Size: 306 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 446 B

After

Width:  |  Height:  |  Size: 448 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 574 B

After

Width:  |  Height:  |  Size: 579 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 474 B

After

Width:  |  Height:  |  Size: 478 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 439 B

After

Width:  |  Height:  |  Size: 441 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 170 B

After

Width:  |  Height:  |  Size: 177 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 738 B

After

Width:  |  Height:  |  Size: 744 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 163 B

After

Width:  |  Height:  |  Size: 166 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 481 B

After

Width:  |  Height:  |  Size: 484 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 258 B

After

Width:  |  Height:  |  Size: 325 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 2.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 269 B

After

Width:  |  Height:  |  Size: 318 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 207 B

After

Width:  |  Height:  |  Size: 219 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 167 B

After

Width:  |  Height:  |  Size: 215 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 167 B

After

Width:  |  Height:  |  Size: 169 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 739 B

After

Width:  |  Height:  |  Size: 850 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 167 B

After

Width:  |  Height:  |  Size: 169 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 229 B

After

Width:  |  Height:  |  Size: 230 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 483 B

After

Width:  |  Height:  |  Size: 485 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 115 B

After

Width:  |  Height:  |  Size: 122 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 352 B

After

Width:  |  Height:  |  Size: 356 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 272 B

After

Width:  |  Height:  |  Size: 273 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 278 B

After

Width:  |  Height:  |  Size: 279 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 169 B

After

Width:  |  Height:  |  Size: 171 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 309 B

After

Width:  |  Height:  |  Size: 310 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 266 B

After

Width:  |  Height:  |  Size: 270 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 88 B

After

Width:  |  Height:  |  Size: 135 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 117 B

After

Width:  |  Height:  |  Size: 160 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 286 B

After

Width:  |  Height:  |  Size: 311 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 387 B

After

Width:  |  Height:  |  Size: 396 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 281 B

After

Width:  |  Height:  |  Size: 288 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 433 B

After

Width:  |  Height:  |  Size: 436 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 282 B

After

Width:  |  Height:  |  Size: 289 B