def GetClosestSupportedMotionBuilderVersion(Version: int):
    """
    Get the closest MotionBuilder version that is supported 
    """
    if Version < 2018:
        return 2018

    if Version == 2021:
        return 2022

    return Version