Package org.terasology.game

Examples of org.terasology.game.GameManifest.addModule()


        WorldProvider worldProvider = CoreRegistry.get(WorldProvider.class);
        Game game = CoreRegistry.get(Game.class);

        GameManifest gameManifest = new GameManifest(game.getName(), game.getSeed(), game.getTime().getGameTimeInMs());
        for (Module module : CoreRegistry.get(ModuleManager.class).getEnvironment()) {
            gameManifest.addModule(module.getId(), module.getVersion());
        }

        List<String> registeredBlockFamilies = Lists.newArrayList();
        for (BlockFamily family : blockManager.listRegisteredBlockFamilies()) {
            registeredBlockFamilies.add(family.getURI().toString());
View Full Code Here


                            errorMessagePopup.setMessage("Invalid Module Selection", "Please review your module seleciton and try again");
                        }
                        return;
                    }
                    for (Module module : result.getModules()) {
                        gameManifest.addModule(module.getId(), module.getVersion());
                    }

                    float timeOffset = 0.25f + 0.025f// Time at dawn + little offset to spawn in a brighter env.
                    WorldInfo worldInfo = new WorldInfo(TerasologyConstants.MAIN_WORLD, gameManifest.getSeed(),
                            (long) (WorldTime.DAY_LENGTH * timeOffset), worldGenerator.getSelection().getUri());
View Full Code Here

        Config config = CoreRegistry.get(Config.class);
        ModuleManager moduleManager = CoreRegistry.get(ModuleManager.class);
        for (Name moduleName : config.getDefaultModSelection().listModules()) {
            Module module = moduleManager.getRegistry().getLatestModuleVersion(moduleName);
            if (module != null) {
                gameManifest.addModule(module.getId(), module.getVersion());
            }
        }

        WorldGenerationConfig worldGenConfig = config.getWorldGeneration();
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.