Skip to content

ConveyorCell

namespace Griff.Scenes;
public struct ConveyorCell

One cell of a Conveyor: its column and row (counted as a tilemap’s are, row 0 at the top), the way it carries (x right, y up, as a grid mover steps) and what it is.

public ValueTuple<int, int> Cell { get; }

Its column and row.

public ConveyorCellKind Kind { get; init; }
public ValueTuple<int, int> Next { get; }

The cell it carries into (rows count down, so up is the row above).

public float Speed { get; init; }

Cells a second it carries items at, for a slow chute or a fast belt in the same line; 0 (the default) for the conveyor’s Speed.

public ValueTuple<int, int> Way { get; }

The way it carries: (1, 0) right, (0, 1) up, (-1, 0) left, (0, -1) down.

public int WayX { get; init; }
public int WayY { get; init; }
public int X { get; init; }
public int Y { get; init; }
public void Deconstruct(out int X, out int Y, out int WayX, out int WayY, out ConveyorCellKind Kind)
public override bool Equals(object obj)
public bool Equals(ConveyorCell other)
public override int GetHashCode()
public override string ToString()