Search in sources :

Example 21 with CharacterData

use of delta.games.lotro.character.CharacterData in project lotro-companion by dmorcellet.

the class MainTestShowBuffChoiceWindow method main.

/**
 * Basic main method for test.
 * @param args Not used.
 */
public static void main(String[] args) {
    CharacterData c = new CharacterData();
    c.setCharacterClass(CharacterClass.CAPTAIN);
    c.setRace(Race.MAN);
    BuffsManager buffs = new BuffsManager();
    List<Buff> possibleBuffs = BuffRegistry.getInstance().buildBuffSelection(c, buffs);
    Buff initialBuff = possibleBuffs.get(3);
    System.out.println(initialBuff);
    Buff buff = BuffChoiceWindowController.selectBuff(null, possibleBuffs, initialBuff);
    System.out.println(buff);
}
Also used : CharacterData(delta.games.lotro.character.CharacterData) Buff(delta.games.lotro.character.stats.buffs.Buff) BuffsManager(delta.games.lotro.character.stats.buffs.BuffsManager)

Example 22 with CharacterData

use of delta.games.lotro.character.CharacterData in project lotro-companion by dmorcellet.

the class MainTestAllEssencesEditionWindow method main.

/**
 * Basic main method for test.
 * @param args Not used.
 */
public static void main(String[] args) {
    CharacterGenerationTools tools = new CharacterGenerationTools();
    CharacterGeneratorMeva mevaGenerator = new CharacterGeneratorMeva(tools);
    CharacterData meva = mevaGenerator.buildCharacter();
    meva.setDate(Long.valueOf(System.currentTimeMillis()));
    AllEssencesEditionWindowController ctrl = new AllEssencesEditionWindowController(null, meva);
    ctrl.show();
}
Also used : CharacterData(delta.games.lotro.character.CharacterData) CharacterGeneratorMeva(delta.games.lotro.character.stats.CharacterGeneratorMeva) CharacterGenerationTools(delta.games.lotro.character.stats.CharacterGenerationTools)

Example 23 with CharacterData

use of delta.games.lotro.character.CharacterData in project lotro-companion by dmorcellet.

the class MainTestStatCurveChart method doIt.

private void doIt(CharacterData data) {
    // Load toon stats
    CharacterGenerationTools tools = new CharacterGenerationTools();
    CharacterGeneratorGiswald generator = new CharacterGeneratorGiswald(tools);
    CharacterData c = generator.buildCharacter();
    List<StatCurvesChartConfiguration> configs = new ArrayList<StatCurvesChartConfiguration>();
    StatCurvesConfigurationFactory factory = new StatCurvesConfigurationFactory(c.getCharacterClass());
    configs.add(factory.buildPhysicalDamageChart());
    configs.add(factory.buildTacticalDamageChart());
    configs.add(factory.buildCriticalsChart());
    configs.add(factory.buildFinesseChart());
    configs.add(factory.buildHealingChart());
    configs.add(factory.buildIncomingHealingChart());
    configs.add(factory.buildBlockChart());
    configs.add(factory.buildParryChart());
    configs.add(factory.buildEvadeChart());
    configs.add(factory.buildResistanceChart());
    configs.add(factory.buildCriticalDefenceChart());
    configs.add(factory.buildPhysicalMitigationChart());
    configs.add(factory.buildTacticalMitigationChart());
    configs.add(factory.buildOrcCraftFellWroughtMitigationChart());
    CharacterStatsComputer statsComputer = new CharacterStatsComputer();
    BasicStatsSet stats = statsComputer.getStats(c);
    c.getStats().setStats(stats);
    int level = c.getLevel();
    for (StatCurvesChartConfiguration config : configs) {
        config.setLevel(level);
        config.setMaxRating(config.getAutoMaxRating());
        StatCurvesPanelController controller = new StatCurvesPanelController(config);
        controller.update(c);
        JPanel statPanel = controller.getPanel();
        DefaultWindowController w = new DefaultWindowController();
        w.getFrame().add(statPanel);
        w.getFrame().pack();
        w.show();
    }
}
Also used : JPanel(javax.swing.JPanel) DefaultWindowController(delta.common.ui.swing.windows.DefaultWindowController) ArrayList(java.util.ArrayList) CharacterGeneratorGiswald(delta.games.lotro.character.stats.CharacterGeneratorGiswald) BasicStatsSet(delta.games.lotro.character.stats.BasicStatsSet) CharacterData(delta.games.lotro.character.CharacterData) CharacterStatsComputer(delta.games.lotro.character.stats.CharacterStatsComputer) CharacterGenerationTools(delta.games.lotro.character.stats.CharacterGenerationTools)

Example 24 with CharacterData

use of delta.games.lotro.character.CharacterData in project lotro-companion by dmorcellet.

the class MainTestTomesEditionPanel method main.

/**
 * Basic main method for test.
 * @param args Not used.
 */
public static void main(String[] args) {
    CharacterData c = new CharacterData();
    TomesSet tomes = c.getTomes();
    tomes.setTomeRank(STAT.MIGHT, 5);
    TomesEditionPanelController controller = new TomesEditionPanelController(c);
    JFrame frame = new JFrame("Tomes edition");
    frame.add(controller.getPanel());
    frame.pack();
    frame.setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE);
    frame.setVisible(true);
}
Also used : CharacterData(delta.games.lotro.character.CharacterData) JFrame(javax.swing.JFrame) TomesSet(delta.games.lotro.character.stats.tomes.TomesSet)

Example 25 with CharacterData

use of delta.games.lotro.character.CharacterData in project lotro-companion by dmorcellet.

the class MainTestVirtuesEditionPanel method main.

/**
 * Basic main method for test.
 * @param args Not used.
 */
public static void main(String[] args) {
    CharacterGenerationTools tools = new CharacterGenerationTools();
    CharacterGeneratorMeva mevaGenerator = new CharacterGeneratorMeva(tools);
    CharacterData meva = mevaGenerator.buildCharacter();
    VirtuesSet virtues = meva.getVirtues();
    virtues.setSelectedVirtue(null, 1);
    VirtuesEditionPanelController panelCtrl = new VirtuesEditionPanelController();
    panelCtrl.setVirtues(virtues);
    JFrame frame = new JFrame("Virtues edition");
    frame.add(panelCtrl.getPanel());
    frame.pack();
    frame.setDefaultCloseOperation(WindowConstants.EXIT_ON_CLOSE);
    frame.setVisible(true);
}
Also used : CharacterData(delta.games.lotro.character.CharacterData) CharacterGeneratorMeva(delta.games.lotro.character.stats.CharacterGeneratorMeva) JFrame(javax.swing.JFrame) VirtuesSet(delta.games.lotro.character.stats.virtues.VirtuesSet) CharacterGenerationTools(delta.games.lotro.character.stats.CharacterGenerationTools)

Aggregations

CharacterData (delta.games.lotro.character.CharacterData)31 CharacterGenerationTools (delta.games.lotro.character.stats.CharacterGenerationTools)8 JFrame (javax.swing.JFrame)7 CharacterFile (delta.games.lotro.character.CharacterFile)6 CharacterGeneratorMeva (delta.games.lotro.character.stats.CharacterGeneratorMeva)6 BasicStatsSet (delta.games.lotro.character.stats.BasicStatsSet)5 CharacterStatsComputer (delta.games.lotro.character.stats.CharacterStatsComputer)5 CharacterInfosManager (delta.games.lotro.character.CharacterInfosManager)4 CharacterEvent (delta.games.lotro.character.events.CharacterEvent)4 CharacterEventType (delta.games.lotro.character.events.CharacterEventType)4 DefaultWindowController (delta.common.ui.swing.windows.DefaultWindowController)3 EQUIMENT_SLOT (delta.games.lotro.character.CharacterEquipment.EQUIMENT_SLOT)3 CharacterClass (delta.games.lotro.common.CharacterClass)3 File (java.io.File)3 JPanel (javax.swing.JPanel)3 WindowController (delta.common.ui.swing.windows.WindowController)2 CharacterEquipment (delta.games.lotro.character.CharacterEquipment)2 CharactersManager (delta.games.lotro.character.CharactersManager)2 LotroTestUtils (delta.games.lotro.character.log.LotroTestUtils)2 CharacterGeneratorGiswald (delta.games.lotro.character.stats.CharacterGeneratorGiswald)2