AssetPart

References
public sealed class AssetPart
A monotone part of an asset.

Constructors

AssetPart

#
public AssetPart(AssetMesh mesh, string name, AssetSeason season, params (AssetColour colour, int luminance)[] colours)
Create a new partial asset.
mesh (AssetMesh)Asset mesh.
name (string)Asset name.
season (AssetSeason)Asset season.
colours (params (AssetColour colour, int luminance)[])One or more luminance adjusted colours (-10 to +10).

AssetPart

#
public AssetPart(AssetMesh mesh, string name, AssetSeason season, params AssetColour[] colours)
Create a new partial asset.
mesh (AssetMesh)Asset mesh.
name (string)Asset name.
season (AssetSeason)Asset season.
colours (params AssetColour[])One or more asset colours.

AssetPart

#
public AssetPart(AssetMesh mesh, string name, AssetSeason season, params Color[] colours)
Create a new partial asset.
mesh (AssetMesh)Asset mesh.
name (string)Asset name.
season (AssetSeason)Asset season.
colours (params Color[])One or more asset colours.

AssetPart

#
public AssetPart(BinaryReader reader)
Deserialise this partial asset from a reader.
reader (BinaryReader)

Properties

Colours

#
public Color[] Colours { get; }
(Potentially unresolved) colours for this part.

Mesh

#
public AssetMesh Mesh { get; }
Low polygon mesh of this part.

Name

#
public string Name { get; }
Name of this part.

Season

#
public AssetSeason Season { get; }
Seasons for which this part is relevant.

Methods

WithColour

#
public AssetPart WithColour(Color[] newColours)
Modify the colours of this part.
newColours (Color[])

WithName

#
public AssetPart WithName(string newName)
Modify the name of this part.
newName (string)

WithSeason

#
public AssetPart WithSeason(AssetSeason newSeason)
Modify the season of this part.
newSeason (AssetSeason)

Write

#
public void Write(BinaryWriter writer)
Serialise this partial asset to a writer.
writer (BinaryWriter)