Round cpu/pg like EVE does
To work around some fits where pyfa shows that items do not fit when they actually do
This commit is contained in:
@@ -215,6 +215,8 @@ class ModifiedAttributeDict(collections.MutableMapping):
|
||||
if force is not None:
|
||||
if cappingValue is not None:
|
||||
force = min(force, cappingValue)
|
||||
if key in (50, 30, 48, 11):
|
||||
force = round(force, 2)
|
||||
return force
|
||||
# Grab our values if they're there, otherwise we'll take default values
|
||||
preIncrease = self.__preIncreases.get(key, 0)
|
||||
@@ -268,7 +270,8 @@ class ModifiedAttributeDict(collections.MutableMapping):
|
||||
# Cap value if we have cap defined
|
||||
if cappingValue is not None:
|
||||
val = min(val, cappingValue)
|
||||
|
||||
if key in (50, 30, 48, 11):
|
||||
val = round(val, 2)
|
||||
return val
|
||||
|
||||
def __handleSkill(self, skillName):
|
||||
|
||||
@@ -1016,11 +1016,11 @@ class Fit(object):
|
||||
|
||||
@property
|
||||
def pgUsed(self):
|
||||
return self.getItemAttrOnlineSum(self.modules, "power")
|
||||
return round(self.getItemAttrOnlineSum(self.modules, "power"), 2)
|
||||
|
||||
@property
|
||||
def cpuUsed(self):
|
||||
return self.getItemAttrOnlineSum(self.modules, "cpu")
|
||||
return round(self.getItemAttrOnlineSum(self.modules, "cpu"), 2)
|
||||
|
||||
@property
|
||||
def droneBandwidthUsed(self):
|
||||
|
||||
Reference in New Issue
Block a user