use of delta.games.lotro.common.objects.ObjectsSet in project lotro-tools by dmorcellet.
the class CheckItemRewardsInDeeds method handleDeed.
private void handleDeed(DeedDescription deed) {
Rewards rewards = deed.getRewards();
ObjectsSet objects = rewards.getObjects();
int nbItems = objects.getNbObjectItems();
for (int i = 0; i < nbItems; i++) {
ObjectItem objectItem = objects.getItem(i);
int id = objectItem.getItemId();
String name = objectItem.getName();
Item item = ItemsManager.getInstance().getItem(id);
if (item == null) {
System.out.println("Item not found: id=" + id + ", name=" + name);
} else {
String itemName = item.getName();
if (!Objects.equals(name, itemName)) {
System.out.println("Fix item reward name from [" + name + "] to [" + itemName + "]");
objectItem.setName(itemName);
}
}
}
}
use of delta.games.lotro.common.objects.ObjectsSet in project lotro-tools by dmorcellet.
the class LotroWikiDeedCategoryPageParser method resolveItemRewards.
private void resolveItemRewards(DeedDescription deed) {
Rewards rewards = deed.getRewards();
ObjectsSet objects = rewards.getObjects();
int nbItems = objects.getNbObjectItems();
for (int i = 0; i < nbItems; i++) {
ObjectItem objectItem = objects.getItem(i);
resolveItem(objectItem);
}
}
use of delta.games.lotro.common.objects.ObjectsSet in project lotro-tools by dmorcellet.
the class QuestsItemsLoader method handleQuest.
private void handleQuest(int index, QuestDescription q) {
try {
// String key=q.getKey();
// System.out.println("#"+index+", quest: "+key);
Rewards r = q.getQuestRewards();
ObjectsSet set = r.getObjects();
handleSet(set);
ObjectsSet set2 = r.getSelectObjects();
handleSet(set2);
} catch (Throwable t) {
t.printStackTrace();
}
}
Aggregations