def _packSingleBonus(cls, bonus, item, label):
     model = IconBonusModel()
     cls._packCommon(bonus, model)
     model.setValue(str(item.get('value', 0)))
     model.setIcon(str(bonus.getC11nItem(item).itemTypeName))
     model.setLabel(label)
     return model
 def _packSingleBonus(cls, bonus, crewSkin, count, label):
     model = IconBonusModel()
     cls._packCommon(bonus, model)
     model.setValue(str(count))
     model.setIcon(str(crewSkin.itemTypeName + str(crewSkin.getRarity())))
     model.setLabel(label)
     return model
 def _packIconBonusModel(cls, bonus, icon, count, label):
     model = IconBonusModel()
     cls._packCommon(bonus, model)
     model.setValue(str(count))
     model.setIcon(icon)
     model.setLabel(label)
     return model
 def _packSingleBonus(cls, bonus, dossierIconName, dossierNamePostfix,
                      dossierValue):
     model = IconBonusModel()
     model.setName(bonus.getName() + dossierNamePostfix)
     model.setIsCompensation(bonus.isCompensation())
     model.setValue(str(dossierValue))
     model.setIcon(dossierIconName)
     return model
 def _pack(cls, bonus):
     model = IconBonusModel()
     cls._packCommon(bonus, model)
     model.setIcon('default')
     return [model]
Esempio n. 6
0
 def _packSingleBonus(cls, bonus):
     model = IconBonusModel()
     model.setName(bonus.getNameForIcon())
     model.setIcon(bonus.getIcon())
     return model
 def _packSingleBonus(cls, bonus, book, count):
     model = IconBonusModel()
     cls._packCommon(bonus, model)
     model.setValue(str(count))
     model.setIcon(book.getBonusIconName())
     return model