use of main.content.CONTENT_CONSTS2.SHOP_LEVEL in project Eidolons by IDemiurge.
the class UnitShop method specialCheck.
private static boolean specialCheck(Unit unit, ObjType type) {
if (type.getOBJ_TYPE_ENUM() == DC_TYPE.JEWELRY) {
// TODO
return true;
}
if (type.getOBJ_TYPE_ENUM() == DC_TYPE.ITEMS) {
// TODO
return true;
}
String property = unit.getProperty(PROPS.ALLOWED_MATERIAL);
if (property.isEmpty()) {
SHOP_LEVEL shopLevel = SHOP_LEVEL.COMMON;
if (unit.getLevel() > 5) {
shopLevel = SHOP_LEVEL.QUALITY;
}
if (unit.getLevel() > 8) {
shopLevel = SHOP_LEVEL.OPULENT;
}
if (unit.getLevel() < 3) {
shopLevel = SHOP_LEVEL.POOR;
}
List<MATERIAL> levelMaterials = ShopMaster.getMaterialsForShopLevel(shopLevel);
property = StringMaster.constructStringContainer(levelMaterials);
}
return StringMaster.compare(type.getProperty(G_PROPS.MATERIAL), property, false);
}
Aggregations