Grand mapgen cleanup Part 1 #2355
No reviewers
Labels
No Label
#P1 CRITICAL
#P2: HIGH
#P3: elevated
#P4 priority: medium
#P6: low
#Review
annoying
API
bug
code quality
combat
commands
compatibility
configurability
contribution inside
controls
core feature
creative mode
delayed for engine release
documentation
duplicate
enhancement
environment
feature request
gameplay
graphics
ground content conflict
GUI/HUD
help wanted
incomplete feature
invalid / won't fix
items
looking for contributor
mapgen
meta
mineclone2+
Minecraft >= 1.13
Minecraft >= 1.17
missing feature
mobile
mobs
mod support
model needed
multiplayer
Needs adoption
needs discussion
needs engine change
needs more information
needs research
nodes
non-mob entities
performance
player
possible close
redstone
release notes
schematics
Skyblock
sounds
Testing / Retest
tools
translation
unconfirmed
mcl5
mcla
Media missing
No Milestone
No project
No Assignees
2 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: VoxeLibre/VoxeLibre#2355
Loading…
Reference in New Issue
No description provided.
Delete Branch "mapgen_fixes"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
While I'm overall happy with the performance of the new structure api - even unoptimized it was notably faster than some legacy mapgen stuff (cough tsm_railcorridors)
I did findd a few things that could still be optimized though:
Furthermore some cleanup of legacy stuff in mcl_mapgen_core.
Use mcl's "register_generator" mapgen pipeline instead of plain on_generated
Optimize Terrain feature generation (bulk_set_node instead of set_node, no logging)
Use decorations in caves except for v6 (minetest used to not support it apparently, but now it does via the "all_floors" flag)
Add "solid_ground" flag for structures which means the api will check if there's solid ground and deny placement if there is not.
Add "make_foundation" flag which will make the solid ground if needed
Add jungle temple and ocean ruins (schematics by @PrairieAstronomer
implement the old chunk probability logic in the new api
Move simple legacy structures to new api
- implement mcl_secret_ores for netherite (I'll make that a separate pr once netherite is in.
Most of this PR is adding some features to the structure api so it supports the stuff that was done "manually" in a long spaghetti in mcl_mapgen_core and moving those features to mcl_structures into separate files using the new struct api.
Next up (in part 2)
after this mcl_mapgen_core should only contain api code and the generation code for the basic world layout (bedrock, dimensions).
so we'll have
neatly separated as the main mapgen mods. More complex structure stuff like villages can still be their own mods and depend on mcl_structures. Simple structures can be additional lua files in mcl_structures (I'll move shipwrecks back there).
This PR fixes #2364
This PR fixes #2372
Testing
Seed "y"
cold_ocean_ruins (1205,-10,2896)
desert_temple (1639,-7,2628)
igloo (1187,2,2867)
jungle_temple (2440,36,4193)
shipwreck (1106,-22,16573)
warm_ocean_ruins (1032,-20,17333)
witch_hut (670,2,15623)
desert well (2165,6,1956)
fossil (-650,-9,4)
woodland cabin (1283,56,-473)
water lake 210,14,904
lava pool 1030,8,1285
village (690,30,5000) - village gen is unchanged as of yet
d549d3721c
tob7957a1930
WIP: mapgen/structures fixes, optimizations, api additionsto WIP: mapgen/structures fixes, optimizations, api additions, new schematicsWIP: mapgen/structures fixes, optimizations, api additions, new schematicsto WIP: Grand mapgen cleanup Part 1WIP: Grand mapgen cleanup Part 1to Grand mapgen cleanup Part 13978da690a
to8f1ab7f86e
rebased
The distribution still needs to be tweaked (most structs are somewhat common rn hehe) but seeing as this fixes some issues and all of this will need testing anyways i think it is good to go.
8f1ab7f86e
toe3432a8b90
e3432a8b90
tof115fc8ea0
Alright, been testing this for a while. Pretty awesome so far.
First up:
I tried testing to see if issue #2372 was fixed. And, while there's no crash. No lake loaded. And, I'm having trouble finding one to test.
On master, with seed "y" I found one at the following location:
water lake: 1312, 14, 1320
On this branch it's gone.
I know there's a couple changes to spawning them. Do you know of a water or lava lake spawn to confirm?
Second:
The desert temple's have no loot.
Seems to work okay if I set the following line:
https://git.minetest.land/MineClone2/MineClone2/src/branch/mapgen_fixes/mods/MAPGEN/mcl_structures/desert_temple.lua#L50
To:
Then load a new temple.
Everything else seems to spawn correctly, nice work!
Oh yeah i suppose they have the old chests in the schematic .. i'll see about the lakes
yeah surface pools were broken..
That last one is because pools (and geodes) tend to get cut off sometimes otherwise.
Retested, works; thanks!