Class PaintCellItemUserToolStateBase<TBrushTarget, TTerrainLayer, TChunkMeshLayerGroup, TChunkMeshLayer>
Inheritance
PaintCellItemUserToolStateBase<TBrushTarget, TTerrainLayer, TChunkMeshLayerGroup, TChunkMeshLayer>
Assembly: fwt.hexterrains.dll
public abstract class PaintCellItemUserToolStateBase<TBrushTarget, TTerrainLayer, TChunkMeshLayerGroup, TChunkMeshLayer> : BrushUserToolState<TBrushTarget, UserToolSettingsDataSource, UniversalToolSettingsScreen, TTerrainLayer>, ISmState where TBrushTarget : HexTerrainLayerGroup where TTerrainLayer : CellItemLayer where TChunkMeshLayerGroup : HexTerrainLayerGroup, IComponentData where TChunkMeshLayer : ChunkMeshLayer
Type Parameters
| Name |
Description |
| TBrushTarget |
|
| TTerrainLayer |
|
| TChunkMeshLayerGroup |
|
| TChunkMeshLayer |
|
Constructors
Declaration
public PaintCellItemUserToolStateBase(ISmState parent)
Parameters
Fields
Declaration
public KeyCode ReadCellKey
Field Value
Properties
Declaration
public virtual int ChunkMeshLayerIndex { get; set; }
Property Value
Declaration
public virtual HexTerrainLayerReference ChunkMeshLayerReference { get; }
Property Value
Declaration
public virtual int DataSourceItemsCount { get; }
Property Value
Declaration
public bool IsCheckBiome { get; set; }
Property Value
Declaration
public bool IsCheckCellHeight { get; set; }
Property Value
Declaration
public int MaxBiomeIndex { get; set; }
Property Value
Declaration
public float MaxCellHeight { get; set; }
Property Value
Declaration
public int MinBiomeIndex { get; set; }
Property Value
Declaration
public float MinCellHeight { get; set; }
Property Value
If IsGetLayerByIndex is true, this index is used to get terrain layer from terrain layers list."/>
Declaration
public override int TerrainLayerIndex { get; set; }
Property Value
Overrides
Methods
Declaration
protected virtual int? GetCellBiome(int cellIndex)
Parameters
| Type |
Name |
Description |
| int |
cellIndex |
|
Returns
Declaration
protected virtual float? GetCellHeight(int cellIndex)
Parameters
| Type |
Name |
Description |
| int |
cellIndex |
|
Returns
Initializes the tool state with the specified settings.
Declaration
public override void Init(UserToolStateSettings settings)
Parameters
| Type |
Name |
Description |
| UserToolStateSettings |
settings |
The settings to apply to the tool state. Cannot be null.
|
Overrides
Initializes the default settings for the current instance. This method is intended to be overridden in
derived classes to configure initial values or options as needed.
Declaration
protected override void InitDefaultSettings()
Overrides
Initializes the tool using the specified initialization arguments.
Declaration
public override void Init<TInitArgs>(TInitArgs args)
Parameters
| Type |
Name |
Description |
| TInitArgs |
args |
The initialization arguments used to configure the tool. If the argument implements IUserToolStateConfig,
its ToolSettings are used; otherwise, default settings are applied.
|
Type Parameters
| Name |
Description |
| TInitArgs |
The type of the initialization arguments used to configure the tool. If the type implements
IUserToolStateConfig, its ToolSettings will be used; otherwise, default settings are applied.
|
Overrides
Determines whether the specified brush mode applies to every cell on the map.
Declaration
public override bool IsAppliedToEveryCellOnMap(int brushMode)
Parameters
| Type |
Name |
Description |
| int |
brushMode |
The brush mode to evaluate. Typically, a value of 1 indicates that the brush is applied to all cells.
|
Returns
| Type |
Description |
| bool |
true if the brush mode applies to every cell on the map; otherwise, false.
|
Overrides
Declaration
protected virtual bool? IsValidCellToPaint(int cellIndex)
Parameters
| Type |
Name |
Description |
| int |
cellIndex |
|
Returns
Loads configuration settings for the current instance. Derived classes override this method to implement
custom settings initialization.
Declaration
protected override void LoadSettings()
Overrides
Saves the current settings to the underlying storage or configuration source.
Declaration
protected override void SaveSettings()
Overrides
Implements
Extension Methods