mirror of
https://github.com/EDCD/coriolis-data.git
synced 2025-12-10 07:55:33 +00:00
Merge branch 'develop'
This commit is contained in:
19
.eslintrc.js
19
.eslintrc.js
@@ -1,10 +1,13 @@
|
|||||||
module.exports = {
|
module.exports = {
|
||||||
"env": {},
|
'env': {
|
||||||
"extends": "eslint:recommended",
|
'browser': true,
|
||||||
"rules": {
|
'node': true
|
||||||
"indent": [2, 4],
|
},
|
||||||
"linebreak-style": [2, "unix"],
|
'extends': 'eslint:recommended',
|
||||||
"quotes": [2, "single"],
|
'rules': {
|
||||||
"semi": [2, "always"]
|
'indent': ['error', 2],
|
||||||
}
|
'linebreak-style': [2, 'unix'],
|
||||||
|
'quotes': [2, 'single'],
|
||||||
|
'semi': [2, 'always']
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|||||||
47
dist/index.js
vendored
47
dist/index.js
vendored
@@ -101,7 +101,7 @@ module.exports = {
|
|||||||
speed: 230,
|
speed: 230,
|
||||||
boost: 330,
|
boost: 330,
|
||||||
boostEnergy: 19,
|
boostEnergy: 19,
|
||||||
baseShieldStrength: 154,
|
baseShieldStrength: 200,
|
||||||
baseArmour: 280,
|
baseArmour: 280,
|
||||||
hardness: 65,
|
hardness: 65,
|
||||||
hullMass: 400,
|
hullMass: 400,
|
||||||
@@ -3728,7 +3728,7 @@ module.exports = {
|
|||||||
}, {
|
}, {
|
||||||
class: 2,
|
class: 2,
|
||||||
cost: 162e3,
|
cost: 162e3,
|
||||||
edID: 128064037,
|
edID: 128833988,
|
||||||
eddbID: 895,
|
eddbID: 895,
|
||||||
eff: .5,
|
eff: .5,
|
||||||
grp: "pp",
|
grp: "pp",
|
||||||
@@ -3742,11 +3742,11 @@ module.exports = {
|
|||||||
}, {
|
}, {
|
||||||
class: 3,
|
class: 3,
|
||||||
cost: 291600,
|
cost: 291600,
|
||||||
edID: 128064037,
|
edID: 128833989,
|
||||||
eddbID: 895,
|
eddbID: 895,
|
||||||
eff: .5,
|
eff: .5,
|
||||||
grp: "pp",
|
grp: "pp",
|
||||||
id: "0B",
|
id: "0T",
|
||||||
integrity: 70,
|
integrity: 70,
|
||||||
mass: 2.9,
|
mass: 2.9,
|
||||||
pgen: 15.8,
|
pgen: 15.8,
|
||||||
@@ -3756,7 +3756,7 @@ module.exports = {
|
|||||||
}, {
|
}, {
|
||||||
class: 4,
|
class: 4,
|
||||||
cost: 524880,
|
cost: 524880,
|
||||||
edID: 128064037,
|
edID: 128833990,
|
||||||
eddbID: 895,
|
eddbID: 895,
|
||||||
eff: .5,
|
eff: .5,
|
||||||
grp: "pp",
|
grp: "pp",
|
||||||
@@ -3770,7 +3770,7 @@ module.exports = {
|
|||||||
}, {
|
}, {
|
||||||
class: 5,
|
class: 5,
|
||||||
cost: 944790,
|
cost: 944790,
|
||||||
edID: 128064037,
|
edID: 128833991,
|
||||||
eddbID: 895,
|
eddbID: 895,
|
||||||
eff: .5,
|
eff: .5,
|
||||||
grp: "pp",
|
grp: "pp",
|
||||||
@@ -3784,7 +3784,7 @@ module.exports = {
|
|||||||
}, {
|
}, {
|
||||||
class: 6,
|
class: 6,
|
||||||
cost: 1700610,
|
cost: 1700610,
|
||||||
edID: 128064037,
|
edID: 128833992,
|
||||||
eddbID: 895,
|
eddbID: 895,
|
||||||
eff: .5,
|
eff: .5,
|
||||||
grp: "pp",
|
grp: "pp",
|
||||||
@@ -3798,7 +3798,7 @@ module.exports = {
|
|||||||
}, {
|
}, {
|
||||||
class: 7,
|
class: 7,
|
||||||
cost: 3061100,
|
cost: 3061100,
|
||||||
edID: 128064037,
|
edID: 128833993,
|
||||||
eddbID: 895,
|
eddbID: 895,
|
||||||
eff: .5,
|
eff: .5,
|
||||||
grp: "pp",
|
grp: "pp",
|
||||||
@@ -3812,7 +3812,7 @@ module.exports = {
|
|||||||
}, {
|
}, {
|
||||||
class: 8,
|
class: 8,
|
||||||
cost: 5509980,
|
cost: 5509980,
|
||||||
edID: 128064037,
|
edID: 128833994,
|
||||||
eddbID: 895,
|
eddbID: 895,
|
||||||
eff: .5,
|
eff: .5,
|
||||||
grp: "pp",
|
grp: "pp",
|
||||||
@@ -11282,6 +11282,28 @@ module.exports = {
|
|||||||
name: "Corrosion Resistant",
|
name: "Corrosion Resistant",
|
||||||
rating: "F",
|
rating: "F",
|
||||||
symbol: "Int_CorrosionProofCargoRack_Size1_Class2"
|
symbol: "Int_CorrosionProofCargoRack_Size1_Class2"
|
||||||
|
}, {
|
||||||
|
cargo: 4,
|
||||||
|
class: 2,
|
||||||
|
cost: 12563,
|
||||||
|
edID: 128681992,
|
||||||
|
eddbID: 1552,
|
||||||
|
grp: "cr",
|
||||||
|
id: "0V",
|
||||||
|
name: "Corrosion Resistant",
|
||||||
|
rating: "F",
|
||||||
|
symbol: "Int_CorrosionProofCargoRack_Size2_Class1"
|
||||||
|
}, {
|
||||||
|
cargo: 16,
|
||||||
|
class: 4,
|
||||||
|
cost: 94330,
|
||||||
|
edID: 128681992,
|
||||||
|
eddbID: 1552,
|
||||||
|
grp: "cr",
|
||||||
|
id: "0W",
|
||||||
|
name: "Corrosion Resistant",
|
||||||
|
rating: "E",
|
||||||
|
symbol: "Int_CorrosionProofCargoRack_Size4_Class1"
|
||||||
} ],
|
} ],
|
||||||
cc: [ {
|
cc: [ {
|
||||||
class: 1,
|
class: 1,
|
||||||
@@ -21802,7 +21824,7 @@ module.exports = {
|
|||||||
integrity: [ .12, .15 ],
|
integrity: [ .12, .15 ],
|
||||||
mass: [ 3, 3 ],
|
mass: [ 3, 3 ],
|
||||||
power: [ .25, .25 ],
|
power: [ .25, .25 ],
|
||||||
shieldboost: [ .372, .456 ]
|
shieldboost: [ .372, .38 ]
|
||||||
},
|
},
|
||||||
uuid: "933e238e-56e0-44d6-b114-49eaab02f033"
|
uuid: "933e238e-56e0-44d6-b114-49eaab02f033"
|
||||||
}
|
}
|
||||||
@@ -22786,7 +22808,6 @@ module.exports = {
|
|||||||
features: {
|
features: {
|
||||||
piercing: [ 0, .4 ],
|
piercing: [ 0, .4 ],
|
||||||
range: [ 0, .36 ],
|
range: [ 0, .36 ],
|
||||||
rof: [ 0, .36 ],
|
|
||||||
thermload: [ .01, .01 ]
|
thermload: [ .01, .01 ]
|
||||||
},
|
},
|
||||||
uuid: "fc3e4f2e-04fb-4509-a31f-1121940e1bc6"
|
uuid: "fc3e4f2e-04fb-4509-a31f-1121940e1bc6"
|
||||||
@@ -22799,7 +22820,6 @@ module.exports = {
|
|||||||
features: {
|
features: {
|
||||||
piercing: [ .4, .6 ],
|
piercing: [ .4, .6 ],
|
||||||
range: [ .36, .52 ],
|
range: [ .36, .52 ],
|
||||||
rof: [ .36, .52 ],
|
|
||||||
thermload: [ .02, .02 ]
|
thermload: [ .02, .02 ]
|
||||||
},
|
},
|
||||||
uuid: "437e00b1-a6fd-4d84-9242-075c3ce8adcb"
|
uuid: "437e00b1-a6fd-4d84-9242-075c3ce8adcb"
|
||||||
@@ -22813,7 +22833,6 @@ module.exports = {
|
|||||||
features: {
|
features: {
|
||||||
piercing: [ .6, .8 ],
|
piercing: [ .6, .8 ],
|
||||||
range: [ .52, .68 ],
|
range: [ .52, .68 ],
|
||||||
rof: [ .52, .68 ],
|
|
||||||
thermload: [ .03, .03 ]
|
thermload: [ .03, .03 ]
|
||||||
},
|
},
|
||||||
uuid: "bfbadc34-e11a-4cc4-80cc-83dde5731e6f"
|
uuid: "bfbadc34-e11a-4cc4-80cc-83dde5731e6f"
|
||||||
@@ -22827,7 +22846,6 @@ module.exports = {
|
|||||||
features: {
|
features: {
|
||||||
piercing: [ .8, 1 ],
|
piercing: [ .8, 1 ],
|
||||||
range: [ .68, .84 ],
|
range: [ .68, .84 ],
|
||||||
rof: [ .68, .84 ],
|
|
||||||
thermload: [ .04, .04 ]
|
thermload: [ .04, .04 ]
|
||||||
},
|
},
|
||||||
uuid: "7c41f9fc-90ec-435e-9d92-6024c32ac40d"
|
uuid: "7c41f9fc-90ec-435e-9d92-6024c32ac40d"
|
||||||
@@ -22841,7 +22859,6 @@ module.exports = {
|
|||||||
features: {
|
features: {
|
||||||
piercing: [ 1, 1.2 ],
|
piercing: [ 1, 1.2 ],
|
||||||
range: [ .84, 1 ],
|
range: [ .84, 1 ],
|
||||||
rof: [ .84, 1 ],
|
|
||||||
thermload: [ .05, .05 ]
|
thermload: [ .05, .05 ]
|
||||||
},
|
},
|
||||||
uuid: "d9306721-43a4-45cd-b225-ac9174da4d13"
|
uuid: "d9306721-43a4-45cd-b225-ac9174da4d13"
|
||||||
|
|||||||
64
dist/index.json
vendored
64
dist/index.json
vendored
@@ -147,7 +147,7 @@
|
|||||||
"speed": 230,
|
"speed": 230,
|
||||||
"boost": 330,
|
"boost": 330,
|
||||||
"boostEnergy": 19,
|
"boostEnergy": 19,
|
||||||
"baseShieldStrength": 154,
|
"baseShieldStrength": 200,
|
||||||
"baseArmour": 280,
|
"baseArmour": 280,
|
||||||
"hardness": 65,
|
"hardness": 65,
|
||||||
"hullMass": 400,
|
"hullMass": 400,
|
||||||
@@ -5648,7 +5648,7 @@
|
|||||||
{
|
{
|
||||||
"class": 2,
|
"class": 2,
|
||||||
"cost": 162000,
|
"cost": 162000,
|
||||||
"edID": 128064037,
|
"edID": 128833988,
|
||||||
"eddbID": 895,
|
"eddbID": 895,
|
||||||
"eff": 0.5,
|
"eff": 0.5,
|
||||||
"grp": "pp",
|
"grp": "pp",
|
||||||
@@ -5663,11 +5663,11 @@
|
|||||||
{
|
{
|
||||||
"class": 3,
|
"class": 3,
|
||||||
"cost": 291600,
|
"cost": 291600,
|
||||||
"edID": 128064037,
|
"edID": 128833989,
|
||||||
"eddbID": 895,
|
"eddbID": 895,
|
||||||
"eff": 0.5,
|
"eff": 0.5,
|
||||||
"grp": "pp",
|
"grp": "pp",
|
||||||
"id": "0B",
|
"id": "0T",
|
||||||
"integrity": 70,
|
"integrity": 70,
|
||||||
"mass": 2.9,
|
"mass": 2.9,
|
||||||
"pgen": 15.8,
|
"pgen": 15.8,
|
||||||
@@ -5678,7 +5678,7 @@
|
|||||||
{
|
{
|
||||||
"class": 4,
|
"class": 4,
|
||||||
"cost": 524880,
|
"cost": 524880,
|
||||||
"edID": 128064037,
|
"edID": 128833990,
|
||||||
"eddbID": 895,
|
"eddbID": 895,
|
||||||
"eff": 0.5,
|
"eff": 0.5,
|
||||||
"grp": "pp",
|
"grp": "pp",
|
||||||
@@ -5693,7 +5693,7 @@
|
|||||||
{
|
{
|
||||||
"class": 5,
|
"class": 5,
|
||||||
"cost": 944790,
|
"cost": 944790,
|
||||||
"edID": 128064037,
|
"edID": 128833991,
|
||||||
"eddbID": 895,
|
"eddbID": 895,
|
||||||
"eff": 0.5,
|
"eff": 0.5,
|
||||||
"grp": "pp",
|
"grp": "pp",
|
||||||
@@ -5708,7 +5708,7 @@
|
|||||||
{
|
{
|
||||||
"class": 6,
|
"class": 6,
|
||||||
"cost": 1700610,
|
"cost": 1700610,
|
||||||
"edID": 128064037,
|
"edID": 128833992,
|
||||||
"eddbID": 895,
|
"eddbID": 895,
|
||||||
"eff": 0.5,
|
"eff": 0.5,
|
||||||
"grp": "pp",
|
"grp": "pp",
|
||||||
@@ -5723,7 +5723,7 @@
|
|||||||
{
|
{
|
||||||
"class": 7,
|
"class": 7,
|
||||||
"cost": 3061100,
|
"cost": 3061100,
|
||||||
"edID": 128064037,
|
"edID": 128833993,
|
||||||
"eddbID": 895,
|
"eddbID": 895,
|
||||||
"eff": 0.5,
|
"eff": 0.5,
|
||||||
"grp": "pp",
|
"grp": "pp",
|
||||||
@@ -5738,7 +5738,7 @@
|
|||||||
{
|
{
|
||||||
"class": 8,
|
"class": 8,
|
||||||
"cost": 5509980,
|
"cost": 5509980,
|
||||||
"edID": 128064037,
|
"edID": 128833994,
|
||||||
"eddbID": 895,
|
"eddbID": 895,
|
||||||
"eff": 0.5,
|
"eff": 0.5,
|
||||||
"grp": "pp",
|
"grp": "pp",
|
||||||
@@ -13634,6 +13634,30 @@
|
|||||||
"name": "Corrosion Resistant",
|
"name": "Corrosion Resistant",
|
||||||
"rating": "F",
|
"rating": "F",
|
||||||
"symbol": "Int_CorrosionProofCargoRack_Size1_Class2"
|
"symbol": "Int_CorrosionProofCargoRack_Size1_Class2"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"cargo": 4,
|
||||||
|
"class": 2,
|
||||||
|
"cost": 12563,
|
||||||
|
"edID": 128681992,
|
||||||
|
"eddbID": 1552,
|
||||||
|
"grp": "cr",
|
||||||
|
"id": "0V",
|
||||||
|
"name": "Corrosion Resistant",
|
||||||
|
"rating": "F",
|
||||||
|
"symbol": "Int_CorrosionProofCargoRack_Size2_Class1"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"cargo": 16,
|
||||||
|
"class": 4,
|
||||||
|
"cost": 94330,
|
||||||
|
"edID": 128681992,
|
||||||
|
"eddbID": 1552,
|
||||||
|
"grp": "cr",
|
||||||
|
"id": "0W",
|
||||||
|
"name": "Corrosion Resistant",
|
||||||
|
"rating": "E",
|
||||||
|
"symbol": "Int_CorrosionProofCargoRack_Size4_Class1"
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
"cc": [
|
"cc": [
|
||||||
@@ -28227,7 +28251,7 @@
|
|||||||
],
|
],
|
||||||
"shieldboost": [
|
"shieldboost": [
|
||||||
0.372,
|
0.372,
|
||||||
0.456
|
0.38
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"uuid": "933e238e-56e0-44d6-b114-49eaab02f033"
|
"uuid": "933e238e-56e0-44d6-b114-49eaab02f033"
|
||||||
@@ -29962,10 +29986,6 @@
|
|||||||
0,
|
0,
|
||||||
0.36
|
0.36
|
||||||
],
|
],
|
||||||
"rof": [
|
|
||||||
0,
|
|
||||||
0.36
|
|
||||||
],
|
|
||||||
"thermload": [
|
"thermload": [
|
||||||
0.01,
|
0.01,
|
||||||
0.01
|
0.01
|
||||||
@@ -29987,10 +30007,6 @@
|
|||||||
0.36,
|
0.36,
|
||||||
0.52
|
0.52
|
||||||
],
|
],
|
||||||
"rof": [
|
|
||||||
0.36,
|
|
||||||
0.52
|
|
||||||
],
|
|
||||||
"thermload": [
|
"thermload": [
|
||||||
0.02,
|
0.02,
|
||||||
0.02
|
0.02
|
||||||
@@ -30013,10 +30029,6 @@
|
|||||||
0.52,
|
0.52,
|
||||||
0.68
|
0.68
|
||||||
],
|
],
|
||||||
"rof": [
|
|
||||||
0.52,
|
|
||||||
0.68
|
|
||||||
],
|
|
||||||
"thermload": [
|
"thermload": [
|
||||||
0.03,
|
0.03,
|
||||||
0.03
|
0.03
|
||||||
@@ -30039,10 +30051,6 @@
|
|||||||
0.68,
|
0.68,
|
||||||
0.84
|
0.84
|
||||||
],
|
],
|
||||||
"rof": [
|
|
||||||
0.68,
|
|
||||||
0.84
|
|
||||||
],
|
|
||||||
"thermload": [
|
"thermload": [
|
||||||
0.04,
|
0.04,
|
||||||
0.04
|
0.04
|
||||||
@@ -30065,10 +30073,6 @@
|
|||||||
0.84,
|
0.84,
|
||||||
1
|
1
|
||||||
],
|
],
|
||||||
"rof": [
|
|
||||||
0.84,
|
|
||||||
1
|
|
||||||
],
|
|
||||||
"thermload": [
|
"thermload": [
|
||||||
0.05,
|
0.05,
|
||||||
0.05
|
0.05
|
||||||
|
|||||||
@@ -9267,7 +9267,7 @@
|
|||||||
],
|
],
|
||||||
"shieldboost": [
|
"shieldboost": [
|
||||||
0.372,
|
0.372,
|
||||||
0.456
|
0.38
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"uuid": "933e238e-56e0-44d6-b114-49eaab02f033"
|
"uuid": "933e238e-56e0-44d6-b114-49eaab02f033"
|
||||||
@@ -11002,10 +11002,6 @@
|
|||||||
0,
|
0,
|
||||||
0.36
|
0.36
|
||||||
],
|
],
|
||||||
"rof": [
|
|
||||||
0,
|
|
||||||
0.36
|
|
||||||
],
|
|
||||||
"thermload": [
|
"thermload": [
|
||||||
0.01,
|
0.01,
|
||||||
0.01
|
0.01
|
||||||
@@ -11027,10 +11023,6 @@
|
|||||||
0.36,
|
0.36,
|
||||||
0.52
|
0.52
|
||||||
],
|
],
|
||||||
"rof": [
|
|
||||||
0.36,
|
|
||||||
0.52
|
|
||||||
],
|
|
||||||
"thermload": [
|
"thermload": [
|
||||||
0.02,
|
0.02,
|
||||||
0.02
|
0.02
|
||||||
@@ -11053,10 +11045,6 @@
|
|||||||
0.52,
|
0.52,
|
||||||
0.68
|
0.68
|
||||||
],
|
],
|
||||||
"rof": [
|
|
||||||
0.52,
|
|
||||||
0.68
|
|
||||||
],
|
|
||||||
"thermload": [
|
"thermload": [
|
||||||
0.03,
|
0.03,
|
||||||
0.03
|
0.03
|
||||||
@@ -11079,10 +11067,6 @@
|
|||||||
0.68,
|
0.68,
|
||||||
0.84
|
0.84
|
||||||
],
|
],
|
||||||
"rof": [
|
|
||||||
0.68,
|
|
||||||
0.84
|
|
||||||
],
|
|
||||||
"thermload": [
|
"thermload": [
|
||||||
0.04,
|
0.04,
|
||||||
0.04
|
0.04
|
||||||
@@ -11105,10 +11089,6 @@
|
|||||||
0.84,
|
0.84,
|
||||||
1
|
1
|
||||||
],
|
],
|
||||||
"rof": [
|
|
||||||
0.84,
|
|
||||||
1
|
|
||||||
],
|
|
||||||
"thermload": [
|
"thermload": [
|
||||||
0.05,
|
0.05,
|
||||||
0.05
|
0.05
|
||||||
|
|||||||
@@ -111,6 +111,30 @@
|
|||||||
"name": "Corrosion Resistant",
|
"name": "Corrosion Resistant",
|
||||||
"rating": "F",
|
"rating": "F",
|
||||||
"symbol": "Int_CorrosionProofCargoRack_Size1_Class2"
|
"symbol": "Int_CorrosionProofCargoRack_Size1_Class2"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"cargo": 4,
|
||||||
|
"class": 2,
|
||||||
|
"cost": 12563,
|
||||||
|
"edID": 128681992,
|
||||||
|
"eddbID": 1552,
|
||||||
|
"grp": "cr",
|
||||||
|
"id": "0V",
|
||||||
|
"name": "Corrosion Resistant",
|
||||||
|
"rating": "F",
|
||||||
|
"symbol": "Int_CorrosionProofCargoRack_Size2_Class1"
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"cargo": 16,
|
||||||
|
"class": 4,
|
||||||
|
"cost": 94330,
|
||||||
|
"edID": 128681992,
|
||||||
|
"eddbID": 1552,
|
||||||
|
"grp": "cr",
|
||||||
|
"id": "0W",
|
||||||
|
"name": "Corrosion Resistant",
|
||||||
|
"rating": "E",
|
||||||
|
"symbol": "Int_CorrosionProofCargoRack_Size4_Class1"
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
@@ -493,7 +493,7 @@
|
|||||||
{
|
{
|
||||||
"class": 2,
|
"class": 2,
|
||||||
"cost": 162000,
|
"cost": 162000,
|
||||||
"edID": 128064037,
|
"edID": 128833988,
|
||||||
"eddbID": 895,
|
"eddbID": 895,
|
||||||
"eff": 0.5,
|
"eff": 0.5,
|
||||||
"grp": "pp",
|
"grp": "pp",
|
||||||
@@ -508,7 +508,7 @@
|
|||||||
{
|
{
|
||||||
"class": 3,
|
"class": 3,
|
||||||
"cost": 291600,
|
"cost": 291600,
|
||||||
"edID": 128064037,
|
"edID": 128833989,
|
||||||
"eddbID": 895,
|
"eddbID": 895,
|
||||||
"eff": 0.5,
|
"eff": 0.5,
|
||||||
"grp": "pp",
|
"grp": "pp",
|
||||||
@@ -523,7 +523,7 @@
|
|||||||
{
|
{
|
||||||
"class": 4,
|
"class": 4,
|
||||||
"cost": 524880,
|
"cost": 524880,
|
||||||
"edID": 128064037,
|
"edID": 128833990,
|
||||||
"eddbID": 895,
|
"eddbID": 895,
|
||||||
"eff": 0.5,
|
"eff": 0.5,
|
||||||
"grp": "pp",
|
"grp": "pp",
|
||||||
@@ -538,7 +538,7 @@
|
|||||||
{
|
{
|
||||||
"class": 5,
|
"class": 5,
|
||||||
"cost": 944790,
|
"cost": 944790,
|
||||||
"edID": 128064037,
|
"edID": 128833991,
|
||||||
"eddbID": 895,
|
"eddbID": 895,
|
||||||
"eff": 0.5,
|
"eff": 0.5,
|
||||||
"grp": "pp",
|
"grp": "pp",
|
||||||
@@ -553,7 +553,7 @@
|
|||||||
{
|
{
|
||||||
"class": 6,
|
"class": 6,
|
||||||
"cost": 1700610,
|
"cost": 1700610,
|
||||||
"edID": 128064037,
|
"edID": 128833992,
|
||||||
"eddbID": 895,
|
"eddbID": 895,
|
||||||
"eff": 0.5,
|
"eff": 0.5,
|
||||||
"grp": "pp",
|
"grp": "pp",
|
||||||
@@ -568,7 +568,7 @@
|
|||||||
{
|
{
|
||||||
"class": 7,
|
"class": 7,
|
||||||
"cost": 3061100,
|
"cost": 3061100,
|
||||||
"edID": 128064037,
|
"edID": 128833993,
|
||||||
"eddbID": 895,
|
"eddbID": 895,
|
||||||
"eff": 0.5,
|
"eff": 0.5,
|
||||||
"grp": "pp",
|
"grp": "pp",
|
||||||
@@ -583,7 +583,7 @@
|
|||||||
{
|
{
|
||||||
"class": 8,
|
"class": 8,
|
||||||
"cost": 5509980,
|
"cost": 5509980,
|
||||||
"edID": 128064037,
|
"edID": 128833994,
|
||||||
"eddbID": 895,
|
"eddbID": 895,
|
||||||
"eff": 0.5,
|
"eff": 0.5,
|
||||||
"grp": "pp",
|
"grp": "pp",
|
||||||
|
|||||||
@@ -10,7 +10,7 @@
|
|||||||
"speed": 230,
|
"speed": 230,
|
||||||
"boost": 330,
|
"boost": 330,
|
||||||
"boostEnergy": 19,
|
"boostEnergy": 19,
|
||||||
"baseShieldStrength": 154,
|
"baseShieldStrength": 200,
|
||||||
"baseArmour": 280,
|
"baseArmour": 280,
|
||||||
"hardness": 65,
|
"hardness": 65,
|
||||||
"hullMass": 400,
|
"hullMass": 400,
|
||||||
|
|||||||
@@ -1,232 +1,230 @@
|
|||||||
var Modules = require('../modules');
|
const Modules = require('../modules');
|
||||||
var Ships = require('../ships');
|
const Ships = require('../ships');
|
||||||
var Modifications = require('../modifications');
|
const Modifications = require('../modifications');
|
||||||
|
|
||||||
describe('JSON Data', function() {
|
describe('JSON Data', () => {
|
||||||
|
const shipProperties = [
|
||||||
|
'name',
|
||||||
|
'manufacturer',
|
||||||
|
'class',
|
||||||
|
'hullCost',
|
||||||
|
'speed',
|
||||||
|
'boost',
|
||||||
|
'boostEnergy',
|
||||||
|
'baseShieldStrength',
|
||||||
|
'baseArmour',
|
||||||
|
'hardness',
|
||||||
|
'hullMass',
|
||||||
|
'masslock',
|
||||||
|
'pipSpeed',
|
||||||
|
'pitch',
|
||||||
|
'roll',
|
||||||
|
'yaw',
|
||||||
|
'crew'
|
||||||
|
];
|
||||||
|
|
||||||
var shipProperties = [
|
const edIDs = {};
|
||||||
'name',
|
const eddbIDs = {};
|
||||||
'manufacturer',
|
|
||||||
'class',
|
|
||||||
'hullCost',
|
|
||||||
'speed',
|
|
||||||
'boost',
|
|
||||||
'boostEnergy',
|
|
||||||
'baseShieldStrength',
|
|
||||||
'baseArmour',
|
|
||||||
'hardness',
|
|
||||||
'hullMass',
|
|
||||||
'masslock',
|
|
||||||
'pipSpeed',
|
|
||||||
'pitch',
|
|
||||||
'roll',
|
|
||||||
'yaw',
|
|
||||||
'crew'
|
|
||||||
];
|
|
||||||
|
|
||||||
var edIDs = {};
|
it('has an up-to-date distribution', () => {
|
||||||
var eddbIDs = {};
|
const dist = require('../dist');
|
||||||
|
expect(dist.Ships).toEqual(Ships, 'Distribution ships does not match. Did you run `npm start`?');
|
||||||
|
expect(dist.Modules).toEqual(Modules, 'Distribution modules does not match. Did you run `npm start`?');
|
||||||
|
});
|
||||||
|
|
||||||
it('has an up-to-date distribution', function() {
|
it('has valid standard modules', () => {
|
||||||
var dist = require('../dist/index.js');
|
const ids = {};
|
||||||
expect(dist.Ships).toEqual(Ships, 'Distribution ships does not match. Did you run `npm start`?');
|
for (const s in Modules.standard) {
|
||||||
expect(dist.Modules).toEqual(Modules, 'Distribution modules does not match. Did you run `npm start`?');
|
const group = Modules.standard[s];
|
||||||
});
|
for (let i = 0; i < group.length; i++) {
|
||||||
|
const id = group[i].id;
|
||||||
it('has valid standard modules', function() {
|
expect(ids[id]).toBeFalsy('ID already exists: ' + id);
|
||||||
var ids = {};
|
expect(group[i].edID > 0).toBeTruthy('Standard module ' + id + ' is missing E:D ID');
|
||||||
for (var s in Modules.standard) {
|
expect(group[i].eddbID > 0).toBeTruthy('Standard module ' + id + ' is missing EDDB ID');
|
||||||
var group = Modules.standard[s];
|
if (s != 'ft' && s != 'pas') {
|
||||||
for (var i = 0; i < group.length; i++) {
|
expect(group[i].integrity).toBeDefined('Standard module ' + id + ' is missing integrity');
|
||||||
var id = group[i].id;
|
}
|
||||||
expect(ids[id]).toBeFalsy('ID already exists: ' + id);
|
expect(group[i].grp).toBeDefined(`No group defined, Type: ${s}, ID: ${id}, Index: ${i}`);
|
||||||
expect(group[i].edID > 0).toBeTruthy('Standard module ' + id + ' is missing E:D ID');
|
|
||||||
expect(group[i].eddbID > 0).toBeTruthy('Standard module ' + id + ' is missing EDDB ID');
|
|
||||||
if (s != 'ft' && s != 'pas' ) {
|
|
||||||
expect(group[i].integrity).toBeDefined('Standard module ' + id + ' is missing integrity');
|
|
||||||
}
|
|
||||||
expect(group[i].grp).toBeDefined(`No group defined, Type: ${s}, ID: ${id}, Index: ${i}`);
|
|
||||||
expect(eddbIDs[group[i].eddbID]).toBeFalsy(`EDDB ID [${group[i].eddbID}] already exists for ID: ${id}, Index: ${i}`);
|
|
||||||
expect(edIDs[group[i].edID]).toBeFalsy(`E:D ID [${group[i].edID}] already exists for ID: ${id}, Index: ${i}`);
|
|
||||||
if (group[i].eddbID) {
|
|
||||||
eddbIDs[group[i].eddbID] = true;
|
|
||||||
}
|
|
||||||
if (group[i].edID) {
|
|
||||||
edIDs[group[i].edID] = true;
|
|
||||||
}
|
|
||||||
ids[id] = true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
it('has valid hardpoints', function() {
|
|
||||||
var ids = {};
|
|
||||||
|
|
||||||
for (var g in Modules.hardpoints) {
|
|
||||||
var group = Modules.hardpoints[g];
|
|
||||||
for (var i = 0; i < group.length; i++) {
|
|
||||||
var id = group[i].id;
|
|
||||||
expect(ids[id]).toBeFalsy('ID already exists: ' + id);
|
|
||||||
expect(group[i].grp).toBeDefined('Hardpoint has no group defined, ID:' + id);
|
|
||||||
expect(group[i].mass).toBeDefined(`Hardpoint ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''} is missing mass`);
|
|
||||||
expect(group[i].integrity).toBeDefined(`Hardpoint ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''} is missing integrity`);
|
|
||||||
expect(group[i].eddbID > 0).toBeTruthy(`Hardpoint ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''} is missing EDDB ID`);
|
|
||||||
expect(group[i].edID > 0).toBeTruthy(`Hardpoint ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''} is missing E:D ID`);
|
|
||||||
expect(eddbIDs[group[i].eddbID]).toBeFalsy(`EDDB ID [${group[i].eddbID}] already exists: ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''}`);
|
expect(eddbIDs[group[i].eddbID]).toBeFalsy(`EDDB ID [${group[i].eddbID}] already exists: ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''}`);
|
||||||
expect(edIDs[group[i].edID]).toBeFalsy(`E:D ID [${group[i].edID}] already exists: ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''}`);
|
expect(edIDs[group[i].edID]).toBeFalsy(`E:D ID [${group[i].edID}] already exists: ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''}`);
|
||||||
if (group[i].eddbID) {
|
if (group[i].eddbID) {
|
||||||
eddbIDs[group[i].eddbID] = true;
|
eddbIDs[group[i].eddbID] = true;
|
||||||
}
|
}
|
||||||
if (group[i].edID) {
|
if (group[i].edID) {
|
||||||
edIDs[group[i].edID] = true;
|
edIDs[group[i].edID] = true;
|
||||||
}
|
}
|
||||||
if (group[i].damage) {
|
ids[id] = true;
|
||||||
expect(group[i].damage).toBeDefined(`Hardpoint ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''} is missing damage`);
|
}
|
||||||
expect(group[i].damagedist).toBeDefined(`Hardpoint ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''} is missing damage distribution`);
|
}
|
||||||
if (group[i].grp != 'po') {
|
});
|
||||||
expect(group[i].thermload).toBeDefined(`Hardpoint ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''} is missing thermload`);
|
|
||||||
expect(group[i].breachmin).toBeDefined(`Hardpoint ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''} is missing breachmin`);
|
|
||||||
expect(group[i].breachmax).toBeDefined(`Hardpoint ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''} is missing breachmax`);
|
|
||||||
expect(group[i].breachdmg).toBeDefined(`Hardpoint ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''} is missing breachdmg`);
|
|
||||||
expect(group[i].piercing).toBeDefined(`Hardpoint ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''} is missing piercing`);
|
|
||||||
expect(group[i].distdraw).toBeDefined(`Hardpoint ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''} is missing distdraw`);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
if ((group[i].ammo || group[i].reload || group[i].clip) && g != 'hs' && g != 'ec') {
|
|
||||||
expect(group[i].ammo).toBeDefined(`Hardpoint ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''} is missing ammo`);
|
|
||||||
expect(group[i].clip).toBeDefined(`Hardpoint ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''} is missing clip`);
|
|
||||||
expect(group[i].reload).toBeDefined(`Hardpoint ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''} is missing reload`);
|
|
||||||
}
|
|
||||||
ids[id] = true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
it('has valid internal modules', function() {
|
it('has valid hardpoints', () => {
|
||||||
var ids = {};
|
const ids = {};
|
||||||
|
|
||||||
for (var g in Modules.internal) {
|
for (const g in Modules.hardpoints) {
|
||||||
var group = Modules.internal[g];
|
const group = Modules.hardpoints[g];
|
||||||
for (var i = 0; i < group.length; i++) {
|
for (let i = 0; i < group.length; i++) {
|
||||||
var id = group[i].id;
|
const id = group[i].id;
|
||||||
expect(group[i].grp).toBeDefined(`No group defined, ID: ${id}`);
|
expect(ids[id]).toBeFalsy('ID already exists: ' + id);
|
||||||
expect(ids[id]).toBeFalsy('ID already exists: ' + id);
|
expect(group[i].grp).toBeDefined('Hardpoint has no group defined, ID:' + id);
|
||||||
expect(group[i].eddbID > 0).toBeTruthy(`${group[i].grp}:${id} ${group[i].name ? group[i].name : ''} is missing EDDB ID`);
|
expect(group[i].mass).toBeDefined(`Hardpoint ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''} is missing mass`);
|
||||||
expect(group[i].edID > 0).toBeTruthy(`${group[i].grp}:${id} ${group[i].name ? group[i].name : ''} is missing E:D ID`);
|
expect(group[i].integrity).toBeDefined(`Hardpoint ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''} is missing integrity`);
|
||||||
if (group[i].grp != 'ft') { // Standard and Internal Fuel tanks have the same IDs
|
expect(group[i].eddbID > 0).toBeTruthy(`Hardpoint ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''} is missing EDDB ID`);
|
||||||
expect(eddbIDs[group[i].eddbID]).toBeFalsy(`EDDB ID [${group[i].eddbID}] already exists: ${id}`);
|
expect(group[i].edID > 0).toBeTruthy(`Hardpoint ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''} is missing E:D ID`);
|
||||||
expect(edIDs[group[i].edID]).toBeFalsy(`E:D ID [${group[i].edID}] already exists: ${id}`);
|
expect(eddbIDs[group[i].eddbID]).toBeFalsy(`EDDB ID [${group[i].eddbID}] already exists: ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''}`);
|
||||||
}
|
expect(edIDs[group[i].edID]).toBeFalsy(`E:D ID [${group[i].edID}] already exists: ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''}`);
|
||||||
if (group[i].eddbID) {
|
if (group[i].eddbID) {
|
||||||
eddbIDs[group[i].eddbID] = true;
|
eddbIDs[group[i].eddbID] = true;
|
||||||
}
|
}
|
||||||
if (group[i].edID) {
|
if (group[i].edID) {
|
||||||
edIDs[group[i].edID] = true;
|
edIDs[group[i].edID] = true;
|
||||||
}
|
}
|
||||||
ids[id] = true;
|
if (group[i].damage) {
|
||||||
}
|
expect(group[i].damage).toBeDefined(`Hardpoint ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''} is missing damage`);
|
||||||
}
|
expect(group[i].damagedist).toBeDefined(`Hardpoint ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''} is missing damage distribution`);
|
||||||
});
|
if (group[i].grp != 'po') {
|
||||||
|
expect(group[i].thermload).toBeDefined(`Hardpoint ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''} is missing thermload`);
|
||||||
|
expect(group[i].breachmin).toBeDefined(`Hardpoint ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''} is missing breachmin`);
|
||||||
|
expect(group[i].breachmax).toBeDefined(`Hardpoint ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''} is missing breachmax`);
|
||||||
|
expect(group[i].breachdmg).toBeDefined(`Hardpoint ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''} is missing breachdmg`);
|
||||||
|
expect(group[i].piercing).toBeDefined(`Hardpoint ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''} is missing piercing`);
|
||||||
|
expect(group[i].distdraw).toBeDefined(`Hardpoint ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''} is missing distdraw`);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if ((group[i].ammo || group[i].reload || group[i].clip) && g != 'hs' && g != 'ec') {
|
||||||
|
expect(group[i].ammo).toBeDefined(`Hardpoint ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''} is missing ammo`);
|
||||||
|
expect(group[i].clip).toBeDefined(`Hardpoint ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''} is missing clip`);
|
||||||
|
expect(group[i].reload).toBeDefined(`Hardpoint ${group[i].grp}:${id} ${group[i].name ? group[i].name : ''} is missing reload`);
|
||||||
|
}
|
||||||
|
ids[id] = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
it('has data for every ship', function() {
|
it('has valid internal modules', () => {
|
||||||
var bulkheadIds = {};
|
const ids = {};
|
||||||
|
|
||||||
for (var s in Ships) {
|
for (const g in Modules.internal) {
|
||||||
for (var p = 0; p < shipProperties.length; p++) {
|
const group = Modules.internal[g];
|
||||||
expect(Ships[s].properties[shipProperties[p]]).toBeDefined(shipProperties[p] + ' is missing for ' + s);
|
for (let i = 0; i < group.length; i++) {
|
||||||
}
|
const id = group[i].id;
|
||||||
expect(Ships[s].eddbID > 0).toBeTruthy(s + ' is missing EDDB ID');
|
expect(group[i].grp).toBeDefined(`No group defined, ID: ${id}`);
|
||||||
expect(Ships[s].edID > 0).toBeTruthy(s + ' is missing E:D ID');
|
expect(ids[id]).toBeFalsy('ID already exists: ' + id);
|
||||||
expect(edIDs[Ships[s].edID]).toBeFalsy(`${s} E:D ID [${Ships[s].edID}] already exists`);
|
expect(group[i].eddbID > 0).toBeTruthy(`${group[i].grp}:${id} ${group[i].name ? group[i].name : ''} is missing EDDB ID`);
|
||||||
expect(Ships[s].slots.standard.length).toEqual(7, s + ' is missing standard slots');
|
expect(group[i].edID > 0).toBeTruthy(`${group[i].grp}:${id} ${group[i].name ? group[i].name : ''} is missing E:D ID`);
|
||||||
expect(Ships[s].defaults.standard.length).toEqual(7, s + ' is missing standard defaults');
|
if (group[i].grp != 'ft') { // Standard and Internal Fuel tanks have the same IDs
|
||||||
expect(Ships[s].slots.hardpoints.length).toEqual(Ships[s].defaults.hardpoints.length, s + ' hardpoint slots and defaults dont match');
|
expect(eddbIDs[group[i].eddbID]).toBeFalsy(`EDDB ID [${group[i].eddbID}] already exists: ${id}`);
|
||||||
expect(Ships[s].slots.internal.length).toEqual(Ships[s].defaults.internal.length, s + ' internal slots and defaults dont match');
|
expect(edIDs[group[i].edID]).toBeFalsy(`E:D ID [${group[i].edID}] already exists: ${id}`);
|
||||||
expect(Ships[s].retailCost).toBeGreaterThan(Ships[s].properties.hullCost, s + ' has invalid retail cost');
|
}
|
||||||
expect(Ships[s].bulkheads).toBeDefined(s + ' is missing bulkheads');
|
if (group[i].eddbID) {
|
||||||
expect(Ships[s].bulkheads.length).toEqual(5, s + ' is missing bulkheads');
|
eddbIDs[group[i].eddbID] = true;
|
||||||
if (Ships[s].edID) {
|
}
|
||||||
edIDs[Ships[s].edID] = true;
|
if (group[i].edID) {
|
||||||
}
|
edIDs[group[i].edID] = true;
|
||||||
|
}
|
||||||
|
ids[id] = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
for (var i = 0; i < Ships[s].bulkheads.length; i++) {
|
it('has data for every ship', () => {
|
||||||
var b = Ships[s].bulkheads[i];
|
const bulkheadIds = {};
|
||||||
expect(b.id).toBeDefined(`${s} bulkhead [${i}] is missing an ID`);
|
|
||||||
expect(bulkheadIds[b.id]).toBeFalsy(`${s} bulkhead [${i} - ${b.id}] ID already exists`);
|
|
||||||
expect(b.eddbID > 0).toBeTruthy(`${s} bulkhead [${i} - ${b.id}] is missing EDDB ID`);
|
|
||||||
expect(eddbIDs[b.eddbID]).toBeFalsy(`EDDB ID [${b.eddbID}] already exists: ${s} bulkhead [${i} - ${b.id}]`);
|
|
||||||
expect(b.edID > 0).toBeTruthy(`${s} bulkhead [${i} - ${b.id}] is missing E:D ID`);
|
|
||||||
expect(edIDs[b.edID]).toBeFalsy(`E:D ID [${b.edID}] already exists: ${s} bulkhead [${i} - ${b.id}]`);
|
|
||||||
if (b.eddbID) {
|
|
||||||
eddbIDs[b.eddbID] = true;
|
|
||||||
}
|
|
||||||
if (b.edID) {
|
|
||||||
edIDs[b.edID] = true;
|
|
||||||
}
|
|
||||||
bulkheadIds[b.id] = true;
|
|
||||||
}
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
it('has valid blueprints', function() {
|
for (const s in Ships) {
|
||||||
var ids = {};
|
for (let p = 0; p < shipProperties.length; p++) {
|
||||||
var names = {};
|
expect(Ships[s].properties[shipProperties[p]]).toBeDefined(shipProperties[p] + ' is missing for ' + s);
|
||||||
|
}
|
||||||
|
expect(Ships[s].eddbID > 0).toBeTruthy(s + ' is missing EDDB ID');
|
||||||
|
expect(Ships[s].edID > 0).toBeTruthy(s + ' is missing E:D ID');
|
||||||
|
expect(edIDs[Ships[s].edID]).toBeFalsy(`${s} E:D ID [${Ships[s].edID}] already exists`);
|
||||||
|
expect(Ships[s].slots.standard.length).toEqual(7, s + ' is missing standard slots');
|
||||||
|
expect(Ships[s].defaults.standard.length).toEqual(7, s + ' is missing standard defaults');
|
||||||
|
expect(Ships[s].slots.hardpoints.length).toEqual(Ships[s].defaults.hardpoints.length, s + ' hardpoint slots and defaults dont match');
|
||||||
|
expect(Ships[s].slots.internal.length).toEqual(Ships[s].defaults.internal.length, s + ' internal slots and defaults dont match');
|
||||||
|
expect(Ships[s].retailCost).toBeGreaterThan(Ships[s].properties.hullCost, s + ' has invalid retail cost');
|
||||||
|
expect(Ships[s].bulkheads).toBeDefined(s + ' is missing bulkheads');
|
||||||
|
expect(Ships[s].bulkheads.length).toEqual(5, s + ' is missing bulkheads');
|
||||||
|
if (Ships[s].edID) {
|
||||||
|
edIDs[Ships[s].edID] = true;
|
||||||
|
}
|
||||||
|
|
||||||
for (var blueprintname in Modifications.blueprints) {
|
for (let i = 0; i < Ships[s].bulkheads.length; i++) {
|
||||||
const blueprint = Modifications.blueprints[blueprintname];
|
const b = Ships[s].bulkheads[i];
|
||||||
expect(names[blueprintname]).toBeFalsy('Name already exists: ' + blueprintname);
|
expect(b.id).toBeDefined(`${s} bulkhead [${i}] is missing an ID`);
|
||||||
names[blueprintname] = true;
|
expect(bulkheadIds[b.id]).toBeFalsy(`${s} bulkhead [${i} - ${b.id}] ID already exists`);
|
||||||
expect(ids[blueprint.id]).toBeFalsy('ID already exists: ' + blueprint.id);
|
expect(b.eddbID > 0).toBeTruthy(`${s} bulkhead [${i} - ${b.id}] is missing EDDB ID`);
|
||||||
ids[blueprint.id] = true;
|
expect(eddbIDs[b.eddbID]).toBeFalsy(`EDDB ID [${b.eddbID}] already exists: ${s} bulkhead [${i} - ${b.id}]`);
|
||||||
expect(blueprint.name).toBeDefined('Blueprint has no name, ID:' + blueprint.id);
|
expect(b.edID > 0).toBeTruthy(`${s} bulkhead [${i} - ${b.id}] is missing E:D ID`);
|
||||||
expect(blueprint.grades).toBeDefined('Blueprint has no grades, ID:' + blueprint.id);
|
expect(edIDs[b.edID]).toBeFalsy(`E:D ID [${b.edID}] already exists: ${s} bulkhead [${i} - ${b.id}]`);
|
||||||
|
if (b.eddbID) {
|
||||||
|
eddbIDs[b.eddbID] = true;
|
||||||
|
}
|
||||||
|
if (b.edID) {
|
||||||
|
edIDs[b.edID] = true;
|
||||||
|
}
|
||||||
|
bulkheadIds[b.id] = true;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
grades = {}
|
it('has valid blueprints', () => {
|
||||||
for (var grade in blueprint.grades) {
|
const ids = {};
|
||||||
expect(grades[grade]).toBeFalsy('Grade already exists: ' + grade + ' for ' + blueprintname);
|
const names = {};
|
||||||
grades[grade] = true;
|
|
||||||
|
|
||||||
const blueprintgrade = blueprint.grades[grade];
|
for (const blueprintname in Modifications.blueprints) {
|
||||||
expect(blueprintgrade.components).toBeDefined('Blueprint grade ' + grade + ' has no components for ' + blueprintname);
|
const blueprint = Modifications.blueprints[blueprintname];
|
||||||
expect(blueprintgrade.features).toBeDefined('Blueprint grade ' + grade + ' has no features for ' + blueprintname);
|
expect(names[blueprintname]).toBeFalsy('Name already exists: ' + blueprintname);
|
||||||
}
|
names[blueprintname] = true;
|
||||||
}
|
expect(ids[blueprint.id]).toBeFalsy('ID already exists: ' + blueprint.id);
|
||||||
});
|
ids[blueprint.id] = true;
|
||||||
|
expect(blueprint.name).toBeDefined('Blueprint has no name, ID:' + blueprint.id);
|
||||||
|
expect(blueprint.grades).toBeDefined('Blueprint has no grades, ID:' + blueprint.id);
|
||||||
|
|
||||||
it('has valid modifications', function() {
|
grades = {};
|
||||||
var ids = {};
|
for (const grade in blueprint.grades) {
|
||||||
|
expect(grades[grade]).toBeFalsy('Grade already exists: ' + grade + ' for ' + blueprintname);
|
||||||
|
grades[grade] = true;
|
||||||
|
|
||||||
for (var k in Modifications.modifications) {
|
const blueprintgrade = blueprint.grades[grade];
|
||||||
const modification = Modifications.modifications[k];
|
expect(blueprintgrade.components).toBeDefined('Blueprint grade ' + grade + ' has no components for ' + blueprintname);
|
||||||
expect(ids[modification.id]).toBeFalsy('ID already exists: ' + modification.id);
|
expect(blueprintgrade.features).toBeDefined('Blueprint grade ' + grade + ' has no features for ' + blueprintname);
|
||||||
expect(modification.name).toBeDefined('Modification has no name, ID:' + modification.id);
|
}
|
||||||
expect(modification.type).toBeDefined('Modification has no type, ID:' + modification.id);
|
}
|
||||||
expect(modification.method).toBeDefined('Modification has no method, ID:' + modification.id);
|
});
|
||||||
ids[modification.id] = true;
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
it('has valid module modifications', function() {
|
it('has valid modifications', () => {
|
||||||
for (var m in Modifications.modules) {
|
const ids = {};
|
||||||
const module = Modifications.modules[m];
|
|
||||||
for (var bp in module.blueprints) {
|
|
||||||
expect(Modifications.blueprints[bp]).toBeDefined('Missing ' + bp + ' for ' + m);
|
|
||||||
for (var grade in module.blueprints[bp].grades) {
|
|
||||||
expect(Modifications.blueprints[bp].grades[grade]).toBeDefined('Missing ' + bp + ' grade ' + grade + ' for ' + m);
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
|
||||||
});
|
|
||||||
|
|
||||||
it('has valid specials', function() {
|
for (const k in Modifications.modifications) {
|
||||||
var ids = {};
|
const modification = Modifications.modifications[k];
|
||||||
|
expect(ids[modification.id]).toBeFalsy('ID already exists: ' + modification.id);
|
||||||
|
expect(modification.name).toBeDefined('Modification has no name, ID:' + modification.id);
|
||||||
|
expect(modification.type).toBeDefined('Modification has no type, ID:' + modification.id);
|
||||||
|
expect(modification.method).toBeDefined('Modification has no method, ID:' + modification.id);
|
||||||
|
ids[modification.id] = true;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
for (var k in Modifications.specials) {
|
it('has valid module modifications', () => {
|
||||||
const special = Modifications.specials[k];
|
for (const m in Modifications.modules) {
|
||||||
expect(ids[special.id]).toBeFalsy('ID already exists: ' + special.id);
|
const module = Modifications.modules[m];
|
||||||
expect(special.name).toBeDefined('Special has no name, ID:' + special.id);
|
for (const bp in module.blueprints) {
|
||||||
ids[special.id] = true;
|
expect(Modifications.blueprints[bp]).toBeDefined('Missing ' + bp + ' for ' + m);
|
||||||
}
|
for (const grade in module.blueprints[bp].grades) {
|
||||||
});
|
expect(Modifications.blueprints[bp].grades[grade]).toBeDefined('Missing ' + bp + ' grade ' + grade + ' for ' + m);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
it('has valid specials', () => {
|
||||||
|
const ids = {};
|
||||||
|
|
||||||
|
for (const k in Modifications.specials) {
|
||||||
|
const special = Modifications.specials[k];
|
||||||
|
expect(ids[special.id]).toBeFalsy('ID already exists: ' + special.id);
|
||||||
|
expect(special.name).toBeDefined('Special has no name, ID:' + special.id);
|
||||||
|
ids[special.id] = true;
|
||||||
|
}
|
||||||
|
});
|
||||||
});
|
});
|
||||||
|
|||||||
Reference in New Issue
Block a user