{
  "format_version": "1.19.0",
  "minecraft:attachable": {
    "description": {
      "identifier": "tsu_morph:vex_morph",
      "materials": {
        "default": "entity_alphatest",
        "arms": "entity_alphatest"
      },
      "textures": {
        "default": "textures/entity/vex/vex"
      },
      "geometry": {
        "default": "geometry.tsu_morph.vex"
      },
      "animations": {
        "look_at_target": "animation.tsu_morph.look_at_target",
        "idle": "animation.tsu_morph.vex.idle",
        "charge": "animation.tsu_morph.vex.charge",

        "hurt_sounds": "controller.animation.tsu_morph.hurt_sounds",
        "idle_sounds": "animation.tsu_morph.idle_sounds"
      },
      "sound_effects": {
        "hurt": "mob.vex.hurt",
        "idle": "mob.vex.ambient"
      },
      "scripts": {
        "pre_animation": [
          "variable.tcos0 = (Math.cos(query.modified_distance_moved * 38.17) * query.modified_move_speed) * 57.3;",
          "variable.empty_handed  = !query.is_item_equipped(0) && !query.is_item_equipped(1);",
          "v.display_fp = c.is_first_person && !q.is_in_ui && q.is_local_player;",
          "v.item_use_normalized = q.is_using_item ? 1-q.item_in_use_duration/q.item_max_use_duration : 0;",
          "v.has_ability_item = q.is_item_name_any('slot.weapon.mainhand', 0, 'tsu_morph:vex_ability');"
        ],
        "animate": [
          "idle",
          {
            "charge": "!q.is_on_ground && q.is_moving"
          },
          "hurt_sounds",
          "idle_sounds"
        ]
      },
      "render_controllers": [
        {
          "controller.render.tsu_morph.default": "!v.display_fp"
        }
      ]
    }
  }
}