Skip to content

ColoredGlyphState Struct

A ColoredGlyphBase with state information.

C#
public readonly struct ColoredGlyphState

Creates a new state from a cell.

C#
public ColoredGlyphState(ColoredGlyphBase cell)

cell ColoredGlyphBase
The colored glyph this state is a copy of.

ColoredGlyphState(CellDecorator[], Color, Color, int, Mirror, bool)

Section titled “ColoredGlyphState(CellDecorator[], Color, Color, int, Mirror, bool)”

Creates a new state.

C#
[JsonConstructor]
public ColoredGlyphState(CellDecorator[] decorators, Color foreground, Color background, int glyph, Mirror mirror, bool isVisible)

decorators CellDecorator[]
Decorators for the cell.

foreground SadRogue.Primitives.Color
Foreground color.

background SadRogue.Primitives.Color
Background color.

glyph int
The glyph index.

mirror Mirror
The mirror effect.

isVisible bool
The visibility of the glyph.

A copy of the Decorators property.

C#
public CellDecorator[] Decorators { get; }

A copy of the Foreground property.

C#
public Color Foreground { get; }

A copy of the Background property.

C#
public Color Background { get; }

A copy of the Glyph property.

C#
public int Glyph { get; }

A copy of the Mirror property.

C#
public Mirror Mirror { get; }

A copy of the IsVisible property.

C#
public bool IsVisible { get; }

Restores this state to the specified cell.

C#
public void RestoreState(ref ColoredGlyphBase cell)

cell ColoredGlyphBase