Table of Contents

Class PolarTileGridBuilder<TPoint>

Namespace
Gamelogic.Grids
Assembly
Assembly-CSharp.dll

Base class for polar tile grid builders.

[Version(1, 8, 0)]
public abstract class PolarTileGridBuilder<TPoint> : GridBuilder<TPoint>, ITileGrid<TPoint>, IGridBuilderBase, IGLScriptableObject where TPoint : IGridPoint<TPoint>

Type Parameters

TPoint
Inheritance
GridBuilder<TPoint>
PolarTileGridBuilder<TPoint>
Implements
ITileGrid<TPoint>
Derived
Inherited Members
MonoBehaviour.IsInvoking()
MonoBehaviour.StopCoroutine(Coroutine)
MonoBehaviour.StopAllCoroutines()
MonoBehaviour.runInEditMode
Component.GetComponent<T>()
Component.GetComponentInChildren<T>()
Component.GetComponentsInChildren<T>()
Component.GetComponentsInParent<T>()
Component.transform
Component.gameObject
Component.tag
Object.Instantiate(Object, Vector3, Quaternion)
Object.Instantiate(Object)
Object.Instantiate(Object, Transform)
Object.Instantiate<T>(T, Vector3, Quaternion, Transform)
Object.Instantiate<T>(T, Transform)
Object.Destroy(Object)
Object.DestroyImmediate(Object)
Object.DestroyObject(Object)
Object.FindObjectsOfType<T>()
Object.name
Object.hideFlags
Extension Methods

Fields

alignment

[SerializeField]
[Tooltip("How the anchor of the grid lies relative to the grid.")]
protected MapAlignment alignment

Field Value

MapAlignment

cellPrefab

[SerializeField]
[Tooltip("The object that will be used to display each cell.")]
protected MeshTileCell cellPrefab

Field Value

MeshTileCell

cellSpacingFactor

[SerializeField]
[Tooltip("A factor that controls the spacing between cells.")]
protected float cellSpacingFactor

Field Value

float

colorFunction

[SerializeField]
[Tooltip("The color function to use to color cells.")]
protected ColorFunction colorFunction

Field Value

ColorFunction

colors

[SerializeField]
[Tooltip("The DefaultColors to use to color cells.")]
protected Color[] colors

Field Value

Color[]

dimensions

[SerializeField]
[Tooltip("The width and height of your shape (in cells).")]
protected InspectableVectorPoint dimensions

Field Value

InspectableVectorPoint

plane

[SerializeField]
[Tooltip("The 2D plane in which your grid will lie.")]
protected MapPlane plane

Field Value

MapPlane

polarGridProperties

[SerializeField]
public PolarGridProperties polarGridProperties

Field Value

PolarGridProperties

polarMap

protected IPolarMap<TPoint> polarMap

Field Value

IPolarMap<TPoint>

size

[SerializeField]
[Tooltip("The size of your shape (in cells).")]
protected int size

Field Value

int

useColor

[SerializeField]
[Tooltip("Whether to set cells DefaultColors")]
protected bool useColor

Field Value

bool

Properties

Alignment

public MapAlignment Alignment { get; set; }

Property Value

MapAlignment

CellPrefab

Returns the cell prefab this builder uses to build the grid.

public MeshTileCell CellPrefab { get; set; }

Property Value

MeshTileCell

CellSpacingFactor

public float CellSpacingFactor { get; set; }

Property Value

float

ColorFunction

public ColorFunction ColorFunction { get; set; }

Property Value

ColorFunction

Colors

public Color[] Colors { get; set; }

Property Value

Color[]

Dimensions

Returns the dimensions for this grid if it makes sense for the current shape.

(The dimension field is hidden in the inspector if it does not make sense).

public VectorPoint Dimensions { get; set; }

Property Value

VectorPoint

Grid

public IGrid<TileCell, TPoint> Grid { get; protected set; }

Property Value

IGrid<TileCell, TPoint>

Map

public IMap3D<TPoint> Map { get; protected set; }

Property Value

IMap3D<TPoint>

Plane

public MapPlane Plane { get; set; }

Property Value

MapPlane

Size

Returns the size for this grid if it makes sense for the current shape. (The dimension field is hidden in the inspector if it does not make sense).

public int Size { get; set; }

Property Value

int

UseColor

public bool UseColor { get; set; }

Property Value

bool

Methods

CreatePolarMap()

protected abstract IPolarMap<TPoint> CreatePolarMap()

Returns

IPolarMap<TPoint>

GetColorFunc(int, int, int)

protected abstract Func<TPoint, int> GetColorFunc(int x0, int x1, int y1)

Parameters

x0 int
x1 int
y1 int

Returns

Func<TPoint, int>

InitGrid()

protected abstract void InitGrid()

Start()

public void Start()

__UpdatePresentation(bool)

public void __UpdatePresentation(bool forceUpdate)

Parameters

forceUpdate bool