Packagecom.kraftner.justlineon.lineservers
Classpublic class LineServer
InheritanceLineServer Inheritance flash.display.Sprite
SubclassesAlwaysTurn, AlwaysTurnImplosion, CircularExplosion, CircularImplosion, PathPlayer

Template for all kinds of LineServers

This Class defines the base functionality of all LineServers. It doesn't create any path on it's own but uses the mousePosition instead.



Public Properties
 PropertyDefined by
  isAlive : Boolean
[read-only] true if this LineServer is active
LineServer
Protected Properties
 PropertyDefined by
  counter : uint = 0
Counts the number of Segments already drawn
LineServer
  initial_angle : Number = 0
LineServer
  initial_length : Number = 0
LineServer
  initial_rel_x : Number = 0
LineServer
  initial_rel_y : Number = 0
LineServer
  initial_x : Number = 0
LineServer
  initial_y : Number = 0
LineServer
  killme : Boolean = false
Stores if this Lineserver is active or not.
LineServer
  newSegment : Segment
[read-only] This method defines the new Segment.
LineServer
  prev_Segment : Segment
LineServer
Public Methods
 MethodDefined by
  
LineServer
  
addPainter(painter:Painter):void
Adds a Painter to this LineServer
LineServer
  
addPointTransformer(pointTransformer:PointTransformer):void
Adds a PointTransformer to this LineServer
LineServer
  
destroy():void
Contains Code to be executed when this LineServer is destroyed.
LineServer
  
dump():void
Dumps the content of all Painters in this LineServer to a Bitmap.
LineServer
  
step():Boolean
This method is called by the main application to trigger a new Segment.
LineServer
Property detail
counterproperty
protected var counter:uint = 0

Counts the number of Segments already drawn

initial_angleproperty 
protected var initial_angle:Number = 0
initial_lengthproperty 
protected var initial_length:Number = 0
initial_rel_xproperty 
protected var initial_rel_x:Number = 0
initial_rel_yproperty 
protected var initial_rel_y:Number = 0
initial_xproperty 
protected var initial_x:Number = 0
initial_yproperty 
protected var initial_y:Number = 0
isAliveproperty 
isAlive:Boolean  [read-only]

true if this LineServer is active

Implementation
    public function get isAlive():Boolean

See also

killmeproperty 
protected var killme:Boolean = false

Stores if this Lineserver is active or not.

See also

com.kraftner.justlineon.JustLineOn.step()
newSegmentproperty 
newSegment:Segment  [read-only]

This method defines the new Segment. It should be overwritten if you subclass your own LineServer.

Implementation
    protected function get newSegment():Segment
prev_Segmentproperty 
protected var prev_Segment:Segment
Constructor detail
LineServer()constructor
public function LineServer()
Method detail
addPainter()method
public function addPainter(painter:Painter):void

Adds a Painter to this LineServer

Parameters
painter:Painter — Painter to add to this LineServer
addPointTransformer()method 
public function addPointTransformer(pointTransformer:PointTransformer):void

Adds a PointTransformer to this LineServer

Parameters
pointTransformer:PointTransformer — PointTransformer to add to this LineServer
destroy()method 
public function destroy():void

Contains Code to be executed when this LineServer is destroyed. Use this to destroy all kinds of Listeners and other dependencies. Should be overwritten in Subclasses.

dump()method 
public function dump():void

Dumps the content of all Painters in this LineServer to a Bitmap. This makes Vector export impossible but improves performance.

step()method 
public function step():Boolean

This method is called by the main application to trigger a new Segment.

Returns
Boolean — true if this LineServer is deactivated

See also

com.kraftner.justlineon.JustLineOn.step()