package electrosphere.engine.loadingthreads; import electrosphere.engine.Globals; import electrosphere.logger.LoggerInterface; import electrosphere.server.saves.SaveUtils; import electrosphere.server.terrain.manager.ServerTerrainManager; public class ServerLoading { protected static void loadMainGameServer(){ //initialize the terrain manager (server only) // if(Globals.RUN_SERVER){ // initServerGameTerrainManager(); // } //TODO: Globals.serverTerrainManager = new ServerTerrainManager(2000,50,100,randomDampener,0); Globals.serverTerrainManager = new ServerTerrainManager(2000,50,ServerTerrainManager.SERVER_TERRAIN_MANAGER_INTERPOLATION_RATIO,0.0f,0); SaveUtils.loadSave(Globals.currentSaveName); // LoadingUtils.initTerrainDataCellManager(); //TODO: set spawnpoint //TODO: Globals.serverWorldData = ServerWorldData.createGameWorld(Globals.serverTerrainManager); //TODO: Globals.dataCellManager = new DataCellManager(Globals.serverWorldData); // Globals.serverWorldData = ServerWorldData.createGameWorld(Globals.serverTerrainManager); // Globals.dataCellManager = new DataCellManager(Globals.serverWorldData); LoggerInterface.loggerEngine.INFO("run server: " + Globals.RUN_SERVER + " run client: " + Globals.RUN_CLIENT); //init authentication LoadingUtils.initAuthenticationManager(); //initialize the server thread (server only) LoadingUtils.initServerThread(); //initialize the "virtual" objects simulation LoadingUtils.initMacroSimulation(); //initialize the "real" objects simulation LoadingUtils.initMicroSimulation(); //init game specific stuff (ie different skybox colors) LoadingUtils.initGameGraphicalEntities(); //set simulations to ready if they exist LoadingUtils.setSimulationsToReady(); //log LoggerInterface.loggerEngine.INFO("[Server]Finished loading main world"); } }