8 Commits
v3.4 ... v3.6

Author SHA1 Message Date
a6d1f55f0a Technic and Toolranks support (#73)
Co-authored-by: Treer <treer.git@gmail.com>
2024-04-28 18:53:46 +02:00
d16b530685 Call old on_place when not clicking on portal material (#74)
This is needed to work with telemosaic since telemosaic depends on `on_rightclick` being called on beacon node when wielding a mese crystal fragment.
2024-03-09 19:29:03 +01:00
ea677c5a1b Hide unknown nodes under the nether bug (#72)
Hides bug #51 - the node_stone of the biome appears in the whole chunk under the Nether, so make nether:native_mapgen look the same as default:stone, and drop whatever default:stone drops
2023-05-06 14:44:54 +02:00
21c7e2801d restore string key in template
903025e accidently dropped a .
2023-04-16 01:38:43 +10:00
3470b1e22e add some French translations
I Hope all of the formatting is the same. I did check it multiple times.
2023-04-16 01:38:43 +10:00
3e809a811b Merge pull request #65 from Treer/feature/fix-netherrack-slab-upstream
Update localization files
2023-04-15 12:51:51 +10:00
6c6a182366 Update localization files 2023-04-15 12:43:56 +10:00
9c1fa2c843 A fix for Netherrack slab being called Deep Netherrack slab (#63)
* fix netherrack slab being called Deep Netherrack
* Fix several lowercase block names

Several slabs and stairs were incorrectly named.
2023-04-15 12:34:20 +10:00
10 changed files with 165 additions and 84 deletions

View File

@ -27,9 +27,12 @@ read_globals = {
"stairsplus", "stairsplus",
"string.split", "string.split",
table = { fields = { "copy", "getn" } }, table = { fields = { "copy", "getn" } },
"technic",
"toolranks",
"vector", "vector",
"VoxelArea", "VoxelArea",
"VoxelManip", "VoxelManip",
"walls",
xpanes = { fields = { "register_pane" } }, xpanes = { fields = { "register_pane" } },
} }

View File

@ -144,7 +144,9 @@ if nether.NETHER_REALM_ENABLED then
end end
end end
dofile(nether.path .. "/portal_examples.lua") dofile(nether.path .. "/portal_examples.lua")
if minetest.get_modpath("technic") then
dofile(nether.path .. "/nether-compressor-recipe.lua")
end
-- Portals are ignited by right-clicking with a mese crystal fragment -- Portals are ignited by right-clicking with a mese crystal fragment
nether.register_portal_ignition_item( nether.register_portal_ignition_item(

View File

@ -1,6 +1,6 @@
# textdomain: nether # textdomain: nether
# Translation FR by Louis Royer # Translation FR by Louis Royer and JoeEnderman
### init.lua ### ### init.lua ###
@ -15,75 +15,76 @@ Nether Portal=Portail du Nether
### mapgen_mantle.lua ### ### mapgen_mantle.lua ###
, @1m above lava-sea level= , @1m above lava-sea level=, @1m au-dessus du niveau de la mer de lave
, @1m below lava-sea level= , @1m below lava-sea level=, @1m en-dessous du niveau de la mer de lave
, approaching y boundary of Nether= , approaching y boundary of Nether=, approchant de la limite y du Nether
@1@2@3@4= @1@2@3@4=
Center/Mantle, but outside the caverns= Center/Mantle, but outside the caverns=Centre/Manteau, mais à l'extérieur des cavernes
Center/Mantle, inside cavern= Center/Mantle, inside cavern=Centre/Manteau, à l'intérieur d'une caverne
Describes which region of the nether the player is in= Describes which region of the nether the player is in=Indique dans quelle région du Nether se trouve le joueur
Negative nether= Negative nether=Nether négatif
Positive nether= Positive nether=Nether positif
Shell between negative nether and center region= Shell between negative nether and center region=Coquille entre le Nether négatif et la région centrale
Shell between positive nether and center region= Shell between positive nether and center region=Coquille entre le Nether positif et la région centrale
The Overworld= The Overworld=L'Overworld
Unknown player position= Unknown player position=Position du joueur inconnue
[Perlin @1] = [Perlin @1] =
### nodes.lua ### ### nodes.lua ###
A Deep Netherrack wall= A Deep Netherrack Wall=Un mur profond en Netherrack
A Netherrack wall= A Netherrack Wall=Un mur en Netherrack
A finely finished block of solid Nether Basalt.= A finely finished block of solid Nether Basalt.=Un bloc fini de basalte du Nether solide.
A rough cut solid block of Nether Basalt.= A rough cut solid block of Nether Basalt.=Un bloc solide de basalte du Nether taillé à la hache.
A thin crust of cooled lava with liquid lava beneath= A thin crust of cooled lava with liquid lava beneath=Une croûte fine de lave refroidie avec de la lave liquide en dessous
A vent in the earth emitting steam and gas= A vent in the earth emitting steam and gas=Une fissure dans la terre émettant de la vapeur et du gaz
Can be repurposed to provide puffs of smoke in a chimney= Can be repurposed to provide puffs of smoke in a chimney=Peut être réutilisé pour produire des bouffées de fumée dans une cheminée
Chiselled Basalt= Chiselled Basalt=Basalte sculpté
Columns of dark basalt found only in magma oceans deep within the Nether.= Columns of dark basalt found only in magma oceans deep within the Nether.=Colonnes de basalte noir que l'on trouve uniquement dans les océans de magma profonds du Nether.
Compressed Netherbrick= Compressed Netherbrick=Briques du Nether compressées
Cracked Nether Brick= Cracked Nether Brick=Briques du Nether craquelées
Deep Glowstone= Deep Glowstone=Pierre lumineuse profonde
Deep Nether Brick= Deep Nether Brick=Briques du Nether profondes
Deep Nether Slab= Deep Nether Slab=Dalle du Nether profonde
Deep Nether Stair= Deep Nether Stair=Escalier du Nether profond
Deep Netherrack= Deep Netherrack=Netherrack profond
Deep Netherrack slab= Deep Netherrack Slab=Dalle de Netherrack profonde
Deep Netherrack stair= Deep Netherrack Stair=Escalier de Netherrack profond
Fumarolic Chimney= Fumarolic Chimney=Cheminée fumarolique
Fumarolic Chimney Corner= Fumarolic Chimney Corner=Coin de cheminée fumarolique
Fumarolic Chimney Slab= Fumarolic Chimney Slab=Dalle de cheminée fumarolique
Glowstone=Pierre lumineuse Glowstone=Pierre lumineuse
Hewn Basalt= Hewn Basalt=Basalte taillé
Inner Deep Nether Stair= Inner Deep Nether Stair=Escalier intérieur du Nether profond
Inner Nether Stair=Escalier intérieur du Nether Inner Nether Stair=Escalier intérieur du Nether
Lava Crust= Lava Crust=Croûte de lave
Lava crust is strong enough to walk on, but still hot enough to inflict burns.= Lava crust is strong enough to walk on, but still hot enough to inflict burns.=La croûte de lave est assez solide pour marcher dessus, mais encore assez chaude pour causer des brûlures
Nether Basalt= Nether Basalt=Basalte du Nether
Nether Beryl= Nether Beryl=Béryl du Nether
Nether Berylite= Nether Berylite=Bérylite du Nether
Nether Brick=Brique du Nether Nether Brick=Brique du Nether
Nether Brick Fence=Barrière en briques du Nether Nether Brick Fence=Barrière en briques du Nether
Nether Brick Fence Rail=Clôture en briques du Nether Nether Brick Fence Rail=Rail de barrière en briques du Nether
Nether Crystal Pane= Nether Crystal Pane=Panneau de cristal du Nether
Nether Slab=Dalle du Nether Nether Slab=Dalle du Nether
Nether Stair=Escalier du Nether Nether Stair=Escalier du Nether
Nether geode crystal, found lining the interior walls of Nether geodes= Nether geode crystal, found lining the interior walls of Nether geodes=Cristal de géode du Nether, trouvé le long des parois intérieures des géodes du Nether
Nether geode crystal. A crystalline structure with faint glow found inside large Nether geodes= Nether geode crystal. A crystalline structure with faint glow found inside large Nether geodes=Cristal de géode du Nether. Une structure cristalline avec une faible lueur trouvée à l'intérieur des grandes géodes du Nether.
Netherrack=Roche du Nether Netherrack=Roche du Nether
Netherrack from deep in the mantle= Netherrack from deep in the mantle=Roche du Nether provenant des profondeurs du manteau
Netherrack stair= Netherrack Slab=Dalle du Nether
Netherrack Stair=Escalier du Nether
Nethersand=Sable du Nether Nethersand=Sable du Nether
Outer Deep Nether Stair= Outer Deep Nether Stair=Escalier extérieur profond du Nether
Outer Nether Stair=Escalier extérieur du Nether Outer Nether Stair=Escalier extérieur du Nether
Portal= Portal=Portail
### portal_api.lua ### ### portal_api.lua ###
@ -100,7 +101,7 @@ In all my travels, and time spent in the Great Libraries, I have encountered no
In all my travels, and time spent in the Great Libraries, I have encountered no shortage of legends surrounding preternatural doorways said to open into other worlds, yet only one can I confirm as being more than merely a story.=Après tous mes voyages, et le temps passé dans les Grandes Bibliothèques, je ne manque pas de légendes sur les portes surnaturelles qui, dit-on souvrent vers dautres mondes, mais seul une personne peut confirmer que ce sont plus que de simples histoires. In all my travels, and time spent in the Great Libraries, I have encountered no shortage of legends surrounding preternatural doorways said to open into other worlds, yet only one can I confirm as being more than merely a story.=Après tous mes voyages, et le temps passé dans les Grandes Bibliothèques, je ne manque pas de légendes sur les portes surnaturelles qui, dit-on souvrent vers dautres mondes, mais seul une personne peut confirmer que ce sont plus que de simples histoires.
Mysterious forces prevented you from opening that portal. Please try another location= Mysterious forces prevented you from opening that portal. Please try another location=Des forces mystérieuses vous empêchent d'ouvrir ce portail. Veuillez essayer un autre emplacement.
Portal wormhole=Vortex du portail Portal wormhole=Vortex du portail
@ -125,16 +126,16 @@ There is a floating land of hills and forests up there, over the edges of which
### tools.lua ### ### tools.lua ###
Nether Axe= Nether Axe=Hache du Nether
Nether Ingot= Nether Ingot=Lingot du Nether
Nether Lump= Nether Lump=Morceau du Nether
Nether Pickaxe@nWell suited for mining netherrack= Nether Pickaxe@nWell suited for mining netherrack=Pioche du Nether@nBien adaptée pour miner la roche du Nether
Nether Shovel= Nether Shovel=Pelle du Nether
Nether Sword= Nether Sword=Épée du Nether
Nether staff of Eternal Light@nCreates glowstone from netherrack= Nether staff of Eternal Light@nCreates glowstone from netherrack=Bâton du Nether de lumière éternelle@nCrée des blocs de pierre lumineuse à partir de roche du Nether
Nether staff of Light@nTemporarily transforms the netherrack into glowstone= Nether staff of Light@nTemporarily transforms the netherrack into glowstone=Bâton du Nether de lumière@nTransforme temporairement la roche du Nether en blocs de pierre lumineuse
Uniquely suited for mining netherrack, with minimal wear when doing so. Blunts quickly on other materials.= Uniquely suited for mining netherrack, with minimal wear when doing so. Blunts quickly on other materials.=Convient parfaitement pour miner la roche du Nether avec une usure minimale. S'émousse rapidement sur les autres matériaux.

View File

@ -31,8 +31,8 @@ Unknown player position=
### nodes.lua ### ### nodes.lua ###
A Deep Netherrack wall= A Deep Netherrack Wall=
A Netherrack wall= A Netherrack Wall=
A finely finished block of solid Nether Basalt.= A finely finished block of solid Nether Basalt.=
A rough cut solid block of Nether Basalt.= A rough cut solid block of Nether Basalt.=
A thin crust of cooled lava with liquid lava beneath= A thin crust of cooled lava with liquid lava beneath=
@ -49,8 +49,8 @@ Deep Nether Brick=
Deep Nether Slab= Deep Nether Slab=
Deep Nether Stair= Deep Nether Stair=
Deep Netherrack= Deep Netherrack=
Deep Netherrack slab= Deep Netherrack Slab=
Deep Netherrack stair= Deep Netherrack Stair=
Fumarolic Chimney= Fumarolic Chimney=
Fumarolic Chimney Corner= Fumarolic Chimney Corner=
Fumarolic Chimney Slab= Fumarolic Chimney Slab=
@ -78,7 +78,8 @@ Nether geode crystal. A crystalline structure with faint glow found inside large
Netherrack= Netherrack=
Netherrack from deep in the mantle= Netherrack from deep in the mantle=
Netherrack stair= Netherrack Slab=
Netherrack Stair=
Nethersand= Nethersand=
Outer Deep Nether Stair= Outer Deep Nether Stair=
Outer Nether Stair= Outer Nether Stair=

View File

@ -171,7 +171,11 @@ mapgen.shift_existing_biomes(NETHER_FLOOR, NETHER_CEILING)
-- Ores and decorations can be registered against "nether:rack" instead, and the lua -- Ores and decorations can be registered against "nether:rack" instead, and the lua
-- on_generate() callback will carve the Nether with nether:rack before invoking -- on_generate() callback will carve the Nether with nether:rack before invoking
-- generate_decorations and generate_ores. -- generate_decorations and generate_ores.
minetest.register_node("nether:native_mapgen", {}) -- It is disguised as stone to hide any bug where it leaks out of the nether, such as
-- https://github.com/minetest/minetest/issues/13440 or if on_generated() somehow was aborted.
local stone_copy_def = table.copy(minetest.registered_nodes["default:stone"] or {})
stone_copy_def.drop = stone_copy_def.drop or "default:stone" -- probably already defined as cobblestone
minetest.register_node("nether:native_mapgen", stone_copy_def)
minetest.register_biome({ minetest.register_biome({
name = "nether_caverns", name = "nether_caverns",

View File

@ -1,4 +1,4 @@
name = nether name = nether
description = Adds a deep underground realm with different mapgen that you can reach with obsidian portals. description = Adds a deep underground realm with different mapgen that you can reach with obsidian portals.
depends = stairs, default depends = stairs, default
optional_depends = moreblocks, mesecons, loot, dungeon_loot, doc_basics, fire, climate_api, ethereal, xpanes, walls optional_depends = toolranks, technic, moreblocks, mesecons, loot, dungeon_loot, doc_basics, fire, climate_api, ethereal, xpanes, walls

View File

@ -0,0 +1,40 @@
local S = minetest.get_translator("nether")
technic.register_recipe_type("compressing", { description = S("Compressing") })
function register_compressor_recipe(data)
data.time = data.time or 4
technic.register_recipe("compressing", data)
end
local recipes = {
{"nether:rack", "nether:brick",},
{"nether:rack_deep", "nether:brick_deep"},
{"nether:brick 9", "nether:brick_compressed", 12},
{"nether:brick_compressed 9", "nether:nether_lump", 12}
}
-- clear craft recipe
-- But allow brick blocks to be crafted like the other bricks from Minetest Game
minetest.clear_craft({
recipe = {
{"nether:brick","nether:brick","nether:brick"},
{"nether:brick","nether:brick","nether:brick"},
{"nether:brick","nether:brick","nether:brick"},
}
})
minetest.clear_craft({
recipe = {
{"nether:brick_compressed","nether:brick_compressed","nether:brick_compressed"},
{"nether:brick_compressed","nether:brick_compressed","nether:brick_compressed"},
{"nether:brick_compressed","nether:brick_compressed","nether:brick_compressed"},
}
})
for _, data in pairs(recipes) do
register_compressor_recipe({input = {data[1]}, output = data[2], time = data[3]})
end

View File

@ -383,7 +383,7 @@ stairs.register_stair(
"nether:rack", "nether:rack",
{cracky = 2, level = 2}, {cracky = 2, level = 2},
{"nether_rack.png"}, {"nether_rack.png"},
S("Netherrack stair"), S("Netherrack Stair"),
minetest.registered_nodes["nether:rack"].sounds minetest.registered_nodes["nether:rack"].sounds
) )
stairs.register_slab( -- register a slab without adding inner and outer stairs stairs.register_slab( -- register a slab without adding inner and outer stairs
@ -391,7 +391,7 @@ stairs.register_slab( -- register a slab without adding inner and outer stairs
"nether:rack", "nether:rack",
{cracky = 2, level = 2}, {cracky = 2, level = 2},
{"nether_rack.png"}, {"nether_rack.png"},
S("Deep Netherrack slab"), S("Netherrack Slab"),
minetest.registered_nodes["nether:rack"].sounds minetest.registered_nodes["nether:rack"].sounds
) )
@ -400,7 +400,7 @@ stairs.register_stair(
"nether:rack_deep", "nether:rack_deep",
{cracky = 2, level = 2}, {cracky = 2, level = 2},
{"nether_rack_deep.png"}, {"nether_rack_deep.png"},
S("Deep Netherrack stair"), S("Deep Netherrack Stair"),
minetest.registered_nodes["nether:rack_deep"].sounds minetest.registered_nodes["nether:rack_deep"].sounds
) )
stairs.register_slab( -- register a slab without adding inner and outer stairs stairs.register_slab( -- register a slab without adding inner and outer stairs
@ -408,14 +408,14 @@ stairs.register_slab( -- register a slab without adding inner and outer stairs
"nether:rack_deep", "nether:rack_deep",
{cracky = 2, level = 2}, {cracky = 2, level = 2},
{"nether_rack_deep.png"}, {"nether_rack_deep.png"},
S("Deep Netherrack slab"), S("Deep Netherrack Slab"),
minetest.registered_nodes["nether:rack_deep"].sounds minetest.registered_nodes["nether:rack_deep"].sounds
) )
-- Connecting walls -- Connecting walls
if minetest.get_modpath("walls") and minetest.global_exists("walls") and walls.register ~= nil then if minetest.get_modpath("walls") and minetest.global_exists("walls") and walls.register ~= nil then
walls.register("nether:rack_wall", S("A Netherrack wall"), "nether_rack.png", "nether:rack", minetest.registered_nodes["nether:rack"].sounds) walls.register("nether:rack_wall", S("A Netherrack Wall"), "nether_rack.png", "nether:rack", minetest.registered_nodes["nether:rack"].sounds)
walls.register("nether:rack_deep_wall", S("A Deep Netherrack wall"), "nether_rack_deep.png", "nether:rack_deep", minetest.registered_nodes["nether:rack_deep"].sounds) walls.register("nether:rack_deep_wall", S("A Deep Netherrack Wall"), "nether_rack_deep.png", "nether:rack_deep", minetest.registered_nodes["nether:rack_deep"].sounds)
end end
-- StairsPlus -- StairsPlus

View File

@ -2166,22 +2166,20 @@ function nether.unregister_portal(name)
end end
function nether.register_portal_ignition_item(item_name, ignition_failure_sound) function nether.register_portal_ignition_item(item_name, ignition_failure_sound)
local old_on_place = minetest.registered_items[item_name].on_place or minetest.item_place
minetest.override_item(item_name, { minetest.override_item(item_name, {
on_place = function(stack, placer, pt) on_place = function(stack, placer, pt, ...)
local done = false
if pt.under and nether.is_frame_node[minetest.get_node(pt.under).name] then if pt.under and nether.is_frame_node[minetest.get_node(pt.under).name] then
done = ignite_portal(pt.under, placer:get_player_name()) local done = ignite_portal(pt.under, placer:get_player_name())
if done and not minetest.settings:get_bool("creative_mode") then if done and not minetest.settings:get_bool("creative_mode") then
stack:take_item() stack:take_item()
end end
end
if not done and ignition_failure_sound ~= nil then if not done and ignition_failure_sound ~= nil then
minetest.sound_play(ignition_failure_sound, {pos = pt.under, max_hear_distance = 10}) minetest.sound_play(ignition_failure_sound, {pos = pt.under, max_hear_distance = 10})
end end
return stack return stack
end
return old_on_place(stack, placer, pt, ...)
end, end,
}) })

View File

@ -153,6 +153,38 @@ minetest.register_craft({
}) })
if minetest.get_modpath("toolranks") then
local function add_toolranks(name)
local nethertool_after_use = ItemStack(name):get_definition().after_use
toolranks.add_tool(name)
local toolranks_after_use = ItemStack(name):get_definition().after_use
if nethertool_after_use == nil or nethertool_after_use == toolranks_after_use then
return
end
minetest.override_item(name, {
after_use = function(itemstack, user, node, digparams)
-- combine nethertool_after_use and toolranks_after_use by allowing
-- nethertool_after_use() to calculate the wear...
local initial_wear = itemstack:get_wear()
itemstack = nethertool_after_use(itemstack, user, node, digparams)
local wear = itemstack:get_wear() - initial_wear
itemstack:set_wear(initial_wear) -- restore/undo the wear
-- ...and have toolranks_after_use() apply the wear.
digparams.wear = wear
return toolranks_after_use(itemstack, user, node, digparams)
end
})
end
add_toolranks("nether:pick_nether")
add_toolranks("nether:shovel_nether")
add_toolranks("nether:axe_nether")
add_toolranks("nether:sword_nether")
end
--===========================-- --===========================--