Limit drone stacks by ship bandwidth too
This commit is contained in:
@@ -1507,19 +1507,19 @@ class Fit(object):
|
||||
|
||||
return True
|
||||
|
||||
def howManyDronesRelease(self, item):
|
||||
def getReleaseLimitForDrone(self, item):
|
||||
if not item.isDrone:
|
||||
return 0
|
||||
bw = round(self.ship.getModifiedItemAttr("droneBandwidth"))
|
||||
volume = round(item.attribsWithOverrides['volume'])
|
||||
volume = round(item.attribsWithOverrides['volume'].value)
|
||||
return int(bw / volume)
|
||||
|
||||
def howManyDronesStore(self, item):
|
||||
def getStoreLimitForDrone(self, item):
|
||||
if not item.isDrone:
|
||||
return 0
|
||||
bayTotal = round(self.ship.getModifiedItemAttr("droneCapacity"))
|
||||
bayUsed = round(self.droneBayUsed)
|
||||
volume = item.attribsWithOverrides['volume']
|
||||
volume = item.attribsWithOverrides['volume'].value
|
||||
return int((bayTotal - bayUsed) / volume)
|
||||
|
||||
def __deepcopy__(self, memo=None):
|
||||
|
||||
Reference in New Issue
Block a user