+ // Search the rocket for any ComponentPresets (version 1.5)
+ for (RocketComponent c : document.getRocket()) {
+ if (c.getPresetComponent() != null) {
+ return FILE_VERSION_DIVISOR + 5;
+ }
+ }
+
+ // Search for recovery device deployment type LOWER_STAGE_SEPARATION (version 1.5)
+ for (RocketComponent c : document.getRocket()) {
+ if (c instanceof RecoveryDevice) {
+ if (((RecoveryDevice) c).getDeployEvent() == DeployEvent.LOWER_STAGE_SEPARATION) {
+ return FILE_VERSION_DIVISOR + 5;
+ }
+ }
+ }
+
+ // Check for custom expressions
+ if (!document.getCustomExpressions().isEmpty()) {
+ return FILE_VERSION_DIVISOR + 5;
+ }
+