[
  {
    "type": "effect_on_condition",
    "id": "EOC_CONSUMED_BLOOD_TREATMENT",
    "//": "Should resist and reverse some of the early stages of the vampire virus.",
    "condition": { "u_has_effect": "blood_treatment" },
    "effect": [
      { "u_add_effect": "blood_treatment", "duration": "16 hours" },
      { "u_message": "You take a blood treatment.", "type": "info" }
    ],
    "false_effect": [
      { "u_add_effect": "blood_treatment", "duration": "16 hours" },
      { "u_message": "You take a blood treatment.", "type": "info" },
      {
        "run_eocs": [
          {
            "id": "EOC_REDUCE_VAMPVIRUS",
            "condition": { "compare_num": [ { "u_val": "effect_intensity", "effect": "vampire_virus" }, "=", { "const": 1 } ] },
            "effect": [
              { "u_lose_effect": "vampire_virus" },
              { "u_lose_trait": "VAMPIRE" },
              { "u_lose_trait": "EYEGLEAM" },
              { "u_lose_trait": "STAMINAFORBLOOD" },
              { "u_lose_trait": "BLOODBANK" },
              { "u_lose_trait": "COMMUNE_NIGHT" },
              { "u_message": "The light seems less bright and the air fresher.", "type": "good" }
            ]
          },
          {
            "id": "EOC_REDUCE_VAMPVIRUS1",
            "condition": { "compare_num": [ { "u_val": "effect_intensity", "effect": "vampire_virus" }, "=", { "const": 2 } ] },
            "effect": [
              { "u_add_effect": "vampire_virus", "intensity": 1, "duration": "PERMANENT" },
              { "u_lose_trait": "VAMPIRE2" },
              { "u_lose_trait": "COAGULANTWEAVE" },
              { "u_lose_trait": "BLOODHEAL" },
              {
                "u_message": "You seem to be feeling a little better, but the thirst for blood remains.",
                "type": "good"
              }
            ]
          },
          {
            "id": "EOC_REDUCE_VAMPVIRUS2",
            "condition": { "compare_num": [ { "u_val": "effect_intensity", "effect": "vampire_virus" }, "=", { "const": 3 } ] },
            "effect": [
              { "u_add_effect": "vampire_virus", "intensity": 2, "duration": "PERMANENT" },
              { "u_lose_trait": "VAMPIRE3" },
              { "u_lose_trait": "BLOODBANK" },
              { "u_lose_trait": "HYPNOTIC_GAZE" },
              { "u_lose_trait": "BLOODHASTE" },
              {
                "u_message": "You no longer instantly turn red in sunlight, but your skin is still concerningly pale.",
                "type": "good"
              }
            ]
          },
          {
            "id": "EOC_REDUCE_VAMPVIRUS3",
            "condition": {
              "and": [
                { "u_has_effect": "vampire_virus_ascendant", "intensity": 1 },
                {
                  "compare_num": [ { "u_val": "effect_intensity", "effect": "vampire_virus_ascendant" }, "=", { "const": 1 } ]
                }
              ]
            },
            "effect": [
              { "u_add_effect": "poisoned_blood", "intensity": 1, "duration": "4 hours" },
              {
                "u_message": "Your veins burn and ache.  What were you thinking trying this?  You are already one of the damned!",
                "type": "bad"
              }
            ]
          },
          {
            "id": "EOC_REDUCE_VAMPVIRUS4",
            "condition": {
              "and": [
                { "u_has_effect": "vampire_virus_post_mortal", "intensity": 1 },
                {
                  "compare_num": [ { "u_val": "effect_intensity", "effect": "vampire_virus_post_mortal" }, "=", { "const": 1 } ]
                }
              ]
            },
            "effect": [
              { "u_add_effect": "poisoned_blood2", "intensity": 1, "duration": "1 hours" },
              {
                "u_message": "Your veins burn and ache.  What were you thinking trying this?  You are already one of the damned!",
                "type": "bad"
              }
            ]
          }
        ]
      }
    ]
  },
  {
    "type": "effect_on_condition",
    "id": "EOC_COMPLETED_ROLL_REMAINDER_VAMPVIRUS",
    "effect": { "u_message": "You flush with desire as you think about blood." }
  },
  {
    "type": "effect_on_condition",
    "id": "EOC_COMPLETED_VAMPIRE3",
    "effect": { "u_message": "You can advance no further without access to a mentor.  (4th wall no further content exists yet)" }
  },
  {
    "type": "effect_on_condition",
    "id": "EOC_SUCCESFUL_ROLL_REMAINDER",
    "effect": { "u_message": "Suddenly you feel your heart pounding and you realize a new ability." }
  },
  {
    "type": "effect_on_condition",
    "id": "EOC_SUCCESFUL_ROLL_REMAINDER2",
    "effect": { "u_message": "Suddenly you feel your heart slowing and you realize a new ability." }
  },
  {
    "type": "effect_on_condition",
    "id": "EOC_ADD_VAMPIRUS_INTENSITY1",
    "condition": { "and": [ { "u_has_trait": "EYEGLEAM" }, { "u_has_trait": "STAMINAFORBLOOD" }, { "u_has_trait": "COMMUNE_NIGHT" } ] },
    "effect": { "u_add_effect": "vampire_virus", "intensity": 2, "duration": "PERMANENT" }
  },
  {
    "type": "effect_on_condition",
    "id": "EOC_ADD_VAMPIRUS_INTENSITY2",
    "condition": { "and": [ { "u_has_trait": "COAGULANTWEAVE" }, { "u_has_trait": "BLOODHEAL" } ] },
    "effect": { "u_add_effect": "vampire_virus", "intensity": 3, "duration": "PERMANENT" }
  },
  {
    "type": "effect_on_condition",
    "id": "EOC_VAMPIRES",
    "recurrence": [ { "global_val": "ps_min_woc", "default": "1 days" }, { "global_val": "ps_max_woc", "default": "2 days" } ],
    "global": true,
    "effect": { "run_eocs": "EOC_vampire_virus_escalation" }
  },
  {
    "type": "effect_on_condition",
    "id": "EOC_vampire_virus_escalation",
    "//": "This EOC controls the speed at which vampires mutate and evolve.",
    "recurrence": [ "48 hours", "72 hours 15 minutes" ],
    "condition": { "and": [ { "u_has_effect": "vampire_virus" }, { "not": { "u_has_effect": "blood_treatment" } } ] },
    "deactivate_condition": { "not": { "u_has_effect": "vampire_virus" } },
    "effect": {
      "run_eocs": [
        {
          "id": "EOC_VAMPVIRUS",
          "condition": {
            "and": [
              { "u_has_effect": "vampire_virus", "intensity": 1 },
              { "compare_num": [ { "u_val": "effect_intensity", "effect": "vampire_virus" }, "=", { "const": 1 } ] }
            ]
          },
          "effect": {
            "run_eocs": {
              "id": "eoc_vampvirus_1_trait",
              "condition": { "u_has_trait": "VAMPIRE" },
              "effect": [
                {
                  "u_roll_remainder": [ "EYEGLEAM", "STAMINAFORBLOOD", "COMMUNE_NIGHT" ],
                  "type": "mutation",
                  "true_eocs": [ "EOC_SUCCESFUL_ROLL_REMAINDER" ],
                  "false_eocs": [ "EOC_COMPLETED_ROLL_REMAINDER_VAMPVIRUS", "EOC_VAMPVIRUS1" ]
                },
                { "queue_eocs": "EOC_ADD_VAMPIRUS_INTENSITY1", "time_in_future": [ "5 days", "8 hours" ] }
              ],
              "false_effect": [
                { "u_add_trait": "VAMPIRE" },
                {
                  "u_message": "You suddenly understand that drinking someones blood will make you feel better than you've ever felt before in your life."
                }
              ]
            }
          }
        },
        {
          "id": "EOC_VAMPVIRUS1",
          "condition": {
            "and": [
              { "u_has_effect": "vampire_virus", "intensity": 2 },
              { "compare_num": [ { "u_val": "effect_intensity", "effect": "vampire_virus" }, "=", { "const": 2 } ] }
            ]
          },
          "effect": {
            "run_eocs": {
              "id": "eoc_vampvirus_2_trait",
              "condition": { "u_has_trait": "VAMPIRE2" },
              "effect": [
                {
                  "u_roll_remainder": [ "BLOODHEAL", "COAGULANTWEAVE" ],
                  "type": "mutation",
                  "true_eocs": [ "EOC_SUCCESFUL_ROLL_REMAINDER" ],
                  "false_eocs": [ "EOC_COMPLETED_ROLL_REMAINDER_VAMPVIRUS", "EOC_VAMPVIRUS2" ]
                },
                { "queue_eocs": "EOC_ADD_VAMPIRUS_INTENSITY2", "time_in_future": [ "15 days", "8 hours" ] }
              ],
              "false_effect": [
                { "u_add_trait": "VAMPIRE2" },
                {
                  "u_message": "With a popping sound several of your teeth fall out but when you put a finger into your mouth to feel the hole, there are new sharp fangs where you expected nothing."
                }
              ]
            }
          }
        },
        {
          "id": "EOC_VAMPVIRUS2",
          "condition": {
            "and": [
              { "u_has_effect": "vampire_virus", "intensity": 3 },
              { "compare_num": [ { "u_val": "effect_intensity", "effect": "vampire_virus" }, "=", { "const": 3 } ] }
            ]
          },
          "effect": {
            "run_eocs": {
              "id": "eoc_vampvirus_3_trait",
              "condition": { "u_has_trait": "VAMPIRE3" },
              "effect": [
                {
                  "u_roll_remainder": [ "BLOODHASTE", "HYPNOTIC_GAZE", "BLOODBANK" ],
                  "type": "mutation",
                  "true_eocs": [ "EOC_SUCCESFUL_ROLL_REMAINDER" ],
                  "false_eocs": [ "EOC_COMPLETED_VAMPIRE3" ]
                }
              ],
              "false_effect": [
                { "u_add_trait": "VAMPIRE3" },
                {
                  "u_message": "You feel the absence of your heart beating for several seconds and then it resumes at this new rhythm."
                }
              ]
            }
          }
        }
      ]
    }
  },
  {
    "type": "effect_on_condition",
    "id": "EOC_vampire_virus_blood_needs",
    "//": "This EOC works on telling the vampire whether they need to consume blood or not.",
    "recurrence": [ "8 hours", "14 hours 15 minutes" ],
    "condition": {
      "and": [
        { "compare_num": [ { "u_val": "vitamin", "name": "human_blood_vitamin" }, "<=", { "const": -450 } ] },
        { "u_has_effect": "vampire_virus" }
      ]
    },
    "deactivate_condition": { "not": { "u_has_effect": "vampire_virus" } },
    "effect": {
      "run_eocs": [
        {
          "id": "EOC_VAMPVIRUS_HUNGER",
          "condition": {
            "and": [
              { "u_has_effect": "vampire_virus", "intensity": 1 },
              { "compare_num": [ { "u_val": "effect_intensity", "effect": "vampire_virus" }, ">=", { "const": 1 } ] }
            ]
          },
          "effect": {
            "run_eocs": {
              "id": "eoc_blood_hunger",
              "condition": { "u_has_trait": "VAMPIRE" },
              "effect": { "u_message": "You need to consume human blood to stay alive." }
            }
          }
        }
      ]
    }
  }
]
