mirror of
https://github.com/EDCD/coriolis.git
synced 2025-12-10 07:05:35 +00:00
Ensure that hidden blueprint effects are applied when a blueprint is selected
This commit is contained in:
@@ -435,6 +435,14 @@ export default class Ship {
|
||||
*/
|
||||
setModuleBlueprint(m, bp) {
|
||||
m.blueprint = bp;
|
||||
this.clearModifications(m);
|
||||
// Set any hidden items for the blueprint now
|
||||
const features = m.blueprint.grades[m.blueprint.grade].features;
|
||||
for (const featureName in features) {
|
||||
if (Modifications.modifications[featureName].hidden) {
|
||||
this.setModification(m, featureName, bp.grades[bp.grade].features[featureName][0]);
|
||||
}
|
||||
}
|
||||
this.updateModificationsString();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user