{
  "$id": "blockception.minecraft.behavior.entities.minecraft.behavior.swim_with_entity",
  "type": "object",
  "title": "Swim With Entity",
  "description": "Allows the entity follow another entity. Both entities must be swimming and in water.",
  "additionalProperties": false,
  "required": [],
  "properties": {
    "priority": { "$ref": "types/priority.json" },
    "speed_multiplier": { "$ref": "types/speed_multiplier.json" },
    "success_rate": {
      "title": "Success Rate",
      "type": "number",
      "default": 0.1,
      "description": "Percent chance to start following another entity, if not already doing so. 1.0 = 100%"
    },
    "chance_to_stop": {
      "title": "Chance To Stop",
      "type": "number",
      "default": 0.0333,
      "description": "Percent chance to stop following the current entity, if they're riding another entity or they're not swimming. 1.0 = 100%"
    },
    "state_check_interval": {
      "title": "State Check Interval",
      "type": "number",
      "default": 0.5,
      "description": "Time (in seconds) between checks to determine if this entity should catch up to the entity being followed or match the direction of the entity being followed."
    },
    "catch_up_threshold": {
      "title": "Catch Up Threshold",
      "type": "number",
      "default": 12,
      "description": "Distance, from the entity being followed, at which this entity will speed up to reach that entity."
    },
    "match_direction_threshold": {
      "title": "Match Direction Threshold",
      "type": "number",
      "default": 2,
      "description": "Distance, from the entity being followed, at which this entity will try to match that entity's direction."
    },
    "catch_up_multiplier": {
      "title": "Catch Up Multiplier",
      "type": "number",
      "default": 2.5,
      "description": "The multiplier this entity's speed is modified by when matching another entity's direction."
    },
    "search_range": {
      "title": "Search Range",
      "type": "number",
      "default": 20,
      "description": "Radius around this entity to search for another entity to follow."
    },
    "stop_distance": {
      "title": "Stop Distance",
      "type": "number",
      "default": 5,
      "description": "Distance, from the entity being followed, at which this entity will stop following that entity."
    },
    "entity_types": {
      "$ref": "../types/entity_types.json",
      "title": "Entity Types",
      "description": "Filters which determine what entites are valid to follow."
    }
  },
  "examples": [
    {
      "success_rate": 0.1,
      "chance_to_stop": 0.0333,
      "state_check_interval": 0.5,
      "catch_up_threshold": 12,
      "match_direction_threshold": 2,
      "catch_up_multiplier": 2.5,
      "search_range": 20,
      "stop_distance": 5
    }
  ]
}
