GuiCreateWorld.java 文件源码

java
阅读 27 收藏 0 点赞 0 评论 0

项目:Backmemed 作者:
/**
 * Set the initial values of a new world to create, from the values from an existing world.
 *  
 * Called after construction when a user selects the "Recreate" button.
 */
public void recreateFromExistingWorld(WorldInfo original)
{
    this.worldName = I18n.format("selectWorld.newWorld.copyOf", new Object[] {original.getWorldName()});
    this.worldSeed = original.getSeed() + "";
    this.selectedIndex = original.getTerrainType().getWorldTypeID();
    this.chunkProviderSettingsJson = original.getGeneratorOptions();
    this.generateStructuresEnabled = original.isMapFeaturesEnabled();
    this.allowCheats = original.areCommandsAllowed();

    if (original.isHardcoreModeEnabled())
    {
        this.gameMode = "hardcore";
    }
    else if (original.getGameType().isSurvivalOrAdventure())
    {
        this.gameMode = "survival";
    }
    else if (original.getGameType().isCreative())
    {
        this.gameMode = "creative";
    }
}
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号