mirror of
https://github.com/BentoBoxWorld/Level.git
synced 2025-02-13 10:11:29 +01:00
Fixes deprecated getLevelsData method.
Tested with Biomes 1.7.0.
This commit is contained in:
parent
284f18c680
commit
8f85e90830
@ -338,6 +338,12 @@ public class Level extends Addon implements Listener {
|
|||||||
getPlugin().getAddonsManager().getGameModeAddons().stream()
|
getPlugin().getAddonsManager().getGameModeAddons().stream()
|
||||||
.filter(gm -> !settings.getGameModes().contains(gm.getDescription().getName()))
|
.filter(gm -> !settings.getGameModes().contains(gm.getDescription().getName()))
|
||||||
.forEach(gm -> {
|
.forEach(gm -> {
|
||||||
|
if (getSettings().isZeroNewIslandLevels()) {
|
||||||
|
Island island = getIslands().getIsland(gm.getOverWorld(), targetPlayer);
|
||||||
|
if (island != null) {
|
||||||
|
ld.setInitialLevel(gm.getOverWorld(), this.getInitialIslandLevel(island));
|
||||||
|
}
|
||||||
|
}
|
||||||
ld.setLevel(gm.getOverWorld(), this.getIslandLevel(gm.getOverWorld(), targetPlayer));
|
ld.setLevel(gm.getOverWorld(), this.getIslandLevel(gm.getOverWorld(), targetPlayer));
|
||||||
});
|
});
|
||||||
return ld;
|
return ld;
|
||||||
|
Loading…
Reference in New Issue
Block a user