1
0
Fork 0

Merge branch 'master' into swimming_fix

This commit is contained in:
SumianVoice 2022-07-17 13:15:18 +00:00
commit 0158681cf8
18 changed files with 200 additions and 50 deletions

View File

@ -27,6 +27,10 @@
* Code-Sploit * Code-Sploit
* NO11 * NO11
* kabou * kabou
* rudzik8
* chmodsayshello
* PrarieWind
* RandomLegoBrick
## Contributors ## Contributors
* Laurent Rocher * Laurent Rocher
@ -71,6 +75,10 @@
* Sven792 * Sven792
* aldum * aldum
* Dieter44 * Dieter44
* Pepebotella
* MrRar
* Lazerbeak12345
* mrminer
## MineClone5 ## MineClone5
* kay27 * kay27
@ -78,10 +86,12 @@
* epCode * epCode
* NO11 * NO11
* j45 * j45
* chmodsayshello
* 3raven * 3raven
* PrarieWind * PrarieWind
* Gustavo1 * Gustavo1
* CableGuy67 * CableGuy67
* MrRar
## Mineclonia ## Mineclonia
* erlehmann * erlehmann
@ -134,6 +144,9 @@
* yutyo * yutyo
* NO11 * NO11
* kay27 * kay27
* MysticTempest
* RandomLegoBrick
* cora
## Translations ## Translations
* Wuzzy * Wuzzy
@ -143,6 +156,8 @@
* pitchum * pitchum
* todoporlalibertad * todoporlalibertad
* Marcin Serwin * Marcin Serwin
* Pepebotella
* Emojigit
## Funders ## Funders
* 40W * 40W
@ -150,5 +165,6 @@
## Special thanks ## Special thanks
* celeron55 for creating Minetest * celeron55 for creating Minetest
* Jordach for the jukebox music compilation from Big Freaking Dig * Jordach for the jukebox music compilation from Big Freaking Dig
* wsor for working tirelessly in the shadows for the good of all of us, particularly helping with solving contentDB and copyright issues.
* The workaholics who spent way too much time writing for the Minecraft Wiki. It's an invaluable resource for creating this game * The workaholics who spent way too much time writing for the Minecraft Wiki. It's an invaluable resource for creating this game
* Notch and Jeb for being the major forces behind Minecraft * Notch and Jeb for being the major forces behind Minecraft

View File

@ -2,7 +2,7 @@
An unofficial Minecraft-like game for Minetest. Forked from MineClone by davedevils. An unofficial Minecraft-like game for Minetest. Forked from MineClone by davedevils.
Developed by many people. Not developed or endorsed by Mojang AB. Developed by many people. Not developed or endorsed by Mojang AB.
Version: 0.75 (in development) Version: 0.78 (in development)
### Gameplay ### Gameplay
You start in a randomly-generated world made entirely of cubes. You can explore You start in a randomly-generated world made entirely of cubes. You can explore
@ -91,11 +91,11 @@ The MineClone2 repository is hosted at Mesehub. To contribute or report issues,
## Target ## Target
- Crucially, create a stable, moddable, free/libre clone of Minecraft - Crucially, create a stable, moddable, free/libre clone of Minecraft
based on the Minetest engine with polished features, usable in both based on the Minetest engine with polished features, usable in both
singleplayer and multiplayer. Currently, most of **Minecraft Java singleplayer and multiplayer. Currently, a lot of **Minecraft Java
Edition 1.12.2** features are already implemented and polishing existing Edition** features are already implemented and polishing existing
features are prioritized over new feature requests. features are prioritized over new feature requests.
- With lessened priority yet strictly, implement features targetting - With lessened priority yet strictly, implement features targetting
**Minecraft version 1.17 + OptiFine** (OptiFine only as far as supported **Current Minecraft versions + OptiFine** (OptiFine only as far as supported
by the Minetest Engine). This means features in parity with the listed by the Minetest Engine). This means features in parity with the listed
Minecraft experiences are prioritized over those that don't fulfill this Minecraft experiences are prioritized over those that don't fulfill this
scope. scope.
@ -108,8 +108,7 @@ playerbase on low spec computers, optimizations are hard to investigate.
This game is currently in **beta** stage. This game is currently in **beta** stage.
It is playable, but not yet feature-complete. It is playable, but not yet feature-complete.
Backwards-compability is not entirely guaranteed, updating your world might cause small bugs. Backwards-compability is not entirely guaranteed, updating your world might cause small bugs.
If you want to use the git version of MineClone2 in production, consider using the production branch. If you want to use the development version of MineClone2 in production, the master branch is usually relatively stable. The testing branch often features some experimental PRs and should be considered less stable.
It is updated weekly and contains relatively stable code for servers.
The following main features are available: The following main features are available:
@ -124,7 +123,7 @@ The following main features are available:
* Most blocks in the overworld * Most blocks in the overworld
* Water and lava * Water and lava
* Weather * Weather
* 28 biomes * 28 biomes + 5 Nether Biomes
* The Nether, a fiery underworld in another dimension * The Nether, a fiery underworld in another dimension
* Redstone circuits (partially) * Redstone circuits (partially)
* Minecarts (partial) * Minecarts (partial)
@ -162,7 +161,7 @@ The following features are incomplete:
* Special minecarts * Special minecarts
* A couple of non-trivial blocks and items * A couple of non-trivial blocks and items
Bonus features (not found in Minecraft 1.12): Bonus features (not found in Minecraft):
* Built-in crafting guide which shows you crafting and smelting recipes * Built-in crafting guide which shows you crafting and smelting recipes
* In-game help system containing extensive help about gameplay basics, blocks, items and more * In-game help system containing extensive help about gameplay basics, blocks, items and more
@ -175,6 +174,9 @@ Bonus features (not found in Minecraft 1.12):
* Nether Brick Fence Gate * Nether Brick Fence Gate
* Red Nether Brick Fence * Red Nether Brick Fence
* Red Nether Brick Fence Gate * Red Nether Brick Fence Gate
* Structure replacements - these small variants of Minecraft structures serve as replacements until we can get large structures working:
* Woodland Cabin (Mansions)
* Nether Outpost (Fortress)
Technical differences from Minecraft: Technical differences from Minecraft:

View File

@ -91,7 +91,7 @@ minetest.register_chatcommand("clearmobs",{
if o.is_mob then if o.is_mob then
if param == "all" or if param == "all" or
( param == "nametagged" and o.nametag ) or ( param == "nametagged" and o.nametag ) or
( param == "" and not o.nametag and not o.tamed ) or ( param == "" and ( not o.nametag or o.nametag == "" ) and not o.tamed ) or
( num and num > 0 and vector.distance(p:get_pos(),o.object:get_pos()) <= num ) then ( num and num > 0 and vector.distance(p:get_pos(),o.object:get_pos()) <= num ) then
o.object:remove() o.object:remove()
end end
@ -2312,9 +2312,9 @@ local function check_doors(self)
local def = minetest.registered_nodes[n.name] local def = minetest.registered_nodes[n.name]
local closed = n.name:find("_b_1") local closed = n.name:find("_b_1")
if t < 0.3 or t > 0.8 then if t < 0.3 or t > 0.8 then
if not closed then def.on_rightclick(d,n,self) end if not closed and def.on_rightclick then def.on_rightclick(d,n,self) end
else else
if closed then def.on_rightclick(d,n,self) end if closed and def.on_rightclick then def.on_rightclick(d,n,self) end
end end
end end

View File

@ -1,64 +1,58 @@
# textdomain: mobs_mc # textdomain: mobs_mc
Agent=Agente
Bat=Murciélago Bat=Murciélago
Blaze=Blaze Blaze=Blaze
Chicken=Pollo Chicken=Pollo
Cod=Bacalao
Cow=Vaca Cow=Vaca
Mooshroom=Champiñaca Mooshroom=Champivaca
Creeper=Creeper Creeper=Creeper
Ender Dragon=Enderdragón Dolphin=Delfín
Ender Dragon=Ender Dragon
Enderman=Enderman Enderman=Enderman
Endermite=Endermite Endermite=Endermite
Ghast=Ghast Ghast=Ghast
Elder Guardian=Gran guardián
Guardian=Guardián Guardian=Guardián
Horse=Caballo Elder Guardian=Guardián Anciano
Skeleton Horse=Caballo esquelético
Zombie Horse=Caballo zombie
Donkey=Burro Donkey=Burro
Horse=Caballo
Mule=Mula Mule=Mula
Skeleton Horse=Caballo esqueleto
Zombie Horse=Caballo zombi
Iron Golem=Golem de hierro Iron Golem=Golem de hierro
Llama=Llama Llama=Llama
Cat=Gato
Ocelot=Ocelote Ocelot=Ocelote
Parrot=Loro Parrot=Loro
Pig=Cerdo Pig=Cerdo
Polar Bear=Oso polar Polar Bear=Oso polar
Rabbit=Conejo
Killer Bunny=Conejo asesino Killer Bunny=Conejo asesino
Rabbit=Conejo
Salmon=Salmón
Sheep=Oveja Sheep=Oveja
Shulker=Shulker Shulker=Shulker
Silverfish=Lepisma Silverfish=Lepisma
Skeleton=Esqueleto Skeleton=Esqueleto
Stray=Esqueleto Stray=Esqueleto glacial
Wither Skeleton=Esqueleto wither Wither Skeleton=Esqueleto del Wither
Magma Cube=Cubo de Magma Magma Cube=Cubo de Magma
Slime=Slime Slime=Slime
Snow Golem=Golem de nieve Snow Golem=Golem de nieve
Spider=Araña
Cave Spider=Araña de las cuevas Cave Spider=Araña de las cuevas
Spider=Araña
Squid=Calamar Squid=Calamar
Vex=Ánima Vex=Ánima
Master=Maestro
Villager=Aldeano
Evoker=Invocador Evoker=Invocador
Illusioner=Illusionista Illusioner=Illusionista
Villager=Aldeano
Vindicator=Vindicador Vindicator=Vindicador
Zombie Villager=Aldeano zombie Zombie Villager=Aldeano zombi
Witch=Bruja Witch=Bruja
Wither=Wither Wither=Wither
Wolf=Lobo Wolf=Lobo
Husk=Husk Baby Husk=Bebé Zombi Momificado
Zombie=Zombie Baby Zombie=Bebé Zombi
Zombie Pigman=Cerdo Zombie Husk=Zombi Momificado
Farmer=Granjero Zombie=Zombi
Fisherman=Pescador Baby Zombie Pigman=Bebé Hombrecerdo Zombi
Fletcher=Flechador Zombie Pigman=Hombrecerdo Zombi
Shepherd=Sacerdote
Librarian=Bibliotecario
Cartographer=Cartógrafo
Armorer=Armero
Leatherworker=Peletero
Butcher=Carnicero
Weapon Smith=Herrero de Armas
Tool Smith=Herrero de Herramientas
Cleric=Sacerdote
Nitwit=Simple

View File

@ -1,6 +1,7 @@
local S = minetest.get_translator(minetest.get_current_modname()) local S = minetest.get_translator(minetest.get_current_modname())
local mod_target = minetest.get_modpath("mcl_target") local mod_target = minetest.get_modpath("mcl_target")
local enable_pvp = minetest.settings:get_bool("enable_pvp")
local math = math local math = math
local vector = vector local vector = vector
@ -204,9 +205,9 @@ function ARROW_ENTITY.on_step(self, dtime)
if hitpoint.type == "object" then if hitpoint.type == "object" then
-- find the closest object that is in the way of the arrow -- find the closest object that is in the way of the arrow
local ok = false local ok = false
if hitpoint.ref:is_player() then if hitpoint.ref:is_player() and enable_pvp then
ok = true ok = true
elseif hitpoint.ref:get_luaentity() then elseif not hitpoint.ref:is_player() and hitpoint.ref:get_luaentity() then
if (hitpoint.ref:get_luaentity().is_mob or hitpoint.ref:get_luaentity()._hittable_by_projectile) then if (hitpoint.ref:get_luaentity().is_mob or hitpoint.ref:get_luaentity()._hittable_by_projectile) then
ok = true ok = true
end end

View File

@ -231,6 +231,7 @@ end
local mod_awards = minetest.get_modpath("awards") and minetest.get_modpath("mcl_achievements") local mod_awards = minetest.get_modpath("awards") and minetest.get_modpath("mcl_achievements")
local mod_button = minetest.get_modpath("mesecons_button") local mod_button = minetest.get_modpath("mesecons_button")
local mod_target = minetest.get_modpath("mcl_target") local mod_target = minetest.get_modpath("mcl_target")
local enable_pvp = minetest.settings:get_bool("enable_pvp")
minetest.register_craftitem("mcl_bows:rocket", { minetest.register_craftitem("mcl_bows:rocket", {
description = S("Arrow"), description = S("Arrow"),
@ -417,9 +418,9 @@ function ARROW_ENTITY.on_step(self, dtime)
if hitpoint.type == "object" then if hitpoint.type == "object" then
-- find the closest object that is in the way of the arrow -- find the closest object that is in the way of the arrow
local ok = false local ok = false
if hitpoint.ref:is_player() then if hitpoint.ref:is_player() and enable_pvp then
ok = true ok = true
elseif hitpoint.ref:get_luaentity() then elseif not hitpoint.ref:is_player() and hitpoint.ref:get_luaentity() then
if (hitpoint.ref:get_luaentity().is_mob or hitpoint.ref:get_luaentity()._hittable_by_projectile) then if (hitpoint.ref:get_luaentity().is_mob or hitpoint.ref:get_luaentity()._hittable_by_projectile) then
ok = true ok = true
end end

View File

@ -23,4 +23,13 @@ minetest.register_craft({
{"mcl_core:iron_nugget", "mcl_torches:torch" , "mcl_core:iron_nugget"}, {"mcl_core:iron_nugget", "mcl_torches:torch" , "mcl_core:iron_nugget"},
{"mcl_core:iron_nugget", "mcl_core:iron_nugget", "mcl_core:iron_nugget"}, {"mcl_core:iron_nugget", "mcl_core:iron_nugget", "mcl_core:iron_nugget"},
}, },
}) })
minetest.register_craft({
output = "mcl_lanterns:soul_lantern_floor",
recipe = {
{"mcl_core:iron_nugget", "mcl_core:iron_nugget" , "mcl_core:iron_nugget"},
{"mcl_core:iron_nugget", "mcl_blackstone:soul_torch" , "mcl_core:iron_nugget"},
{"mcl_core:iron_nugget", "mcl_core:iron_nugget" , "mcl_core:iron_nugget"},
},
})

View File

@ -30,6 +30,7 @@ local how_to_shoot = minetest.registered_items["mcl_bows:arrow"]._doc_items_usag
local mod_awards = minetest.get_modpath("awards") and minetest.get_modpath("mcl_achievements") local mod_awards = minetest.get_modpath("awards") and minetest.get_modpath("mcl_achievements")
local mod_button = minetest.get_modpath("mesecons_button") local mod_button = minetest.get_modpath("mesecons_button")
local enable_pvp = minetest.settings:get_bool("enable_pvp")
local arrow_longdesc = minetest.registered_items["mcl_bows:arrow"]._doc_items_longdesc or "" local arrow_longdesc = minetest.registered_items["mcl_bows:arrow"]._doc_items_longdesc or ""
local arrow_tt = minetest.registered_items["mcl_bows:arrow"]._tt_help or "" local arrow_tt = minetest.registered_items["mcl_bows:arrow"]._tt_help or ""
@ -217,9 +218,9 @@ function mcl_potions.register_arrow(name, desc, color, def)
if hitpoint.type == "object" then if hitpoint.type == "object" then
-- find the closest object that is in the way of the arrow -- find the closest object that is in the way of the arrow
local ok = false local ok = false
if hitpoint.ref:is_player() then if hitpoint.ref:is_player() and enable_pvp then
ok = true ok = true
elseif hitpoint.ref:get_luaentity() then elseif not hitpoint.ref:is_player() and hitpoint.ref:get_luaentity() then
if (hitpoint.ref:get_luaentity().is_mob or hitpoint.ref:get_luaentity()._hittable_by_projectile) then if (hitpoint.ref:get_luaentity().is_mob or hitpoint.ref:get_luaentity()._hittable_by_projectile) then
ok = true ok = true
end end
@ -283,7 +284,7 @@ function mcl_potions.register_arrow(name, desc, color, def)
if is_player then if is_player then
if self._shooter and self._shooter:is_player() then if self._shooter and self._shooter:is_player() then
-- “Ding” sound for hitting another player -- “Ding” sound for hitting another player
minetest.sound_play({name="mcl_bows_hit_player", gain=0.1}, {to_player=self._shooter}, true) minetest.sound_play({name="mcl_bows_hit_player", gain=0.1}, {to_player=self._shooter:get_player_name()}, true)
end end
end end

View File

@ -404,6 +404,46 @@ if minetest.settings:get_bool("mcl_generate_ores", true) then
y_max = mcl_worlds.layer_to_y(15), y_max = mcl_worlds.layer_to_y(15),
}) })
--
-- Ancient debris
--
local ancient_debris_wherein = {"mcl_nether:netherrack","mcl_blackstone:blackstone","mcl_blackstone:basalt"}
-- Common spawn
minetest.register_ore({
ore_type = "scatter",
ore = "mcl_nether:ancient_debris",
wherein = ancient_debris_wherein,
clust_scarcity = 25000, -- 0.004% chance
clust_num_ores = 3,
clust_size = 3,
y_min = mcl_vars.mg_nether_min + 8,
y_max = mcl_vars.mg_nether_min + 22,
})
-- Rare spawn (below)
minetest.register_ore({
ore_type = "scatter",
ore = "mcl_nether:ancient_debris",
wherein = ancient_debris_wherein,
clust_scarcity = 32000,
clust_num_ores = 2,
clust_size = 3,
y_min = mcl_vars.mg_nether_min,
y_max = mcl_vars.mg_nether_min + 8,
})
-- Rare spawn (above)
minetest.register_ore({
ore_type = "scatter",
ore = "mcl_nether:ancient_debris",
wherein = ancient_debris_wherein,
clust_scarcity = 32000,
clust_num_ores = 2,
clust_size = 3,
y_min = mcl_vars.mg_nether_min + 22,
y_max = mcl_vars.mg_nether_min + 119,
})
-- --
-- Redstone -- Redstone
-- --

View File

@ -244,6 +244,7 @@ dofile(modpath.."/ocean_ruins.lua")
dofile(modpath.."/witch_hut.lua") dofile(modpath.."/witch_hut.lua")
dofile(modpath.."/igloo.lua") dofile(modpath.."/igloo.lua")
dofile(modpath.."/woodland_mansion.lua") dofile(modpath.."/woodland_mansion.lua")
dofile(modpath.."/ruined_portal.lua")
dofile(modpath.."/geode.lua") dofile(modpath.."/geode.lua")

View File

@ -0,0 +1,85 @@
local modname = minetest.get_current_modname()
local modpath = minetest.get_modpath(modname)
local function get_replacements(b,c,pr)
local r = {}
if not b then return r end
for k,v in pairs(b) do
if pr:next(1,100) < c then table.insert(r,v) end
end
return r
end
local def = {
place_on = {"group:grass_block","group:dirt","mcl_core:dirt_with_grass","group:grass_block","group:sand","group:grass_block_snow","mcl_core:snow"},
fill_ratio = 0.01,
flags = "place_center_x, place_center_z, all_floors",
solid_ground = true,
make_foundation = true,
chunk_probability = 400,
y_max = mcl_vars.mg_overworld_max,
y_min = 1,
sidelen = 10,
y_offset = -4,
filenames = {
modpath.."/schematics/mcl_structures_ruined_portal_1.mts",
modpath.."/schematics/mcl_structures_ruined_portal_2.mts",
modpath.."/schematics/mcl_structures_ruined_portal_3.mts",
modpath.."/schematics/mcl_structures_ruined_portal_4.mts",
modpath.."/schematics/mcl_structures_ruined_portal_5.mts",
modpath.."/schematics/mcl_structures_ruined_portal_99.mts",
},
after_place = function(pos,def,pr)
local hl = def.sidelen / 2
local p1 = vector.offset(pos,-hl,-hl,-hl)
local p2 = vector.offset(pos,hl,hl,hl)
local gold = minetest.find_nodes_in_area(p1,p2,{"mcl_core:goldblock"})
local lava = minetest.find_nodes_in_area(p1,p2,{"mcl_core:lava_source"})
local rack = minetest.find_nodes_in_area(p1,p2,{"mcl_nether:netherrack"})
local brick = minetest.find_nodes_in_area(p1,p2,{"mcl_core:stonebrick"})
local obby = minetest.find_nodes_in_area(p1,p2,{"mcl_core:obsidian"})
minetest.bulk_set_node(get_replacements(gold,30,pr),{name="air"})
minetest.bulk_set_node(get_replacements(lava,20,pr),{name="mcl_nether:magma"})
minetest.bulk_set_node(get_replacements(rack,7,pr),{name="mcl_nether:magma"})
minetest.bulk_set_node(get_replacements(obby,30,pr),{name="mcl_core:crying_obsidian"})
minetest.bulk_set_node(get_replacements(obby,10,pr),{name="air"})
minetest.bulk_set_node(get_replacements(brick,50,pr),{name="mcl_core:stonebrickcracked"})
brick = minetest.find_nodes_in_area(p1,p2,{"mcl_core:stonebrick"})
minetest.bulk_set_node(get_replacements(brick,50,pr),{name="mcl_core:stonebrickmossy"})
end,
loot = {
["mcl_chests:chest_small" ] ={{
stacks_min = 2,
stacks_max = 6,
items = {
{ itemstring = "mcl_core:iron_nugget", weight = 40, amount_min = 9, amount_max = 18 },
{ itemstring = "mcl_core:flint", weight = 40, amount_min = 1, amount_max=4 },
{ itemstring = "mcl_core:obsidian", weight = 40, amount_min = 1, amount_max=2 },
{ itemstring = "mcl_fire:fire_charge", weight = 40, amount_min = 1, amount_max = 1 },
{ itemstring = "mcl_fire:flint_and_steel", weight = 40, amount_min = 1, amount_max = 1 },
{ itemstring = "mcl_core:gold_nugget", weight = 15, amount_min = 4, amount_max = 24 },
{ itemstring = "mcl_core:apple_gold", weight = 15, },
{ itemstring = "mcl_books:book", weight = 1, func = function(stack, pr)
mcl_enchanting.enchant_uniform_randomly(stack, {"soul_speed"}, pr)
end },
--{ itemstring = "mcl_bamboo:bamboo", weight = 15, amount_min = 1, amount_max=3 }, --FIXME BAMBOO
{ itemstring = "mcl_core:diamond", weight = 3, amount_min = 1, amount_max = 3 },
{ itemstring = "mcl_mobitems:saddle", weight = 3, },
{ itemstring = "mcl_core:emerald", weight = 2, amount_min = 1, amount_max = 3 },
{ itemstring = "mcl_mobitems:iron_horse_armor", weight = 1, },
{ itemstring = "mcl_mobitems:gold_horse_armor", weight = 1, },
{ itemstring = "mcl_mobitems:diamond_horse_armor", weight = 1, },
{ itemstring = "mcl_core:apple_gold", weight = 15, },
}
}}
}
}
mcl_structures.register_structure("ruined_portal_overworld",def)
local ndef = table.copy(def)
ndef.y_min=mcl_vars.mg_lava_nether_max +10
ndef.y_max=mcl_vars.mg_nether_max - 15
ndef.place_on = {"mcl_nether:netherrack","group:soul_block","mcl_blackstone:basalt,mcl_blackstone:blackstone","mcl_crimson:crimson_nylium","mcl_crimson:warped_nylium"},
mcl_structures.register_structure("ruined_portal_nether",ndef)

View File

@ -19,7 +19,7 @@ pathlist = Path(path).rglob('*.lua')
for path in pathlist: for path in pathlist:
path_in_str = str(path) path_in_str = str(path)
# print(path_in_str) # print(path_in_str)
trouve = False found = False
with open(path_in_str) as f: with open(path_in_str) as f:
local_vars = [] local_vars = []
for i, line in enumerate(f.readlines()): for i, line in enumerate(f.readlines()):
@ -38,7 +38,7 @@ for path in pathlist:
local_vars.append(n.group('local_var')) local_vars.append(n.group('local_var'))
if not found: if not found:
nb_varloc = len(variables_locales) nb_varloc = len(local_vars)
#print(path_in_str, ": -", "({} variables locales)".format(nb_varloc) if nb_varloc > 0 else '') #print(path_in_str, ": -", "({} variables locales)".format(nb_varloc) if nb_varloc > 0 else '')
print(', '.join(['"{}"'.format(v) for v in global_vars])) print(', '.join(['"{}"'.format(v) for v in global_vars]))