PathModelDisplay
A class in Root.Township, the global namespace.
Skill shrine visualizer that shows a profession path's 3D model with a dissolve-in cone effect. Client-side; it does nothing on a headless server.
- Listed in Global namespace: P
- Inherits or implements
SkillShrineVisualizer
Constructors
| Member | What it is |
|---|---|
PathModelDisplay() | Unity makes components itself; use AddComponent or spawn a prefab instead of new. |
Fields
11 private and internal fields
| Member | What it is |
|---|---|
private readonly int _Progress | Shader property ID for the dissolve progress. |
private DurationCurve animationSettings | Duration and curve of the show and hide animation. |
private Material baseMaterial | Material copied onto the path model. |
private Material coneMaterial | Copied material on the cone renderer. |
private Renderer coneRenderer | The spawned cone renderer. |
private Transform coneRendererParent | Where the cone is spawned. |
private Renderer coneRendererPrefab | Prefab for the cone renderer. |
private ProgressionPath currentlyOpenPath | The path whose model is shown. |
private bool isOpen | True while a model is shown. |
private GameObject model | The spawned path model. |
private Material modelMaterial | Copied material on the path model. |
Methods
| Member | What it is |
|---|---|
override void Disable() | Client: plays the hide animation and marks the display closed. |
override void PrepareOnServer(PlayerProgressionManager progressionManager) | Shows the model on a host that isn't headless. |
override void Serialize(Stream stream, PlayerProgressionManager manager) | Shows the model when a remote client reads the shrine's state. |
2 private and internal methods
| Member | What it is |
|---|---|
private IEnumerator Animate(bool isStarting) (iterator) | Coroutine that animates _Progress on the model and cone materials in or out, destroying the model when hiding. |
private void InstantiateModel(ProgressionPath newPath) | Client: spawns the path's model from its profession tree with a copied material, then animates it in. |