Search in sources :

Example 6 with CampaignFileLoader

use of pcgen.persistence.CampaignFileLoader in project pcgen by PCGen.

the class Main method startupWithoutGUI.

private static boolean startupWithoutGUI() {
    loadProperties(false);
    validateEnvironment(false);
    PCGenTaskExecutor executor = new PCGenTaskExecutor();
    executor.addPCGenTask(createLoadPluginTask());
    executor.addPCGenTask(new GameModeFileLoader());
    executor.addPCGenTask(new CampaignFileLoader());
    executor.execute();
    UIDelegate uiDelegate = new ConsoleUIDelegate();
    BatchExporter exporter = new BatchExporter(exportSheet, uiDelegate);
    boolean result = true;
    if (partyFile != null) {
        result = exporter.exportParty(partyFile, outputFile);
    }
    if (characterFile != null) {
        result = exporter.exportCharacter(characterFile, outputFile);
    }
    return result;
}
Also used : CampaignFileLoader(pcgen.persistence.CampaignFileLoader) GameModeFileLoader(pcgen.persistence.GameModeFileLoader) UIDelegate(pcgen.facade.core.UIDelegate)

Aggregations

CampaignFileLoader (pcgen.persistence.CampaignFileLoader)6 GameModeFileLoader (pcgen.persistence.GameModeFileLoader)6 IOException (java.io.IOException)3 PCGenTask (pcgen.system.PCGenTask)3 PropertyContextFactory (pcgen.system.PropertyContextFactory)3 WindowAdapter (java.awt.event.WindowAdapter)1 WindowEvent (java.awt.event.WindowEvent)1 ArrayList (java.util.ArrayList)1 UIDelegate (pcgen.facade.core.UIDelegate)1 SplashScreen (pcgen.gui2.SplashScreen)1 CampaignPanel (pcgen.gui2.converter.panel.CampaignPanel)1 ConvertSubPanel (pcgen.gui2.converter.panel.ConvertSubPanel)1 GameModePanel (pcgen.gui2.converter.panel.GameModePanel)1 RunConvertPanel (pcgen.gui2.converter.panel.RunConvertPanel)1 SourceSelectionPanel (pcgen.gui2.converter.panel.SourceSelectionPanel)1 StartupPanel (pcgen.gui2.converter.panel.StartupPanel)1 SummaryPanel (pcgen.gui2.converter.panel.SummaryPanel)1 WriteDirectoryPanel (pcgen.gui2.converter.panel.WriteDirectoryPanel)1