Search in sources :

Example 1 with LotroPlanItemsDbLoader

use of delta.games.lotro.tools.lore.items.lotroplan.LotroPlanItemsDbLoader in project lotro-tools by dmorcellet.

the class LotroPlanMordorRelicsLoader method loadGorgorothRelics.

/**
 * Load Gorgoroth relics.
 * @return A list of relics.
 */
public List<Relic> loadGorgorothRelics() {
    List<Relic> relics = new ArrayList<Relic>();
    LotroPlanItemsDbLoader tableLoader = new LotroPlanItemsDbLoader();
    List<Item> items = tableLoader.loadTable("mordor_relics.txt");
    for (Item item : items) {
        Relic relic = itemToRelic(item);
        relics.add(relic);
    }
    return relics;
}
Also used : Relic(delta.games.lotro.lore.items.legendary.relics.Relic) Item(delta.games.lotro.lore.items.Item) ArrayList(java.util.ArrayList) LotroPlanItemsDbLoader(delta.games.lotro.tools.lore.items.lotroplan.LotroPlanItemsDbLoader)

Example 2 with LotroPlanItemsDbLoader

use of delta.games.lotro.tools.lore.items.lotroplan.LotroPlanItemsDbLoader in project lotro-tools by dmorcellet.

the class ItemsDatabaseGenerator method main.

/**
 * Main method of this tool.
 * @param args Not used.
 */
public static void main(String[] args) {
    // 1) Generate independant databases
    // Build from Tulkas items index
    // items19.2.2.txt -> itemsTulkasIndex.xml
    {
        File from = new File("data/items/in/items22.0.1.txt").getAbsoluteFile();
        new TulkasItemsDBParser(from, EncodingNames.UTF_8, TulkasItemsDBParser.INDEX).doIt();
    }
    // Build from LATEST Tulkas items with stats
    // Items13.1.lua -> itemsTulkas13.1.xml
    {
        File from = new File("data/items/in/items13.1.txt").getAbsoluteFile();
        new TulkasItemsDBParser(from, EncodingNames.UTF_8, TulkasItemsDBParser.NEW_VERSION).doIt();
    }
    // Build from lotroplan database
    // itemsdb.txt -> itemsdb.xml
    new LotroPlanItemsDbLoader().doIt();
    // 2) Merges
    // itemsTulkasIndex.xml + itemsLegacy.xml -> itemsLegacy+TulkasIndex.xml
    new MergeItemsLegacyAndTulkasIndex().doIt();
    // itemsLegacy+TulkasIndex.xml + itemsTulkas13.1.xml -> itemsLegacy+Tulkas.xml
    new MergeWithTulkasNew().doIt();
    // itemsLegacy+Tulkas.xml + itemsdb.xml -> items-rc.xml
    new MergeWithLotroPlanDb().doIt();
    // 3) Normalize
    // items-rc.xml -> items.xml
    new ItemNormalization().doIt();
}
Also used : TulkasItemsDBParser(delta.games.lotro.tools.lore.items.tulkas.TulkasItemsDBParser) ItemNormalization(delta.games.lotro.tools.lore.items.merges.ItemNormalization) MergeWithLotroPlanDb(delta.games.lotro.tools.lore.items.merges.MergeWithLotroPlanDb) LotroPlanItemsDbLoader(delta.games.lotro.tools.lore.items.lotroplan.LotroPlanItemsDbLoader) File(java.io.File) MergeItemsLegacyAndTulkasIndex(delta.games.lotro.tools.lore.items.merges.MergeItemsLegacyAndTulkasIndex) MergeWithTulkasNew(delta.games.lotro.tools.lore.items.merges.MergeWithTulkasNew)

Aggregations

LotroPlanItemsDbLoader (delta.games.lotro.tools.lore.items.lotroplan.LotroPlanItemsDbLoader)2 Item (delta.games.lotro.lore.items.Item)1 Relic (delta.games.lotro.lore.items.legendary.relics.Relic)1 ItemNormalization (delta.games.lotro.tools.lore.items.merges.ItemNormalization)1 MergeItemsLegacyAndTulkasIndex (delta.games.lotro.tools.lore.items.merges.MergeItemsLegacyAndTulkasIndex)1 MergeWithLotroPlanDb (delta.games.lotro.tools.lore.items.merges.MergeWithLotroPlanDb)1 MergeWithTulkasNew (delta.games.lotro.tools.lore.items.merges.MergeWithTulkasNew)1 TulkasItemsDBParser (delta.games.lotro.tools.lore.items.tulkas.TulkasItemsDBParser)1 File (java.io.File)1 ArrayList (java.util.ArrayList)1