private void loadSchematic() { int selectedIndex = this.guiSchematicLoadSlot.selectedIndex; try { if (selectedIndex >= 0 && selectedIndex < this.schematicFiles.size()) { GuiSchematicEntry schematic = this.schematicFiles.get(selectedIndex); this.settings.loadSchematic( (new File(this.currentDirectory, schematic.getName())).getCanonicalPath()); } } catch (Exception e) { Settings.logger.logSevereException("Failed to load schematic!", e); } this.settings.moveHere(); }
private void loadSchematic() { int selectedIndex = this.guiSchematicLoadSlot.selectedIndex; try { if (selectedIndex >= 0 && selectedIndex < this.schematicFiles.size()) { GuiSchematicEntry schematicEntry = this.schematicFiles.get(selectedIndex); if (Schematica.proxy.loadSchematic(null, this.currentDirectory, schematicEntry.getName())) { SchematicWorld schematic = ClientProxy.schematic; if (schematic != null) { ClientProxy.moveSchematicToPlayer(schematic); } } } } catch (Exception e) { Reference.logger.error("Failed to load schematic!", e); } }