Skip to content

Commit

Permalink
Fixing CommandException in World Creator Command by using Custom Envi…
Browse files Browse the repository at this point in the history
…ronment
  • Loading branch information
Dev7ex committed Aug 24, 2024
1 parent f875118 commit d45800f
Showing 1 changed file with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -297,8 +297,9 @@ public void createWorld(@NotNull final String creatorName, @NotNull final String
final ParsedMap<WorldDefaultProperty, Object> defaultProperties = this.pluginConfiguration.getDefaultProperties();
final CommandSender commandSender = BukkitCommon.getCommandSender(creatorName);

worldCreator.environment(BukkitWorldEnvironment.from(environment));
worldCreator.generator(generator);
if (BukkitWorldEnvironment.from(environment) != World.Environment.CUSTOM) {
worldCreator.environment(BukkitWorldEnvironment.from(environment));
}

switch (generator) {
case "FlatWorldGenerator":
Expand Down

0 comments on commit d45800f

Please sign in to comment.