Ludibrium PQ + MapleIdRetriever

Implemented LPQ. New application tool that realizes fetches by names and
returns respective ids, over all items depicted in the GM handbook.
This commit is contained in:
ronancpl
2017-05-13 15:24:02 -03:00
parent ed6121dd5f
commit b26469301d
94 changed files with 36729 additions and 1186 deletions

View File

@@ -77,7 +77,13 @@ public class MapleInventory implements Iterable<Item> {
public Item findByName(String name) {
for (Item item : inventory.values()) {
if (name.compareToIgnoreCase(MapleItemInformationProvider.getInstance().getName(item.getItemId())) == 0) {
String itemName = MapleItemInformationProvider.getInstance().getName(item.getItemId());
if(itemName == null) {
System.out.println("[CRITICAL] Item " + item.getItemId() + " has no name.");
continue;
}
if (name.compareToIgnoreCase(itemName) == 0) {
return item;
}
}