LookAtWorldUp
Defines the world-up vector for the look-at calculation.
| Type | Name | Interface Description |
|---|---|---|
| Enum | ObjectX | • Function: Use the object's positive X-axis as the world up vector. |
| Enum | ObjectY | • Function: Use the object's positive Y-axis as the world up vector. |
| Enum | ObjectZ | • Function: Use the object's positive Z-axis as the world up vector. |
| Enum | SceneX | • Function: Use the scene's positive X-axis as the world up vector. |
| Enum | SceneY | • Function: Use the scene's positive Y-axis as the world up vector. |
| Enum | SceneZ | • Function: Use the scene's positive Z-axis as the world up vector. |
| Enum | TargetX | • Function: Use the target's positive X-axis as the world up vector. |
| Enum | TargetY | • Function: Use the target's positive Y-axis as the world up vector. |
| Enum | TargetZ | • Function: Use the target's positive Z-axis as the world up vector. |
Examples
ObjectX
let value = APJS.LookAtWorldUp.ObjectX;
ObjectY
let value = APJS.LookAtWorldUp.ObjectY;
ObjectZ
let value = APJS.LookAtWorldUp.ObjectZ;
SceneX
let value = APJS.LookAtWorldUp.SceneX;
SceneY
let value = APJS.LookAtWorldUp.SceneY;
SceneZ
let value = APJS.LookAtWorldUp.SceneZ;
TargetX
let value = APJS.LookAtWorldUp.TargetX;
TargetY
let value = APJS.LookAtWorldUp.TargetY;
TargetZ
let value = APJS.LookAtWorldUp.TargetZ;
Use Case
@component()
export class NewBehaviourScript extends APJS.BasicScriptComponent {
onStart() {
// TODO: instantiate / use LookAtWorldUp here
}
onUpdate(deltaTime: number) {
}
}