[
  {
    "type": "effect_type",
    "id": "effect_perk_in_the_zone",
    "name": [ "In the Zone" ],
    "desc": [
      "You are one with the Nether and the Nether is with you.  The stamina cost of channeling your next power is reduced by 25%."
    ],
    "apply_message": "",
    "rating": "good",
    "max_duration": "5 s"
  },
  {
    "type": "effect_type",
    "id": "effect_perk_in_the_zone_rate_limiter",
    "//": "We'll see if this is the problem",
    "name": [ "" ],
    "desc": [ "" ]
  },
  {
    "type": "effect_on_condition",
    "id": "EOC_PERK_IN_THE_ZONE_ADD_EFFECT_TRIGGER",
    "eoc_type": "EVENT",
    "required_event": "spellcasting_finish",
    "condition": {
      "and": [
        { "test_eoc": "EOC_CONDITION_SPELLCASTING_FINISH_TRAIT_AND_SCHOOL_LIST" },
        { "not": { "u_has_effect": "effect_perk_in_the_zone" } },
        { "u_has_trait": "perk_in_the_zone" }
      ]
    },
    "effect": [
      { "u_add_effect": "effect_perk_in_the_zone", "duration": 5 },
      { "u_add_effect": "effect_perk_in_the_zone_rate_limiter", "duration": 0 }
    ]
  },
  {
    "type": "effect_on_condition",
    "id": "EOC_PERK_IN_THE_ZONE_REMOVE_EFFECT_TRIGGER",
    "eoc_type": "EVENT",
    "required_event": "spellcasting_finish",
    "condition": {
      "and": [
        { "test_eoc": "EOC_CONDITION_SPELLCASTING_FINISH_TRAIT_AND_SCHOOL_LIST" },
        { "u_has_trait": "perk_in_the_zone" },
        { "not": { "u_has_effect": "effect_perk_in_the_zone_rate_limiter" } },
        { "u_has_effect": "effect_perk_in_the_zone" }
      ]
    },
    "effect": [ { "u_lose_effect": "effect_perk_in_the_zone" } ]
  },
  {
    "type": "effect_on_condition",
    "id": "EOC_PERK_IN_THE_ZONE_ACTUAL_COST_ADJUSTMENT",
    "eoc_type": "EVENT",
    "required_event": "opens_spellbook",
    "condition": { "u_has_effect": "effect_perk_in_the_zone" },
    "effect": [ { "math": [ "u_spellcasting_adjustment('cost', 'flag_whitelist': 'PSIONIC') = -0.25" ] } ]
  }
]
