// Path: src/main/java/org/scorpion/jmugen/exception/ConfigException.java
// public class ConfigException extends GenericException implements NonFatal {
// 
//     public ConfigException(String message) {
//         super(message, null, false, false);
//     }
// 
//     public static ConfigException missing(String title, String group, String key) {
//         StringBuilder sb = new StringBuilder(title)
//                 .append(": Missing ")
//                 .append(key);
//         if (group != null) {
//             sb.append(" in ").append(group);
//         }
//         return new ConfigException(sb.toString());
//     }
// 
// }


import org.apache.commons.lang3.StringUtils;
import org.scorpion.jmugen.core.maths.*;
import org.scorpion.jmugen.exception.ConfigException;
import java.util.*;
import java.util.function.Function;
        CAMERA_CONFIG_CONVERTERS.put(CAMERA_BOUND_LOW, Float::parseFloat);
    }

    private String name;
    private GroupedConfig stageConfig;
    private List<BG> backgrounds = new ArrayList<>();

    public StageDef(String name, GroupedConfig stageConfig) {
        this.name = name;
        this.stageConfig = new GroupedConfig().merge(DEFAULT_GENERAL_CONFIG).merge(stageConfig);
    }

    @Override
    public StageDef load() {
        Config generalInfoConfig = Optional.ofNullable(stageConfig.get(GROUP_GERERAL_INFO))
                .orElseGet(Config::new);
        String stageName = generalInfoConfig.get(STAGE_NAME);
        if (stageName != null) {
            this.name = stageName;
        }

        Config stageInfoConfig = Optional.ofNullable(stageConfig.get(GROUP_STAGE_INFO))
                .orElseGet(Config::new)
                .applyConverters(STAGE_CONFIG_CONVERTERS);
        stageConfig.add(GROUP_STAGE_INFO, stageInfoConfig);

        Config bgConfig = Optional.ofNullable(stageConfig.get(GROUP_BG_DEF))
                .orElseGet(Config::new)
                .applyConverters(BG_DEF_CONVERTERS);
        if (bgConfig.get(SPR) == null) {
// Path: src/main/java/org/scorpion/jmugen/exception/ConfigException.java
// public class ConfigException extends GenericException implements NonFatal {
// 
//     public ConfigException(String message) {
//         super(message, null, false, false);
//     }
// 
//     public static ConfigException missing(String title, String group, String key) {
//         StringBuilder sb = new StringBuilder(title)
//                 .append(": Missing ")
//                 .append(key);
//         if (group != null) {
//             sb.append(" in ").append(group);
//         }
//         return new ConfigException(sb.toString());
//     }
// 
// }


// Path: src/main/java/org/scorpion/jmugen/core/config/StageDef.java
import org.apache.commons.lang3.StringUtils;
import org.scorpion.jmugen.core.maths.*;
import org.scorpion.jmugen.exception.ConfigException;
import java.util.*;
import java.util.function.Function;

        CAMERA_CONFIG_CONVERTERS.put(CAMERA_BOUND_LOW, Float::parseFloat);
    }

    private String name;
    private GroupedConfig stageConfig;
    private List<BG> backgrounds = new ArrayList<>();

    public StageDef(String name, GroupedConfig stageConfig) {
        this.name = name;
        this.stageConfig = new GroupedConfig().merge(DEFAULT_GENERAL_CONFIG).merge(stageConfig);
    }

    @Override
    public StageDef load() {
        Config generalInfoConfig = Optional.ofNullable(stageConfig.get(GROUP_GERERAL_INFO))
                .orElseGet(Config::new);
        String stageName = generalInfoConfig.get(STAGE_NAME);
        if (stageName != null) {
            this.name = stageName;
        }

        Config stageInfoConfig = Optional.ofNullable(stageConfig.get(GROUP_STAGE_INFO))
                .orElseGet(Config::new)
                .applyConverters(STAGE_CONFIG_CONVERTERS);
        stageConfig.add(GROUP_STAGE_INFO, stageInfoConfig);

        Config bgConfig = Optional.ofNullable(stageConfig.get(GROUP_BG_DEF))
                .orElseGet(Config::new)
                .applyConverters(BG_DEF_CONVERTERS);
        if (bgConfig.get(SPR) == null) {
            throw ConfigException.missing("Stage " + name, GROUP_BG_DEF, SPR);