Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fixed null world on biome set #774

Merged
merged 3 commits into from
Jan 14, 2024
Merged

fixed null world on biome set #774

merged 3 commits into from
Jan 14, 2024

Conversation

sh0inx
Copy link
Contributor

@sh0inx sh0inx commented Dec 12, 2023

see IS 768

Comment on lines 234 to 246
setIslandBiome(island, XBiome.matchXBiome(schematicConfig.overworld.biome));
setIslandBiome(island, XBiome.matchXBiome(schematicConfig.nether.biome));
setIslandBiome(island, XBiome.matchXBiome(schematicConfig.end.biome));

for(Map.Entry<World.Environment, Boolean> enabledWorld : IridiumSkyblock.getInstance().getConfiguration().enabledWorlds.entrySet()) {
if(!enabledWorld.getValue()) {
continue;
}

switch (enabledWorld.getKey()) {
case NETHER:
setIslandBiome(island, XBiome.matchXBiome(schematicConfig.nether.biome));
break;
case THE_END:
setIslandBiome(island, XBiome.matchXBiome(schematicConfig.end.biome));
break;
default:
setIslandBiome(island, XBiome.matchXBiome(schematicConfig.overworld.biome));
}
}
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can this section not stay how it is? since we already handle if the world is enabled in setIslandBiome no?

I think the previous code is alot cleaner

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ill do some testing, i also found it a bit redundant but i wanted to make sure we got rid of the problem

this still doesn't help anything if the worlds are enabled/disabled during server runtime - this is a separate issue tho

@PeachesMLG PeachesMLG merged commit c9e5e0d into master Jan 14, 2024
2 checks passed
@PeachesMLG PeachesMLG deleted the null-world-biome-set-fix branch January 14, 2024 13:05
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants