# Triggering Damage Absorbed

Grammar — Triggering damage absorbed
FlagsNative | Function

Returns the triggering damage amount, including damage absorbed by damage modification behaviors.

Returns — fixed

native fixed EventUnitDamageAbsorbed();

# Supported triggers

Category: Unit / Combat

# Examples

campaigns/swarm.sc2campaignbase.sc2maps/maps/campaign/voidprologue/voidprologue01.sc2map/MapScript.galaxy:3583

        }

        if (!((EventUnitDamageAbsorbed() >= UnitGetPropertyFixed(EventUnit(), c_unitPropLife, c_unitPropCurrent)))) {
            return false;
        }

campaigns/swarm.sc2campaign/base.sc2maps/maps/campaign/voidprologue/voidprologue01.sc2mapMapScript.galaxy:3583

        }

        if (!((EventUnitDamageAbsorbed() >= UnitGetPropertyFixed(EventUnit(), c_unitPropLife, c_unitPropCurrent)))) {
            return false;
        }

campaigns/voidstory.sc2campaignbase.sc2data/TriggerLibs/VoidCampaignLib.galaxy:10274

    }

    libVoiC_gv_pC_AchievementShieldAbsorbTotal += EventUnitDamageAbsorbed();
    if (((FixedToInt(libVoiC_gv_pC_AchievementShieldAbsorbTotal) - FixedToInt(libVoiC_gv_pC_AchievementShieldAbsorbLast)) > 5)) {
        AchievementTermQuantityAdd(1, "SOA_ShieldOvercharge", (FixedToInt(libVoiC_gv_pC_AchievementShieldAbsorbTotal) - FixedToInt(libVoiC_gv_pC_AchievementShieldAbsorbLast)));

mods/heroesdata.stormmodbase.stormdata/TriggerLibs/GameDataHelperLib.galaxy:6287

    // Conditions
    if (testConds) {
        if (!((EventUnitDamageAbsorbed() > 1.0))) {
            return false;
        }

mods/heroesdata.stormmodbase.stormdata/TriggerLibs/GameDataHelperLib.galaxy:6301

    }

    lv_healingAvailable = (EventUnitDamageAbsorbed() * libGDHL_gv_heroArthasAntiMagicShellHealingFraction);
    CatalogFieldValueSetFixed(c_gameCatalogEffect, "ArthasAntiMagicShellCreateHealer", "RechargeVitalRate", lv_arthasPlayer, lv_healingAvailable);
    UnitCreateEffectUnit(lv_arthas, "ArthasAntiMagicShellCreateHealer", lv_arthas);

mods/heroesdata.stormmodbase.stormdata/TriggerLibs/GameDataHelperLib.galaxy:8889

    lv_chen = EventUnit();
    lv_chenOwner = UnitGetOwner(lv_chen);
    lv_damageTaken = (EventUnitDamageAbsorbed() * libGDHL_gv_heroChenStaggerDamageModification[lv_chenOwner]);
    lv_damageTakenInteger = FixedToInt(lv_damageTaken);

mods/heroesdata.stormmodbase.stormdata/TriggerLibs/GameDataHelperLib.galaxy:18075

    // Automatic Variable Declarations
    // Variable Initialization
    lv_damage = (EventUnitDamageAbsorbed() + EventUnitDamageAmount());
    lv_image = EventUnit();
    lv_imageOwner = UnitGetOwner(lv_image);

mods/heroesdata.stormmodbase.stormdata/TriggerLibs/GameLib.galaxy:15332

    // Variable Initialization
    lv_casterPlayer = UnitBehaviorEffectPlayer(EventUnit(), EventUnitBehavior(), c_effectPlayerCaster, 0);
    lv_damageAbsorbed = EventUnitDamageAbsorbed();
    lv_casterUnit = UnitBehaviorEffectUnit(lv_shieldedUnit, EventUnitBehavior(), c_effectUnitCaster, 0);
    lv_casterUnitOwner = UnitGetOwner(lv_casterUnit);

mods/heroesdata.stormmodbase.stormdata/TriggerLibs/GameLib.galaxy:19447

    if ((lv_eventPlayer <= libCore_gv_bALMaxPlayers) && (UnitTypeTestAttribute(lv_triggeringUnitType, c_unitAttributeHeroic) == true) && (UnitTestState(EventUnit(), c_unitStateHallucination) == false) && (UnitHasBehavior(EventUnit(), "GenericVehicleBehaviorEmpty") == false) && (UnitHasBehavior(EventUnit(), "GenericVehicleBehaviorOccupied") == false)) {
        if ((lv_eventUnitDamageSourcePlayer != 15)) {
            libGame_gv_scoreValues[lv_eventPlayer].lv_damageTaken += FixedToInt(EventUnitDamageAbsorbed());
            libGame_gv_scoreValues[lv_eventPlayer].lv_damageSoaked += FixedToInt(EventUnitDamageAbsorbed());
            libGame_gf_AddGuardianDamage(EventUnitDamageAbsorbed(), lv_eventPlayer);

mods/heroesdata.stormmodbase.stormdata/TriggerLibs/GameLib.galaxy:19448

        if ((lv_eventUnitDamageSourcePlayer != 15)) {
            libGame_gv_scoreValues[lv_eventPlayer].lv_damageTaken += FixedToInt(EventUnitDamageAbsorbed());
            libGame_gv_scoreValues[lv_eventPlayer].lv_damageSoaked += FixedToInt(EventUnitDamageAbsorbed());
            libGame_gf_AddGuardianDamage(EventUnitDamageAbsorbed(), lv_eventPlayer);
            libGame_gf_AddScrapperDamage(lv_damageTaken, lv_eventUnitDamageSourcePlayer);

mods/heroesdata.stormmodbase.stormdata/TriggerLibs/GameLib.galaxy:19449

            libGame_gv_scoreValues[lv_eventPlayer].lv_damageTaken += FixedToInt(EventUnitDamageAbsorbed());
            libGame_gv_scoreValues[lv_eventPlayer].lv_damageSoaked += FixedToInt(EventUnitDamageAbsorbed());
            libGame_gf_AddGuardianDamage(EventUnitDamageAbsorbed(), lv_eventPlayer);
            libGame_gf_AddScrapperDamage(lv_damageTaken, lv_eventUnitDamageSourcePlayer);
            libGame_gf_ScoreValuesReportIntegerValueAndLog(lv_eventPlayer, "DamageTaken", libGame_gv_scoreValues[lv_eventPlayer].lv_damageTaken);

mods/heromods/genji.stormmodbase.stormdata/LibHGen.galaxy:336

    lv_genjiUnit = EventUnit();
    lv_genjiPlayer = UnitGetOwner(lv_genjiUnit);
    lv_incomingDamage = EventUnitDamageAbsorbed();

    // Actions

mods/heromods/genji.stormmodbase.stormdata/LibHGen.galaxy:408

    lv_genjiUnit = EventUnit();
    lv_genjiPlayer = UnitGetOwner(lv_genjiUnit);
    lv_incomingDamage = EventUnitDamageAbsorbed();

    // Actions

mods/heromods/zarya.stormmodbase.stormdata/LibHZAR.galaxy:1045

    lv_zaryaUnit = EventUnitBehaviorCasterUnit();
    lv_zaryaPlayer = UnitGetOwner(lv_zaryaUnit);
    lv_damageAbsorbed = EventUnitDamageAbsorbed();
    lv_incomingBoost = lv_damageAbsorbed;

mods/starcoop/starcoop.sc2modbase.sc2data/LibCOMI.galaxy:18112

    }

    UnitSetPropertyFixed(EventUnit(), c_unitPropLife, (UnitGetPropertyFixed(EventUnit(), c_unitPropLife, c_unitPropCurrent) - (EventUnitDamageAbsorbed() / 2.0)));
    return true;
}

mods/starcoop/starcoop.sc2modbase.sc2data/LibCOOC.galaxy:6525

    }

    libCOOC_gv_cC_ScoreArtanisAbsorb[UnitGetOwner(EventUnit())] += EventUnitDamageAbsorbed();
    PlayerScoreValueSetFromInt(UnitGetOwner(EventUnit()), "ArtanisShieldAbsorb", FixedToInt(libCOOC_gv_cC_ScoreArtanisAbsorb[UnitGetOwner(EventUnit())]));
    if ((libCOOC_gf_ActiveCommanderForPlayer(UnitGetOwner(EventUnit())) != "ProtossArtanis")) {

mods/starcoop/starcoop.sc2modbase.sc2data/LibCOOC.galaxy:7494

    }

    libCOOC_gv_cC_ScoreNovaHeal[UnitGetOwner(EventUnit())] += EventUnitDamageAbsorbed();
    PlayerScoreValueSetFromInt(UnitGetOwner(EventUnit()), "NovaHealandAbsorb", FixedToInt(libCOOC_gv_cC_ScoreNovaHeal[UnitGetOwner(EventUnit())]));
    return true;

mods/starcoop/starcoop.sc2modbase.sc2data/LibCOOC.galaxy:8222

    }

    libCOOC_gv_cC_ScoreTychusMedicHeal[UnitGetOwner(EventUnit())] += EventUnitDamageAbsorbed();
    PlayerScoreValueSetFromInt(UnitGetOwner(EventUnit()), "TychusMedicHeal", FixedToInt(libCOOC_gv_cC_ScoreTychusMedicHeal[UnitGetOwner(EventUnit())]));
    return true;