Add versioning data to EFS export
This commit is contained in:
@@ -8,6 +8,7 @@ import json
|
|||||||
import eos.db
|
import eos.db
|
||||||
|
|
||||||
from math import log
|
from math import log
|
||||||
|
from config import version as pyfaVersion
|
||||||
from service.fit import Fit
|
from service.fit import Fit
|
||||||
from service.market import Market
|
from service.market import Market
|
||||||
from eos.enum import Enum
|
from eos.enum import Enum
|
||||||
@@ -30,6 +31,7 @@ class RigSize(Enum):
|
|||||||
|
|
||||||
class EfsPort():
|
class EfsPort():
|
||||||
wepTestSet = {}
|
wepTestSet = {}
|
||||||
|
version = 0.01
|
||||||
|
|
||||||
@staticmethod
|
@staticmethod
|
||||||
def attrDirectMap(values, target, source):
|
def attrDirectMap(values, target, source):
|
||||||
@@ -608,7 +610,6 @@ class EfsPort():
|
|||||||
}
|
}
|
||||||
resonance = {"hull": hullResonance, "armor": armorResonance, "shield": shieldResonance}
|
resonance = {"hull": hullResonance, "armor": armorResonance, "shield": shieldResonance}
|
||||||
shipSize = EfsPort.getShipSize(fit.ship.item.groupID)
|
shipSize = EfsPort.getShipSize(fit.ship.item.groupID)
|
||||||
|
|
||||||
try:
|
try:
|
||||||
dataDict = {
|
dataDict = {
|
||||||
"name": fitName, "ehp": fit.ehp, "droneDPS": fit.droneDPS,
|
"name": fitName, "ehp": fit.ehp, "droneDPS": fit.droneDPS,
|
||||||
@@ -628,7 +629,8 @@ class EfsPort():
|
|||||||
"droneControlRange": fitModAttr("droneControlRange"), "mass": fitModAttr("mass"),
|
"droneControlRange": fitModAttr("droneControlRange"), "mass": fitModAttr("mass"),
|
||||||
"unpropedSpeed": propData["unpropedSpeed"], "unpropedSig": propData["unpropedSig"],
|
"unpropedSpeed": propData["unpropedSpeed"], "unpropedSig": propData["unpropedSig"],
|
||||||
"usingMWD": propData["usingMWD"], "mwdPropSpeed": mwdPropSpeed, "projections": projections,
|
"usingMWD": propData["usingMWD"], "mwdPropSpeed": mwdPropSpeed, "projections": projections,
|
||||||
"modTypeIDs": modTypeIDs, "moduleNames": moduleNames
|
"modTypeIDs": modTypeIDs, "moduleNames": moduleNames,
|
||||||
|
"pyfaVersion": pyfaVersion, "efsExportVersion": EfsPort.version
|
||||||
}
|
}
|
||||||
except TypeError:
|
except TypeError:
|
||||||
pyfalog.error("Error parsing fit:" + str(fit))
|
pyfalog.error("Error parsing fit:" + str(fit))
|
||||||
|
|||||||
Reference in New Issue
Block a user