# Set Fog of War Alpha

FlagsNative | Action

Override a player’s Fog of War transparency level. (0 = transparent, 100 = opaque)

# Arguments

  • int — Player
  • fixed — Alpha

Returns — void

native void VisSetFoWAlpha(int player, fixed alpha);

Category: Visibility / Basic

# Examples

campaigns/voidstory.sc2campaignbase.sc2data/TriggerLibs/VoidCampaignMissionLib.galaxy:711

        Wait(lv_incrementFrequency, c_timeGame);
        lv_currentAlpha += lv_alphaIncrement;
        VisSetFoWAlpha(1, lv_currentAlpha);
    }
    VisSetFoWAlpha(1, lp_targetAlpha);

campaigns/voidstory.sc2campaignbase.sc2data/TriggerLibs/VoidCampaignMissionLib.galaxy:713

        VisSetFoWAlpha(1, lv_currentAlpha);
    }
    VisSetFoWAlpha(1, lp_targetAlpha);
    return true;
}

campaigns/voidstory.sc2campaignbase.sc2data/TriggerLibs/VoidCampaignMissionLib.galaxy:753

    lv_increments = AbsI(FixedToInt((lp_duration / lv_incrementFrequency)));
    lv_alphaIncrement = ((lv_targetAlpha-lv_currentAlpha)/IntToFixed(lv_increments));
    VisSetFoWAlpha(1, lv_currentAlpha);
    auto30DD2C34_n = lv_increments;
    for (auto30DD2C34_i = 1; auto30DD2C34_i <= auto30DD2C34_n; auto30DD2C34_i += 1) {

campaigns/voidstory.sc2campaignbase.sc2data/TriggerLibs/VoidCampaignMissionLib.galaxy:758

        Wait(lv_incrementFrequency, c_timeGame);
        lv_currentAlpha += lv_alphaIncrement;
        VisSetFoWAlpha(1, lv_currentAlpha);
    }
    VisResetFoWAlpha(1);

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

        Wait(lv_incrementFrequency, c_timeGame);
        lv_currentAlpha += lv_alphaIncrement;
        VisSetFoWAlpha(lp_player, lv_currentAlpha);
    }
    VisSetFoWAlpha(lp_player, lp_targetAlpha);

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

        VisSetFoWAlpha(lp_player, lv_currentAlpha);
    }
    VisSetFoWAlpha(lp_player, lp_targetAlpha);
    return true;
}

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

    lv_increments = AbsI(FixedToInt((lp_duration / lv_incrementFrequency)));
    lv_alphaIncrement = ((lv_targetAlpha-lv_currentAlpha)/IntToFixed(lv_increments));
    VisSetFoWAlpha(lp_player, lv_currentAlpha);
    auto26F5891F_n = lv_increments;
    for (auto26F5891F_i = 1; auto26F5891F_i <= auto26F5891F_n; auto26F5891F_i += 1) {

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

        Wait(lv_incrementFrequency, c_timeGame);
        lv_currentAlpha += lv_alphaIncrement;
        VisSetFoWAlpha(lp_player, lv_currentAlpha);
    }
    VisResetFoWAlpha(lp_player);

mods/starcoop/starcoop.sc2modbase.sc2data/LibCOMU.galaxy:6163

        lv_indexPlayer = PlayerGroupNextPlayer(autoE7520291_g, lv_indexPlayer);
        if (lv_indexPlayer < 0) { break; }
        VisSetFoWAlpha(lv_indexPlayer, 100.0);
    }
    auto21312E9A_g = PlayerGroupAll();