[Bug] No Ore Generation
Flainity opened this issue ยท 18 comments
I don't want to reopen this again, but currently I have the same problem.
Minecraft Version
1.16.5
Forge Version
36.2.8
Mod Version
2.5.1
Reference Issue
Describe the bug
As described in #32 , no ores underground, just stone and air.
How to reproduce
I didn't upgrade the mod version. I just installed it today and never used it before. I tried every solution mentioned here, but without success. Neither does reinstalling work, nor deleting and regenerating the default configs.
I also removed every other mod except of World Stripper, still no ore generation.
After some testing I have figured out older OS such as Win7 could cause this issue.
What OS are you guys currently on? @Flainity @Atlntssplayer @jankornfeld @lynnpye
Lets try to break down this issue.
Can you go download the Curse Forge client https://download.curseforge.com/ if you are not already using this.
- Select Minecraft.
- My Modpacks
- Create a new custom profile
- Select 1.16.5 and Forge 36.2.8
- Click Create
- Click add more content.
- Search for Ore Tweaker
- Install
- Search for World Stripper
- Install
- Click Play
- Wait for Minecraft to boot up
- Create a new world and select gamemode Creative
- Once in that world in Creative Mode press delete key
Can you see any ores now, Yes or No?
Hello!
Thank you for this mod and your support!
I have the same or very similar issue to the one reported above.
THE PROBLEM:
With OreTweaker installed and on default settings, the world doesn't have any ores in it.
I only checked the Overworld dimension.
ENVIRONMENT:
Minecraft 1.16.5
Forge 36.2.8
OreTweaker-1.16.5-2.5.1.jar
few other mods, none of them suppose to touch ore gen.
REPRODUCTION STEPS:
- I copy the OreTweaker jar file into my mods folder, the same as with every other mod.
- I start the game.
- I generate a new game in creative mode.
- I use world stripper to check for ores.
- No ores are found anywhere.
- I close the game.
- I delete OreTweaker and it's config files.
- I re-run the game.
- I re-generate the world in creative mode with the same seed as before.
- I use world stripper.
- There are a lots of ores like it should be in vanilla.
I think this proves that the problem is connected or caused by OreTweaker.
Related problems:
-
There is no OreTweaker.json generated by default.
If I create it manually it gets moved into a the "config\oretweaker\backup" folder.
If I try to write the ore config into OreTweaker.toml the game crashes when loading. -
There is no information here or on Cursefoge where this file should be.
-
There is not enough documentaion what exactly are all the files in "data" and "templates" folders and how to use them. Should they be merged into an OreTweaker.json? If yes where to put this file?
-
There should be a sample OreTweaker.json downloadable here or generated by the game with the vanilla ore gen. settings in it.
-
With a proper OreTweaker.json the reported issue with no ores generating by default would probably go away, but I don't know for sure.
-
In the folder "config\oretweaker\templates\collectives" what is the difference between the files "default.json" and "default_overworld.json".
This is a great mod but it needs a more comprehensible documention and insturctions for the simple minded users, like me. I also checked the Wiki here.
Don't take this the wrong way, but:
I have tried thousands of different windows programs in my life.
I have tried thousands of mods accross many games.
I have tried hundreds of Minecraft mods.
If it takes more than 5 or at the maximum 10 minutes for me to figure out how to change the config for a mod, there is a problem with the mod or the instructions for the mods.
Thank you!
In 1.17.1 this mod was working. But when I installed it in 1.16.5 all ores were gone except one ore from a different mod. (So only Vanilla ores are gone)
In my server console on startup it prints an error:
[12:52:40] [main/ERROR] [oretweaker/]: minecraft:ancient_debris can't be reconstructed from JSON..
[12:52:40] [main/ERROR] [oretweaker/]: minecraft:ancient_debris can't be reconstructed from JSON..
[12:52:40] [main/ERROR] [oretweaker/]: minecraft:andesite can't be reconstructed from JSON..
[12:52:40] [main/ERROR] [oretweaker/]: minecraft:blackstone can't be reconstructed from JSON..
[12:52:40] [main/ERROR] [oretweaker/]: minecraft:coal_ore can't be reconstructed from JSON..
[12:52:40] [main/ERROR] [oretweaker/]: minecraft:diamond_ore can't be reconstructed from JSON..
[12:52:40] [main/ERROR] [oretweaker/]: minecraft:diorite can't be reconstructed from JSON..
[12:52:40] [main/ERROR] [oretweaker/]: minecraft:dirt can't be reconstructed from JSON..
[12:52:40] [main/ERROR] [oretweaker/]: minecraft:emerald_ore can't be reconstructed from JSON..
[12:52:40] [main/ERROR] [oretweaker/]: minecraft:gold_ore can't be reconstructed from JSON..
[12:52:40] [main/ERROR] [oretweaker/]: minecraft:granite can't be reconstructed from JSON..
[12:52:40] [main/ERROR] [oretweaker/]: minecraft:gravel can't be reconstructed from JSON..
[12:52:40] [main/ERROR] [oretweaker/]: minecraft:gravel can't be reconstructed from JSON..
[12:52:40] [main/ERROR] [oretweaker/]: minecraft:infested_stone can't be reconstructed from JSON..
[12:52:40] [main/ERROR] [oretweaker/]: minecraft:iron_ore can't be reconstructed from JSON..
[12:52:40] [main/ERROR] [oretweaker/]: minecraft:lapis_ore can't be reconstructed from JSON..
[12:52:40] [main/ERROR] [oretweaker/]: minecraft:magma_block can't be reconstructed from JSON..
[12:52:40] [main/ERROR] [oretweaker/]: minecraft:nether_gold_ore can't be reconstructed from JSON..
[12:52:40] [main/ERROR] [oretweaker/]: minecraft:nether_gold_ore can't be reconstructed from JSON..
[12:52:40] [main/ERROR] [oretweaker/]: minecraft:nether_quartz_ore can't be reconstructed from JSON..
[12:52:40] [main/ERROR] [oretweaker/]: minecraft:nether_quartz_ore can't be reconstructed from JSON..
[12:52:40] [main/ERROR] [oretweaker/]: minecraft:redstone_ore can't be reconstructed from JSON..
[12:52:40] [main/ERROR] [oretweaker/]: minecraft:soul_sand can't be reconstructed from JSON..
Hello! Thank you for this mod and your support!
I have the same or very similar issue to the one reported above.
THE PROBLEM: With OreTweaker installed and on default settings, the world doesn't have any ores in it. I only checked the Overworld dimension.
ENVIRONMENT: Minecraft 1.16.5 Forge 36.2.8 OreTweaker-1.16.5-2.5.1.jar few other mods, none of them suppose to touch ore gen.
REPRODUCTION STEPS:
- I copy the OreTweaker jar file into my mods folder, the same as with every other mod.
- I start the game.
- I generate a new game in creative mode.
- I use world stripper to check for ores.
- No ores are found anywhere.
- I close the game.
- I delete OreTweaker and it's config files.
- I re-run the game.
- I re-generate the world in creative mode with the same seed as before.
- I use world stripper.
- There are a lots of ores like it should be in vanilla.
I think this proves that the problem is connected or caused by OreTweaker.
Related problems:
- There is no OreTweaker.json generated by default.
If I create it manually it gets moved into a the "config\oretweaker\backup" folder.
If I try to write the ore config into OreTweaker.toml the game crashes when loading.- There is no information here or on Cursefoge where this file should be.
- There is not enough documentaion what exactly are all the files in "data" and "templates" folders and how to use them. Should they be merged into an OreTweaker.json? If yes where to put this file?
- There should be a sample OreTweaker.json downloadable here or generated by the game with the vanilla ore gen. settings in it.
- With a proper OreTweaker.json the reported issue with no ores generating by default would probably go away, but I don't know for sure.
- In the folder "config\oretweaker\templates\collectives" what is the difference between the files "default.json" and "default_overworld.json".
This is a great mod but it needs a more comprehensible documention and insturctions for the simple minded users, like me. I also checked the Wiki here.
Don't take this the wrong way, but: I have tried thousands of different windows programs in my life. I have tried thousands of mods accross many games. I have tried hundreds of Minecraft mods. If it takes more than 5 or at the maximum 10 minutes for me to figure out how to change the config for a mod, there is a problem with the mod or the instructions for the mods.
Thank you!
The OreTweaker.json
is no longer used. If that file is found it is automatically being backed up in the backup folder and deleted. OreTweaker now uses the datafolder that can contain multiple .json
files. OreTweaker may not work with every mod out there.
If you still think world stripper does not work for your computer you can try:
Can you go download the Curse Forge client https://download.curseforge.com/ if you are not already using this.
- Select Minecraft.
- My Modpacks
- Create a new custom profile
- Select 1.16.5 and Forge 36.2.8
- Click Create
- Click add more content.
- Search for Ore Tweaker
- Install
- Search for World Stripper
- Install
- Click Play
- Wait for Minecraft to boot up
- Create a new world and select gamemode Creative
- Once in that world in Creative Mode press delete key
Can you see any ores now, Yes or No?
If yes, you can slowly add other mods on top of that until you figure out what mod it is conflicting with and report it here so I can see what I can do about it.
if no, what OS are you using?
Currently in the hospital so can't make any code changes right now.
Hmmm, I don't think it could have anything with Java version either. Very hard for me to fix a bug only occurring for some users but not all and especially I can't seem to replicate it. I am still looking for a solution to this.
Right now everything works perfectly fine for me using this setup:
Minecraft: 1.16.5
Forge: 36.2.9
Java: 1.8.0_51 64 bit
by Adopt OpenJDK (Hotspot)
OS: Windows 10 Pro
Launched through: CurseForge App
Other mods: World Stripper
Windows 11
I also tried out your solution with a curseforge clean install, but that also didn't work.
I just startet a new fresh install of a 1.17.1 server with this mod and stripper installed (newest versions from curseforge). changed coal and diamond ore to 0. And no ores in the ground and no error message in the console. And I haven't changed the java version.
Minecraft: 1.17.1
Forge: 37.0.103
Java: "16.0.2" 2021-07-20
OS: Windows 10 Pro
Launched through: CurseForge App
Other mods: World Stripper
I added an error above from my server. This could be a good starting point. Do you know where this error is thrown (class and line of code)? @EwyBoy
@jankornfeld yes, gonna look closer into why it does throw that error. I also think if it works for 1.17 it's either a problem with specific java 8 versions or some difference in the code between 1.16 & 1.17. Gonna compare the two different versions and see if I can find anything. Then I will test on some other Java 8 distributions and versions and see if it can have anything to do with that.
@EwyBoy I believe that 1.17.1 is using Java 16. At least the server is only starting with that version
@jankornfeld Yes, 1.17 changed to Java 16, so I suspect java version could be the cause of the bug.
Feel free to update ur Java 8 to this version that is confirmed to work:
https://adoptium.net/?variant=openjdk8
and respond if it fixes the issue.
Just tested on a brand new 1.17.1 server with latest forge version with only world stripper and ore tweaker. Also changed coal and diamond ore to 0 like you can see below. Worked perfectly fine for me.
{
"oreConfig": [
{
"ore": "minecraft:coal_ore",
"filler": "minecraft:stone",
"minY": 1,
"maxY": 128,
"maxVeinSize": 16,
"spawnRate": 0.0,
"biomeBlacklist": [],
"biomeWhitelist": []
}
]
}
{
"oreConfig": [
{
"ore": "minecraft:diamond_ore",
"filler": "minecraft:stone",
"minY": 1,
"maxY": 16,
"maxVeinSize": 7,
"spawnRate": 0.0,
"biomeBlacklist": [],
"biomeWhitelist": []
}
]
}
No coal or diamond spawned for me like it was configured to and the rest of the ores did. So everything works perfectly fine for me..
Minecraft: 1.17.1
Forge: 37.0.104
Java: "16.0.2" 64bit
OS: Windows 10 Pro
Launched through: CurseForge App
Other mods: World Stripper
@Flainity @Atlntssplayer @jankornfeld @lynnpye
Hey! Sorry to tag all of you but I believe I have found the cause of the issue.
Its a very technical bug hence why it has taken me so long to be able to fix it.
The bug is caused in this part of the code:
private static ConfiguredFeature<?, ?> reconstructOre(Block ore, Block filler, int minY, int maxY, float spawnRate, int maxVeinSize) {
ModLogger.debug("Reconstructing ore: " + ore);
String registryName = String.format("%s_%s_%d_%d_%f_%d",
Objects.requireNonNull(ore.getRegistryName()).getPath(),
Objects.requireNonNull(filler.getRegistryName()).getPath(),
minY, maxY, spawnRate, maxVeinSize
);
return register(
registryName, reconstructFeature(
ore,
filler,
minY,
maxY,
spawnRate,
maxVeinSize
)
);
}
Specifically:
String registryName = String.format("%s_%s_%d_%d_%f_%d",
Objects.requireNonNull(ore.getRegistryName()).getPath(),
Objects.requireNonNull(filler.getRegistryName()).getPath(),
minY, maxY, spawnRate, maxVeinSize
);
Some Java VMs (Java Virtual Machines) fail to format and cast String.format("%s_%s_%d_%d_%f_%d") properly and ends up creating an illegal ResourceLocation
for each ore entry. This is why this bug was not occurring for me and most other people.
I hope it works now cause this bug has been so time consuming and hear tearing to fix.
This specific bug is also not present on Minecraft 1.17.x
. This bug can also occur if you mess up your JSON data files so then its probably your fault. But everything should now work out of the box with a clean install with only OreTweaker and World Stripper installed. In the coming days I will work on better debugging tools and making it harder for the end users to mess up the JSON files. Gonna work on a system that catches if it is something wrong and don't allow you to create a world until the JSON files are fixed.
The patch can be found here: https://www.curseforge.com/minecraft/mc-mods/ore-tweaker/files/3520897
So make sure you are using version 2.6.+
from now on.
Please tell me if this patch fixes this issue for you and if you still have problems with this issue on a clean install with the patch comment here.
Thank you for your patience and all help with this issue.