Create Ore Excavation

Create Ore Excavation

10M Downloads

Questions about vein finding

BAKAOLC opened this issue ยท 1 comments

commented

Why doesn't the vein finder always return the distance to the vein closest to the player? It's so weird that I moved a little bit and the modification pointed me to a vein further away, which doesn't make any sense at all.

I know this may be designed for optimization, but it is really unreasonable, especially if the x-axis coordinates or z-axis coordinates of the ore vein are close to point 0, it will seriously increase the difficulty of finding the ore vein

Image

Game Version: 1.21.1
NeoForge: 21.1.141
Mod Version: 1.6.3

commented

I've encountered similar things myself, and the map addon shows this very clearly:
Image

I used the Vein Finder in 3 Locations in this image, marked by the red text. The Amethyst Geode is the closest Vein to all 3 Locations, yet two of them show other Veins much further away.

I suspect the long range locate for the Vein Finder is not designed to handle Veins of different Spread/Separation. The less common a vein is, the more visible it will become. Biome White/Blacklists don't affect this.
For instance, while I allowed Coal Veins to spawn in any overworld biome, I made them thinly spread to reduce total quantity. Because of this, Coal Veins are visible from huge distances away (~2500 blocks) even if other Veins are closer.
Veins like the Stannous and Auric are limited to Temerate/Dry biomes, but have a modest spread. They don't appear within that radius around a Coal Vein until you are within ~500 blocks
Veins like Amethyst only appear in Floral biomes and have a really dense spread to make up for it, and don't appear until ~200 blocks out, even around the Stannous and Auric Veins.

I suspect that if all Veins had the same Spread + Separation values (but different seeds), the Vein Finder might accurately point you to the nearest Vein. Then again, I can imagine reasons why it might not. It depends on how the locate function works.

I do have a question though, does the Vein Locator use the same code (or call the same function) as Vanilla Minecraft's /Locate command?