Skip to content

MaterialRef

public sealed class MaterialRef

Namespace MapExpansions

A material taken from a renderer of one of the worlds, matched by name.

public WorldSide Side { get; set; }

Type: WorldSide

public string Renderer { get; set; }

Renderer name, compared case-insensitively from the start.

public string Parent { get; set; }

When set, some ancestor’s name starts with this.

public int Slot { get; set; }

Material slot of the renderer.

public Color Fallback { get; set; }

Colour of the plain material used when the renderer is not found.

public float Tiling { get; set; }

Metres of surface one texture repeat covers along and across the road.

public static MaterialRef From(
WorldSide side,
string renderer,
string parent = null,
int slot = 0)

Types: WorldSide

public MaterialRef Tiled(float metres)
public MaterialRef Or(Color fallback)
public override string ToString()