Implement the + button in stage 2 and make the fit count work

This commit is contained in:
cncfanatics
2010-10-26 14:59:58 +02:00
parent 0d33b3dba6
commit f2d81d111f
2 changed files with 6 additions and 6 deletions

View File

@@ -45,10 +45,10 @@ class Fit(object):
fit = eos.db.getFit(fitID)
return fit.modules[pos]
def newFit(self, shipID, name):
def newFit(self, shipID, name=None):
fit = eos.types.Fit()
fit.ship = eos.types.Ship(eos.db.getItem(shipID))
fit.name = name
fit.name = name if name is not None else "New %s" % fit.ship.item.name
fit.damagePattern = DamagePattern.getInstance().getDamagePattern("Uniform")
eos.db.save(fit)
fit.calculateModifiedAttributes()