Class TransformInterpolateTowardsObjectBlock
- Namespace
- LunyScript.Blocks /
- Assembly
- LunyScript.dll
Abstract base for Towards blocks whose target is an ILunyObject in the scene (Move and Rotate towards).
public abstract class TransformInterpolateTowardsObjectBlock : TransformInterpolateBlock, IScriptBlock
Expand Details ...
- Inheritance
-
ObjectTransformInterpolateTowardsObjectBlock
- Implements
- Derived
- Inherited Members
-
- TransformInterpolateBlock.Speed
- TransformInterpolateBlock.DeadZone
- TransformInterpolateBlock.AxisLock
- TransformInterpolateBlock.Responsiveness
- TransformInterpolateBlock.ComputeStep()
- TransformInterpolateBlock.TowardsToString()
- ActionBlock.IsNullOrEmpty(ActionBlock[])
- ActionBlock.Execute(IScriptRuntimeContext)
Constructors
TransformInterpolateTowardsObjectBlock(ILunyObject, Double, Double, LunyVector3, Double)
protected TransformInterpolateTowardsObjectBlock(ILunyObject target, Double speed, Double deadZone, LunyVector3 axisLock, Double responsiveness)
Parameters
| Type | Name | Description |
|---|---|---|
target |
||
speed |
||
deadZone |
||
axisLock |
||
responsiveness |
Fields
Target
protected readonly ILunyObject Target
Field Value
Methods
TowardsObjectToString()
protected String TowardsObjectToString()
Returns
- String
TryGetPositionDelta(IScriptRuntimeContext, out LunyVector3, out LunyVector3)
Computes the axis-masked position delta and masked target position. Returns false (and skips) when the distance is within the dead zone.
protected Boolean TryGetPositionDelta(IScriptRuntimeContext ctx, out LunyVector3 current, out LunyVector3 maskedTarget)
Parameters
| Type | Name | Description |
|---|---|---|
ctx |
||
current |
||
maskedTarget |
Returns
- Boolean
TryGetTargetRotation(IScriptRuntimeContext, out LunyQuaternion, out LunyQuaternion)
Computes the target rotation from the direction toward the target object. Returns false (and skips) when the direction is zero or the angle is within the dead zone.
protected Boolean TryGetTargetRotation(IScriptRuntimeContext ctx, out LunyQuaternion currentRotation, out LunyQuaternion targetRotation)
Parameters
| Type | Name | Description |
|---|---|---|
ctx |
||
currentRotation |
||
targetRotation |
Returns
- Boolean