GeneratablePart
An abstract class in Root.Township, the global namespace.
Base for parts of a GenerationCore (a procedurally placed static piece) that adjust or add to it when it generates, such as aligning to a path or the terrain slope.
- Listed in Global namespace: E to H
- Inherits or implements
MonoBehaviour - Derived types
AlignWithPath,AlignWithPathSlope,AlignWithTerrainSlope,DynamicPathPart,LinearPartClonerPart,LinkerPart,PathEndsPart,PointTowardsEachotherPart,RandomRotation3d,RandomRotationPart,SignPointPart,SnapToTerrain,SpawnerPart,TerrainOffsetPart,TerrainSplatPart,TerrainSpline
Constructors
| Member | What it is |
|---|---|
protected GeneratablePart() | Unity makes components itself; use AddComponent or spawn a prefab instead of new. |
Methods
| Member | What it is |
|---|---|
virtual void GenerateDynamic(GenerationCore core) | Called after GenerateStatic, only when the spawn data is generating (first time). Use it to make saved, dynamic content. |
virtual void GenerateStatic(GenerationCore core, bool isModifyingTerrain) | Called every time the piece generates, with whether terrain may be changed. Use it for the parts rebuilt on each load. |
Used in
Members of other types that take, return or hold a GeneratablePart: