Add support for explicitly converting items to another.
This commit is contained in:
@@ -23,6 +23,7 @@ from sqlalchemy.sql import and_, or_, select, func
|
||||
from sqlalchemy.orm import join, exc
|
||||
from eos.types import Item, Category, Group, MarketGroup, AttributeInfo, MetaData, MetaGroup
|
||||
from eos.db.util import processEager, processWhere
|
||||
from eos.itemMapping import itemMapping
|
||||
import eos.config
|
||||
|
||||
configVal = getattr(eos.config, "gamedataCache", None)
|
||||
@@ -86,6 +87,8 @@ def getItem(lookfor, eager=None):
|
||||
itemNameMap[lookfor] = item.ID
|
||||
else:
|
||||
raise TypeError("Need integer or string as argument")
|
||||
if item.name in itemMapping:
|
||||
item = getItem(itemMapping[item.name], eager)
|
||||
return item
|
||||
|
||||
groupNameMap = {}
|
||||
|
||||
Reference in New Issue
Block a user