Show / Hide Table of Contents

Class WallPropPositioner

Finds an appropriate position and rotation for objects that replace billboard wall props such as torches.

Inheritance
Object
Object
Component
Behaviour
MonoBehaviour
ObjectPositioner
WallPropPositioner
Implements
IObjectPositioner
Inherited Members
ObjectPositioner.maxDistance
ObjectPositioner.Direction
ObjectPositioner.Renderer
ObjectPositioner.Move(Vector3)
Namespace: DaggerfallWorkshop.Utility.AssetInjection
Assembly: Assembly-CSharp.dll
Syntax
[HelpURL("http://www.dfworkshop.net/projects/daggerfall-unity/modding/models-flats/#WallPropPositioner")]
public class WallPropPositioner : ObjectPositioner, IObjectPositioner
Remarks

This component performs three operations:

  1. Ensures the object faces the wall on the set direction and rotates if needed.
  2. Moves the object next to the wall or away from it if clipping.
  3. Aligns the object if wall is not perpendicular to the floor.

Properties

| Improve this Doc View Source

AllowFlatRotation

Always false because rotation is set for wall direction.

Declaration
public sealed override bool AllowFlatRotation { get; }
Property Value
Type Description
Boolean
Overrides
ObjectPositioner.AllowFlatRotation

Methods

| Improve this Doc View Source

Align(Vector3)

Calculates the angle with the wall and apply a corresponding rotation.

Declaration
protected void Align(Vector3 direction)
Parameters
Type Name Description
Vector3 direction

A normalized direction in local space.

| Improve this Doc View Source

PerformPositioning(Vector3)

Performs all positioning operations.

Declaration
protected override void PerformPositioning(Vector3 direction)
Parameters
Type Name Description
Vector3 direction

A normalized direction in local space.

Overrides
ObjectPositioner.PerformPositioning(Vector3)
| Improve this Doc View Source

Rotate(Vector3)

Rotates the object from the given direction to a collider found next to it.

Declaration
protected void Rotate(Vector3 from)
Parameters
Type Name Description
Vector3 from

A normalized direction in local space.

Implements

IObjectPositioner

Extension Methods

MBExtensions.Invoke(MonoBehaviour, Action, Single)
MBExtensions.Invoke<T>(MonoBehaviour, Action<T>, T, Single)
MBExtensions.Invoke<T1, T2>(MonoBehaviour, Action<T1, T2>, T1, T2, Single)
MBExtensions.Invoke<T1, T2, T3>(MonoBehaviour, Action<T1, T2, T3>, T1, T2, T3, Single)
MBExtensions.Invoke<T1, T2, T3, T4>(MonoBehaviour, Action<T1, T2, T3, T4>, T1, T2, T3, T4, Single)
  • Improve this Doc
  • View Source
In This Article
Back to top Generated by DocFX