{
  "format_version": "1.17.0",
  "minecraft:spawn_rules": {
    "description": {
      "identifier": "minecraft:bat",
      "population_control": "ambient"
    },
    "conditions": [
      {
        "minecraft:spawns_underground": {},
        "minecraft:brightness_filter": {
          "min": 0,
          "max": 4,
          "adjust_for_weather": true
        },
        "minecraft:height_filter": {
          "min": -63,
          "max": 63
        },
        "minecraft:weight": {
          "default": 10
        },
        "minecraft:herd": {
          "min_size": 2,
          "max_size": 2
        },
        "minecraft:density_limit": {
          "surface": 5
        },
        
        "minecraft:biome_filter": {
          "test": "has_biome_tag", "operator":"==", "value": "animal"
        }
      }
    ]
  }
}