private void deployServerToMemory() { GameServer_Management DeployConfig = new GameServer_Management(); DeployConfig.DeployGameserver( //Server-based Properties txtServerGivenName.Text, DeploymentValues.SERVER_type, DeploymentValues.SERVER_launch_arguments, false, //Directory-based Properties DeploymentValues.DIR_install_location, DeploymentValues.DIR_executable, DeploymentValues.DIR_config, DeploymentValues.DIR_config_file, //Steam-based Properties DeploymentValues.STEAM_authrequired, DeploymentValues.STEAM_steamcmd_required, DeploymentValues.STEAM_workshop_enabled, //Miscellanious Properties DeploymentValues.ENGINE_type, DeploymentValues.bsm_integration, //Deployment Property false); btnCancelDeployGameserver.Visible = false; btnDeployGameserver.Enabled = true; }
private void BorealisServerManager_FormClosed(object sender, FormClosedEventArgs e) { //Write data in memory to disk into gameservers.json if (GameServer_Management.server_collection != null) { //Delete existing gameservers.json if (System.IO.File.Exists(Environment.CurrentDirectory + @"\gameservers.json")) { System.IO.File.Delete(Environment.CurrentDirectory + @"\gameservers.json"); } foreach (JObject gameserver in GameServer_Management.server_collection) { GameServer_Management WriteConfigOnClose = new GameServer_Management(); WriteConfigOnClose.DeployGameserver( //Server-based Properties (string)gameserver["SERVER_name_friendly"], (string)gameserver["SERVER_type"], (string)gameserver["SERVER_launch_arguments"], (bool)gameserver["SERVER_running_status"], //Directory-based Properties (string)gameserver["DIR_install_location"], (string)gameserver["DIR_executable"], (string)gameserver["DIR_config"], (string)gameserver["DIR_config_file"], //Steam-based Properties (bool)gameserver["STEAM_authrequired"], (bool)gameserver["STEAM_steamcmd_required"], (bool)gameserver["STEAM_workshop_enabled"], //Miscellanious Properties (string)gameserver["ENGINE_type"], (string)gameserver["bsm_integration"], //Deployment Property true); } } }