Packageaway3d.controllers
Classpublic class FirstPersonController
InheritanceFirstPersonController Inheritance ControllerBase Inheritance Object

Extended camera used to hover round a specified target object.

See also

away3d.containers.View3D


Public Properties
 PropertyDefined By
 InheritedautoUpdate : Boolean
Determines whether the controller applies updates automatically.
ControllerBase
  maxTiltAngle : Number
Maximum bounds for the tiltAngle.
FirstPersonController
  minTiltAngle : Number
Minimum bounds for the tiltAngle.
FirstPersonController
  panAngle : Number
Rotation of the camera in degrees around the y axis.
FirstPersonController
  steps : uint
Fractional step taken each time the hover() method is called.
FirstPersonController
 InheritedtargetObject : Entity
Target object on which the controller acts.
ControllerBase
  tiltAngle : Number
Elevation angle of the camera in degrees.
FirstPersonController
Protected Properties
 PropertyDefined By
 Inherited_autoUpdate : Boolean = true
ControllerBase
 Inherited_targetObject : Entity
ControllerBase
Public Methods
 MethodDefined By
  
FirstPersonController(targetObject:Entity = null, panAngle:Number = 0, tiltAngle:Number = 90, minTiltAngle:Number = -90, maxTiltAngle:Number = 90, steps:uint = 8)
Creates a new HoverController object.
FirstPersonController
  
incrementStrafe(val:Number):void
FirstPersonController
  
incrementWalk(val:Number):void
FirstPersonController
  
update():void
[override] Updates the current tilt angle and pan angle values.
FirstPersonController
Protected Methods
 MethodDefined By
 Inherited
ControllerBase
Property Detail
_currentPanAngleproperty
arcane var _currentPanAngle:Number = 0

_currentTiltAngleproperty 
arcane var _currentTiltAngle:Number = 90

maxTiltAngleproperty 
maxTiltAngle:Number

Maximum bounds for the tiltAngle. Defaults to 90.


Implementation
    public function get maxTiltAngle():Number
    public function set maxTiltAngle(value:Number):void

See also

minTiltAngleproperty 
minTiltAngle:Number

Minimum bounds for the tiltAngle. Defaults to -90.


Implementation
    public function get minTiltAngle():Number
    public function set minTiltAngle(value:Number):void

See also

panAngleproperty 
panAngle:Number

Rotation of the camera in degrees around the y axis. Defaults to 0.


Implementation
    public function get panAngle():Number
    public function set panAngle(value:Number):void
stepsproperty 
steps:uint

Fractional step taken each time the hover() method is called. Defaults to 8. Affects the speed at which the tiltAngle and panAngle resolve to their targets.


Implementation
    public function get steps():uint
    public function set steps(value:uint):void

See also

tiltAngleproperty 
tiltAngle:Number

Elevation angle of the camera in degrees. Defaults to 90.


Implementation
    public function get tiltAngle():Number
    public function set tiltAngle(value:Number):void
Constructor Detail
FirstPersonController()Constructor
public function FirstPersonController(targetObject:Entity = null, panAngle:Number = 0, tiltAngle:Number = 90, minTiltAngle:Number = -90, maxTiltAngle:Number = 90, steps:uint = 8)

Creates a new HoverController object.

Parameters
targetObject:Entity (default = null)
 
panAngle:Number (default = 0)
 
tiltAngle:Number (default = 90)
 
minTiltAngle:Number (default = -90)
 
maxTiltAngle:Number (default = 90)
 
steps:uint (default = 8)
Method Detail
incrementStrafe()method
public function incrementStrafe(val:Number):void

Parameters

val:Number

incrementWalk()method 
public function incrementWalk(val:Number):void

Parameters

val:Number

update()method 
override public function update():void

Updates the current tilt angle and pan angle values. Values are calculated using the defined tiltAngle, panAngle and steps variables.

See also