fix rate of fire

probably
This commit is contained in:
willyb321
2017-12-19 14:49:04 +11:00
parent c2f1fa81af
commit ba2e46f88f

View File

@@ -338,6 +338,8 @@ function _addModifications(module, modifiers, blueprint, grade, specialModificat
value = (modifiers[i].value - module.hullboost) / module.hullboost;
} else if (i === 'OutfittingFieldType_DefenceModifierHealthMultiplier') {
value = modifiers[i].value / module.hullboost;
} else if (i === 'OutfittingFieldType_RateOfFire') {
value = (1 / Math.abs(modifiers[i].value));
} else {
value = modifiers[i].value - 1;
}
@@ -444,11 +446,6 @@ function _addModifications(module, modifiers, blueprint, grade, specialModificat
module.setModValue('jitter', module.getModValue('jitter') / 100);
}
// FD uses interval between bursts internally, so we need to translate this to a real rate of fire
if (module.getModValue('rof')) {
module.setModValue('rof', ((1 / (1 + module.getModValue('rof') / 10000)) - 1) * 10000);
}
// Clip size is rounded up so that the result is a whole number
if (module.getModValue('clip')) {
const individual = 1 / (module.clip || 1);