{
  "format_version": "1.10.0",
  "animation_controllers": {
    "controller.animation.silverlabs_nat.slug.bounce": {
      "initial_state": "default",
      "states": {
        "default": {
          "on_entry": ["@s silverlabs_nat:can_detect_bounce"],
          "transitions": [
            { "bounce": "query.property('silverlabs_nat:bounce')" }
          ]
        },

        "bounce": {
          "on_entry": [
            "v.delay = 2;",
            "v.current_delay = query.life_time;",
            "/scriptevent silverlabs_nat:should_bounce_player @p"
          ],

          "transitions": [
            { "default": "(query.life_time - v.current_delay >= v.delay)" }
          ]
        }
      }
    }
  }
}
