public static List <BlockData> ImportBlockData(string filePath) { List <BlockData> blocks; string extension = Path.GetExtension(filePath).ToLower(); switch (extension) { case ".schematic": fileType = FileType.FILE_Schematic; SchematicProcessor schematicProcessor = new SchematicProcessor(filePath); blocks = schematicProcessor.generateBlockData(); break; case ".mcr": fileType = FileType.FILE_MCR; List <Chunk> chunkList = VoxelTerrainImporter.LoadTerrain(filePath); blocks = VoxelTerrainImporter.GenerateBlocks(chunkList); break; case ".mca": fileType = FileType.FILE_MCA; chunkList = VoxelTerrainImporter.LoadTerrain(filePath); blocks = VoxelTerrainImporter.GenerateBlocks(chunkList); break; default: MessageBox.Show(String.Format("The {0} format is not accepted - Aborting", extension)); blocks = null; break; } return(blocks); }
private void HandelSchematicCommand(string[] commandArgs) { SchematicProcessor.SchematicCommandProcessor(commandArgs); }