PackagePBLabs.Rendering2D
Classpublic class BaseRenderComponent
InheritanceBaseRenderComponent Inheritance EntityComponent
ImplementsIDrawable2D
SubclassesBox2DDebugComponent, SimpleShapeRenderComponent, SpriteRenderComponent, SWFRenderComponent



Public Properties
 PropertyDefined by
 InheritedIsRegistered : Boolean
Whether or not the component is currently registered with an entity.
EntityComponent
  LayerIndex : int
Objects are sorted by layer, and this is the index of this object's layer.
BaseRenderComponent
 InheritedName : String
The name given to the component when it is added to an entity.
EntityComponent
 InheritedOwner : IEntity
A reference to the entity that this component currently belongs to.
EntityComponent
  PositionOffset : Point
An offset to apply to the position retrieved from the PositionReference.
BaseRenderComponent
  PositionReference : PropertyReference
A reference for the position property on the owner entity.
BaseRenderComponent
  RenderCacheKey : int
BaseRenderComponent
  RenderPosition : Point
[read-only] Report the center position of this object as used for rendering.
BaseRenderComponent
  RenderScale : Point
[read-only]
BaseRenderComponent
  RenderSortKey : int
Expose a sort key.
BaseRenderComponent
  RotationReference : PropertyReference
A reference for the rotation property on the owner entity.
BaseRenderComponent
  SizeReference : PropertyReference
A reference for the size property on the owner entity.
BaseRenderComponent
Public Methods
 MethodDefined by
  
BaseRenderComponent
  
OnDraw(manager:IDrawManager2D):void
Callback during rendering to give the object an opportunity to give the IDrawManager2D stuff to display.
BaseRenderComponent
 Inherited
Register(owner:IEntity, name:String):void
Registers the component with an entity.
EntityComponent
 Inherited
Reset():void
This is called by an entity on all of its components any time a component is added or removed.
EntityComponent
 Inherited
Unregister():void
Unregisters the component from an entity.
EntityComponent
Protected Methods
 MethodDefined by
 Inherited
_OnAdd():void
This is called when the component is added to an entity.
EntityComponent
 Inherited
_OnRemove():void
This is called when the component is removed from an entity.
EntityComponent
 Inherited
_OnReset():void
This is called anytime a component is added or removed from the owner entity.
EntityComponent
Property detail
LayerIndexproperty
LayerIndex:int  [read-write]

Objects are sorted by layer, and this is the index of this object's layer.

Implementation
    public function get LayerIndex():int
    public function set LayerIndex(value:int):void
PositionOffsetproperty 
public var PositionOffset:Point

An offset to apply to the position retrieved from the PositionReference.

PositionReferenceproperty 
public var PositionReference:PropertyReference

A reference for the position property on the owner entity. This should be a point.

RenderCacheKeyproperty 
RenderCacheKey:int  [read-write]Implementation
    public function get RenderCacheKey():int
    public function set RenderCacheKey(value:int):void
RenderPositionproperty 
RenderPosition:Point  [read-only]

Report the center position of this object as used for rendering.

Implementation
    public function get RenderPosition():Point
RenderScaleproperty 
RenderScale:Point  [read-only]Implementation
    public function get RenderScale():Point
RenderSortKeyproperty 
RenderSortKey:int  [read-write]

Expose a sort key. This integer is used for general sorting logic.

Implementation
    public function get RenderSortKey():int
    public function set RenderSortKey(value:int):void
RotationReferenceproperty 
public var RotationReference:PropertyReference

A reference for the rotation property on the owner entity. This should be a Number.

SizeReferenceproperty 
public var SizeReference:PropertyReference

A reference for the size property on the owner entity. This should be a point.

Method detail
InvalidateRenderCache()method
public function InvalidateRenderCache():void
OnDraw()method 
public function OnDraw(manager:IDrawManager2D):void

Callback during rendering to give the object an opportunity to give the IDrawManager2D stuff to display.

Parameters
manager:IDrawManager2D