/// <inheritdoc /> public override bool ApplyToCell(ColoredGlyph cell, EffectsManager.ColoredGlyphState originalState) { Color oldForeground = cell.Foreground; Color oldBackground = cell.Background; if (FadeForeground) { if (UseCellForeground) { DestinationForeground.Stops[UseCellDestinationReverse ? DestinationForeground.Stops.Length - 1 : 0].Color = originalState.Foreground; } cell.Foreground = DestinationForeground.Lerp((float)_calculatedValue); } if (FadeBackground) { if (UseCellBackground) { DestinationBackground.Stops[UseCellDestinationReverse ? DestinationBackground.Stops.Length - 1 : 0].Color = originalState.Background; } cell.Background = DestinationBackground.Lerp((float)_calculatedValue); } return(oldForeground != cell.Foreground || oldBackground != cell.Background); }
/// <inheritdoc /> public override bool ApplyToCell(ColoredGlyph cell, EffectsManager.ColoredGlyphState originalState) { if (_activeEffect != null) { return(_activeEffect.ApplyToCell(cell, originalState)); } else { return(false); } }
/// <inheritdoc /> public override bool ApplyToCell(ColoredGlyph cell, EffectsManager.ColoredGlyphState originalState) { int oldGlyph = cell.Glyph; if (!_isOn) { cell.Glyph = GlyphIndex; } else { cell.Glyph = originalState.Glyph; } return(cell.Glyph != oldGlyph); }
/// <inheritdoc /> public override bool ApplyToCell(ColoredGlyph cell, EffectsManager.ColoredGlyphState originalState) { Color oldForeground = cell.Foreground; Color oldBackground = cell.Background; if (DoBackground) { cell.Background = Background; } if (DoForeground) { cell.Foreground = Foreground; } return(oldForeground != cell.Foreground || oldBackground != cell.Background); }
/// <inheritdoc /> public override bool ApplyToCell(ColoredGlyph cell, EffectsManager.ColoredGlyphState originalState) { Color oldColor = cell.Foreground; if (!_isOn) { if (UseCellBackgroundColor) { cell.Foreground = originalState.Background; } else { cell.Foreground = BlinkOutColor; } } else { cell.Foreground = originalState.Foreground; } return(cell.Foreground != oldColor); }
/// <inheritdoc /> public override bool ApplyToCell(ColoredGlyph cell, EffectsManager.ColoredGlyphState state) => false;