Skip to main content

LerpModifier

A class in Root.Township, the global namespace.

Float modifier that maps its input from 0 to 1 onto a range between from and to.

Constructors​

MemberWhat it is
LerpModifier()Unity makes components itself; use AddComponent or spawn a prefab instead of new.

Fields​

2 private and internal fields
MemberWhat it is
private float fromOutput for an input of 0.
private float toOutput for an input of 1. Defaults to 10.

Methods​

MemberWhat it is
override void Input(float value)Outputs the value lerped between from and to. Inputs are clamped to 0 to 1.