camera

From Teverse


Properties

fov

Type: number

position

Type: vector3

className [readonly]

Type: string

name [readonly]

Type: string

rotation

Type: quaternion

Inherited from baseClass:

name

Type: string
A none unique identifier

className [readonly]

Type: string
The name of the object's class

Methods

worldToScreen

boolean, vector2, number camera:worldToScreen(vector3 position)
Converts a 3d cooridinate into screenspace. Returns a bool indicating if the point is infront of the camera, returns a vector2 with the screenspace coordinates,

lookAt

nil camera:lookAt(vector3 position)
Changes the objects rotation so that it is looking towards the provided position.

Inherited from baseClass:

getDescendants

table camera:getDescendants()
Returns a table of all descended objects

isContainer

boolean camera:isContainer()

isA

boolean camera:isA(string className)
Returns true if this object is derived from the className given.

destroy

nil camera:destroy()
Locks the object before removing it from the hierarchy. Children will also be destroyed.

getFullName

string camera:getFullName()
Returns a string including ancestor names

constructor

nil camera:constructor()

destroyAllChildren

nil camera:destroyAllChildren()
Invokes the destroy method on each child of this instance.

hasChild

boolean camera:hasChild(string name)
Returns true if this object has a child with the name given

isDescendantOf

boolean camera:isDescendantOf(baseClass ancestor)
Returns true if this object is a descendant of the ancestor object given

describe

nil camera:describe()

clone

variant camera:clone()
Creates and returns a copy of this object

Events

Inherited from baseClass:

changed

eventListener camera:changed(function(string propertyName, variant newValuevariant))
Fired when a property changes

childAdded

eventListener camera:childAdded(function(baseClass child))
Fired when a child is added

childRemoved

eventListener camera:childRemoved(function(baseClass child))
Fired when a child is removed

destroying

eventListener camera:destroying(function())
Fired just before an object is destroyed.

Sub classes

Category derivedFromcamera not found