Packagecom.kraftner.justlineon.pointtransformers
Classpublic class PointPlusRandom
InheritancePointPlusRandom Inheritance PointTransformer

This PointTransformer changes the original coordinate as created by a LineServer in a certain range.

If you want to add or substract a certain factor from the original set x1=x2 and/or y1=y2. This can be useful when moving the path from a PathPlayer class by a certain factor.

See also

com.kraftner.justlineon.lineservers.PathPlayer


Public Methods
 MethodDefined by
  
PointPlusRandom(x1:Number, x2:Number, y1:Number, y2:Number)
PointPlusRandom
  
transform(s:Segment):Boolean
Transforms the coordinates of the original Segment
PointPlusRandom
Constructor detail
PointPlusRandom()constructor
public function PointPlusRandom(x1:Number, x2:Number, y1:Number, y2:Number)

Parameters
x1:Number — Minimum to add to the original x-coordinate
 
x2:Number — Maximum to add to the original x-coordinate
 
y1:Number — Minimum to add to the original y-coordinate
 
y2:Number — Maximum to add to the original y-coordinate
Method detail
transform()method
public override function transform(s:Segment):Boolean

Transforms the coordinates of the original Segment

Parameters
s:Segment

Returns
Boolean