Section 1
//b2CircleDef (Box2D.Collision.Shapes.b2CircleDef)
package Box2D.Collision.Shapes {
import Box2D.Common.Math.*;
public class b2CircleDef extends b2ShapeDef {
public var radius:Number;
public var localPosition:b2Vec2;
public function b2CircleDef(){
localPosition = new b2Vec2(0, 0);
super();
type = b2Shape.e_circleShape;
radius = 1;
}
}
}//package Box2D.Collision.Shapes
Section 2
//b2CircleShape (Box2D.Collision.Shapes.b2CircleShape)
package Box2D.Collision.Shapes {
import Box2D.Dynamics.*;
import Box2D.Common.Math.*;
import Box2D.Collision.*;
import Box2D.Common.*;
public class b2CircleShape extends b2Shape {
public var m_localPosition:b2Vec2;
public var m_radius:Number;
public function b2CircleShape(_arg1:b2ShapeDef){
m_localPosition = new b2Vec2();
super(_arg1);
var _local2:b2CircleDef = (_arg1 as b2CircleDef);
m_type = e_circleShape;
m_localPosition.SetV(_local2.localPosition);
m_radius = _local2.radius;
}
override public function TestSegment(_arg1:b2XForm, _arg2:Array, _arg3:b2Vec2, _arg4:b2Segment, _arg5:Number):Boolean{
var _local10:Number;
var _local6:b2Mat22 = _arg1.R;
var _local7:Number = (_arg1.position.x + ((_local6.col1.x * m_localPosition.x) + (_local6.col2.x * m_localPosition.y)));
var _local8:Number = (_arg1.position.x + ((_local6.col1.y * m_localPosition.x) + (_local6.col2.y * m_localPosition.y)));
var _local9:Number = (_arg4.p1.x - _local7);
_local10 = (_arg4.p1.y - _local8);
var _local11:Number = (((_local9 * _local9) + (_local10 * _local10)) - (m_radius * m_radius));
if (_local11 < 0){
return (false);
};
var _local12:Number = (_arg4.p2.x - _arg4.p1.x);
var _local13:Number = (_arg4.p2.y - _arg4.p1.y);
var _local14:Number = ((_local9 * _local12) + (_local10 * _local13));
var _local15:Number = ((_local12 * _local12) + (_local13 * _local13));
var _local16:Number = ((_local14 * _local14) - (_local15 * _local11));
if ((((_local16 < 0)) || ((_local15 < Number.MIN_VALUE)))){
return (false);
};
var _local17:Number = -((_local14 + Math.sqrt(_local16)));
if ((((0 <= _local17)) && ((_local17 <= (_arg5 * _local15))))){
_local17 = (_local17 / _local15);
_arg2[0] = _local17;
_arg3.x = (_local9 + (_local17 * _local12));
_arg3.y = (_local10 + (_local17 * _local13));
_arg3.Normalize();
return (true);
};
return (false);
}
public function GetLocalPosition():b2Vec2{
return (m_localPosition);
}
public function GetRadius():Number{
return (m_radius);
}
override public function ComputeSweptAABB(_arg1:b2AABB, _arg2:b2XForm, _arg3:b2XForm):void{
var _local4:b2Mat22;
_local4 = _arg2.R;
var _local5:Number = (_arg2.position.x + ((_local4.col1.x * m_localPosition.x) + (_local4.col2.x * m_localPosition.y)));
var _local6:Number = (_arg2.position.y + ((_local4.col1.y * m_localPosition.x) + (_local4.col2.y * m_localPosition.y)));
_local4 = _arg3.R;
var _local7:Number = (_arg3.position.x + ((_local4.col1.x * m_localPosition.x) + (_local4.col2.x * m_localPosition.y)));
var _local8:Number = (_arg3.position.y + ((_local4.col1.y * m_localPosition.x) + (_local4.col2.y * m_localPosition.y)));
_arg1.lowerBound.Set((((_local5 < _local7)) ? _local5 : _local7 - m_radius), (((_local6 < _local8)) ? _local6 : _local8 - m_radius));
_arg1.upperBound.Set((((_local5 > _local7)) ? _local5 : _local7 + m_radius), (((_local6 > _local8)) ? _local6 : _local8 + m_radius));
}
override public function ComputeMass(_arg1:b2MassData):void{
_arg1.mass = (((m_density * b2Settings.b2_pi) * m_radius) * m_radius);
_arg1.center.SetV(m_localPosition);
_arg1.I = (_arg1.mass * (((0.5 * m_radius) * m_radius) + ((m_localPosition.x * m_localPosition.x) + (m_localPosition.y * m_localPosition.y))));
}
override public function UpdateSweepRadius(_arg1:b2Vec2):void{
var _local2:Number = (m_localPosition.x - _arg1.x);
var _local3:Number = (m_localPosition.y - _arg1.y);
_local2 = Math.sqrt(((_local2 * _local2) + (_local3 * _local3)));
m_sweepRadius = ((_local2 + m_radius) - b2Settings.b2_toiSlop);
}
override public function ComputeAABB(_arg1:b2AABB, _arg2:b2XForm):void{
var _local3:b2Mat22 = _arg2.R;
var _local4:Number = (_arg2.position.x + ((_local3.col1.x * m_localPosition.x) + (_local3.col2.x * m_localPosition.y)));
var _local5:Number = (_arg2.position.y + ((_local3.col1.y * m_localPosition.x) + (_local3.col2.y * m_localPosition.y)));
_arg1.lowerBound.Set((_local4 - m_radius), (_local5 - m_radius));
_arg1.upperBound.Set((_local4 + m_radius), (_local5 + m_radius));
}
override public function TestPoint(_arg1:b2XForm, _arg2:b2Vec2):Boolean{
var _local3:b2Mat22 = _arg1.R;
var _local4:Number = (_arg1.position.x + ((_local3.col1.x * m_localPosition.x) + (_local3.col2.x * m_localPosition.y)));
var _local5:Number = (_arg1.position.y + ((_local3.col1.y * m_localPosition.x) + (_local3.col2.y * m_localPosition.y)));
_local4 = (_arg2.x - _local4);
_local5 = (_arg2.y - _local5);
return ((((_local4 * _local4) + (_local5 * _local5)) <= (m_radius * m_radius)));
}
}
}//package Box2D.Collision.Shapes
Section 3
//b2FilterData (Box2D.Collision.Shapes.b2FilterData)
package Box2D.Collision.Shapes {
public class b2FilterData {
public var maskBits:uint;// = 0xFFFF
public var groupIndex:int;// = 0
public var categoryBits:uint;// = 1
public function Copy():b2FilterData{
var _local1:b2FilterData = new b2FilterData();
_local1.categoryBits = categoryBits;
_local1.maskBits = maskBits;
_local1.groupIndex = groupIndex;
return (_local1);
}
}
}//package Box2D.Collision.Shapes
Section 4
//b2MassData (Box2D.Collision.Shapes.b2MassData)
package Box2D.Collision.Shapes {
import Box2D.Common.Math.*;
public class b2MassData {
public var mass:Number;// = 0
public var center:b2Vec2;
public var I:Number;// = 0
public function b2MassData(){
center = new b2Vec2(0, 0);
super();
}
}
}//package Box2D.Collision.Shapes
Section 5
//b2PolygonDef (Box2D.Collision.Shapes.b2PolygonDef)
package Box2D.Collision.Shapes {
import Box2D.Common.Math.*;
import Box2D.Common.*;
public class b2PolygonDef extends b2ShapeDef {
public var vertices:Array;
public var vertexCount:int;
private static var s_mat:b2Mat22 = new b2Mat22();
public function b2PolygonDef(){
vertices = new Array(b2Settings.b2_maxPolygonVertices);
super();
type = b2Shape.e_polygonShape;
vertexCount = 0;
var _local1:int;
while (_local1 < b2Settings.b2_maxPolygonVertices) {
vertices[_local1] = new b2Vec2();
_local1++;
};
}
public function SetAsOrientedBox(_arg1:Number, _arg2:Number, _arg3:b2Vec2=null, _arg4:Number=0):void{
var _local5:b2Vec2;
var _local6:b2Mat22;
var _local7:int;
vertexCount = 4;
vertices[0].Set(-(_arg1), -(_arg2));
vertices[1].Set(_arg1, -(_arg2));
vertices[2].Set(_arg1, _arg2);
vertices[3].Set(-(_arg1), _arg2);
if (_arg3){
_local5 = _arg3;
_local6 = s_mat;
_local6.Set(_arg4);
_local7 = 0;
while (_local7 < vertexCount) {
_arg3 = vertices[_local7];
_arg1 = (_local5.x + ((_local6.col1.x * _arg3.x) + (_local6.col2.x * _arg3.y)));
_arg3.y = (_local5.y + ((_local6.col1.y * _arg3.x) + (_local6.col2.y * _arg3.y)));
_arg3.x = _arg1;
_local7++;
};
};
}
public function SetAsBox(_arg1:Number, _arg2:Number):void{
vertexCount = 4;
vertices[0].Set(-(_arg1), -(_arg2));
vertices[1].Set(_arg1, -(_arg2));
vertices[2].Set(_arg1, _arg2);
vertices[3].Set(-(_arg1), _arg2);
}
}
}//package Box2D.Collision.Shapes
Section 6
//b2PolygonShape (Box2D.Collision.Shapes.b2PolygonShape)
package Box2D.Collision.Shapes {
import Box2D.Dynamics.*;
import Box2D.Common.Math.*;
import Box2D.Collision.*;
import Box2D.Common.*;
public class b2PolygonShape extends b2Shape {
public var m_coreVertices:Array;
public var m_vertices:Array;
private var s_supportVec:b2Vec2;
public var m_centroid:b2Vec2;
public var m_normals:Array;
public var m_obb:b2OBB;
public var m_vertexCount:int;
private static var s_computeMat:b2Mat22 = new b2Mat22();
private static var s_sweptAABB1:b2AABB = new b2AABB();
private static var s_sweptAABB2:b2AABB = new b2AABB();
public function b2PolygonShape(_arg1:b2ShapeDef){
var _local3:int;
var _local6:Number;
var _local7:Number;
var _local8:Number;
var _local9:Number;
var _local10:Number;
var _local11:Number;
var _local12:Number;
var _local13:Number;
var _local14:Number;
var _local15:Number;
var _local16:Number;
var _local17:Number;
s_supportVec = new b2Vec2();
m_obb = new b2OBB();
m_vertices = new Array(b2Settings.b2_maxPolygonVertices);
m_normals = new Array(b2Settings.b2_maxPolygonVertices);
m_coreVertices = new Array(b2Settings.b2_maxPolygonVertices);
super(_arg1);
m_type = e_polygonShape;
var _local2:b2PolygonDef = (_arg1 as b2PolygonDef);
m_vertexCount = _local2.vertexCount;
var _local4:int = _local3;
var _local5:int = _local3;
_local3 = 0;
while (_local3 < m_vertexCount) {
m_vertices[_local3] = _local2.vertices[_local3].Copy();
_local3++;
};
_local3 = 0;
while (_local3 < m_vertexCount) {
_local4 = _local3;
_local5 = (((_local3 + 1) < m_vertexCount)) ? (_local3 + 1) : 0;
_local6 = (m_vertices[_local5].x - m_vertices[_local4].x);
_local7 = (m_vertices[_local5].y - m_vertices[_local4].y);
_local8 = Math.sqrt(((_local6 * _local6) + (_local7 * _local7)));
m_normals[_local3] = new b2Vec2((_local7 / _local8), (-(_local6) / _local8));
_local3++;
};
m_centroid = ComputeCentroid(_local2.vertices, _local2.vertexCount);
ComputeOBB(m_obb, m_vertices, m_vertexCount);
_local3 = 0;
while (_local3 < m_vertexCount) {
_local4 = (((_local3 - 1) >= 0)) ? (_local3 - 1) : (m_vertexCount - 1);
_local5 = _local3;
_local9 = m_normals[_local4].x;
_local10 = m_normals[_local4].y;
_local11 = m_normals[_local5].x;
_local12 = m_normals[_local5].y;
_local13 = (m_vertices[_local3].x - m_centroid.x);
_local14 = (m_vertices[_local3].y - m_centroid.y);
_local15 = (((_local9 * _local13) + (_local10 * _local14)) - b2Settings.b2_toiSlop);
_local16 = (((_local11 * _local13) + (_local12 * _local14)) - b2Settings.b2_toiSlop);
_local17 = (1 / ((_local9 * _local12) - (_local10 * _local11)));
m_coreVertices[_local3] = new b2Vec2(((_local17 * ((_local12 * _local15) - (_local10 * _local16))) + m_centroid.x), ((_local17 * ((_local9 * _local16) - (_local11 * _local15))) + m_centroid.y));
_local3++;
};
}
override public function ComputeSweptAABB(_arg1:b2AABB, _arg2:b2XForm, _arg3:b2XForm):void{
var _local4:b2AABB = s_sweptAABB1;
var _local5:b2AABB = s_sweptAABB2;
ComputeAABB(_local4, _arg2);
ComputeAABB(_local5, _arg3);
_arg1.lowerBound.Set(((_local4.lowerBound.x < _local5.lowerBound.x)) ? _local4.lowerBound.x : _local5.lowerBound.x, ((_local4.lowerBound.y < _local5.lowerBound.y)) ? _local4.lowerBound.y : _local5.lowerBound.y);
_arg1.upperBound.Set(((_local4.upperBound.x > _local5.upperBound.x)) ? _local4.upperBound.x : _local5.upperBound.x, ((_local4.upperBound.y > _local5.upperBound.y)) ? _local4.upperBound.y : _local5.upperBound.y);
}
public function GetVertices():Array{
return (m_vertices);
}
public function GetCoreVertices():Array{
return (m_coreVertices);
}
public function GetCentroid():b2Vec2{
return (m_centroid);
}
public function GetOBB():b2OBB{
return (m_obb);
}
public function GetFirstVertex(_arg1:b2XForm):b2Vec2{
return (b2Math.b2MulX(_arg1, m_coreVertices[0]));
}
public function Centroid(_arg1:b2XForm):b2Vec2{
return (b2Math.b2MulX(_arg1, m_centroid));
}
override public function TestSegment(_arg1:b2XForm, _arg2:Array, _arg3:b2Vec2, _arg4:b2Segment, _arg5:Number):Boolean{
var _local8:Number;
var _local9:Number;
var _local10:b2Mat22;
var _local11:b2Vec2;
var _local20:Number;
var _local21:Number;
var _local6:Number = 0;
var _local7:Number = _arg5;
_local8 = (_arg4.p1.x - _arg1.position.x);
_local9 = (_arg4.p1.y - _arg1.position.y);
_local10 = _arg1.R;
var _local12:Number = ((_local8 * _local10.col1.x) + (_local9 * _local10.col1.y));
var _local13:Number = ((_local8 * _local10.col2.x) + (_local9 * _local10.col2.y));
_local8 = (_arg4.p2.x - _arg1.position.x);
_local9 = (_arg4.p2.y - _arg1.position.y);
_local10 = _arg1.R;
var _local14:Number = ((_local8 * _local10.col1.x) + (_local9 * _local10.col1.y));
var _local15:Number = ((_local8 * _local10.col2.x) + (_local9 * _local10.col2.y));
var _local16:Number = (_local14 - _local12);
var _local17:Number = (_local15 - _local13);
var _local18 = -1;
var _local19:int;
while (_local19 < m_vertexCount) {
_local11 = m_vertices[_local19];
_local8 = (_local11.x - _local12);
_local9 = (_local11.y - _local13);
_local11 = m_normals[_local19];
_local20 = ((_local11.x * _local8) + (_local11.y * _local9));
_local21 = ((_local11.x * _local16) + (_local11.y * _local17));
if ((((_local21 < 0)) && ((_local20 < (_local6 * _local21))))){
_local6 = (_local20 / _local21);
_local18 = _local19;
} else {
if ((((_local21 > 0)) && ((_local20 < (_local7 * _local21))))){
_local7 = (_local20 / _local21);
};
};
if (_local7 < _local6){
return (false);
};
_local19++;
};
if (_local18 >= 0){
_arg2[0] = _local6;
_local10 = _arg1.R;
_local11 = m_normals[_local18];
_arg3.x = ((_local10.col1.x * _local11.x) + (_local10.col2.x * _local11.y));
_arg3.y = ((_local10.col1.y * _local11.x) + (_local10.col2.y * _local11.y));
return (true);
};
return (false);
}
override public function ComputeMass(_arg1:b2MassData):void{
var _local10:b2Vec2;
var _local11:b2Vec2;
var _local12:Number;
var _local13:Number;
var _local14:Number;
var _local15:Number;
var _local16:Number;
var _local17:Number;
var _local18:Number;
var _local19:Number;
var _local20:Number;
var _local21:Number;
var _local22:Number;
var _local23:Number;
var _local24:Number;
var _local25:Number;
var _local2:Number = 0;
var _local3:Number = 0;
var _local4:Number = 0;
var _local5:Number = 0;
var _local6:Number = 0;
var _local7:Number = 0;
var _local8:Number = (1 / 3);
var _local9:int;
while (_local9 < m_vertexCount) {
_local10 = m_vertices[_local9];
_local11 = (((_local9 + 1) < m_vertexCount)) ? m_vertices[int((_local9 + 1))] : m_vertices[0];
_local12 = (_local10.x - _local6);
_local13 = (_local10.y - _local7);
_local14 = (_local11.x - _local6);
_local15 = (_local11.y - _local7);
_local16 = ((_local12 * _local15) - (_local13 * _local14));
_local17 = (0.5 * _local16);
_local4 = (_local4 + _local17);
_local2 = (_local2 + ((_local17 * _local8) * ((_local6 + _local10.x) + _local11.x)));
_local3 = (_local3 + ((_local17 * _local8) * ((_local7 + _local10.y) + _local11.y)));
_local18 = _local6;
_local19 = _local7;
_local20 = _local12;
_local21 = _local13;
_local22 = _local14;
_local23 = _local15;
_local24 = ((_local8 * ((0.25 * (((_local20 * _local20) + (_local22 * _local20)) + (_local22 * _local22))) + ((_local18 * _local20) + (_local18 * _local22)))) + ((0.5 * _local18) * _local18));
_local25 = ((_local8 * ((0.25 * (((_local21 * _local21) + (_local23 * _local21)) + (_local23 * _local23))) + ((_local19 * _local21) + (_local19 * _local23)))) + ((0.5 * _local19) * _local19));
_local5 = (_local5 + (_local16 * (_local24 + _local25)));
_local9++;
};
_arg1.mass = (m_density * _local4);
_local2 = (_local2 * (1 / _local4));
_local3 = (_local3 * (1 / _local4));
_arg1.center.Set(_local2, _local3);
_arg1.I = (m_density * _local5);
}
public function GetNormals():Array{
return (m_normals);
}
public function Support(_arg1:b2XForm, _arg2:Number, _arg3:Number):b2Vec2{
var _local4:b2Vec2;
var _local5:b2Mat22;
var _local11:Number;
_local5 = _arg1.R;
var _local6:Number = ((_arg2 * _local5.col1.x) + (_arg3 * _local5.col1.y));
var _local7:Number = ((_arg2 * _local5.col2.x) + (_arg3 * _local5.col2.y));
var _local8:int;
_local4 = m_coreVertices[0];
var _local9:Number = ((_local4.x * _local6) + (_local4.y * _local7));
var _local10 = 1;
while (_local10 < m_vertexCount) {
_local4 = m_coreVertices[_local10];
_local11 = ((_local4.x * _local6) + (_local4.y * _local7));
if (_local11 > _local9){
_local8 = _local10;
_local9 = _local11;
};
_local10++;
};
_local5 = _arg1.R;
_local4 = m_coreVertices[_local8];
s_supportVec.x = (_arg1.position.x + ((_local5.col1.x * _local4.x) + (_local5.col2.x * _local4.y)));
s_supportVec.y = (_arg1.position.y + ((_local5.col1.y * _local4.x) + (_local5.col2.y * _local4.y)));
return (s_supportVec);
}
public function GetVertexCount():int{
return (m_vertexCount);
}
override public function ComputeAABB(_arg1:b2AABB, _arg2:b2XForm):void{
var _local3:b2Mat22;
var _local4:b2Vec2;
var _local5:b2Mat22 = s_computeMat;
_local3 = _arg2.R;
_local4 = m_obb.R.col1;
_local5.col1.x = ((_local3.col1.x * _local4.x) + (_local3.col2.x * _local4.y));
_local5.col1.y = ((_local3.col1.y * _local4.x) + (_local3.col2.y * _local4.y));
_local4 = m_obb.R.col2;
_local5.col2.x = ((_local3.col1.x * _local4.x) + (_local3.col2.x * _local4.y));
_local5.col2.y = ((_local3.col1.y * _local4.x) + (_local3.col2.y * _local4.y));
_local5.Abs();
var _local6:b2Mat22 = _local5;
_local4 = m_obb.extents;
var _local7:Number = ((_local6.col1.x * _local4.x) + (_local6.col2.x * _local4.y));
var _local8:Number = ((_local6.col1.y * _local4.x) + (_local6.col2.y * _local4.y));
_local3 = _arg2.R;
_local4 = m_obb.center;
var _local9:Number = (_arg2.position.x + ((_local3.col1.x * _local4.x) + (_local3.col2.x * _local4.y)));
var _local10:Number = (_arg2.position.y + ((_local3.col1.y * _local4.x) + (_local3.col2.y * _local4.y)));
_arg1.lowerBound.Set((_local9 - _local7), (_local10 - _local8));
_arg1.upperBound.Set((_local9 + _local7), (_local10 + _local8));
}
override public function UpdateSweepRadius(_arg1:b2Vec2):void{
var _local2:b2Vec2;
var _local4:Number;
var _local5:Number;
m_sweepRadius = 0;
var _local3:int;
while (_local3 < m_vertexCount) {
_local2 = m_coreVertices[_local3];
_local4 = (_local2.x - _arg1.x);
_local5 = (_local2.y - _arg1.y);
_local4 = Math.sqrt(((_local4 * _local4) + (_local5 * _local5)));
if (_local4 > m_sweepRadius){
m_sweepRadius = _local4;
};
_local3++;
};
}
override public function TestPoint(_arg1:b2XForm, _arg2:b2Vec2):Boolean{
var _local3:b2Vec2;
var _local10:Number;
var _local4:b2Mat22 = _arg1.R;
var _local5:Number = (_arg2.x - _arg1.position.x);
var _local6:Number = (_arg2.y - _arg1.position.y);
var _local7:Number = ((_local5 * _local4.col1.x) + (_local6 * _local4.col1.y));
var _local8:Number = ((_local5 * _local4.col2.x) + (_local6 * _local4.col2.y));
var _local9:int;
while (_local9 < m_vertexCount) {
_local3 = m_vertices[_local9];
_local5 = (_local7 - _local3.x);
_local6 = (_local8 - _local3.y);
_local3 = m_normals[_local9];
_local10 = ((_local3.x * _local5) + (_local3.y * _local6));
if (_local10 > 0){
return (false);
};
_local9++;
};
return (true);
}
public static function ComputeCentroid(_arg1:Array, _arg2:int):b2Vec2{
var _local3:b2Vec2;
var _local7:Number;
var _local9:b2Vec2;
var _local10:b2Vec2;
var _local11:Number;
var _local12:Number;
var _local13:Number;
var _local14:Number;
var _local15:Number;
var _local16:Number;
_local3 = new b2Vec2();
var _local4:Number = 0;
var _local5:Number = 0;
var _local6:Number = 0;
_local7 = (1 / 3);
var _local8:int;
while (_local8 < _arg2) {
_local9 = _arg1[_local8];
_local10 = (((_local8 + 1) < _arg2)) ? _arg1[int((_local8 + 1))] : _arg1[0];
_local11 = (_local9.x - _local5);
_local12 = (_local9.y - _local6);
_local13 = (_local10.x - _local5);
_local14 = (_local10.y - _local6);
_local15 = ((_local11 * _local14) - (_local12 * _local13));
_local16 = (0.5 * _local15);
_local4 = (_local4 + _local16);
_local3.x = (_local3.x + ((_local16 * _local7) * ((_local5 + _local9.x) + _local10.x)));
_local3.y = (_local3.y + ((_local16 * _local7) * ((_local6 + _local9.y) + _local10.y)));
_local8++;
};
_local3.x = (_local3.x * (1 / _local4));
_local3.y = (_local3.y * (1 / _local4));
return (_local3);
}
public static function ComputeOBB(_arg1:b2OBB, _arg2:Array, _arg3:int):void{
var _local4:int;
var _local7:b2Vec2;
var _local8:Number;
var _local9:Number;
var _local10:Number;
var _local11:Number;
var _local12:Number;
var _local13:Number;
var _local14:Number;
var _local15:Number;
var _local16:Number;
var _local17:int;
var _local18:Number;
var _local19:Number;
var _local20:Number;
var _local21:Number;
var _local22:Number;
var _local23:Number;
var _local24:Number;
var _local25:b2Mat22;
var _local5:Array = new Array((b2Settings.b2_maxPolygonVertices + 1));
_local4 = 0;
while (_local4 < _arg3) {
_local5[_local4] = _arg2[_local4];
_local4++;
};
_local5[_arg3] = _local5[0];
var _local6:Number = Number.MAX_VALUE;
_local4 = 1;
while (_local4 <= _arg3) {
_local7 = _local5[int((_local4 - 1))];
_local8 = (_local5[_local4].x - _local7.x);
_local9 = (_local5[_local4].y - _local7.y);
_local10 = Math.sqrt(((_local8 * _local8) + (_local9 * _local9)));
_local8 = (_local8 / _local10);
_local9 = (_local9 / _local10);
_local11 = -(_local9);
_local12 = _local8;
_local13 = Number.MAX_VALUE;
_local14 = Number.MAX_VALUE;
_local15 = -(Number.MAX_VALUE);
_local16 = -(Number.MAX_VALUE);
_local17 = 0;
while (_local17 < _arg3) {
_local19 = (_local5[_local17].x - _local7.x);
_local20 = (_local5[_local17].y - _local7.y);
_local21 = ((_local8 * _local19) + (_local9 * _local20));
_local22 = ((_local11 * _local19) + (_local12 * _local20));
if (_local21 < _local13){
_local13 = _local21;
};
if (_local22 < _local14){
_local14 = _local22;
};
if (_local21 > _local15){
_local15 = _local21;
};
if (_local22 > _local16){
_local16 = _local22;
};
_local17++;
};
_local18 = ((_local15 - _local13) * (_local16 - _local14));
if (_local18 < (0.95 * _local6)){
_local6 = _local18;
_arg1.R.col1.x = _local8;
_arg1.R.col1.y = _local9;
_arg1.R.col2.x = _local11;
_arg1.R.col2.y = _local12;
_local23 = (0.5 * (_local13 + _local15));
_local24 = (0.5 * (_local14 + _local16));
_local25 = _arg1.R;
_arg1.center.x = (_local7.x + ((_local25.col1.x * _local23) + (_local25.col2.x * _local24)));
_arg1.center.y = (_local7.y + ((_local25.col1.y * _local23) + (_local25.col2.y * _local24)));
_arg1.extents.x = (0.5 * (_local15 - _local13));
_arg1.extents.y = (0.5 * (_local16 - _local14));
};
_local4++;
};
}
}
}//package Box2D.Collision.Shapes
Section 7
//b2Shape (Box2D.Collision.Shapes.b2Shape)
package Box2D.Collision.Shapes {
import Box2D.Dynamics.*;
import Box2D.Common.Math.*;
import Box2D.Collision.*;
public class b2Shape {
public var m_next:b2Shape;
public var m_type:int;
public var m_sweepRadius:Number;
public var m_density:Number;
public var m_filter:b2FilterData;
public var m_friction:Number;
public var m_isSensor:Boolean;
public var m_restitution:Number;
public var m_userData;
public var m_proxyId:uint;
public var m_body:b2Body;
public static const e_polygonShape:int = 1;
public static const e_unknownShape:int = -1;
public static const e_circleShape:int = 0;
public static const e_shapeTypeCount:int = 2;
private static var s_resetAABB:b2AABB = new b2AABB();
private static var s_syncAABB:b2AABB = new b2AABB();
private static var s_proxyAABB:b2AABB = new b2AABB();
public function b2Shape(_arg1:b2ShapeDef){
m_userData = _arg1.userData;
m_friction = _arg1.friction;
m_restitution = _arg1.restitution;
m_density = _arg1.density;
m_body = null;
m_sweepRadius = 0;
m_next = null;
m_proxyId = b2Pair.b2_nullProxy;
m_filter = _arg1.filter.Copy();
m_isSensor = _arg1.isSensor;
}
public function SetUserData(_arg1):void{
m_userData = _arg1;
}
public function GetSweepRadius():Number{
return (m_sweepRadius);
}
public function GetNext():b2Shape{
return (m_next);
}
public function ComputeSweptAABB(_arg1:b2AABB, _arg2:b2XForm, _arg3:b2XForm):void{
}
public function GetType():int{
return (m_type);
}
public function GetRestitution():Number{
return (m_restitution);
}
public function GetFriction():Number{
return (m_friction);
}
public function GetFilterData():b2FilterData{
return (m_filter.Copy());
}
public function TestSegment(_arg1:b2XForm, _arg2:Array, _arg3:b2Vec2, _arg4:b2Segment, _arg5:Number):Boolean{
return (false);
}
public function RefilterProxy(_arg1:b2BroadPhase, _arg2:b2XForm):void{
if (m_proxyId == b2Pair.b2_nullProxy){
return;
};
_arg1.DestroyProxy(m_proxyId);
var _local3:b2AABB = s_resetAABB;
ComputeAABB(_local3, _arg2);
var _local4:Boolean = _arg1.InRange(_local3);
if (_local4){
m_proxyId = _arg1.CreateProxy(_local3, this);
} else {
m_proxyId = b2Pair.b2_nullProxy;
};
}
public function SetFilterData(_arg1:b2FilterData):void{
m_filter = _arg1.Copy();
}
public function GetUserData(){
return (m_userData);
}
public function Synchronize(_arg1:b2BroadPhase, _arg2:b2XForm, _arg3:b2XForm):Boolean{
if (m_proxyId == b2Pair.b2_nullProxy){
return (false);
};
var _local4:b2AABB = s_syncAABB;
ComputeSweptAABB(_local4, _arg2, _arg3);
if (_arg1.InRange(_local4)){
_arg1.MoveProxy(m_proxyId, _local4);
return (true);
};
return (false);
}
public function ComputeMass(_arg1:b2MassData):void{
}
public function IsSensor():Boolean{
return (m_isSensor);
}
public function DestroyProxy(_arg1:b2BroadPhase):void{
if (m_proxyId != b2Pair.b2_nullProxy){
_arg1.DestroyProxy(m_proxyId);
m_proxyId = b2Pair.b2_nullProxy;
};
}
public function UpdateSweepRadius(_arg1:b2Vec2):void{
}
public function ComputeAABB(_arg1:b2AABB, _arg2:b2XForm):void{
}
public function GetBody():b2Body{
return (m_body);
}
public function CreateProxy(_arg1:b2BroadPhase, _arg2:b2XForm):void{
var _local3:b2AABB = s_proxyAABB;
ComputeAABB(_local3, _arg2);
var _local4:Boolean = _arg1.InRange(_local3);
if (_local4){
m_proxyId = _arg1.CreateProxy(_local3, this);
} else {
m_proxyId = b2Pair.b2_nullProxy;
};
}
public function TestPoint(_arg1:b2XForm, _arg2:b2Vec2):Boolean{
return (false);
}
public static function Destroy(_arg1:b2Shape, _arg2):void{
}
public static function Create(_arg1:b2ShapeDef, _arg2):b2Shape{
switch (_arg1.type){
case e_circleShape:
return (new b2CircleShape(_arg1));
case e_polygonShape:
return (new b2PolygonShape(_arg1));
default:
return (null);
};
}
}
}//package Box2D.Collision.Shapes
Section 8
//b2ShapeDef (Box2D.Collision.Shapes.b2ShapeDef)
package Box2D.Collision.Shapes {
public class b2ShapeDef {
public var friction:Number;// = 0.2
public var isSensor:Boolean;// = false
public var density:Number;// = 0
public var restitution:Number;// = 0
public var userData;// = null
public var filter:b2FilterData;
public var type:int;
public function b2ShapeDef(){
type = b2Shape.e_unknownShape;
filter = new b2FilterData();
super();
}
}
}//package Box2D.Collision.Shapes
Section 9
//b2AABB (Box2D.Collision.b2AABB)
package Box2D.Collision {
import Box2D.Common.Math.*;
public class b2AABB {
public var upperBound:b2Vec2;
public var lowerBound:b2Vec2;
public function b2AABB(){
lowerBound = new b2Vec2();
upperBound = new b2Vec2();
super();
}
public function IsValid():Boolean{
var _local1:Number = (upperBound.x - lowerBound.x);
var _local2:Number = (upperBound.y - lowerBound.y);
var _local3:Boolean = (((_local1 >= 0)) && ((_local2 >= 0)));
_local3 = ((((_local3) && (lowerBound.IsValid()))) && (upperBound.IsValid()));
return (_local3);
}
}
}//package Box2D.Collision
Section 10
//b2Bound (Box2D.Collision.b2Bound)
package Box2D.Collision {
public class b2Bound {
public var value:uint;
public var proxyId:uint;
public var stabbingCount:uint;
public function Swap(_arg1:b2Bound):void{
var _local2:uint = value;
var _local3:uint = proxyId;
var _local4:uint = stabbingCount;
value = _arg1.value;
proxyId = _arg1.proxyId;
stabbingCount = _arg1.stabbingCount;
_arg1.value = _local2;
_arg1.proxyId = _local3;
_arg1.stabbingCount = _local4;
}
public function IsLower():Boolean{
return (((value & 1) == 0));
}
public function IsUpper():Boolean{
return (((value & 1) == 1));
}
}
}//package Box2D.Collision
Section 11
//b2BoundValues (Box2D.Collision.b2BoundValues)
package Box2D.Collision {
public class b2BoundValues {
public var lowerValues:Array;
public var upperValues:Array;
public function b2BoundValues(){
lowerValues = [0, 0];
upperValues = [0, 0];
super();
}
}
}//package Box2D.Collision
Section 12
//b2BroadPhase (Box2D.Collision.b2BroadPhase)
package Box2D.Collision {
import Box2D.Common.Math.*;
import Box2D.Common.*;
public class b2BroadPhase {
public var m_bounds:Array;
public var m_quantizationFactor:b2Vec2;
public var m_worldAABB:b2AABB;
public var m_freeProxy:uint;
public var m_proxyCount:int;
public var m_proxyPool:Array;
public var m_queryResultCount:int;
public var m_pairManager:b2PairManager;
public var m_timeStamp:uint;
public var m_queryResults:Array;
public static const b2_nullEdge:uint = 0xFFFF;
public static const b2_invalid:uint = 0xFFFF;
public static var s_validate:Boolean = false;
public function b2BroadPhase(_arg1:b2AABB, _arg2:b2PairCallback){
var _local3:int;
var _local5:Number;
var _local6:b2Proxy;
var _local7:int;
m_pairManager = new b2PairManager();
m_proxyPool = new Array(b2Settings.b2_maxPairs);
m_bounds = new Array((2 * b2Settings.b2_maxProxies));
m_queryResults = new Array(b2Settings.b2_maxProxies);
m_quantizationFactor = new b2Vec2();
super();
m_pairManager.Initialize(this, _arg2);
m_worldAABB = _arg1;
m_proxyCount = 0;
_local3 = 0;
while (_local3 < b2Settings.b2_maxProxies) {
m_queryResults[_local3] = 0;
_local3++;
};
m_bounds = new Array(2);
_local3 = 0;
while (_local3 < 2) {
m_bounds[_local3] = new Array((2 * b2Settings.b2_maxProxies));
_local7 = 0;
while (_local7 < (2 * b2Settings.b2_maxProxies)) {
m_bounds[_local3][_local7] = new b2Bound();
_local7++;
};
_local3++;
};
var _local4:Number = (_arg1.upperBound.x - _arg1.lowerBound.x);
_local5 = (_arg1.upperBound.y - _arg1.lowerBound.y);
m_quantizationFactor.x = (b2Settings.USHRT_MAX / _local4);
m_quantizationFactor.y = (b2Settings.USHRT_MAX / _local5);
_local3 = 0;
while (_local3 < (b2Settings.b2_maxProxies - 1)) {
_local6 = new b2Proxy();
m_proxyPool[_local3] = _local6;
_local6.SetNext((_local3 + 1));
_local6.timeStamp = 0;
_local6.overlapCount = b2_invalid;
_local6.userData = null;
_local3++;
};
_local6 = new b2Proxy();
m_proxyPool[int((b2Settings.b2_maxProxies - 1))] = _local6;
_local6.SetNext(b2Pair.b2_nullProxy);
_local6.timeStamp = 0;
_local6.overlapCount = b2_invalid;
_local6.userData = null;
m_freeProxy = 0;
m_timeStamp = 1;
m_queryResultCount = 0;
}
public function QueryAABB(_arg1:b2AABB, _arg2, _arg3:int):int{
var _local6:uint;
var _local7:uint;
var _local12:b2Proxy;
var _local4:Array = new Array();
var _local5:Array = new Array();
ComputeBounds(_local4, _local5, _arg1);
var _local8:Array = [_local6];
var _local9:Array = [_local7];
Query(_local8, _local9, _local4[0], _local5[0], m_bounds[0], (2 * m_proxyCount), 0);
Query(_local8, _local9, _local4[1], _local5[1], m_bounds[1], (2 * m_proxyCount), 1);
var _local10:int;
var _local11:int;
while ((((_local11 < m_queryResultCount)) && ((_local10 < _arg3)))) {
_local12 = m_proxyPool[m_queryResults[_local11]];
_arg2[_local11] = _local12.userData;
_local11++;
_local10++;
};
m_queryResultCount = 0;
IncrementTimeStamp();
return (_local10);
}
public function Commit():void{
m_pairManager.Commit();
}
public function GetProxy(_arg1:int):b2Proxy{
var _local2:b2Proxy = m_proxyPool[_arg1];
if ((((_arg1 == b2Pair.b2_nullProxy)) || ((_local2.IsValid() == false)))){
return (null);
};
return (_local2);
}
private function IncrementTimeStamp():void{
var _local1:uint;
if (m_timeStamp == b2Settings.USHRT_MAX){
_local1 = 0;
while (_local1 < b2Settings.b2_maxProxies) {
(m_proxyPool[_local1] as b2Proxy).timeStamp = 0;
_local1++;
};
m_timeStamp = 1;
} else {
m_timeStamp++;
};
}
private function Query(_arg1:Array, _arg2:Array, _arg3:uint, _arg4:uint, _arg5:Array, _arg6:uint, _arg7:int):void{
var _local10:b2Bound;
var _local12:int;
var _local13:int;
var _local14:b2Proxy;
var _local8:uint = BinarySearch(_arg5, _arg6, _arg3);
var _local9:uint = BinarySearch(_arg5, _arg6, _arg4);
var _local11:uint = _local8;
while (_local11 < _local9) {
_local10 = _arg5[_local11];
if (_local10.IsLower()){
IncrementOverlapCount(_local10.proxyId);
};
_local11++;
};
if (_local8 > 0){
_local12 = (_local8 - 1);
_local10 = _arg5[_local12];
_local13 = _local10.stabbingCount;
while (_local13) {
_local10 = _arg5[_local12];
if (_local10.IsLower()){
_local14 = m_proxyPool[_local10.proxyId];
if (_local8 <= _local14.upperBounds[_arg7]){
IncrementOverlapCount(_local10.proxyId);
_local13--;
};
};
_local12--;
};
};
_arg1[0] = _local8;
_arg2[0] = _local9;
}
private function TestOverlapValidate(_arg1:b2Proxy, _arg2:b2Proxy):Boolean{
var _local4:Array;
var _local5:b2Bound;
var _local6:b2Bound;
var _local3:int;
while (_local3 < 2) {
_local4 = m_bounds[_local3];
_local5 = _local4[_arg1.lowerBounds[_local3]];
_local6 = _local4[_arg2.upperBounds[_local3]];
if (_local5.value > _local6.value){
return (false);
};
_local5 = _local4[_arg1.upperBounds[_local3]];
_local6 = _local4[_arg2.lowerBounds[_local3]];
if (_local5.value < _local6.value){
return (false);
};
_local3++;
};
return (true);
}
private function ComputeBounds(_arg1:Array, _arg2:Array, _arg3:b2AABB):void{
var _local4:Number = _arg3.lowerBound.x;
var _local5:Number = _arg3.lowerBound.y;
_local4 = b2Math.b2Min(_local4, m_worldAABB.upperBound.x);
_local5 = b2Math.b2Min(_local5, m_worldAABB.upperBound.y);
_local4 = b2Math.b2Max(_local4, m_worldAABB.lowerBound.x);
_local5 = b2Math.b2Max(_local5, m_worldAABB.lowerBound.y);
var _local6:Number = _arg3.upperBound.x;
var _local7:Number = _arg3.upperBound.y;
_local6 = b2Math.b2Min(_local6, m_worldAABB.upperBound.x);
_local7 = b2Math.b2Min(_local7, m_worldAABB.upperBound.y);
_local6 = b2Math.b2Max(_local6, m_worldAABB.lowerBound.x);
_local7 = b2Math.b2Max(_local7, m_worldAABB.lowerBound.y);
_arg1[0] = (uint((m_quantizationFactor.x * (_local4 - m_worldAABB.lowerBound.x))) & (b2Settings.USHRT_MAX - 1));
_arg2[0] = ((uint((m_quantizationFactor.x * (_local6 - m_worldAABB.lowerBound.x))) & 0xFFFF) | 1);
_arg1[1] = (uint((m_quantizationFactor.y * (_local5 - m_worldAABB.lowerBound.y))) & (b2Settings.USHRT_MAX - 1));
_arg2[1] = ((uint((m_quantizationFactor.y * (_local7 - m_worldAABB.lowerBound.y))) & 0xFFFF) | 1);
}
public function CreateProxy(_arg1:b2AABB, _arg2):uint{
var _local3:uint;
var _local4:b2Proxy;
var _local11:Array;
var _local12:uint;
var _local13:uint;
var _local14:Array;
var _local15:Array;
var _local16:Array;
var _local17:int;
var _local18:int;
var _local19:b2Bound;
var _local20:b2Bound;
var _local21:b2Bound;
var _local22:int;
var _local23:b2Proxy;
var _local5:uint = m_freeProxy;
_local4 = m_proxyPool[_local5];
m_freeProxy = _local4.GetNext();
_local4.overlapCount = 0;
_local4.userData = _arg2;
var _local6:uint = (2 * m_proxyCount);
var _local7:Array = new Array();
var _local8:Array = new Array();
ComputeBounds(_local7, _local8, _arg1);
var _local9:int;
while (_local9 < 2) {
_local11 = m_bounds[_local9];
_local14 = [_local12];
_local15 = [_local13];
Query(_local14, _local15, _local7[_local9], _local8[_local9], _local11, _local6, _local9);
_local12 = _local14[0];
_local13 = _local15[0];
_local16 = new Array();
_local18 = (_local6 - _local13);
_local17 = 0;
while (_local17 < _local18) {
_local16[_local17] = new b2Bound();
_local19 = _local16[_local17];
_local20 = _local11[int((_local13 + _local17))];
_local19.value = _local20.value;
_local19.proxyId = _local20.proxyId;
_local19.stabbingCount = _local20.stabbingCount;
_local17++;
};
_local18 = _local16.length;
_local22 = (_local13 + 2);
_local17 = 0;
while (_local17 < _local18) {
_local20 = _local16[_local17];
_local19 = _local11[int((_local22 + _local17))];
_local19.value = _local20.value;
_local19.proxyId = _local20.proxyId;
_local19.stabbingCount = _local20.stabbingCount;
_local17++;
};
_local16 = new Array();
_local18 = (_local13 - _local12);
_local17 = 0;
while (_local17 < _local18) {
_local16[_local17] = new b2Bound();
_local19 = _local16[_local17];
_local20 = _local11[int((_local12 + _local17))];
_local19.value = _local20.value;
_local19.proxyId = _local20.proxyId;
_local19.stabbingCount = _local20.stabbingCount;
_local17++;
};
_local18 = _local16.length;
_local22 = (_local12 + 1);
_local17 = 0;
while (_local17 < _local18) {
_local20 = _local16[_local17];
_local19 = _local11[int((_local22 + _local17))];
_local19.value = _local20.value;
_local19.proxyId = _local20.proxyId;
_local19.stabbingCount = _local20.stabbingCount;
_local17++;
};
_local13++;
_local19 = _local11[_local12];
_local20 = _local11[_local13];
_local19.value = _local7[_local9];
_local19.proxyId = _local5;
_local20.value = _local8[_local9];
_local20.proxyId = _local5;
_local21 = _local11[int((_local12 - 1))];
_local19.stabbingCount = ((_local12 == 0)) ? 0 : _local21.stabbingCount;
_local21 = _local11[int((_local13 - 1))];
_local20.stabbingCount = _local21.stabbingCount;
_local3 = _local12;
while (_local3 < _local13) {
_local21 = _local11[_local3];
_local21.stabbingCount++;
_local3++;
};
_local3 = _local12;
while (_local3 < (_local6 + 2)) {
_local19 = _local11[_local3];
_local23 = m_proxyPool[_local19.proxyId];
if (_local19.IsLower()){
_local23.lowerBounds[_local9] = _local3;
} else {
_local23.upperBounds[_local9] = _local3;
};
_local3++;
};
_local9++;
};
m_proxyCount++;
var _local10:int;
while (_local10 < m_queryResultCount) {
m_pairManager.AddBufferedPair(_local5, m_queryResults[_local10]);
_local10++;
};
m_pairManager.Commit();
m_queryResultCount = 0;
IncrementTimeStamp();
return (_local5);
}
public function DestroyProxy(_arg1:uint):void{
var _local2:b2Bound;
var _local3:b2Bound;
var _local8:Array;
var _local9:uint;
var _local10:uint;
var _local11:uint;
var _local12:uint;
var _local13:Array;
var _local14:int;
var _local15:int;
var _local16:int;
var _local17:uint;
var _local18:int;
var _local19:b2Proxy;
var _local4:b2Proxy = m_proxyPool[_arg1];
var _local5:int = (2 * m_proxyCount);
var _local6:int;
while (_local6 < 2) {
_local8 = m_bounds[_local6];
_local9 = _local4.lowerBounds[_local6];
_local10 = _local4.upperBounds[_local6];
_local2 = _local8[_local9];
_local11 = _local2.value;
_local3 = _local8[_local10];
_local12 = _local3.value;
_local13 = new Array();
_local15 = ((_local10 - _local9) - 1);
_local14 = 0;
while (_local14 < _local15) {
_local13[_local14] = new b2Bound();
_local2 = _local13[_local14];
_local3 = _local8[int(((_local9 + 1) + _local14))];
_local2.value = _local3.value;
_local2.proxyId = _local3.proxyId;
_local2.stabbingCount = _local3.stabbingCount;
_local14++;
};
_local15 = _local13.length;
_local16 = _local9;
_local14 = 0;
while (_local14 < _local15) {
_local3 = _local13[_local14];
_local2 = _local8[int((_local16 + _local14))];
_local2.value = _local3.value;
_local2.proxyId = _local3.proxyId;
_local2.stabbingCount = _local3.stabbingCount;
_local14++;
};
_local13 = new Array();
_local15 = ((_local5 - _local10) - 1);
_local14 = 0;
while (_local14 < _local15) {
_local13[_local14] = new b2Bound();
_local2 = _local13[_local14];
_local3 = _local8[int(((_local10 + 1) + _local14))];
_local2.value = _local3.value;
_local2.proxyId = _local3.proxyId;
_local2.stabbingCount = _local3.stabbingCount;
_local14++;
};
_local15 = _local13.length;
_local16 = (_local10 - 1);
_local14 = 0;
while (_local14 < _local15) {
_local3 = _local13[_local14];
_local2 = _local8[int((_local16 + _local14))];
_local2.value = _local3.value;
_local2.proxyId = _local3.proxyId;
_local2.stabbingCount = _local3.stabbingCount;
_local14++;
};
_local15 = (_local5 - 2);
_local17 = _local9;
while (_local17 < _local15) {
_local2 = _local8[_local17];
_local19 = m_proxyPool[_local2.proxyId];
if (_local2.IsLower()){
_local19.lowerBounds[_local6] = _local17;
} else {
_local19.upperBounds[_local6] = _local17;
};
_local17++;
};
_local15 = (_local10 - 1);
_local18 = _local9;
while (_local18 < _local15) {
_local2 = _local8[_local18];
_local2.stabbingCount--;
_local18++;
};
Query([0], [0], _local11, _local12, _local8, (_local5 - 2), _local6);
_local6++;
};
var _local7:int;
while (_local7 < m_queryResultCount) {
m_pairManager.RemoveBufferedPair(_arg1, m_queryResults[_local7]);
_local7++;
};
m_pairManager.Commit();
m_queryResultCount = 0;
IncrementTimeStamp();
_local4.userData = null;
_local4.overlapCount = b2_invalid;
_local4.lowerBounds[0] = b2_invalid;
_local4.lowerBounds[1] = b2_invalid;
_local4.upperBounds[0] = b2_invalid;
_local4.upperBounds[1] = b2_invalid;
_local4.SetNext(m_freeProxy);
m_freeProxy = _arg1;
m_proxyCount--;
}
public function TestOverlap(_arg1:b2BoundValues, _arg2:b2Proxy):Boolean{
var _local4:Array;
var _local5:b2Bound;
var _local3:int;
while (_local3 < 2) {
_local4 = m_bounds[_local3];
_local5 = _local4[_arg2.upperBounds[_local3]];
if (_arg1.lowerValues[_local3] > _local5.value){
return (false);
};
_local5 = _local4[_arg2.lowerBounds[_local3]];
if (_arg1.upperValues[_local3] < _local5.value){
return (false);
};
_local3++;
};
return (true);
}
public function Validate():void{
var _local1:b2Pair;
var _local2:b2Proxy;
var _local3:b2Proxy;
var _local4:Boolean;
var _local6:b2Bound;
var _local7:uint;
var _local8:uint;
var _local9:uint;
var _local10:b2Bound;
var _local5:int;
while (_local5 < 2) {
_local6 = m_bounds[_local5];
_local7 = (2 * m_proxyCount);
_local8 = 0;
_local9 = 0;
while (_local9 < _local7) {
_local10 = _local6[_local9];
if (_local10.IsLower() == true){
_local8++;
} else {
_local8--;
};
_local9++;
};
_local5++;
};
}
private function IncrementOverlapCount(_arg1:uint):void{
var _local2:b2Proxy = m_proxyPool[_arg1];
if (_local2.timeStamp < m_timeStamp){
_local2.timeStamp = m_timeStamp;
_local2.overlapCount = 1;
} else {
_local2.overlapCount = 2;
m_queryResults[m_queryResultCount] = _arg1;
m_queryResultCount++;
};
}
public function InRange(_arg1:b2AABB):Boolean{
var _local2:Number;
var _local3:Number;
var _local4:Number;
var _local5:Number;
_local2 = _arg1.lowerBound.x;
_local3 = _arg1.lowerBound.y;
_local2 = (_local2 - m_worldAABB.upperBound.x);
_local3 = (_local3 - m_worldAABB.upperBound.y);
_local4 = m_worldAABB.lowerBound.x;
_local5 = m_worldAABB.lowerBound.y;
_local4 = (_local4 - _arg1.upperBound.x);
_local5 = (_local5 - _arg1.upperBound.y);
_local2 = b2Math.b2Max(_local2, _local4);
_local3 = b2Math.b2Max(_local3, _local5);
return ((b2Math.b2Max(_local2, _local3) < 0));
}
public function MoveProxy(_arg1:uint, _arg2:b2AABB):void{
var _local3:Array;
var _local4:int;
var _local5:uint;
var _local6:uint;
var _local7:b2Bound;
var _local8:b2Bound;
var _local9:b2Bound;
var _local10:uint;
var _local11:b2Proxy;
var _local16:Array;
var _local17:uint;
var _local18:uint;
var _local19:uint;
var _local20:uint;
var _local21:int;
var _local22:int;
var _local23:uint;
var _local24:b2Proxy;
if ((((_arg1 == b2Pair.b2_nullProxy)) || ((b2Settings.b2_maxProxies <= _arg1)))){
return;
};
if (_arg2.IsValid() == false){
return;
};
var _local12:uint = (2 * m_proxyCount);
var _local13:b2Proxy = m_proxyPool[_arg1];
var _local14:b2BoundValues = new b2BoundValues();
ComputeBounds(_local14.lowerValues, _local14.upperValues, _arg2);
var _local15:b2BoundValues = new b2BoundValues();
_local5 = 0;
while (_local5 < 2) {
_local7 = m_bounds[_local5][_local13.lowerBounds[_local5]];
_local15.lowerValues[_local5] = _local7.value;
_local7 = m_bounds[_local5][_local13.upperBounds[_local5]];
_local15.upperValues[_local5] = _local7.value;
_local5++;
};
_local5 = 0;
while (_local5 < 2) {
_local16 = m_bounds[_local5];
_local17 = _local13.lowerBounds[_local5];
_local18 = _local13.upperBounds[_local5];
_local19 = _local14.lowerValues[_local5];
_local20 = _local14.upperValues[_local5];
_local7 = _local16[_local17];
_local21 = (_local19 - _local7.value);
_local7.value = _local19;
_local7 = _local16[_local18];
_local22 = (_local20 - _local7.value);
_local7.value = _local20;
if (_local21 < 0){
_local6 = _local17;
while ((((_local6 > 0)) && ((_local19 < (_local16[int((_local6 - 1))] as b2Bound).value)))) {
_local7 = _local16[_local6];
_local8 = _local16[int((_local6 - 1))];
_local23 = _local8.proxyId;
_local24 = m_proxyPool[_local8.proxyId];
_local8.stabbingCount++;
if (_local8.IsUpper() == true){
if (TestOverlap(_local14, _local24)){
m_pairManager.AddBufferedPair(_arg1, _local23);
};
_local3 = _local24.upperBounds;
_local4 = _local3[_local5];
_local4++;
_local3[_local5] = _local4;
_local7.stabbingCount++;
} else {
_local3 = _local24.lowerBounds;
_local4 = _local3[_local5];
_local4++;
_local3[_local5] = _local4;
_local7.stabbingCount--;
};
_local3 = _local13.lowerBounds;
_local4 = _local3[_local5];
_local4--;
_local3[_local5] = _local4;
_local7.Swap(_local8);
_local6--;
};
};
if (_local22 > 0){
_local6 = _local18;
while ((((_local6 < (_local12 - 1))) && (((_local16[int((_local6 + 1))] as b2Bound).value <= _local20)))) {
_local7 = _local16[_local6];
_local9 = _local16[int((_local6 + 1))];
_local10 = _local9.proxyId;
_local11 = m_proxyPool[_local10];
_local9.stabbingCount++;
if (_local9.IsLower() == true){
if (TestOverlap(_local14, _local11)){
m_pairManager.AddBufferedPair(_arg1, _local10);
};
_local3 = _local11.lowerBounds;
_local4 = _local3[_local5];
_local4--;
_local3[_local5] = _local4;
_local7.stabbingCount++;
} else {
_local3 = _local11.upperBounds;
_local4 = _local3[_local5];
_local4--;
_local3[_local5] = _local4;
_local7.stabbingCount--;
};
_local3 = _local13.upperBounds;
_local4 = _local3[_local5];
_local4++;
_local3[_local5] = _local4;
_local7.Swap(_local9);
_local6++;
};
};
if (_local21 > 0){
_local6 = _local17;
while ((((_local6 < (_local12 - 1))) && (((_local16[int((_local6 + 1))] as b2Bound).value <= _local19)))) {
_local7 = _local16[_local6];
_local9 = _local16[int((_local6 + 1))];
_local10 = _local9.proxyId;
_local11 = m_proxyPool[_local10];
_local9.stabbingCount--;
if (_local9.IsUpper()){
if (TestOverlap(_local15, _local11)){
m_pairManager.RemoveBufferedPair(_arg1, _local10);
};
_local3 = _local11.upperBounds;
_local4 = _local3[_local5];
_local4--;
_local3[_local5] = _local4;
_local7.stabbingCount--;
} else {
_local3 = _local11.lowerBounds;
_local4 = _local3[_local5];
_local4--;
_local3[_local5] = _local4;
_local7.stabbingCount++;
};
_local3 = _local13.lowerBounds;
_local4 = _local3[_local5];
_local4++;
_local3[_local5] = _local4;
_local7.Swap(_local9);
_local6++;
};
};
if (_local22 < 0){
_local6 = _local18;
while ((((_local6 > 0)) && ((_local20 < (_local16[int((_local6 - 1))] as b2Bound).value)))) {
_local7 = _local16[_local6];
_local8 = _local16[int((_local6 - 1))];
_local23 = _local8.proxyId;
_local24 = m_proxyPool[_local23];
_local8.stabbingCount--;
if (_local8.IsLower() == true){
if (TestOverlap(_local15, _local24)){
m_pairManager.RemoveBufferedPair(_arg1, _local23);
};
_local3 = _local24.lowerBounds;
_local4 = _local3[_local5];
_local4++;
_local3[_local5] = _local4;
_local7.stabbingCount--;
} else {
_local3 = _local24.upperBounds;
_local4 = _local3[_local5];
_local4++;
_local3[_local5] = _local4;
_local7.stabbingCount++;
};
_local3 = _local13.upperBounds;
_local4 = _local3[_local5];
_local4--;
_local3[_local5] = _local4;
_local7.Swap(_local8);
_local6--;
};
};
_local5++;
};
}
public static function BinarySearch(_arg1:Array, _arg2:int, _arg3:uint):uint{
var _local6:int;
var _local7:b2Bound;
var _local4:int;
var _local5:int = (_arg2 - 1);
while (_local4 <= _local5) {
_local6 = ((_local4 + _local5) / 2);
_local7 = _arg1[_local6];
if (_local7.value > _arg3){
_local5 = (_local6 - 1);
} else {
if (_local7.value < _arg3){
_local4 = (_local6 + 1);
} else {
return (uint(_local6));
};
};
};
return (uint(_local4));
}
}
}//package Box2D.Collision
Section 13
//b2BufferedPair (Box2D.Collision.b2BufferedPair)
package Box2D.Collision {
public class b2BufferedPair {
public var proxyId1:uint;
public var proxyId2:uint;
}
}//package Box2D.Collision
Section 14
//b2Collision (Box2D.Collision.b2Collision)
package Box2D.Collision {
import Box2D.Common.Math.*;
import Box2D.Collision.Shapes.*;
import Box2D.Common.*;
public class b2Collision {
public static const b2_nullFeature:uint = 0xFF;
private static var b2CollidePolyTempVec:b2Vec2 = new b2Vec2();
public static function EdgeSeparation(_arg1:b2PolygonShape, _arg2:b2XForm, _arg3:int, _arg4:b2PolygonShape, _arg5:b2XForm):Number{
var _local11:b2Mat22;
var _local12:b2Vec2;
var _local25:Number;
var _local6:int = _arg1.m_vertexCount;
var _local7:Array = _arg1.m_vertices;
var _local8:Array = _arg1.m_normals;
var _local9:int = _arg4.m_vertexCount;
var _local10:Array = _arg4.m_vertices;
_local11 = _arg2.R;
_local12 = _local8[_arg3];
var _local13:Number = ((_local11.col1.x * _local12.x) + (_local11.col2.x * _local12.y));
var _local14:Number = ((_local11.col1.y * _local12.x) + (_local11.col2.y * _local12.y));
_local11 = _arg5.R;
var _local15:Number = ((_local11.col1.x * _local13) + (_local11.col1.y * _local14));
var _local16:Number = ((_local11.col2.x * _local13) + (_local11.col2.y * _local14));
var _local17:int;
var _local18:Number = Number.MAX_VALUE;
var _local19:int;
while (_local19 < _local9) {
_local12 = _local10[_local19];
_local25 = ((_local12.x * _local15) + (_local12.y * _local16));
if (_local25 < _local18){
_local18 = _local25;
_local17 = _local19;
};
_local19++;
};
_local12 = _local7[_arg3];
_local11 = _arg2.R;
var _local20:Number = (_arg2.position.x + ((_local11.col1.x * _local12.x) + (_local11.col2.x * _local12.y)));
var _local21:Number = (_arg2.position.y + ((_local11.col1.y * _local12.x) + (_local11.col2.y * _local12.y)));
_local12 = _local10[_local17];
_local11 = _arg5.R;
var _local22:Number = (_arg5.position.x + ((_local11.col1.x * _local12.x) + (_local11.col2.x * _local12.y)));
var _local23:Number = (_arg5.position.y + ((_local11.col1.y * _local12.x) + (_local11.col2.y * _local12.y)));
_local22 = (_local22 - _local20);
_local23 = (_local23 - _local21);
var _local24:Number = ((_local22 * _local13) + (_local23 * _local14));
return (_local24);
}
public static function b2TestOverlap(_arg1:b2AABB, _arg2:b2AABB):Boolean{
var _local3:b2Vec2 = _arg2.lowerBound;
var _local4:b2Vec2 = _arg1.upperBound;
var _local5:Number = (_local3.x - _local4.x);
var _local6:Number = (_local3.y - _local4.y);
_local3 = _arg1.lowerBound;
_local4 = _arg2.upperBound;
var _local7:Number = (_local3.x - _local4.x);
var _local8:Number = (_local3.y - _local4.y);
if ((((_local5 > 0)) || ((_local6 > 0)))){
return (false);
};
if ((((_local7 > 0)) || ((_local8 > 0)))){
return (false);
};
return (true);
}
public static function FindIncidentEdge(_arg1:Array, _arg2:b2PolygonShape, _arg3:b2XForm, _arg4:int, _arg5:b2PolygonShape, _arg6:b2XForm):void{
var _local12:b2Mat22;
var _local13:b2Vec2;
var _local20:ClipVertex;
var _local23:Number;
var _local7:int = _arg2.m_vertexCount;
var _local8:Array = _arg2.m_normals;
var _local9:int = _arg5.m_vertexCount;
var _local10:Array = _arg5.m_vertices;
var _local11:Array = _arg5.m_normals;
_local12 = _arg3.R;
_local13 = _local8[_arg4];
var _local14:Number = ((_local12.col1.x * _local13.x) + (_local12.col2.x * _local13.y));
var _local15:Number = ((_local12.col1.y * _local13.x) + (_local12.col2.y * _local13.y));
_local12 = _arg6.R;
var _local16:Number = ((_local12.col1.x * _local14) + (_local12.col1.y * _local15));
_local15 = ((_local12.col2.x * _local14) + (_local12.col2.y * _local15));
_local14 = _local16;
var _local17:int;
var _local18:Number = Number.MAX_VALUE;
var _local19:int;
while (_local19 < _local9) {
_local13 = _local11[_local19];
_local23 = ((_local14 * _local13.x) + (_local15 * _local13.y));
if (_local23 < _local18){
_local18 = _local23;
_local17 = _local19;
};
_local19++;
};
var _local21:int = _local17;
var _local22:int = (((_local21 + 1) < _local9)) ? (_local21 + 1) : 0;
_local20 = _arg1[0];
_local13 = _local10[_local21];
_local12 = _arg6.R;
_local20.v.x = (_arg6.position.x + ((_local12.col1.x * _local13.x) + (_local12.col2.x * _local13.y)));
_local20.v.y = (_arg6.position.y + ((_local12.col1.y * _local13.x) + (_local12.col2.y * _local13.y)));
_local20.id.features.referenceEdge = _arg4;
_local20.id.features.incidentEdge = _local21;
_local20.id.features.incidentVertex = 0;
_local20 = _arg1[1];
_local13 = _local10[_local22];
_local12 = _arg6.R;
_local20.v.x = (_arg6.position.x + ((_local12.col1.x * _local13.x) + (_local12.col2.x * _local13.y)));
_local20.v.y = (_arg6.position.y + ((_local12.col1.y * _local13.x) + (_local12.col2.y * _local13.y)));
_local20.id.features.referenceEdge = _arg4;
_local20.id.features.incidentEdge = _local22;
_local20.id.features.incidentVertex = 1;
}
public static function b2CollidePolygons(_arg1:b2Manifold, _arg2:b2PolygonShape, _arg3:b2XForm, _arg4:b2PolygonShape, _arg5:b2XForm):void{
var _local6:ClipVertex;
var _local13:b2PolygonShape;
var _local14:b2PolygonShape;
var _local17:int;
var _local18:uint;
var _local34:int;
var _local37:b2Vec2;
var _local38:Number;
var _local39:b2ManifoldPoint;
_arg1.pointCount = 0;
var _local7:int;
var _local8:Array = [_local7];
var _local9:Number = FindMaxSeparation(_local8, _arg2, _arg3, _arg4, _arg5);
_local7 = _local8[0];
if (_local9 > 0){
return;
};
var _local10:int;
var _local11:Array = [_local10];
var _local12:Number = FindMaxSeparation(_local11, _arg4, _arg5, _arg2, _arg3);
_local10 = _local11[0];
if (_local12 > 0){
return;
};
var _local15:b2XForm = new b2XForm();
var _local16:b2XForm = new b2XForm();
var _local19:Number = 0.98;
var _local20:Number = 0.001;
if (_local12 > ((_local19 * _local9) + _local20)){
_local13 = _arg4;
_local14 = _arg2;
_local15.Set(_arg5);
_local16.Set(_arg3);
_local17 = _local10;
_local18 = 1;
} else {
_local13 = _arg2;
_local14 = _arg4;
_local15.Set(_arg3);
_local16.Set(_arg5);
_local17 = _local7;
_local18 = 0;
};
var _local21:Array = [new ClipVertex(), new ClipVertex()];
FindIncidentEdge(_local21, _local13, _local15, _local17, _local14, _local16);
var _local22:int = _local13.m_vertexCount;
var _local23:Array = _local13.m_vertices;
var _local24:b2Vec2 = _local23[_local17];
var _local25:b2Vec2 = _local24.Copy();
if ((_local17 + 1) < _local22){
_local24 = _local23[int((_local17 + 1))];
_local37 = _local24.Copy();
} else {
_local24 = _local23[0];
_local37 = _local24.Copy();
};
var _local26:b2Vec2 = b2Math.SubtractVV(_local37, _local25);
var _local27:b2Vec2 = b2Math.b2MulMV(_local15.R, b2Math.SubtractVV(_local37, _local25));
_local27.Normalize();
var _local28:b2Vec2 = b2Math.b2CrossVF(_local27, 1);
_local25 = b2Math.b2MulX(_local15, _local25);
_local37 = b2Math.b2MulX(_local15, _local37);
var _local29:Number = b2Math.b2Dot(_local28, _local25);
var _local30:Number = -(b2Math.b2Dot(_local27, _local25));
var _local31:Number = b2Math.b2Dot(_local27, _local37);
var _local32:Array = [new ClipVertex(), new ClipVertex()];
var _local33:Array = [new ClipVertex(), new ClipVertex()];
_local34 = ClipSegmentToLine(_local32, _local21, _local27.Negative(), _local30);
if (_local34 < 2){
return;
};
_local34 = ClipSegmentToLine(_local33, _local32, _local27, _local31);
if (_local34 < 2){
return;
};
_arg1.normal = (_local18) ? _local28.Negative() : _local28.Copy();
var _local35:int;
var _local36:int;
while (_local36 < b2Settings.b2_maxManifoldPoints) {
_local6 = _local33[_local36];
_local38 = (b2Math.b2Dot(_local28, _local6.v) - _local29);
if (_local38 <= 0){
_local39 = _arg1.points[_local35];
_local39.separation = _local38;
_local39.localPoint1 = b2Math.b2MulXT(_arg3, _local6.v);
_local39.localPoint2 = b2Math.b2MulXT(_arg5, _local6.v);
_local39.id.key = _local6.id._key;
_local39.id.features.flip = _local18;
_local35++;
};
_local36++;
};
_arg1.pointCount = _local35;
}
public static function FindMaxSeparation(_arg1:Array, _arg2:b2PolygonShape, _arg3:b2XForm, _arg4:b2PolygonShape, _arg5:b2XForm):Number{
var _local8:b2Vec2;
var _local9:b2Mat22;
var _local22:int;
var _local23:Number;
var _local24:int;
var _local25:Number;
var _local6:int = _arg2.m_vertexCount;
var _local7:Array = _arg2.m_normals;
_local9 = _arg5.R;
_local8 = _arg4.m_centroid;
var _local10:Number = (_arg5.position.x + ((_local9.col1.x * _local8.x) + (_local9.col2.x * _local8.y)));
var _local11:Number = (_arg5.position.y + ((_local9.col1.y * _local8.x) + (_local9.col2.y * _local8.y)));
_local9 = _arg3.R;
_local8 = _arg2.m_centroid;
_local10 = (_local10 - (_arg3.position.x + ((_local9.col1.x * _local8.x) + (_local9.col2.x * _local8.y))));
_local11 = (_local11 - (_arg3.position.y + ((_local9.col1.y * _local8.x) + (_local9.col2.y * _local8.y))));
var _local12:Number = ((_local10 * _arg3.R.col1.x) + (_local11 * _arg3.R.col1.y));
var _local13:Number = ((_local10 * _arg3.R.col2.x) + (_local11 * _arg3.R.col2.y));
var _local14:int;
var _local15:Number = -(Number.MAX_VALUE);
var _local16:int;
while (_local16 < _local6) {
_local8 = _local7[_local16];
_local25 = ((_local8.x * _local12) + (_local8.y * _local13));
if (_local25 > _local15){
_local15 = _local25;
_local14 = _local16;
};
_local16++;
};
var _local17:Number = EdgeSeparation(_arg2, _arg3, _local14, _arg4, _arg5);
if (_local17 > 0){
return (_local17);
};
var _local18:int = (((_local14 - 1) >= 0)) ? (_local14 - 1) : (_local6 - 1);
var _local19:Number = EdgeSeparation(_arg2, _arg3, _local18, _arg4, _arg5);
if (_local19 > 0){
return (_local19);
};
var _local20:int = (((_local14 + 1) < _local6)) ? (_local14 + 1) : 0;
var _local21:Number = EdgeSeparation(_arg2, _arg3, _local20, _arg4, _arg5);
if (_local21 > 0){
return (_local21);
};
if ((((_local19 > _local17)) && ((_local19 > _local21)))){
_local24 = -1;
_local22 = _local18;
_local23 = _local19;
} else {
if (_local21 > _local17){
_local24 = 1;
_local22 = _local20;
_local23 = _local21;
} else {
_arg1[0] = _local14;
return (_local17);
};
};
while (true) {
if (_local24 == -1){
_local14 = (((_local22 - 1) >= 0)) ? (_local22 - 1) : (_local6 - 1);
} else {
_local14 = (((_local22 + 1) < _local6)) ? (_local22 + 1) : 0;
};
_local17 = EdgeSeparation(_arg2, _arg3, _local14, _arg4, _arg5);
if (_local17 > 0){
return (_local17);
};
if (_local17 > _local23){
_local22 = _local14;
_local23 = _local17;
} else {
break;
};
};
_arg1[0] = _local22;
return (_local23);
}
public static function ClipSegmentToLine(_arg1:Array, _arg2:Array, _arg3:b2Vec2, _arg4:Number):int{
var _local5:ClipVertex;
var _local6:int;
var _local7:b2Vec2;
var _local8:b2Vec2;
var _local9:Number;
var _local11:Number;
var _local12:b2Vec2;
var _local13:ClipVertex;
_local6 = 0;
_local5 = _arg2[0];
_local7 = _local5.v;
_local5 = _arg2[1];
_local8 = _local5.v;
_local9 = (b2Math.b2Dot(_arg3, _local7) - _arg4);
var _local10:Number = (b2Math.b2Dot(_arg3, _local8) - _arg4);
if (_local9 <= 0){
var _temp1 = _local6;
_local6 = (_local6 + 1);
var _local14 = _temp1;
_arg1[_local14] = _arg2[0];
};
if (_local10 <= 0){
var _temp2 = _local6;
_local6 = (_local6 + 1);
_local14 = _temp2;
_arg1[_local14] = _arg2[1];
};
if ((_local9 * _local10) < 0){
_local11 = (_local9 / (_local9 - _local10));
_local5 = _arg1[_local6];
_local12 = _local5.v;
_local12.x = (_local7.x + (_local11 * (_local8.x - _local7.x)));
_local12.y = (_local7.y + (_local11 * (_local8.y - _local7.y)));
_local5 = _arg1[_local6];
if (_local9 > 0){
_local13 = _arg2[0];
_local5.id = _local13.id;
} else {
_local13 = _arg2[1];
_local5.id = _local13.id;
};
_local6++;
};
return (_local6);
}
public static function b2CollideCircles(_arg1:b2Manifold, _arg2:b2CircleShape, _arg3:b2XForm, _arg4:b2CircleShape, _arg5:b2XForm):void{
var _local6:b2Mat22;
var _local7:b2Vec2;
var _local18:Number;
var _local24:Number;
var _local25:Number;
_arg1.pointCount = 0;
_local6 = _arg3.R;
_local7 = _arg2.m_localPosition;
var _local8:Number = (_arg3.position.x + ((_local6.col1.x * _local7.x) + (_local6.col2.x * _local7.y)));
var _local9:Number = (_arg3.position.y + ((_local6.col1.y * _local7.x) + (_local6.col2.y * _local7.y)));
_local6 = _arg5.R;
_local7 = _arg4.m_localPosition;
var _local10:Number = (_arg5.position.x + ((_local6.col1.x * _local7.x) + (_local6.col2.x * _local7.y)));
var _local11:Number = (_arg5.position.y + ((_local6.col1.y * _local7.x) + (_local6.col2.y * _local7.y)));
var _local12:Number = (_local10 - _local8);
var _local13:Number = (_local11 - _local9);
var _local14:Number = ((_local12 * _local12) + (_local13 * _local13));
var _local15:Number = _arg2.m_radius;
var _local16:Number = _arg4.m_radius;
var _local17:Number = (_local15 + _local16);
if (_local14 > (_local17 * _local17)){
return;
};
if (_local14 < Number.MIN_VALUE){
_local18 = -(_local17);
_arg1.normal.Set(0, 1);
} else {
_local24 = Math.sqrt(_local14);
_local18 = (_local24 - _local17);
_local25 = (1 / _local24);
_arg1.normal.x = (_local25 * _local12);
_arg1.normal.y = (_local25 * _local13);
};
_arg1.pointCount = 1;
var _local19:b2ManifoldPoint = _arg1.points[0];
_local19.id.key = 0;
_local19.separation = _local18;
_local8 = (_local8 + (_local15 * _arg1.normal.x));
_local9 = (_local9 + (_local15 * _arg1.normal.y));
_local10 = (_local10 - (_local16 * _arg1.normal.x));
_local11 = (_local11 - (_local16 * _arg1.normal.y));
var _local20:Number = (0.5 * (_local8 + _local10));
var _local21:Number = (0.5 * (_local9 + _local11));
var _local22:Number = (_local20 - _arg3.position.x);
var _local23:Number = (_local21 - _arg3.position.y);
_local19.localPoint1.x = ((_local22 * _arg3.R.col1.x) + (_local23 * _arg3.R.col1.y));
_local19.localPoint1.y = ((_local22 * _arg3.R.col2.x) + (_local23 * _arg3.R.col2.y));
_local22 = (_local20 - _arg5.position.x);
_local23 = (_local21 - _arg5.position.y);
_local19.localPoint2.x = ((_local22 * _arg5.R.col1.x) + (_local23 * _arg5.R.col1.y));
_local19.localPoint2.y = ((_local22 * _arg5.R.col2.x) + (_local23 * _arg5.R.col2.y));
}
public static function b2CollidePolygonAndCircle(_arg1:b2Manifold, _arg2:b2PolygonShape, _arg3:b2XForm, _arg4:b2CircleShape, _arg5:b2XForm):void{
var _local6:b2ManifoldPoint;
var _local7:Number;
var _local8:Number;
var _local9:Number;
var _local10:Number;
var _local11:b2Vec2;
var _local12:b2Mat22;
var _local17:Number;
var _local32:Number;
var _local33:Number;
var _local34:Number;
_arg1.pointCount = 0;
_local12 = _arg5.R;
_local11 = _arg4.m_localPosition;
var _local13:Number = (_arg5.position.x + ((_local12.col1.x * _local11.x) + (_local12.col2.x * _local11.y)));
var _local14:Number = (_arg5.position.y + ((_local12.col1.y * _local11.x) + (_local12.col2.y * _local11.y)));
_local7 = (_local13 - _arg3.position.x);
_local8 = (_local14 - _arg3.position.y);
_local12 = _arg3.R;
var _local15:Number = ((_local7 * _local12.col1.x) + (_local8 * _local12.col1.y));
var _local16:Number = ((_local7 * _local12.col2.x) + (_local8 * _local12.col2.y));
var _local18:int;
var _local19:Number = -(Number.MAX_VALUE);
var _local20:Number = _arg4.m_radius;
var _local21:int = _arg2.m_vertexCount;
var _local22:Array = _arg2.m_vertices;
var _local23:Array = _arg2.m_normals;
var _local24:int;
while (_local24 < _local21) {
_local11 = _local22[_local24];
_local7 = (_local15 - _local11.x);
_local8 = (_local16 - _local11.y);
_local11 = _local23[_local24];
_local34 = ((_local11.x * _local7) + (_local11.y * _local8));
if (_local34 > _local20){
return;
};
if (_local34 > _local19){
_local19 = _local34;
_local18 = _local24;
};
_local24++;
};
if (_local19 < Number.MIN_VALUE){
_arg1.pointCount = 1;
_local11 = _local23[_local18];
_local12 = _arg3.R;
_arg1.normal.x = ((_local12.col1.x * _local11.x) + (_local12.col2.x * _local11.y));
_arg1.normal.y = ((_local12.col1.y * _local11.x) + (_local12.col2.y * _local11.y));
_local6 = _arg1.points[0];
_local6.id.features.incidentEdge = _local18;
_local6.id.features.incidentVertex = b2_nullFeature;
_local6.id.features.referenceEdge = 0;
_local6.id.features.flip = 0;
_local9 = (_local13 - (_local20 * _arg1.normal.x));
_local10 = (_local14 - (_local20 * _arg1.normal.y));
_local7 = (_local9 - _arg3.position.x);
_local8 = (_local10 - _arg3.position.y);
_local12 = _arg3.R;
_local6.localPoint1.x = ((_local7 * _local12.col1.x) + (_local8 * _local12.col1.y));
_local6.localPoint1.y = ((_local7 * _local12.col2.x) + (_local8 * _local12.col2.y));
_local7 = (_local9 - _arg5.position.x);
_local8 = (_local10 - _arg5.position.y);
_local12 = _arg5.R;
_local6.localPoint2.x = ((_local7 * _local12.col1.x) + (_local8 * _local12.col1.y));
_local6.localPoint2.y = ((_local7 * _local12.col2.x) + (_local8 * _local12.col2.y));
_local6.separation = (_local19 - _local20);
return;
};
var _local25:int = _local18;
var _local26:int = (((_local25 + 1) < _local21)) ? (_local25 + 1) : 0;
_local11 = _local22[_local25];
var _local27:b2Vec2 = _local22[_local26];
var _local28:Number = (_local27.x - _local11.x);
var _local29:Number = (_local27.y - _local11.y);
var _local30:Number = Math.sqrt(((_local28 * _local28) + (_local29 * _local29)));
_local28 = (_local28 / _local30);
_local29 = (_local29 / _local30);
_local7 = (_local15 - _local11.x);
_local8 = (_local16 - _local11.y);
var _local31:Number = ((_local7 * _local28) + (_local8 * _local29));
_local6 = _arg1.points[0];
if (_local31 <= 0){
_local32 = _local11.x;
_local33 = _local11.y;
_local6.id.features.incidentEdge = b2_nullFeature;
_local6.id.features.incidentVertex = _local25;
} else {
if (_local31 >= _local30){
_local32 = _local27.x;
_local33 = _local27.y;
_local6.id.features.incidentEdge = b2_nullFeature;
_local6.id.features.incidentVertex = _local26;
} else {
_local32 = ((_local28 * _local31) + _local11.x);
_local33 = ((_local29 * _local31) + _local11.y);
_local6.id.features.incidentEdge = _local18;
_local6.id.features.incidentVertex = 0;
};
};
_local7 = (_local15 - _local32);
_local8 = (_local16 - _local33);
_local17 = Math.sqrt(((_local7 * _local7) + (_local8 * _local8)));
_local7 = (_local7 / _local17);
_local8 = (_local8 / _local17);
if (_local17 > _local20){
return;
};
_arg1.pointCount = 1;
_local12 = _arg3.R;
_arg1.normal.x = ((_local12.col1.x * _local7) + (_local12.col2.x * _local8));
_arg1.normal.y = ((_local12.col1.y * _local7) + (_local12.col2.y * _local8));
_local9 = (_local13 - (_local20 * _arg1.normal.x));
_local10 = (_local14 - (_local20 * _arg1.normal.y));
_local7 = (_local9 - _arg3.position.x);
_local8 = (_local10 - _arg3.position.y);
_local12 = _arg3.R;
_local6.localPoint1.x = ((_local7 * _local12.col1.x) + (_local8 * _local12.col1.y));
_local6.localPoint1.y = ((_local7 * _local12.col2.x) + (_local8 * _local12.col2.y));
_local7 = (_local9 - _arg5.position.x);
_local8 = (_local10 - _arg5.position.y);
_local12 = _arg5.R;
_local6.localPoint2.x = ((_local7 * _local12.col1.x) + (_local8 * _local12.col1.y));
_local6.localPoint2.y = ((_local7 * _local12.col2.x) + (_local8 * _local12.col2.y));
_local6.separation = (_local17 - _local20);
_local6.id.features.referenceEdge = 0;
_local6.id.features.flip = 0;
}
}
}//package Box2D.Collision
Section 15
//b2ContactID (Box2D.Collision.b2ContactID)
package Box2D.Collision {
public class b2ContactID {
public var _key:uint;
public var features:Features;
public function b2ContactID(){
features = new Features();
super();
features._m_id = this;
}
public function Set(_arg1:b2ContactID):void{
key = _arg1._key;
}
public function Copy():b2ContactID{
var _local1:b2ContactID = new b2ContactID();
_local1.key = key;
return (_local1);
}
public function set key(_arg1:uint):void{
_key = _arg1;
features._referenceEdge = (_key & 0xFF);
features._incidentEdge = (((_key & 0xFF00) >> 8) & 0xFF);
features._incidentVertex = (((_key & 0xFF0000) >> 16) & 0xFF);
features._flip = (((_key & 4278190080) >> 24) & 0xFF);
}
public function get key():uint{
return (_key);
}
}
}//package Box2D.Collision
Section 16
//b2ContactPoint (Box2D.Collision.b2ContactPoint)
package Box2D.Collision {
import Box2D.Common.Math.*;
import Box2D.Collision.Shapes.*;
public class b2ContactPoint {
public var friction:Number;
public var separation:Number;
public var normal:b2Vec2;
public var position:b2Vec2;
public var restitution:Number;
public var shape1:b2Shape;
public var shape2:b2Shape;
public var id:b2ContactID;
public var velocity:b2Vec2;
public function b2ContactPoint(){
position = new b2Vec2();
velocity = new b2Vec2();
normal = new b2Vec2();
id = new b2ContactID();
super();
}
}
}//package Box2D.Collision
Section 17
//b2Distance (Box2D.Collision.b2Distance)
package Box2D.Collision {
import Box2D.Common.Math.*;
import Box2D.Collision.Shapes.*;
import Box2D.Common.*;
public class b2Distance {
private static var s_p2s:Array = [new b2Vec2(), new b2Vec2(), new b2Vec2()];
private static var s_p1s:Array = [new b2Vec2(), new b2Vec2(), new b2Vec2()];
private static var s_points:Array = [new b2Vec2(), new b2Vec2(), new b2Vec2()];
private static var gPoint:b2Point = new b2Point();
public static var g_GJK_Iterations:int = 0;
public static function InPoints(_arg1:b2Vec2, _arg2:Array, _arg3:int):Boolean{
var _local6:b2Vec2;
var _local7:Number;
var _local8:Number;
var _local9:Number;
var _local10:Number;
var _local4:Number = (100 * Number.MIN_VALUE);
var _local5:int;
while (_local5 < _arg3) {
_local6 = _arg2[_local5];
_local7 = Math.abs((_arg1.x - _local6.x));
_local8 = Math.abs((_arg1.y - _local6.y));
_local9 = Math.max(Math.abs(_arg1.x), Math.abs(_local6.x));
_local10 = Math.max(Math.abs(_arg1.y), Math.abs(_local6.y));
if ((((_local7 < (_local4 * (_local9 + 1)))) && ((_local8 < (_local4 * (_local10 + 1)))))){
return (true);
};
_local5++;
};
return (false);
}
public static function DistanceGeneric(_arg1:b2Vec2, _arg2:b2Vec2, _arg3, _arg4:b2XForm, _arg5, _arg6:b2XForm):Number{
var _local7:b2Vec2;
var _local15:Number;
var _local16:Number;
var _local17:b2Vec2;
var _local18:b2Vec2;
var _local19:Number;
var _local20:Number;
var _local21:Number;
var _local22:Number;
var _local23:int;
var _local8:Array = s_p1s;
var _local9:Array = s_p2s;
var _local10:Array = s_points;
var _local11:int;
_arg1.SetV(_arg3.GetFirstVertex(_arg4));
_arg2.SetV(_arg5.GetFirstVertex(_arg6));
var _local12:Number = 0;
var _local13 = 20;
var _local14:int;
while (_local14 < _local13) {
_local15 = (_arg2.x - _arg1.x);
_local16 = (_arg2.y - _arg1.y);
_local17 = _arg3.Support(_arg4, _local15, _local16);
_local18 = _arg5.Support(_arg6, -(_local15), -(_local16));
_local12 = ((_local15 * _local15) + (_local16 * _local16));
_local19 = (_local18.x - _local17.x);
_local20 = (_local18.y - _local17.y);
_local21 = ((_local15 * _local19) + (_local16 * _local20));
if ((_local12 - ((_local15 * _local19) + (_local16 * _local20))) <= (0.01 * _local12)){
if (_local11 == 0){
_arg1.SetV(_local17);
_arg2.SetV(_local18);
};
g_GJK_Iterations = _local14;
return (Math.sqrt(_local12));
};
switch (_local11){
case 0:
_local7 = _local8[0];
_local7.SetV(_local17);
_local7 = _local9[0];
_local7.SetV(_local18);
_local7 = _local10[0];
_local7.x = _local19;
_local7.y = _local20;
_arg1.SetV(_local8[0]);
_arg2.SetV(_local9[0]);
_local11++;
break;
case 1:
_local7 = _local8[1];
_local7.SetV(_local17);
_local7 = _local9[1];
_local7.SetV(_local18);
_local7 = _local10[1];
_local7.x = _local19;
_local7.y = _local20;
_local11 = ProcessTwo(_arg1, _arg2, _local8, _local9, _local10);
break;
case 2:
_local7 = _local8[2];
_local7.SetV(_local17);
_local7 = _local9[2];
_local7.SetV(_local18);
_local7 = _local10[2];
_local7.x = _local19;
_local7.y = _local20;
_local11 = ProcessThree(_arg1, _arg2, _local8, _local9, _local10);
break;
};
if (_local11 == 3){
g_GJK_Iterations = _local14;
return (0);
};
_local22 = -(Number.MAX_VALUE);
_local23 = 0;
while (_local23 < _local11) {
_local7 = _local10[_local23];
_local22 = b2Math.b2Max(_local22, ((_local7.x * _local7.x) + (_local7.y * _local7.y)));
_local23++;
};
if ((((_local11 == 3)) || ((_local12 <= ((100 * Number.MIN_VALUE) * _local22))))){
g_GJK_Iterations = _local14;
_local15 = (_arg2.x - _arg1.x);
_local16 = (_arg2.y - _arg1.y);
_local12 = ((_local15 * _local15) + (_local16 * _local16));
return (Math.sqrt(_local12));
};
_local14++;
};
g_GJK_Iterations = _local13;
return (Math.sqrt(_local12));
}
public static function DistanceCC(_arg1:b2Vec2, _arg2:b2Vec2, _arg3:b2CircleShape, _arg4:b2XForm, _arg5:b2CircleShape, _arg6:b2XForm):Number{
var _local7:b2Mat22;
var _local8:b2Vec2;
var _local19:Number;
var _local20:Number;
_local7 = _arg4.R;
_local8 = _arg3.m_localPosition;
var _local9:Number = (_arg4.position.x + ((_local7.col1.x * _local8.x) + (_local7.col2.x * _local8.y)));
var _local10:Number = (_arg4.position.y + ((_local7.col1.y * _local8.x) + (_local7.col2.y * _local8.y)));
_local7 = _arg6.R;
_local8 = _arg5.m_localPosition;
var _local11:Number = (_arg6.position.x + ((_local7.col1.x * _local8.x) + (_local7.col2.x * _local8.y)));
var _local12:Number = (_arg6.position.y + ((_local7.col1.y * _local8.x) + (_local7.col2.y * _local8.y)));
var _local13:Number = (_local11 - _local9);
var _local14:Number = (_local12 - _local10);
var _local15:Number = ((_local13 * _local13) + (_local14 * _local14));
var _local16:Number = (_arg3.m_radius - b2Settings.b2_toiSlop);
var _local17:Number = (_arg5.m_radius - b2Settings.b2_toiSlop);
var _local18:Number = (_local16 + _local17);
if (_local15 > (_local18 * _local18)){
_local19 = Math.sqrt(((_local13 * _local13) + (_local14 * _local14)));
_local13 = (_local13 / _local19);
_local14 = (_local14 / _local19);
_local20 = (_local19 - _local18);
_arg1.x = (_local9 + (_local16 * _local13));
_arg1.y = (_local10 + (_local16 * _local14));
_arg2.x = (_local11 - (_local17 * _local13));
_arg2.y = (_local12 - (_local17 * _local14));
return (_local20);
};
if (_local15 > (Number.MIN_VALUE * Number.MIN_VALUE)){
_local19 = Math.sqrt(((_local13 * _local13) + (_local14 * _local14)));
_local13 = (_local13 / _local19);
_local14 = (_local14 / _local19);
_arg1.x = (_local9 + (_local16 * _local13));
_arg1.y = (_local10 + (_local16 * _local14));
_arg2.x = _arg1.x;
_arg2.y = _arg1.y;
return (0);
};
_arg1.x = _local9;
_arg1.y = _local10;
_arg2.x = _arg1.x;
_arg2.y = _arg1.y;
return (0);
}
public static function ProcessThree(_arg1:b2Vec2, _arg2:b2Vec2, _arg3:Array, _arg4:Array, _arg5:Array):int{
var _local6:b2Vec2;
var _local7:b2Vec2;
var _local8:b2Vec2;
var _local9:b2Vec2;
var _local10:b2Vec2;
var _local11:b2Vec2;
var _local12:b2Vec2;
var _local13:b2Vec2;
var _local35:Number;
_local6 = _arg5[0];
_local7 = _arg5[1];
_local8 = _arg5[2];
_local9 = _arg3[0];
_local10 = _arg3[1];
_local11 = _arg3[2];
_local12 = _arg4[0];
_local13 = _arg4[1];
var _local14:b2Vec2 = _arg4[2];
var _local15:Number = _local6.x;
var _local16:Number = _local6.y;
var _local17:Number = _local7.x;
var _local18:Number = _local7.y;
var _local19:Number = _local8.x;
var _local20:Number = _local8.y;
var _local21:Number = (_local17 - _local15);
var _local22:Number = (_local18 - _local16);
var _local23:Number = (_local19 - _local15);
var _local24:Number = (_local20 - _local16);
var _local25:Number = (_local19 - _local17);
var _local26:Number = (_local20 - _local18);
var _local27:Number = -(((_local15 * _local21) + (_local16 * _local22)));
var _local28:Number = ((_local17 * _local21) + (_local18 * _local22));
var _local29:Number = -(((_local15 * _local23) + (_local16 * _local24)));
var _local30:Number = ((_local19 * _local23) + (_local20 * _local24));
var _local31:Number = -(((_local17 * _local25) + (_local18 * _local26)));
var _local32:Number = ((_local19 * _local25) + (_local20 * _local26));
if ((((_local30 <= 0)) && ((_local32 <= 0)))){
_arg1.SetV(_local11);
_arg2.SetV(_local14);
_local9.SetV(_local11);
_local12.SetV(_local14);
_local6.SetV(_local8);
return (1);
};
var _local33:Number = ((_local21 * _local24) - (_local22 * _local23));
var _local34:Number = (_local33 * ((_local15 * _local18) - (_local16 * _local17)));
var _local36:Number = (_local33 * ((_local17 * _local20) - (_local18 * _local19)));
if ((((((((_local36 <= 0)) && ((_local31 >= 0)))) && ((_local32 >= 0)))) && (((_local31 + _local32) > 0)))){
_local35 = (_local31 / (_local31 + _local32));
_arg1.x = (_local10.x + (_local35 * (_local11.x - _local10.x)));
_arg1.y = (_local10.y + (_local35 * (_local11.y - _local10.y)));
_arg2.x = (_local13.x + (_local35 * (_local14.x - _local13.x)));
_arg2.y = (_local13.y + (_local35 * (_local14.y - _local13.y)));
_local9.SetV(_local11);
_local12.SetV(_local14);
_local6.SetV(_local8);
return (2);
};
var _local37:Number = (_local33 * ((_local19 * _local16) - (_local20 * _local15)));
if ((((((((_local37 <= 0)) && ((_local29 >= 0)))) && ((_local30 >= 0)))) && (((_local29 + _local30) > 0)))){
_local35 = (_local29 / (_local29 + _local30));
_arg1.x = (_local9.x + (_local35 * (_local11.x - _local9.x)));
_arg1.y = (_local9.y + (_local35 * (_local11.y - _local9.y)));
_arg2.x = (_local12.x + (_local35 * (_local14.x - _local12.x)));
_arg2.y = (_local12.y + (_local35 * (_local14.y - _local12.y)));
_local10.SetV(_local11);
_local13.SetV(_local14);
_local7.SetV(_local8);
return (2);
};
var _local38:Number = ((_local36 + _local37) + _local34);
_local38 = (1 / _local38);
var _local39:Number = (_local36 * _local38);
var _local40:Number = (_local37 * _local38);
var _local41:Number = ((1 - _local39) - _local40);
_arg1.x = (((_local39 * _local9.x) + (_local40 * _local10.x)) + (_local41 * _local11.x));
_arg1.y = (((_local39 * _local9.y) + (_local40 * _local10.y)) + (_local41 * _local11.y));
_arg2.x = (((_local39 * _local12.x) + (_local40 * _local13.x)) + (_local41 * _local14.x));
_arg2.y = (((_local39 * _local12.y) + (_local40 * _local13.y)) + (_local41 * _local14.y));
return (3);
}
public static function DistancePC(_arg1:b2Vec2, _arg2:b2Vec2, _arg3:b2PolygonShape, _arg4:b2XForm, _arg5:b2CircleShape, _arg6:b2XForm):Number{
var _local7:b2Mat22;
var _local8:b2Vec2;
var _local12:Number;
var _local13:Number;
var _local14:Number;
var _local9:b2Point = gPoint;
_local8 = _arg5.m_localPosition;
_local7 = _arg6.R;
_local9.p.x = (_arg6.position.x + ((_local7.col1.x * _local8.x) + (_local7.col2.x * _local8.y)));
_local9.p.y = (_arg6.position.y + ((_local7.col1.y * _local8.x) + (_local7.col2.y * _local8.y)));
var _local10:Number = DistanceGeneric(_arg1, _arg2, _arg3, _arg4, _local9, b2Math.b2XForm_identity);
var _local11:Number = (_arg5.m_radius - b2Settings.b2_toiSlop);
if (_local10 > _local11){
_local10 = (_local10 - _local11);
_local12 = (_arg2.x - _arg1.x);
_local13 = (_arg2.y - _arg1.y);
_local14 = Math.sqrt(((_local12 * _local12) + (_local13 * _local13)));
_local12 = (_local12 / _local14);
_local13 = (_local13 / _local14);
_arg2.x = (_arg2.x - (_local11 * _local12));
_arg2.y = (_arg2.y - (_local11 * _local13));
} else {
_local10 = 0;
_arg2.x = _arg1.x;
_arg2.y = _arg1.y;
};
return (_local10);
}
public static function Distance(_arg1:b2Vec2, _arg2:b2Vec2, _arg3:b2Shape, _arg4:b2XForm, _arg5:b2Shape, _arg6:b2XForm):Number{
var _local7:int = _arg3.m_type;
var _local8:int = _arg5.m_type;
if ((((_local7 == b2Shape.e_circleShape)) && ((_local8 == b2Shape.e_circleShape)))){
return (DistanceCC(_arg1, _arg2, (_arg3 as b2CircleShape), _arg4, (_arg5 as b2CircleShape), _arg6));
};
if ((((_local7 == b2Shape.e_polygonShape)) && ((_local8 == b2Shape.e_circleShape)))){
return (DistancePC(_arg1, _arg2, (_arg3 as b2PolygonShape), _arg4, (_arg5 as b2CircleShape), _arg6));
};
if ((((_local7 == b2Shape.e_circleShape)) && ((_local8 == b2Shape.e_polygonShape)))){
return (DistancePC(_arg2, _arg1, (_arg5 as b2PolygonShape), _arg6, (_arg3 as b2CircleShape), _arg4));
};
if ((((_local7 == b2Shape.e_polygonShape)) && ((_local8 == b2Shape.e_polygonShape)))){
return (DistanceGeneric(_arg1, _arg2, (_arg3 as b2PolygonShape), _arg4, (_arg5 as b2PolygonShape), _arg6));
};
return (0);
}
public static function ProcessTwo(_arg1:b2Vec2, _arg2:b2Vec2, _arg3:Array, _arg4:Array, _arg5:Array):int{
var _local9:b2Vec2;
var _local10:b2Vec2;
var _local11:b2Vec2;
var _local17:Number;
var _local6:b2Vec2 = _arg5[0];
var _local7:b2Vec2 = _arg5[1];
var _local8:b2Vec2 = _arg3[0];
_local9 = _arg3[1];
_local10 = _arg4[0];
_local11 = _arg4[1];
var _local12:Number = -(_local7.x);
var _local13:Number = -(_local7.y);
var _local14:Number = (_local6.x - _local7.x);
var _local15:Number = (_local6.y - _local7.y);
var _local16:Number = Math.sqrt(((_local14 * _local14) + (_local15 * _local15)));
_local14 = (_local14 / _local16);
_local15 = (_local15 / _local16);
_local17 = ((_local12 * _local14) + (_local13 * _local15));
if ((((_local17 <= 0)) || ((_local16 < Number.MIN_VALUE)))){
_arg1.SetV(_local9);
_arg2.SetV(_local11);
_local8.SetV(_local9);
_local10.SetV(_local11);
_local6.SetV(_local7);
return (1);
};
_local17 = (_local17 / _local16);
_arg1.x = (_local9.x + (_local17 * (_local8.x - _local9.x)));
_arg1.y = (_local9.y + (_local17 * (_local8.y - _local9.y)));
_arg2.x = (_local11.x + (_local17 * (_local10.x - _local11.x)));
_arg2.y = (_local11.y + (_local17 * (_local10.y - _local11.y)));
return (2);
}
}
}//package Box2D.Collision
Section 18
//b2Manifold (Box2D.Collision.b2Manifold)
package Box2D.Collision {
import Box2D.Common.Math.*;
import Box2D.Common.*;
public class b2Manifold {
public var pointCount:int;// = 0
public var normal:b2Vec2;
public var points:Array;
public function b2Manifold(){
points = new Array(b2Settings.b2_maxManifoldPoints);
var _local1:int;
while (_local1 < b2Settings.b2_maxManifoldPoints) {
points[_local1] = new b2ManifoldPoint();
_local1++;
};
normal = new b2Vec2();
}
public function Set(_arg1:b2Manifold):void{
pointCount = _arg1.pointCount;
var _local2:int;
while (_local2 < b2Settings.b2_maxManifoldPoints) {
(points[_local2] as b2ManifoldPoint).Set(_arg1.points[_local2]);
_local2++;
};
normal.SetV(_arg1.normal);
}
public function Reset():void{
var _local1:int;
while (_local1 < b2Settings.b2_maxManifoldPoints) {
(points[_local1] as b2ManifoldPoint).Reset();
_local1++;
};
normal.SetZero();
pointCount = 0;
}
}
}//package Box2D.Collision
Section 19
//b2ManifoldPoint (Box2D.Collision.b2ManifoldPoint)
package Box2D.Collision {
import Box2D.Common.Math.*;
public class b2ManifoldPoint {
public var separation:Number;
public var localPoint2:b2Vec2;
public var normalImpulse:Number;
public var tangentImpulse:Number;
public var localPoint1:b2Vec2;
public var id:b2ContactID;
public function b2ManifoldPoint(){
localPoint1 = new b2Vec2();
localPoint2 = new b2Vec2();
id = new b2ContactID();
super();
}
public function Set(_arg1:b2ManifoldPoint):void{
localPoint1.SetV(_arg1.localPoint1);
localPoint2.SetV(_arg1.localPoint2);
separation = _arg1.separation;
normalImpulse = _arg1.normalImpulse;
tangentImpulse = _arg1.tangentImpulse;
id.key = _arg1.id.key;
}
public function Reset():void{
localPoint1.SetZero();
localPoint2.SetZero();
separation = 0;
normalImpulse = 0;
tangentImpulse = 0;
id.key = 0;
}
}
}//package Box2D.Collision
Section 20
//b2OBB (Box2D.Collision.b2OBB)
package Box2D.Collision {
import Box2D.Common.Math.*;
public class b2OBB {
public var R:b2Mat22;
public var center:b2Vec2;
public var extents:b2Vec2;
public function b2OBB(){
R = new b2Mat22();
center = new b2Vec2();
extents = new b2Vec2();
super();
}
}
}//package Box2D.Collision
Section 21
//b2Pair (Box2D.Collision.b2Pair)
package Box2D.Collision {
public class b2Pair {
public var proxyId1:uint;
public var userData;// = null
public var proxyId2:uint;
public var status:uint;
public var next:uint;
public static var e_pairFinal:uint = 4;
public static var b2_tableMask:int = (b2_tableCapacity - 1);
public static var e_pairRemoved:uint = 2;
public static var b2_nullPair:uint = 0xFFFF;
public static var e_pairBuffered:uint = 1;
public static var b2_nullProxy:uint = 0xFFFF;
public static var b2_tableCapacity:int = 4096;
public function SetBuffered():void{
status = (status | e_pairBuffered);
}
public function IsBuffered():Boolean{
return (((status & e_pairBuffered) == e_pairBuffered));
}
public function IsFinal():Boolean{
return (((status & e_pairFinal) == e_pairFinal));
}
public function ClearRemoved():void{
status = (status & ~(e_pairRemoved));
}
public function SetFinal():void{
status = (status | e_pairFinal);
}
public function IsRemoved():Boolean{
return (((status & e_pairRemoved) == e_pairRemoved));
}
public function ClearBuffered():void{
status = (status & ~(e_pairBuffered));
}
public function SetRemoved():void{
status = (status | e_pairRemoved);
}
}
}//package Box2D.Collision
Section 22
//b2PairCallback (Box2D.Collision.b2PairCallback)
package Box2D.Collision {
public class b2PairCallback {
public function PairRemoved(_arg1, _arg2, _arg3):void{
}
public function PairAdded(_arg1, _arg2){
return (null);
}
}
}//package Box2D.Collision
Section 23
//b2PairManager (Box2D.Collision.b2PairManager)
package Box2D.Collision {
import Box2D.Common.Math.*;
import Box2D.Common.*;
public class b2PairManager {
public var m_pairCount:int;
public var m_pairBuffer:Array;
public var m_hashTable:Array;
public var m_callback:b2PairCallback;
public var m_pairs:Array;
public var m_pairBufferCount:int;
public var m_broadPhase:b2BroadPhase;
public var m_freePair:uint;
public function b2PairManager(){
var _local1:uint;
super();
m_hashTable = new Array(b2Pair.b2_tableCapacity);
_local1 = 0;
while (_local1 < b2Pair.b2_tableCapacity) {
m_hashTable[_local1] = b2Pair.b2_nullPair;
_local1++;
};
m_pairs = new Array(b2Settings.b2_maxPairs);
_local1 = 0;
while (_local1 < b2Settings.b2_maxPairs) {
m_pairs[_local1] = new b2Pair();
_local1++;
};
m_pairBuffer = new Array(b2Settings.b2_maxPairs);
_local1 = 0;
while (_local1 < b2Settings.b2_maxPairs) {
m_pairBuffer[_local1] = new b2BufferedPair();
_local1++;
};
_local1 = 0;
while (_local1 < b2Settings.b2_maxPairs) {
m_pairs[_local1].proxyId1 = b2Pair.b2_nullProxy;
m_pairs[_local1].proxyId2 = b2Pair.b2_nullProxy;
m_pairs[_local1].userData = null;
m_pairs[_local1].status = 0;
m_pairs[_local1].next = (_local1 + 1);
_local1++;
};
m_pairs[int((b2Settings.b2_maxPairs - 1))].next = b2Pair.b2_nullPair;
m_pairCount = 0;
m_pairBufferCount = 0;
}
private function FindHash(_arg1:uint, _arg2:uint, _arg3:uint):b2Pair{
var _local4:b2Pair;
var _local5:uint = m_hashTable[_arg3];
_local4 = m_pairs[_local5];
while (((!((_local5 == b2Pair.b2_nullPair))) && ((Equals(_local4, _arg1, _arg2) == false)))) {
_local5 = _local4.next;
_local4 = m_pairs[_local5];
};
if (_local5 == b2Pair.b2_nullPair){
return (null);
};
return (_local4);
}
private function Find(_arg1:uint, _arg2:uint):b2Pair{
var _local4:uint;
if (_arg1 > _arg2){
_local4 = _arg1;
_arg1 = _arg2;
_arg2 = _local4;
};
var _local3:uint = (Hash(_arg1, _arg2) & b2Pair.b2_tableMask);
return (FindHash(_arg1, _arg2, _local3));
}
private function ValidateBuffer():void{
}
public function Commit():void{
var _local1:b2BufferedPair;
var _local2:int;
var _local5:b2Pair;
var _local6:b2Proxy;
var _local7:b2Proxy;
var _local3:int;
var _local4:Array = m_broadPhase.m_proxyPool;
_local2 = 0;
while (_local2 < m_pairBufferCount) {
_local1 = m_pairBuffer[_local2];
_local5 = Find(_local1.proxyId1, _local1.proxyId2);
_local5.ClearBuffered();
_local6 = _local4[_local5.proxyId1];
_local7 = _local4[_local5.proxyId2];
if (_local5.IsRemoved()){
if (_local5.IsFinal() == true){
m_callback.PairRemoved(_local6.userData, _local7.userData, _local5.userData);
};
_local1 = m_pairBuffer[_local3];
_local1.proxyId1 = _local5.proxyId1;
_local1.proxyId2 = _local5.proxyId2;
_local3++;
} else {
if (_local5.IsFinal() == false){
_local5.userData = m_callback.PairAdded(_local6.userData, _local7.userData);
_local5.SetFinal();
};
};
_local2++;
};
_local2 = 0;
while (_local2 < _local3) {
_local1 = m_pairBuffer[_local2];
RemovePair(_local1.proxyId1, _local1.proxyId2);
_local2++;
};
m_pairBufferCount = 0;
if (b2BroadPhase.s_validate){
ValidateTable();
};
}
public function RemoveBufferedPair(_arg1:int, _arg2:int):void{
var _local3:b2BufferedPair;
var _local4:b2Pair = Find(_arg1, _arg2);
if (_local4 == null){
return;
};
if (_local4.IsBuffered() == false){
_local4.SetBuffered();
_local3 = m_pairBuffer[m_pairBufferCount];
_local3.proxyId1 = _local4.proxyId1;
_local3.proxyId2 = _local4.proxyId2;
m_pairBufferCount++;
};
_local4.SetRemoved();
if (b2BroadPhase.s_validate){
ValidateBuffer();
};
}
private function RemovePair(_arg1:uint, _arg2:uint){
var _local3:b2Pair;
var _local7:uint;
var _local8:uint;
var _local9:*;
if (_arg1 > _arg2){
_local7 = _arg1;
_arg1 = _arg2;
_arg2 = _local7;
};
var _local4:uint = (Hash(_arg1, _arg2) & b2Pair.b2_tableMask);
var _local5:uint = m_hashTable[_local4];
var _local6:b2Pair;
while (_local5 != b2Pair.b2_nullPair) {
if (Equals(m_pairs[_local5], _arg1, _arg2)){
_local8 = _local5;
_local3 = m_pairs[_local5];
if (_local6){
_local6.next = _local3.next;
} else {
m_hashTable[_local4] = _local3.next;
};
_local3 = m_pairs[_local8];
_local9 = _local3.userData;
_local3.next = m_freePair;
_local3.proxyId1 = b2Pair.b2_nullProxy;
_local3.proxyId2 = b2Pair.b2_nullProxy;
_local3.userData = null;
_local3.status = 0;
m_freePair = _local8;
m_pairCount--;
return (_local9);
} else {
_local6 = m_pairs[_local5];
_local5 = _local6.next;
};
};
return (null);
}
public function Initialize(_arg1:b2BroadPhase, _arg2:b2PairCallback):void{
m_broadPhase = _arg1;
m_callback = _arg2;
}
public function AddBufferedPair(_arg1:int, _arg2:int):void{
var _local3:b2BufferedPair;
var _local4:b2Pair = AddPair(_arg1, _arg2);
if (_local4.IsBuffered() == false){
_local4.SetBuffered();
_local3 = m_pairBuffer[m_pairBufferCount];
_local3.proxyId1 = _local4.proxyId1;
_local3.proxyId2 = _local4.proxyId2;
m_pairBufferCount++;
};
_local4.ClearRemoved();
if (b2BroadPhase.s_validate){
ValidateBuffer();
};
}
private function AddPair(_arg1:uint, _arg2:uint):b2Pair{
var _local6:uint;
if (_arg1 > _arg2){
_local6 = _arg1;
_arg1 = _arg2;
_arg2 = _local6;
};
var _local3:uint = (Hash(_arg1, _arg2) & b2Pair.b2_tableMask);
var _local4 = FindHash(_arg1, _arg2, _local3);
if (_local4 != null){
return (_local4);
};
var _local5:uint = m_freePair;
_local4 = m_pairs[_local5];
m_freePair = _local4.next;
_local4.proxyId1 = _arg1;
_local4.proxyId2 = _arg2;
_local4.status = 0;
_local4.userData = null;
_local4.next = m_hashTable[_local3];
m_hashTable[_local3] = _local5;
m_pairCount++;
return (_local4);
}
private function ValidateTable():void{
}
public static function EqualsPair(_arg1:b2BufferedPair, _arg2:b2BufferedPair):Boolean{
return ((((_arg1.proxyId1 == _arg2.proxyId1)) && ((_arg1.proxyId2 == _arg2.proxyId2))));
}
public static function Hash(_arg1:uint, _arg2:uint):uint{
var _local3:uint = (((_arg2 << 16) & 4294901760) | _arg1);
_local3 = (~(_local3) + ((_local3 << 15) & 4294934528));
_local3 = (_local3 ^ ((_local3 >> 12) & 1048575));
_local3 = (_local3 + ((_local3 << 2) & 4294967292));
_local3 = (_local3 ^ ((_local3 >> 4) & 268435455));
_local3 = (_local3 * 2057);
_local3 = (_local3 ^ ((_local3 >> 16) & 0xFFFF));
return (_local3);
}
public static function Equals(_arg1:b2Pair, _arg2:uint, _arg3:uint):Boolean{
return ((((_arg1.proxyId1 == _arg2)) && ((_arg1.proxyId2 == _arg3))));
}
}
}//package Box2D.Collision
Section 24
//b2Point (Box2D.Collision.b2Point)
package Box2D.Collision {
import Box2D.Common.Math.*;
public class b2Point {
public var p:b2Vec2;
public function b2Point(){
p = new b2Vec2();
super();
}
public function GetFirstVertex(_arg1:b2XForm):b2Vec2{
return (p);
}
public function Support(_arg1:b2XForm, _arg2:Number, _arg3:Number):b2Vec2{
return (p);
}
}
}//package Box2D.Collision
Section 25
//b2Proxy (Box2D.Collision.b2Proxy)
package Box2D.Collision {
public class b2Proxy {
public var overlapCount:uint;
public var userData;// = null
public var lowerBounds:Array;
public var upperBounds:Array;
public var timeStamp:uint;
public function b2Proxy(){
lowerBounds = [uint(0), uint(0)];
upperBounds = [uint(0), uint(0)];
super();
}
public function GetNext():uint{
return (lowerBounds[0]);
}
public function IsValid():Boolean{
return (!((overlapCount == b2BroadPhase.b2_invalid)));
}
public function SetNext(_arg1:uint):void{
lowerBounds[0] = (_arg1 & 0xFFFF);
}
}
}//package Box2D.Collision
Section 26
//b2Segment (Box2D.Collision.b2Segment)
package Box2D.Collision {
import Box2D.Common.Math.*;
import Box2D.Common.*;
public class b2Segment {
public var p1:b2Vec2;
public var p2:b2Vec2;
public function b2Segment(){
p1 = new b2Vec2();
p2 = new b2Vec2();
super();
}
public function TestSegment(_arg1:Array, _arg2:b2Vec2, _arg3:b2Segment, _arg4:Number):Boolean{
var _local14:Number;
var _local15:Number;
var _local16:Number;
var _local17:Number;
var _local18:Number;
var _local5:b2Vec2 = _arg3.p1;
var _local6:Number = (_arg3.p2.x - _local5.x);
var _local7:Number = (_arg3.p2.y - _local5.y);
var _local8:Number = (p2.x - p1.x);
var _local9:Number = (p2.y - p1.y);
var _local10:Number = _local9;
var _local11:Number = -(_local8);
var _local12:Number = (100 * Number.MIN_VALUE);
var _local13:Number = -(((_local6 * _local10) + (_local7 * _local11)));
if (_local13 > _local12){
_local14 = (_local5.x - p1.x);
_local15 = (_local5.y - p1.y);
_local16 = ((_local14 * _local10) + (_local15 * _local11));
if ((((0 <= _local16)) && ((_local16 <= (_arg4 * _local13))))){
_local17 = ((-(_local7) * _local15) + (_local7 * _local14));
if (((((-(_local12) * _local13) <= _local17)) && ((_local17 <= (_local13 * (1 + _local12)))))){
_local16 = (_local16 / _local13);
_local18 = Math.sqrt(((_local10 * _local10) + (_local11 * _local11)));
_local10 = (_local10 / _local18);
_local11 = (_local11 / _local18);
_arg1[0] = _local16;
_arg2.Set(_local10, _local11);
return (true);
};
};
};
return (false);
}
}
}//package Box2D.Collision
Section 27
//b2TimeOfImpact (Box2D.Collision.b2TimeOfImpact)
package Box2D.Collision {
import Box2D.Common.Math.*;
import Box2D.Collision.Shapes.*;
import Box2D.Common.*;
public class b2TimeOfImpact {
public static var s_xf1:b2XForm = new b2XForm();
public static var s_xf2:b2XForm = new b2XForm();
public static var s_p1:b2Vec2 = new b2Vec2();
public static var s_p2:b2Vec2 = new b2Vec2();
public static function TimeOfImpact(_arg1:b2Shape, _arg2:b2Sweep, _arg3:b2Shape, _arg4:b2Sweep):Number{
var _local5:Number;
var _local6:Number;
var _local25:Number;
var _local26:b2XForm;
var _local27:b2XForm;
var _local28:Number;
var _local29:Number;
var _local30:Number;
var _local31:Number;
var _local7:Number = _arg1.m_sweepRadius;
var _local8:Number = _arg3.m_sweepRadius;
var _local9:Number = _arg2.t0;
var _local10:Number = (_arg2.c.x - _arg2.c0.x);
var _local11:Number = (_arg2.c.y - _arg2.c0.y);
var _local12:Number = (_arg4.c.x - _arg4.c0.x);
var _local13:Number = (_arg4.c.y - _arg4.c0.y);
var _local14:Number = (_arg2.a - _arg2.a0);
var _local15:Number = (_arg4.a - _arg4.a0);
var _local16:Number = 0;
var _local17:b2Vec2 = s_p1;
var _local18:b2Vec2 = s_p2;
var _local19 = 20;
var _local20:int;
var _local21:Number = 0;
var _local22:Number = 0;
var _local23:Number = 0;
var _local24:Number = 0;
while (true) {
_local25 = (((1 - _local16) * _local9) + _local16);
_local26 = s_xf1;
_local27 = s_xf2;
_arg2.GetXForm(_local26, _local25);
_arg4.GetXForm(_local27, _local25);
_local23 = b2Distance.Distance(_local17, _local18, _arg1, _local26, _arg3, _local27);
if (_local20 == 0){
if (_local23 > (2 * b2Settings.b2_toiSlop)){
_local24 = (1.5 * b2Settings.b2_toiSlop);
} else {
_local5 = (0.05 * b2Settings.b2_toiSlop);
_local6 = (_local23 - (0.5 * b2Settings.b2_toiSlop));
_local24 = ((_local5 > _local6)) ? _local5 : _local6;
};
};
if (((((_local23 - _local24) < (0.05 * b2Settings.b2_toiSlop))) || ((_local20 == _local19)))){
break;
};
_local21 = (_local18.x - _local17.x);
_local22 = (_local18.y - _local17.y);
_local28 = Math.sqrt(((_local21 * _local21) + (_local22 * _local22)));
_local21 = (_local21 / _local28);
_local22 = (_local22 / _local28);
_local29 = ((((_local21 * (_local10 - _local12)) + (_local22 * (_local11 - _local13))) + (((_local14 < 0)) ? -(_local14) : _local14 * _local7)) + (((_local15 < 0)) ? -(_local15) : _local15 * _local8));
if (_local29 == 0){
_local16 = 1;
break;
};
_local30 = ((_local23 - _local24) / _local29);
_local31 = (_local16 + _local30);
if ((((_local31 < 0)) || ((1 < _local31)))){
_local16 = 1;
break;
};
if (_local31 < ((1 + (100 * Number.MIN_VALUE)) * _local16)){
break;
};
_local16 = _local31;
_local20++;
};
return (_local16);
}
}
}//package Box2D.Collision
Section 28
//ClipVertex (Box2D.Collision.ClipVertex)
package Box2D.Collision {
import Box2D.Common.Math.*;
public class ClipVertex {
public var id:b2ContactID;
public var v:b2Vec2;
public function ClipVertex(){
v = new b2Vec2();
id = new b2ContactID();
super();
}
}
}//package Box2D.Collision
Section 29
//Features (Box2D.Collision.Features)
package Box2D.Collision {
public class Features {
public var _referenceEdge:int;
public var _incidentEdge:int;
public var _flip:int;
public var _incidentVertex:int;
public var _m_id:b2ContactID;
public function get referenceEdge():int{
return (_referenceEdge);
}
public function set incidentVertex(_arg1:int):void{
_incidentVertex = _arg1;
_m_id._key = ((_m_id._key & 4278255615) | ((_incidentVertex << 16) & 0xFF0000));
}
public function get flip():int{
return (_flip);
}
public function get incidentEdge():int{
return (_incidentEdge);
}
public function set referenceEdge(_arg1:int):void{
_referenceEdge = _arg1;
_m_id._key = ((_m_id._key & 4294967040) | (_referenceEdge & 0xFF));
}
public function get incidentVertex():int{
return (_incidentVertex);
}
public function set flip(_arg1:int):void{
_flip = _arg1;
_m_id._key = ((_m_id._key & 0xFFFFFF) | ((_flip << 24) & 4278190080));
}
public function set incidentEdge(_arg1:int):void{
_incidentEdge = _arg1;
_m_id._key = ((_m_id._key & 4294902015) | ((_incidentEdge << 8) & 0xFF00));
}
}
}//package Box2D.Collision
Section 30
//b2Mat22 (Box2D.Common.Math.b2Mat22)
package Box2D.Common.Math {
public class b2Mat22 {
public var col1:b2Vec2;
public var col2:b2Vec2;
public function b2Mat22(_arg1:Number=0, _arg2:b2Vec2=null, _arg3:b2Vec2=null){
var _local4:Number;
var _local5:Number;
col1 = new b2Vec2();
col2 = new b2Vec2();
super();
if (((!((_arg2 == null))) && (!((_arg3 == null))))){
col1.SetV(_arg2);
col2.SetV(_arg3);
} else {
_local4 = Math.cos(_arg1);
_local5 = Math.sin(_arg1);
col1.x = _local4;
col2.x = -(_local5);
col1.y = _local5;
col2.y = _local4;
};
}
public function SetIdentity():void{
col1.x = 1;
col2.x = 0;
col1.y = 0;
col2.y = 1;
}
public function SetVV(_arg1:b2Vec2, _arg2:b2Vec2):void{
col1.SetV(_arg1);
col2.SetV(_arg2);
}
public function Set(_arg1:Number):void{
var _local2:Number;
_local2 = Math.cos(_arg1);
var _local3:Number = Math.sin(_arg1);
col1.x = _local2;
col2.x = -(_local3);
col1.y = _local3;
col2.y = _local2;
}
public function SetZero():void{
col1.x = 0;
col2.x = 0;
col1.y = 0;
col2.y = 0;
}
public function SetM(_arg1:b2Mat22):void{
col1.SetV(_arg1.col1);
col2.SetV(_arg1.col2);
}
public function AddM(_arg1:b2Mat22):void{
col1.x = (col1.x + _arg1.col1.x);
col1.y = (col1.y + _arg1.col1.y);
col2.x = (col2.x + _arg1.col2.x);
col2.y = (col2.y + _arg1.col2.y);
}
public function Abs():void{
col1.Abs();
col2.Abs();
}
public function Copy():b2Mat22{
return (new b2Mat22(0, col1, col2));
}
public function Invert(_arg1:b2Mat22):b2Mat22{
var _local2:Number;
var _local4:Number;
var _local6:Number;
_local2 = col1.x;
var _local3:Number = col2.x;
_local4 = col1.y;
var _local5:Number = col2.y;
_local6 = ((_local2 * _local5) - (_local3 * _local4));
_local6 = (1 / _local6);
_arg1.col1.x = (_local6 * _local5);
_arg1.col2.x = (-(_local6) * _local3);
_arg1.col1.y = (-(_local6) * _local4);
_arg1.col2.y = (_local6 * _local2);
return (_arg1);
}
public function GetAngle():Number{
return (Math.atan2(col1.y, col1.x));
}
public function Solve(_arg1:b2Vec2, _arg2:Number, _arg3:Number):b2Vec2{
var _local4:Number = col1.x;
var _local5:Number = col2.x;
var _local6:Number = col1.y;
var _local7:Number = col2.y;
var _local8:Number = ((_local4 * _local7) - (_local5 * _local6));
_local8 = (1 / _local8);
_arg1.x = (_local8 * ((_local7 * _arg2) - (_local5 * _arg3)));
_arg1.y = (_local8 * ((_local4 * _arg3) - (_local6 * _arg2)));
return (_arg1);
}
}
}//package Box2D.Common.Math
Section 31
//b2Math (Box2D.Common.Math.b2Math)
package Box2D.Common.Math {
public class b2Math {
public static const b2Mat22_identity:b2Mat22 = new b2Mat22(0, new b2Vec2(1, 0), new b2Vec2(0, 1));
public static const b2XForm_identity:b2XForm = new b2XForm(b2Vec2_zero, b2Mat22_identity);
public static const b2Vec2_zero:b2Vec2 = new b2Vec2(0, 0);
public static function b2CrossVF(_arg1:b2Vec2, _arg2:Number):b2Vec2{
var _local3:b2Vec2 = new b2Vec2((_arg2 * _arg1.y), (-(_arg2) * _arg1.x));
return (_local3);
}
public static function AddVV(_arg1:b2Vec2, _arg2:b2Vec2):b2Vec2{
var _local3:b2Vec2 = new b2Vec2((_arg1.x + _arg2.x), (_arg1.y + _arg2.y));
return (_local3);
}
public static function b2IsValid(_arg1:Number):Boolean{
return (isFinite(_arg1));
}
public static function b2MinV(_arg1:b2Vec2, _arg2:b2Vec2):b2Vec2{
var _local3:b2Vec2 = new b2Vec2(b2Min(_arg1.x, _arg2.x), b2Min(_arg1.y, _arg2.y));
return (_local3);
}
public static function b2MulX(_arg1:b2XForm, _arg2:b2Vec2):b2Vec2{
var _local3:b2Vec2;
_local3 = b2MulMV(_arg1.R, _arg2);
_local3.x = (_local3.x + _arg1.position.x);
_local3.y = (_local3.y + _arg1.position.y);
return (_local3);
}
public static function b2DistanceSquared(_arg1:b2Vec2, _arg2:b2Vec2):Number{
var _local3:Number = (_arg1.x - _arg2.x);
var _local4:Number = (_arg1.y - _arg2.y);
return (((_local3 * _local3) + (_local4 * _local4)));
}
public static function b2Swap(_arg1:Array, _arg2:Array):void{
var _local3:* = _arg1[0];
_arg1[0] = _arg2[0];
_arg2[0] = _local3;
}
public static function b2AbsM(_arg1:b2Mat22):b2Mat22{
var _local2:b2Mat22 = new b2Mat22(0, b2AbsV(_arg1.col1), b2AbsV(_arg1.col2));
return (_local2);
}
public static function SubtractVV(_arg1:b2Vec2, _arg2:b2Vec2):b2Vec2{
var _local3:b2Vec2 = new b2Vec2((_arg1.x - _arg2.x), (_arg1.y - _arg2.y));
return (_local3);
}
public static function b2MulXT(_arg1:b2XForm, _arg2:b2Vec2):b2Vec2{
var _local3:b2Vec2;
var _local4:Number;
_local3 = SubtractVV(_arg2, _arg1.position);
_local4 = ((_local3.x * _arg1.R.col1.x) + (_local3.y * _arg1.R.col1.y));
_local3.y = ((_local3.x * _arg1.R.col2.x) + (_local3.y * _arg1.R.col2.y));
_local3.x = _local4;
return (_local3);
}
public static function b2Abs(_arg1:Number):Number{
return (((_arg1 > 0)) ? _arg1 : -(_arg1));
}
public static function b2Clamp(_arg1:Number, _arg2:Number, _arg3:Number):Number{
return (b2Max(_arg2, b2Min(_arg1, _arg3)));
}
public static function b2AbsV(_arg1:b2Vec2):b2Vec2{
var _local2:b2Vec2 = new b2Vec2(b2Abs(_arg1.x), b2Abs(_arg1.y));
return (_local2);
}
public static function MulFV(_arg1:Number, _arg2:b2Vec2):b2Vec2{
var _local3:b2Vec2 = new b2Vec2((_arg1 * _arg2.x), (_arg1 * _arg2.y));
return (_local3);
}
public static function b2CrossVV(_arg1:b2Vec2, _arg2:b2Vec2):Number{
return (((_arg1.x * _arg2.y) - (_arg1.y * _arg2.x)));
}
public static function b2Dot(_arg1:b2Vec2, _arg2:b2Vec2):Number{
return (((_arg1.x * _arg2.x) + (_arg1.y * _arg2.y)));
}
public static function b2CrossFV(_arg1:Number, _arg2:b2Vec2):b2Vec2{
var _local3:b2Vec2 = new b2Vec2((-(_arg1) * _arg2.y), (_arg1 * _arg2.x));
return (_local3);
}
public static function AddMM(_arg1:b2Mat22, _arg2:b2Mat22):b2Mat22{
var _local3:b2Mat22 = new b2Mat22(0, AddVV(_arg1.col1, _arg2.col1), AddVV(_arg1.col2, _arg2.col2));
return (_local3);
}
public static function b2Distance(_arg1:b2Vec2, _arg2:b2Vec2):Number{
var _local3:Number = (_arg1.x - _arg2.x);
var _local4:Number = (_arg1.y - _arg2.y);
return (Math.sqrt(((_local3 * _local3) + (_local4 * _local4))));
}
public static function b2MulTMM(_arg1:b2Mat22, _arg2:b2Mat22):b2Mat22{
var _local3:b2Vec2 = new b2Vec2(b2Dot(_arg1.col1, _arg2.col1), b2Dot(_arg1.col2, _arg2.col1));
var _local4:b2Vec2 = new b2Vec2(b2Dot(_arg1.col1, _arg2.col2), b2Dot(_arg1.col2, _arg2.col2));
var _local5:b2Mat22 = new b2Mat22(0, _local3, _local4);
return (_local5);
}
public static function b2MaxV(_arg1:b2Vec2, _arg2:b2Vec2):b2Vec2{
var _local3:b2Vec2 = new b2Vec2(b2Max(_arg1.x, _arg2.x), b2Max(_arg1.y, _arg2.y));
return (_local3);
}
public static function b2IsPowerOfTwo(_arg1:uint):Boolean{
var _local2:Boolean = (((_arg1 > 0)) && (((_arg1 & (_arg1 - 1)) == 0)));
return (_local2);
}
public static function b2ClampV(_arg1:b2Vec2, _arg2:b2Vec2, _arg3:b2Vec2):b2Vec2{
return (b2MaxV(_arg2, b2MinV(_arg1, _arg3)));
}
public static function b2RandomRange(_arg1:Number, _arg2:Number):Number{
var _local3:Number = Math.random();
_local3 = (((_arg2 - _arg1) * _local3) + _arg1);
return (_local3);
}
public static function b2MulTMV(_arg1:b2Mat22, _arg2:b2Vec2):b2Vec2{
var _local3:b2Vec2 = new b2Vec2(b2Dot(_arg2, _arg1.col1), b2Dot(_arg2, _arg1.col2));
return (_local3);
}
public static function b2Min(_arg1:Number, _arg2:Number):Number{
return (((_arg1 < _arg2)) ? _arg1 : _arg2);
}
public static function b2Random():Number{
return (((Math.random() * 2) - 1));
}
public static function b2MulMM(_arg1:b2Mat22, _arg2:b2Mat22):b2Mat22{
var _local3:b2Mat22 = new b2Mat22(0, b2MulMV(_arg1, _arg2.col1), b2MulMV(_arg1, _arg2.col2));
return (_local3);
}
public static function b2NextPowerOfTwo(_arg1:uint):uint{
_arg1 = (_arg1 | ((_arg1 >> 1) & 2147483647));
_arg1 = (_arg1 | ((_arg1 >> 2) & 1073741823));
_arg1 = (_arg1 | ((_arg1 >> 4) & 268435455));
_arg1 = (_arg1 | ((_arg1 >> 8) & 0xFFFFFF));
_arg1 = (_arg1 | ((_arg1 >> 16) & 0xFFFF));
return ((_arg1 + 1));
}
public static function b2Max(_arg1:Number, _arg2:Number):Number{
return (((_arg1 > _arg2)) ? _arg1 : _arg2);
}
public static function b2MulMV(_arg1:b2Mat22, _arg2:b2Vec2):b2Vec2{
var _local3:b2Vec2 = new b2Vec2(((_arg1.col1.x * _arg2.x) + (_arg1.col2.x * _arg2.y)), ((_arg1.col1.y * _arg2.x) + (_arg1.col2.y * _arg2.y)));
return (_local3);
}
}
}//package Box2D.Common.Math
Section 32
//b2Sweep (Box2D.Common.Math.b2Sweep)
package Box2D.Common.Math {
public class b2Sweep {
public var localCenter:b2Vec2;
public var a:Number;
public var c:b2Vec2;
public var a0:Number;
public var c0:b2Vec2;
public var t0:Number;
public function b2Sweep(){
localCenter = new b2Vec2();
c0 = new b2Vec2();
c = new b2Vec2();
super();
}
public function Advance(_arg1:Number):void{
var _local2:Number;
if ((((t0 < _arg1)) && (((1 - t0) > Number.MIN_VALUE)))){
_local2 = ((_arg1 - t0) / (1 - t0));
c0.x = (((1 - _local2) * c0.x) + (_local2 * c.x));
c0.y = (((1 - _local2) * c0.y) + (_local2 * c.y));
a0 = (((1 - _local2) * a0) + (_local2 * a));
t0 = _arg1;
};
}
public function GetXForm(_arg1:b2XForm, _arg2:Number):void{
var _local4:Number;
var _local5:Number;
if ((1 - t0) > Number.MIN_VALUE){
_local4 = ((_arg2 - t0) / (1 - t0));
_arg1.position.x = (((1 - _local4) * c0.x) + (_local4 * c.x));
_arg1.position.y = (((1 - _local4) * c0.y) + (_local4 * c.y));
_local5 = (((1 - _local4) * a0) + (_local4 * a));
_arg1.R.Set(_local5);
} else {
_arg1.position.SetV(c);
_arg1.R.Set(a);
};
var _local3:b2Mat22 = _arg1.R;
_arg1.position.x = (_arg1.position.x - ((_local3.col1.x * localCenter.x) + (_local3.col2.x * localCenter.y)));
_arg1.position.y = (_arg1.position.y - ((_local3.col1.y * localCenter.x) + (_local3.col2.y * localCenter.y)));
}
}
}//package Box2D.Common.Math
Section 33
//b2Vec2 (Box2D.Common.Math.b2Vec2)
package Box2D.Common.Math {
public class b2Vec2 {
public var y:Number;
public var x:Number;
public function b2Vec2(_arg1:Number=0, _arg2:Number=0):void{
x = _arg1;
y = _arg2;
}
public function Add(_arg1:b2Vec2):void{
x = (x + _arg1.x);
y = (y + _arg1.y);
}
public function Set(_arg1:Number=0, _arg2:Number=0):void{
x = _arg1;
y = _arg2;
}
public function Multiply(_arg1:Number):void{
x = (x * _arg1);
y = (y * _arg1);
}
public function Length():Number{
return (Math.sqrt(((x * x) + (y * y))));
}
public function LengthSquared():Number{
return (((x * x) + (y * y)));
}
public function MulM(_arg1:b2Mat22):void{
var _local2:Number = x;
x = ((_arg1.col1.x * _local2) + (_arg1.col2.x * y));
y = ((_arg1.col1.y * _local2) + (_arg1.col2.y * y));
}
public function SetZero():void{
x = 0;
y = 0;
}
public function MinV(_arg1:b2Vec2):void{
x = ((x < _arg1.x)) ? x : _arg1.x;
y = ((y < _arg1.y)) ? y : _arg1.y;
}
public function Normalize():Number{
var _local1:Number = Math.sqrt(((x * x) + (y * y)));
if (_local1 < Number.MIN_VALUE){
return (0);
};
var _local2:Number = (1 / _local1);
x = (x * _local2);
y = (y * _local2);
return (_local1);
}
public function CrossVF(_arg1:Number):void{
var _local2:Number = x;
x = (_arg1 * y);
y = (-(_arg1) * _local2);
}
public function MaxV(_arg1:b2Vec2):void{
x = ((x > _arg1.x)) ? x : _arg1.x;
y = ((y > _arg1.y)) ? y : _arg1.y;
}
public function SetV(_arg1:b2Vec2):void{
x = _arg1.x;
y = _arg1.y;
}
public function Negative():b2Vec2{
return (new b2Vec2(-(x), -(y)));
}
public function CrossFV(_arg1:Number):void{
var _local2:Number = x;
x = (-(_arg1) * y);
y = (_arg1 * _local2);
}
public function Abs():void{
if (x < 0){
x = -(x);
};
if (y < 0){
y = -(y);
};
}
public function Subtract(_arg1:b2Vec2):void{
x = (x - _arg1.x);
y = (y - _arg1.y);
}
public function Copy():b2Vec2{
return (new b2Vec2(x, y));
}
public function MulTM(_arg1:b2Mat22):void{
var _local2:Number = b2Math.b2Dot(this, _arg1.col1);
y = b2Math.b2Dot(this, _arg1.col2);
x = _local2;
}
public function IsValid():Boolean{
return (((b2Math.b2IsValid(x)) && (b2Math.b2IsValid(y))));
}
public static function Make(_arg1:Number, _arg2:Number):b2Vec2{
return (new b2Vec2(_arg1, _arg2));
}
}
}//package Box2D.Common.Math
Section 34
//b2XForm (Box2D.Common.Math.b2XForm)
package Box2D.Common.Math {
public class b2XForm {
public var position:b2Vec2;
public var R:b2Mat22;
public function b2XForm(_arg1:b2Vec2=null, _arg2:b2Mat22=null):void{
position = new b2Vec2();
R = new b2Mat22();
super();
if (_arg1){
position.SetV(_arg1);
R.SetM(_arg2);
};
}
public function Initialize(_arg1:b2Vec2, _arg2:b2Mat22):void{
position.SetV(_arg1);
R.SetM(_arg2);
}
public function Set(_arg1:b2XForm):void{
position.SetV(_arg1.position);
R.SetM(_arg1.R);
}
public function SetIdentity():void{
position.SetZero();
R.SetIdentity();
}
}
}//package Box2D.Common.Math
Section 35
//b2Color (Box2D.Common.b2Color)
package Box2D.Common {
import Box2D.Common.Math.*;
public class b2Color {
private var _r:uint;// = 0
private var _g:uint;// = 0
private var _b:uint;// = 0
public function b2Color(_arg1:Number, _arg2:Number, _arg3:Number){
_r = uint((0xFF * b2Math.b2Clamp(_arg1, 0, 1)));
_g = uint((0xFF * b2Math.b2Clamp(_arg2, 0, 1)));
_b = uint((0xFF * b2Math.b2Clamp(_arg3, 0, 1)));
}
public function Set(_arg1:Number, _arg2:Number, _arg3:Number):void{
_r = uint((0xFF * b2Math.b2Clamp(_arg1, 0, 1)));
_g = uint((0xFF * b2Math.b2Clamp(_arg2, 0, 1)));
_b = uint((0xFF * b2Math.b2Clamp(_arg3, 0, 1)));
}
public function set b(_arg1:Number):void{
_b = uint((0xFF * b2Math.b2Clamp(_arg1, 0, 1)));
}
public function get color():uint{
return (((_r | (_g << 8)) | (_b << 16)));
}
public function set r(_arg1:Number):void{
_r = uint((0xFF * b2Math.b2Clamp(_arg1, 0, 1)));
}
public function set g(_arg1:Number):void{
_g = uint((0xFF * b2Math.b2Clamp(_arg1, 0, 1)));
}
}
}//package Box2D.Common
Section 36
//b2Settings (Box2D.Common.b2Settings)
package Box2D.Common {
import Box2D.Common.Math.*;
public class b2Settings {
public static const b2_angularSleepTolerance:Number = 0.0111111111111111;
public static const b2_linearSleepTolerance:Number = 0.01;
public static const b2_angularSlop:Number = 0.0349065850398866;
public static const b2_linearSlop:Number = 0.005;
public static const b2_pi:Number = 3.14159265358979;
public static const b2_maxProxies:int = 0x0200;
public static const b2_maxAngularVelocitySquared:Number = 62500;
public static const b2_maxPolygonVertices:int = 32;
public static const b2_velocityThreshold:Number = 1;
public static const b2_contactBaumgarte:Number = 0.2;
public static const b2_maxPairs:int = 4096;
public static const b2_maxTOIContactsPerIsland:int = 32;
public static const b2_timeToSleep:Number = 0.5;
public static const b2_maxManifoldPoints:int = 2;
public static const b2_maxAngularVelocity:Number = 250;
public static const b2_maxAngularCorrection:Number = 0.139626340159546;
public static const USHRT_MAX:int = 0xFFFF;
public static const b2_maxLinearVelocity:Number = 200;
public static const b2_maxLinearCorrection:Number = 0.2;
public static const b2_toiSlop:Number = 0.04;
public static const b2_maxLinearVelocitySquared:Number = 40000;
public static function b2Assert(_arg1:Boolean):void{
var _local2:b2Vec2;
if (!_arg1){
_local2.x++;
};
}
}
}//package Box2D.Common
Section 37
//b2CircleContact (Box2D.Dynamics.Contacts.b2CircleContact)
package Box2D.Dynamics.Contacts {
import Box2D.Dynamics.*;
import Box2D.Common.Math.*;
import Box2D.Collision.*;
import Box2D.Collision.Shapes.*;
import Box2D.Common.*;
public class b2CircleContact extends b2Contact {
private var m_manifolds:Array;
public var m_manifold:b2Manifold;
private var m0:b2Manifold;
private static const s_evalCP:b2ContactPoint = new b2ContactPoint();
public function b2CircleContact(_arg1:b2Shape, _arg2:b2Shape){
m_manifolds = [new b2Manifold()];
m0 = new b2Manifold();
super(_arg1, _arg2);
m_manifold = m_manifolds[0];
m_manifold.pointCount = 0;
var _local3:b2ManifoldPoint = m_manifold.points[0];
_local3.normalImpulse = 0;
_local3.tangentImpulse = 0;
}
override public function Evaluate(_arg1:b2ContactListener):void{
var _local2:b2Vec2;
var _local3:b2Vec2;
var _local4:b2ManifoldPoint;
var _local8:b2ManifoldPoint;
var _local5:b2Body = m_shape1.m_body;
var _local6:b2Body = m_shape2.m_body;
m0.Set(m_manifold);
b2Collision.b2CollideCircles(m_manifold, (m_shape1 as b2CircleShape), _local5.m_xf, (m_shape2 as b2CircleShape), _local6.m_xf);
var _local7:b2ContactPoint = s_evalCP;
_local7.shape1 = m_shape1;
_local7.shape2 = m_shape2;
_local7.friction = m_friction;
_local7.restitution = m_restitution;
if (m_manifold.pointCount > 0){
m_manifoldCount = 1;
_local8 = m_manifold.points[0];
if (m0.pointCount == 0){
_local8.normalImpulse = 0;
_local8.tangentImpulse = 0;
if (_arg1){
_local7.position = _local5.GetWorldPoint(_local8.localPoint1);
_local2 = _local5.GetLinearVelocityFromLocalPoint(_local8.localPoint1);
_local3 = _local6.GetLinearVelocityFromLocalPoint(_local8.localPoint2);
_local7.velocity.Set((_local3.x - _local2.x), (_local3.y - _local2.y));
_local7.normal.SetV(m_manifold.normal);
_local7.separation = _local8.separation;
_local7.id.key = _local8.id._key;
_arg1.Add(_local7);
};
} else {
_local4 = m0.points[0];
_local8.normalImpulse = _local4.normalImpulse;
_local8.tangentImpulse = _local4.tangentImpulse;
if (_arg1){
_local7.position = _local5.GetWorldPoint(_local8.localPoint1);
_local2 = _local5.GetLinearVelocityFromLocalPoint(_local8.localPoint1);
_local3 = _local6.GetLinearVelocityFromLocalPoint(_local8.localPoint2);
_local7.velocity.Set((_local3.x - _local2.x), (_local3.y - _local2.y));
_local7.normal.SetV(m_manifold.normal);
_local7.separation = _local8.separation;
_local7.id.key = _local8.id._key;
_arg1.Persist(_local7);
};
};
} else {
m_manifoldCount = 0;
if ((((m0.pointCount > 0)) && (_arg1))){
_local4 = m0.points[0];
_local7.position = _local5.GetWorldPoint(_local4.localPoint1);
_local2 = _local5.GetLinearVelocityFromLocalPoint(_local4.localPoint1);
_local3 = _local6.GetLinearVelocityFromLocalPoint(_local4.localPoint2);
_local7.velocity.Set((_local3.x - _local2.x), (_local3.y - _local2.y));
_local7.normal.SetV(m0.normal);
_local7.separation = _local4.separation;
_local7.id.key = _local4.id._key;
_arg1.Remove(_local7);
};
};
}
override public function GetManifolds():Array{
return (m_manifolds);
}
public static function Destroy(_arg1:b2Contact, _arg2):void{
}
public static function Create(_arg1:b2Shape, _arg2:b2Shape, _arg3):b2Contact{
return (new b2CircleContact(_arg1, _arg2));
}
}
}//package Box2D.Dynamics.Contacts
Section 38
//b2Contact (Box2D.Dynamics.Contacts.b2Contact)
package Box2D.Dynamics.Contacts {
import Box2D.Dynamics.*;
import Box2D.Common.Math.*;
import Box2D.Collision.*;
import Box2D.Collision.Shapes.*;
import Box2D.Common.*;
public class b2Contact {
public var m_shape1:b2Shape;
public var m_shape2:b2Shape;
public var m_prev:b2Contact;
public var m_toi:Number;
public var m_next:b2Contact;
public var m_friction:Number;
public var m_manifoldCount:int;
public var m_node1:b2ContactEdge;
public var m_node2:b2ContactEdge;
public var m_restitution:Number;
public var m_flags:uint;
public static var e_toiFlag:uint = 8;
public static var e_nonSolidFlag:uint = 1;
public static var e_slowFlag:uint = 2;
public static var e_islandFlag:uint = 4;
public static var s_registers:Array;
public static var s_initialized:Boolean = false;
public function b2Contact(_arg1:b2Shape=null, _arg2:b2Shape=null){
m_node1 = new b2ContactEdge();
m_node2 = new b2ContactEdge();
super();
m_flags = 0;
if (((!(_arg1)) || (!(_arg2)))){
m_shape1 = null;
m_shape2 = null;
return;
};
if (((_arg1.IsSensor()) || (_arg2.IsSensor()))){
m_flags = (m_flags | e_nonSolidFlag);
};
m_shape1 = _arg1;
m_shape2 = _arg2;
m_manifoldCount = 0;
m_friction = Math.sqrt((m_shape1.m_friction * m_shape2.m_friction));
m_restitution = b2Math.b2Max(m_shape1.m_restitution, m_shape2.m_restitution);
m_prev = null;
m_next = null;
m_node1.contact = null;
m_node1.prev = null;
m_node1.next = null;
m_node1.other = null;
m_node2.contact = null;
m_node2.prev = null;
m_node2.next = null;
m_node2.other = null;
}
public function IsSolid():Boolean{
return (((m_flags & e_nonSolidFlag) == 0));
}
public function GetShape1():b2Shape{
return (m_shape1);
}
public function GetShape2():b2Shape{
return (m_shape2);
}
public function GetNext():b2Contact{
return (m_next);
}
public function GetManifoldCount():int{
return (m_manifoldCount);
}
public function GetManifolds():Array{
return (null);
}
public function Update(_arg1:b2ContactListener):void{
var _local2:int = m_manifoldCount;
Evaluate(_arg1);
var _local3:int = m_manifoldCount;
var _local4:b2Body = m_shape1.m_body;
var _local5:b2Body = m_shape2.m_body;
if ((((_local3 == 0)) && ((_local2 > 0)))){
_local4.WakeUp();
_local5.WakeUp();
};
if (((((((_local4.IsStatic()) || (_local4.IsBullet()))) || (_local5.IsStatic()))) || (_local5.IsBullet()))){
m_flags = (m_flags & ~(e_slowFlag));
} else {
m_flags = (m_flags | e_slowFlag);
};
}
public function Evaluate(_arg1:b2ContactListener):void{
}
public static function InitializeRegisters():void{
var _local2:int;
s_registers = new Array(b2Shape.e_shapeTypeCount);
var _local1:int;
while (_local1 < b2Shape.e_shapeTypeCount) {
s_registers[_local1] = new Array(b2Shape.e_shapeTypeCount);
_local2 = 0;
while (_local2 < b2Shape.e_shapeTypeCount) {
s_registers[_local1][_local2] = new b2ContactRegister();
_local2++;
};
_local1++;
};
AddType(b2CircleContact.Create, b2CircleContact.Destroy, b2Shape.e_circleShape, b2Shape.e_circleShape);
AddType(b2PolyAndCircleContact.Create, b2PolyAndCircleContact.Destroy, b2Shape.e_polygonShape, b2Shape.e_circleShape);
AddType(b2PolygonContact.Create, b2PolygonContact.Destroy, b2Shape.e_polygonShape, b2Shape.e_polygonShape);
}
public static function Destroy(_arg1:b2Contact, _arg2):void{
if (_arg1.m_manifoldCount > 0){
_arg1.m_shape1.m_body.WakeUp();
_arg1.m_shape2.m_body.WakeUp();
};
var _local3:int = _arg1.m_shape1.m_type;
var _local4:int = _arg1.m_shape2.m_type;
var _local5:b2ContactRegister = s_registers[_local3][_local4];
var _local6:Function = _local5.destroyFcn;
_local6(_arg1, _arg2);
}
public static function AddType(_arg1:Function, _arg2:Function, _arg3:int, _arg4:int):void{
s_registers[_arg3][_arg4].createFcn = _arg1;
s_registers[_arg3][_arg4].destroyFcn = _arg2;
s_registers[_arg3][_arg4].primary = true;
if (_arg3 != _arg4){
s_registers[_arg4][_arg3].createFcn = _arg1;
s_registers[_arg4][_arg3].destroyFcn = _arg2;
s_registers[_arg4][_arg3].primary = false;
};
}
public static function Create(_arg1:b2Shape, _arg2:b2Shape, _arg3):b2Contact{
var _local8:b2Contact;
var _local9:int;
var _local10:b2Manifold;
if (s_initialized == false){
InitializeRegisters();
s_initialized = true;
};
var _local4:int = _arg1.m_type;
var _local5:int = _arg2.m_type;
var _local6:b2ContactRegister = s_registers[_local4][_local5];
var _local7:Function = _local6.createFcn;
if (_local7 != null){
if (_local6.primary){
return (_local7(_arg1, _arg2, _arg3));
};
_local8 = _local7(_arg2, _arg1, _arg3);
_local9 = 0;
while (_local9 < _local8.m_manifoldCount) {
_local10 = _local8.GetManifolds()[_local9];
_local8.GetManifolds()[_local9].normal = _local10.normal.Negative();
_local9++;
};
return (_local8);
//unresolved jump
};
return (null);
}
}
}//package Box2D.Dynamics.Contacts
Section 39
//b2ContactConstraint (Box2D.Dynamics.Contacts.b2ContactConstraint)
package Box2D.Dynamics.Contacts {
import Box2D.Dynamics.*;
import Box2D.Common.Math.*;
import Box2D.Collision.*;
import Box2D.Common.*;
public class b2ContactConstraint {
public var points:Array;
public var normal:b2Vec2;
public var restitution:Number;
public var body1:b2Body;
public var manifold:b2Manifold;
public var body2:b2Body;
public var friction:Number;
public var pointCount:int;
public function b2ContactConstraint(){
normal = new b2Vec2();
super();
points = new Array(b2Settings.b2_maxManifoldPoints);
var _local1:int;
while (_local1 < b2Settings.b2_maxManifoldPoints) {
points[_local1] = new b2ContactConstraintPoint();
_local1++;
};
}
}
}//package Box2D.Dynamics.Contacts
Section 40
//b2ContactConstraintPoint (Box2D.Dynamics.Contacts.b2ContactConstraintPoint)
package Box2D.Dynamics.Contacts {
import Box2D.Common.Math.*;
public class b2ContactConstraintPoint {
public var r2:b2Vec2;
public var separation:Number;
public var positionImpulse:Number;
public var normalImpulse:Number;
public var tangentMass:Number;
public var equalizedMass:Number;
public var tangentImpulse:Number;
public var localAnchor1:b2Vec2;
public var localAnchor2:b2Vec2;
public var normalMass:Number;
public var velocityBias:Number;
public var r1:b2Vec2;
public function b2ContactConstraintPoint(){
localAnchor1 = new b2Vec2();
localAnchor2 = new b2Vec2();
r1 = new b2Vec2();
r2 = new b2Vec2();
super();
}
}
}//package Box2D.Dynamics.Contacts
Section 41
//b2ContactEdge (Box2D.Dynamics.Contacts.b2ContactEdge)
package Box2D.Dynamics.Contacts {
import Box2D.Dynamics.*;
public class b2ContactEdge {
public var other:b2Body;
public var prev:b2ContactEdge;
public var contact:b2Contact;
public var next:b2ContactEdge;
}
}//package Box2D.Dynamics.Contacts
Section 42
//b2ContactRegister (Box2D.Dynamics.Contacts.b2ContactRegister)
package Box2D.Dynamics.Contacts {
public class b2ContactRegister {
public var primary:Boolean;
public var createFcn:Function;
public var destroyFcn:Function;
}
}//package Box2D.Dynamics.Contacts
Section 43
//b2ContactResult (Box2D.Dynamics.Contacts.b2ContactResult)
package Box2D.Dynamics.Contacts {
import Box2D.Common.Math.*;
import Box2D.Collision.*;
import Box2D.Collision.Shapes.*;
public class b2ContactResult {
public var position:b2Vec2;
public var shape1:b2Shape;
public var shape2:b2Shape;
public var normalImpulse:Number;
public var normal:b2Vec2;
public var tangentImpulse:Number;
public var id:b2ContactID;
public function b2ContactResult(){
position = new b2Vec2();
normal = new b2Vec2();
id = new b2ContactID();
super();
}
}
}//package Box2D.Dynamics.Contacts
Section 44
//b2ContactSolver (Box2D.Dynamics.Contacts.b2ContactSolver)
package Box2D.Dynamics.Contacts {
import Box2D.Dynamics.*;
import Box2D.Common.Math.*;
import Box2D.Collision.*;
import Box2D.Common.*;
public class b2ContactSolver {
public var m_constraintCount:int;
public var m_constraints:Array;
public var m_allocator;
public var m_step:b2TimeStep;
public function b2ContactSolver(_arg1:b2TimeStep, _arg2:Array, _arg3:int, _arg4){
var _local5:b2Contact;
var _local6:int;
var _local7:b2Vec2;
var _local8:b2Mat22;
var _local10:b2Body;
var _local11:b2Body;
var _local12:int;
var _local13:Array;
var _local14:Number;
var _local15:Number;
var _local16:Number;
var _local17:Number;
var _local18:Number;
var _local19:Number;
var _local20:Number;
var _local21:Number;
var _local22:int;
var _local23:b2Manifold;
var _local24:Number;
var _local25:Number;
var _local26:b2ContactConstraint;
var _local27:uint;
var _local28:b2ManifoldPoint;
var _local29:b2ContactConstraintPoint;
var _local30:Number;
var _local31:Number;
var _local32:Number;
var _local33:Number;
var _local34:Number;
var _local35:Number;
var _local36:Number;
var _local37:Number;
var _local38:Number;
var _local39:Number;
var _local40:Number;
var _local41:Number;
var _local42:Number;
var _local43:Number;
var _local44:Number;
var _local45:Number;
var _local46:Number;
var _local47:Number;
m_step = new b2TimeStep();
m_constraints = new Array();
super();
m_step.dt = _arg1.dt;
m_step.inv_dt = _arg1.inv_dt;
m_step.maxIterations = _arg1.maxIterations;
m_allocator = _arg4;
m_constraintCount = 0;
_local6 = 0;
while (_local6 < _arg3) {
_local5 = _arg2[_local6];
m_constraintCount = (m_constraintCount + _local5.m_manifoldCount);
_local6++;
};
_local6 = 0;
while (_local6 < m_constraintCount) {
m_constraints[_local6] = new b2ContactConstraint();
_local6++;
};
var _local9:int;
_local6 = 0;
while (_local6 < _arg3) {
_local5 = _arg2[_local6];
_local10 = _local5.m_shape1.m_body;
_local11 = _local5.m_shape2.m_body;
_local12 = _local5.m_manifoldCount;
_local13 = _local5.GetManifolds();
_local14 = _local5.m_friction;
_local15 = _local5.m_restitution;
_local16 = _local10.m_linearVelocity.x;
_local17 = _local10.m_linearVelocity.y;
_local18 = _local11.m_linearVelocity.x;
_local19 = _local11.m_linearVelocity.y;
_local20 = _local10.m_angularVelocity;
_local21 = _local11.m_angularVelocity;
_local22 = 0;
while (_local22 < _local12) {
_local23 = _local13[_local22];
_local24 = _local23.normal.x;
_local25 = _local23.normal.y;
_local26 = m_constraints[_local9];
_local26.body1 = _local10;
_local26.body2 = _local11;
_local26.manifold = _local23;
_local26.normal.x = _local24;
_local26.normal.y = _local25;
_local26.pointCount = _local23.pointCount;
_local26.friction = _local14;
_local26.restitution = _local15;
_local27 = 0;
while (_local27 < _local26.pointCount) {
_local28 = _local23.points[_local27];
_local29 = _local26.points[_local27];
_local29.normalImpulse = _local28.normalImpulse;
_local29.tangentImpulse = _local28.tangentImpulse;
_local29.separation = _local28.separation;
_local29.positionImpulse = 0;
_local29.localAnchor1.SetV(_local28.localPoint1);
_local29.localAnchor2.SetV(_local28.localPoint2);
_local8 = _local10.m_xf.R;
_local32 = (_local28.localPoint1.x - _local10.m_sweep.localCenter.x);
_local33 = (_local28.localPoint1.y - _local10.m_sweep.localCenter.y);
_local30 = ((_local8.col1.x * _local32) + (_local8.col2.x * _local33));
_local33 = ((_local8.col1.y * _local32) + (_local8.col2.y * _local33));
_local32 = _local30;
_local29.r1.Set(_local32, _local33);
_local8 = _local11.m_xf.R;
_local34 = (_local28.localPoint2.x - _local11.m_sweep.localCenter.x);
_local35 = (_local28.localPoint2.y - _local11.m_sweep.localCenter.y);
_local30 = ((_local8.col1.x * _local34) + (_local8.col2.x * _local35));
_local35 = ((_local8.col1.y * _local34) + (_local8.col2.y * _local35));
_local34 = _local30;
_local29.r2.Set(_local34, _local35);
_local36 = ((_local32 * _local32) + (_local33 * _local33));
_local37 = ((_local34 * _local34) + (_local35 * _local35));
_local38 = ((_local32 * _local24) + (_local33 * _local25));
_local39 = ((_local34 * _local24) + (_local35 * _local25));
_local40 = (_local10.m_invMass + _local11.m_invMass);
_local40 = (_local40 + ((_local10.m_invI * (_local36 - (_local38 * _local38))) + (_local11.m_invI * (_local37 - (_local39 * _local39)))));
_local29.normalMass = (1 / _local40);
_local41 = ((_local10.m_mass * _local10.m_invMass) + (_local11.m_mass * _local11.m_invMass));
_local41 = (_local41 + (((_local10.m_mass * _local10.m_invI) * (_local36 - (_local38 * _local38))) + ((_local11.m_mass * _local11.m_invI) * (_local37 - (_local39 * _local39)))));
_local29.equalizedMass = (1 / _local41);
_local42 = _local25;
_local43 = -(_local24);
_local44 = ((_local32 * _local42) + (_local33 * _local43));
_local45 = ((_local34 * _local42) + (_local35 * _local43));
_local46 = (_local10.m_invMass + _local11.m_invMass);
_local46 = (_local46 + ((_local10.m_invI * (_local36 - (_local44 * _local44))) + (_local11.m_invI * (_local37 - (_local45 * _local45)))));
_local29.tangentMass = (1 / _local46);
_local29.velocityBias = 0;
if (_local29.separation > 0){
_local29.velocityBias = (-60 * _local29.separation);
};
_local30 = (((_local18 + (-(_local21) * _local35)) - _local16) - (-(_local20) * _local33));
_local31 = (((_local19 + (_local21 * _local34)) - _local17) - (_local20 * _local32));
_local47 = ((_local26.normal.x * _local30) + (_local26.normal.y * _local31));
if (_local47 < -(b2Settings.b2_velocityThreshold)){
_local29.velocityBias = (_local29.velocityBias + (-(_local26.restitution) * _local47));
};
_local27++;
};
_local9++;
_local22++;
};
_local6++;
};
}
public function InitVelocityConstraints(_arg1:b2TimeStep):void{
var _local2:b2Vec2;
var _local3:b2Vec2;
var _local4:b2Mat22;
var _local6:b2ContactConstraint;
var _local7:b2Body;
var _local8:b2Body;
var _local9:Number;
var _local10:Number;
var _local11:Number;
var _local12:Number;
var _local13:Number;
var _local14:Number;
var _local15:Number;
var _local16:Number;
var _local17:Number;
var _local18:int;
var _local19:int;
var _local20:b2ContactConstraintPoint;
var _local21:Number;
var _local22:Number;
var _local23:b2ContactConstraintPoint;
var _local5:int;
while (_local5 < m_constraintCount) {
_local6 = m_constraints[_local5];
_local7 = _local6.body1;
_local8 = _local6.body2;
_local9 = _local7.m_invMass;
_local10 = _local7.m_invI;
_local11 = _local8.m_invMass;
_local12 = _local8.m_invI;
_local13 = _local6.normal.x;
_local14 = _local6.normal.y;
_local15 = _local14;
_local16 = -(_local13);
if (_arg1.warmStarting){
_local19 = _local6.pointCount;
_local18 = 0;
while (_local18 < _local19) {
_local20 = _local6.points[_local18];
_local6.points[_local18].normalImpulse = (_local20.normalImpulse * _arg1.dtRatio);
_local20.tangentImpulse = (_local20.tangentImpulse * _arg1.dtRatio);
_local21 = ((_local20.normalImpulse * _local13) + (_local20.tangentImpulse * _local15));
_local22 = ((_local20.normalImpulse * _local14) + (_local20.tangentImpulse * _local16));
_local7.m_angularVelocity = (_local7.m_angularVelocity - (_local10 * ((_local20.r1.x * _local22) - (_local20.r1.y * _local21))));
_local7.m_linearVelocity.x = (_local7.m_linearVelocity.x - (_local9 * _local21));
_local7.m_linearVelocity.y = (_local7.m_linearVelocity.y - (_local9 * _local22));
_local8.m_angularVelocity = (_local8.m_angularVelocity + (_local12 * ((_local20.r2.x * _local22) - (_local20.r2.y * _local21))));
_local8.m_linearVelocity.x = (_local8.m_linearVelocity.x + (_local11 * _local21));
_local8.m_linearVelocity.y = (_local8.m_linearVelocity.y + (_local11 * _local22));
_local18++;
};
} else {
_local19 = _local6.pointCount;
_local18 = 0;
while (_local18 < _local19) {
_local23 = _local6.points[_local18];
_local23.normalImpulse = 0;
_local23.tangentImpulse = 0;
_local18++;
};
};
_local5++;
};
}
public function SolvePositionConstraints(_arg1:Number):Boolean{
var _local3:b2Mat22;
var _local4:b2Vec2;
var _local6:b2ContactConstraint;
var _local7:b2Body;
var _local8:b2Body;
var _local9:b2Vec2;
var _local10:Number;
var _local11:b2Vec2;
var _local12:Number;
var _local13:Number;
var _local14:Number;
var _local15:Number;
var _local16:Number;
var _local17:Number;
var _local18:Number;
var _local19:int;
var _local20:int;
var _local21:b2ContactConstraintPoint;
var _local22:Number;
var _local23:Number;
var _local24:Number;
var _local25:Number;
var _local26:Number;
var _local27:Number;
var _local28:Number;
var _local29:Number;
var _local30:Number;
var _local31:Number;
var _local32:Number;
var _local33:Number;
var _local34:Number;
var _local35:Number;
var _local36:Number;
var _local37:Number;
var _local38:Number;
var _local2:Number = 0;
var _local5:int;
while (_local5 < m_constraintCount) {
_local6 = m_constraints[_local5];
_local7 = _local6.body1;
_local8 = _local6.body2;
_local9 = _local7.m_sweep.c;
_local10 = _local7.m_sweep.a;
_local11 = _local8.m_sweep.c;
_local12 = _local8.m_sweep.a;
_local13 = (_local7.m_mass * _local7.m_invMass);
_local14 = (_local7.m_mass * _local7.m_invI);
_local15 = (_local8.m_mass * _local8.m_invMass);
_local16 = (_local8.m_mass * _local8.m_invI);
_local17 = _local6.normal.x;
_local18 = _local6.normal.y;
_local19 = _local6.pointCount;
_local20 = 0;
while (_local20 < _local19) {
_local21 = _local6.points[_local20];
_local3 = _local7.m_xf.R;
_local4 = _local7.m_sweep.localCenter;
_local22 = (_local21.localAnchor1.x - _local4.x);
_local23 = (_local21.localAnchor1.y - _local4.y);
_local26 = ((_local3.col1.x * _local22) + (_local3.col2.x * _local23));
_local23 = ((_local3.col1.y * _local22) + (_local3.col2.y * _local23));
_local22 = _local26;
_local3 = _local8.m_xf.R;
_local4 = _local8.m_sweep.localCenter;
_local24 = (_local21.localAnchor2.x - _local4.x);
_local25 = (_local21.localAnchor2.y - _local4.y);
_local26 = ((_local3.col1.x * _local24) + (_local3.col2.x * _local25));
_local25 = ((_local3.col1.y * _local24) + (_local3.col2.y * _local25));
_local24 = _local26;
_local27 = (_local9.x + _local22);
_local28 = (_local9.y + _local23);
_local29 = (_local11.x + _local24);
_local30 = (_local11.y + _local25);
_local31 = (_local29 - _local27);
_local32 = (_local30 - _local28);
_local33 = (((_local31 * _local17) + (_local32 * _local18)) + _local21.separation);
_local2 = b2Math.b2Min(_local2, _local33);
_local34 = (_arg1 * b2Math.b2Clamp((_local33 + b2Settings.b2_linearSlop), -(b2Settings.b2_maxLinearCorrection), 0));
_local35 = (-(_local21.equalizedMass) * _local34);
_local36 = _local21.positionImpulse;
_local21.positionImpulse = b2Math.b2Max((_local36 + _local35), 0);
_local35 = (_local21.positionImpulse - _local36);
_local37 = (_local35 * _local17);
_local38 = (_local35 * _local18);
_local9.x = (_local9.x - (_local13 * _local37));
_local9.y = (_local9.y - (_local13 * _local38));
_local10 = (_local10 - (_local14 * ((_local22 * _local38) - (_local23 * _local37))));
_local7.m_sweep.a = _local10;
_local7.SynchronizeTransform();
_local11.x = (_local11.x + (_local15 * _local37));
_local11.y = (_local11.y + (_local15 * _local38));
_local12 = (_local12 + (_local16 * ((_local24 * _local38) - (_local25 * _local37))));
_local8.m_sweep.a = _local12;
_local8.SynchronizeTransform();
_local20++;
};
_local5++;
};
return ((_local2 >= (-1.5 * b2Settings.b2_linearSlop)));
}
public function SolveVelocityConstraints():void{
var _local1:int;
var _local2:b2ContactConstraintPoint;
var _local3:Number;
var _local4:Number;
var _local5:Number;
var _local6:Number;
var _local7:Number;
var _local8:Number;
var _local9:Number;
var _local10:Number;
var _local11:Number;
var _local12:Number;
var _local13:Number;
var _local14:Number;
var _local15:Number;
var _local16:Number;
var _local17:b2Mat22;
var _local18:b2Vec2;
var _local20:b2ContactConstraint;
var _local21:b2Body;
var _local22:b2Body;
var _local23:Number;
var _local24:Number;
var _local25:b2Vec2;
var _local26:b2Vec2;
var _local27:Number;
var _local28:Number;
var _local29:Number;
var _local30:Number;
var _local31:Number;
var _local32:Number;
var _local33:Number;
var _local34:Number;
var _local35:Number;
var _local36:Number;
var _local37:int;
var _local38:Number;
var _local19:int;
while (_local19 < m_constraintCount) {
_local20 = m_constraints[_local19];
_local21 = _local20.body1;
_local22 = _local20.body2;
_local23 = _local21.m_angularVelocity;
_local24 = _local22.m_angularVelocity;
_local25 = _local21.m_linearVelocity;
_local26 = _local22.m_linearVelocity;
_local27 = _local21.m_invMass;
_local28 = _local21.m_invI;
_local29 = _local22.m_invMass;
_local30 = _local22.m_invI;
_local31 = _local20.normal.x;
_local32 = _local20.normal.y;
_local33 = _local32;
_local34 = -(_local31);
_local35 = _local20.friction;
_local37 = _local20.pointCount;
_local1 = 0;
while (_local1 < _local37) {
_local2 = _local20.points[_local1];
_local7 = (((_local26.x + (-(_local24) * _local2.r2.y)) - _local25.x) - (-(_local23) * _local2.r1.y));
_local8 = (((_local26.y + (_local24 * _local2.r2.x)) - _local25.y) - (_local23 * _local2.r1.x));
_local9 = ((_local7 * _local31) + (_local8 * _local32));
_local11 = (-(_local2.normalMass) * (_local9 - _local2.velocityBias));
_local10 = ((_local7 * _local33) + (_local8 * _local34));
_local12 = (_local2.tangentMass * -(_local10));
_local13 = b2Math.b2Max((_local2.normalImpulse + _local11), 0);
_local11 = (_local13 - _local2.normalImpulse);
_local38 = (_local35 * _local2.normalImpulse);
_local14 = b2Math.b2Clamp((_local2.tangentImpulse + _local12), -(_local38), _local38);
_local12 = (_local14 - _local2.tangentImpulse);
_local15 = ((_local11 * _local31) + (_local12 * _local33));
_local16 = ((_local11 * _local32) + (_local12 * _local34));
_local25.x = (_local25.x - (_local27 * _local15));
_local25.y = (_local25.y - (_local27 * _local16));
_local23 = (_local23 - (_local28 * ((_local2.r1.x * _local16) - (_local2.r1.y * _local15))));
_local26.x = (_local26.x + (_local29 * _local15));
_local26.y = (_local26.y + (_local29 * _local16));
_local24 = (_local24 + (_local30 * ((_local2.r2.x * _local16) - (_local2.r2.y * _local15))));
_local2.normalImpulse = _local13;
_local2.tangentImpulse = _local14;
_local1++;
};
_local21.m_angularVelocity = _local23;
_local22.m_angularVelocity = _local24;
_local19++;
};
}
public function FinalizeVelocityConstraints():void{
var _local2:b2ContactConstraint;
var _local3:b2Manifold;
var _local4:int;
var _local5:b2ManifoldPoint;
var _local6:b2ContactConstraintPoint;
var _local1:int;
while (_local1 < m_constraintCount) {
_local2 = m_constraints[_local1];
_local3 = _local2.manifold;
_local4 = 0;
while (_local4 < _local2.pointCount) {
_local5 = _local3.points[_local4];
_local6 = _local2.points[_local4];
_local5.normalImpulse = _local6.normalImpulse;
_local5.tangentImpulse = _local6.tangentImpulse;
_local4++;
};
_local1++;
};
}
}
}//package Box2D.Dynamics.Contacts
Section 45
//b2NullContact (Box2D.Dynamics.Contacts.b2NullContact)
package Box2D.Dynamics.Contacts {
import Box2D.Dynamics.*;
public class b2NullContact extends b2Contact {
override public function Evaluate(_arg1:b2ContactListener):void{
}
override public function GetManifolds():Array{
return (null);
}
}
}//package Box2D.Dynamics.Contacts
Section 46
//b2PolyAndCircleContact (Box2D.Dynamics.Contacts.b2PolyAndCircleContact)
package Box2D.Dynamics.Contacts {
import Box2D.Dynamics.*;
import Box2D.Common.Math.*;
import Box2D.Collision.*;
import Box2D.Collision.Shapes.*;
import Box2D.Common.*;
public class b2PolyAndCircleContact extends b2Contact {
private var m_manifolds:Array;
public var m_manifold:b2Manifold;
private var m0:b2Manifold;
private static const s_evalCP:b2ContactPoint = new b2ContactPoint();
public function b2PolyAndCircleContact(_arg1:b2Shape, _arg2:b2Shape){
m_manifolds = [new b2Manifold()];
m0 = new b2Manifold();
super(_arg1, _arg2);
m_manifold = m_manifolds[0];
b2Settings.b2Assert((m_shape1.m_type == b2Shape.e_polygonShape));
b2Settings.b2Assert((m_shape2.m_type == b2Shape.e_circleShape));
m_manifold.pointCount = 0;
var _local3:b2ManifoldPoint = m_manifold.points[0];
_local3.normalImpulse = 0;
_local3.tangentImpulse = 0;
}
override public function Evaluate(_arg1:b2ContactListener):void{
var _local2:int;
var _local3:b2Vec2;
var _local4:b2Vec2;
var _local5:b2ManifoldPoint;
var _local10:b2ManifoldPoint;
var _local11:Boolean;
var _local12:uint;
var _local13:int;
var _local6:b2Body = m_shape1.m_body;
var _local7:b2Body = m_shape2.m_body;
m0.Set(m_manifold);
b2Collision.b2CollidePolygonAndCircle(m_manifold, (m_shape1 as b2PolygonShape), _local6.m_xf, (m_shape2 as b2CircleShape), _local7.m_xf);
var _local8:Array = [false, false];
var _local9:b2ContactPoint = s_evalCP;
_local9.shape1 = m_shape1;
_local9.shape2 = m_shape2;
_local9.friction = m_friction;
_local9.restitution = m_restitution;
if (m_manifold.pointCount > 0){
_local2 = 0;
while (_local2 < m_manifold.pointCount) {
_local10 = m_manifold.points[_local2];
_local10.normalImpulse = 0;
_local10.tangentImpulse = 0;
_local11 = false;
_local12 = _local10.id._key;
_local13 = 0;
while (_local13 < m0.pointCount) {
if (_local8[_local13] == true){
} else {
_local5 = m0.points[_local13];
if (_local5.id._key == _local12){
_local8[_local13] = true;
_local10.normalImpulse = _local5.normalImpulse;
_local10.tangentImpulse = _local5.tangentImpulse;
_local11 = true;
if (_arg1 != null){
_local9.position = _local6.GetWorldPoint(_local10.localPoint1);
_local3 = _local6.GetLinearVelocityFromLocalPoint(_local10.localPoint1);
_local4 = _local7.GetLinearVelocityFromLocalPoint(_local10.localPoint2);
_local9.velocity.Set((_local4.x - _local3.x), (_local4.y - _local3.y));
_local9.normal.SetV(m_manifold.normal);
_local9.separation = _local10.separation;
_local9.id.key = _local12;
_arg1.Persist(_local9);
};
break;
};
};
_local13++;
};
if ((((_local11 == false)) && (!((_arg1 == null))))){
_local9.position = _local6.GetWorldPoint(_local10.localPoint1);
_local3 = _local6.GetLinearVelocityFromLocalPoint(_local10.localPoint1);
_local4 = _local7.GetLinearVelocityFromLocalPoint(_local10.localPoint2);
_local9.velocity.Set((_local4.x - _local3.x), (_local4.y - _local3.y));
_local9.normal.SetV(m_manifold.normal);
_local9.separation = _local10.separation;
_local9.id.key = _local12;
_arg1.Add(_local9);
};
_local2++;
};
m_manifoldCount = 1;
} else {
m_manifoldCount = 0;
};
if (_arg1 == null){
return;
};
_local2 = 0;
while (_local2 < m0.pointCount) {
if (_local8[_local2]){
} else {
_local5 = m0.points[_local2];
_local9.position = _local6.GetWorldPoint(_local5.localPoint1);
_local3 = _local6.GetLinearVelocityFromLocalPoint(_local5.localPoint1);
_local4 = _local7.GetLinearVelocityFromLocalPoint(_local5.localPoint2);
_local9.velocity.Set((_local4.x - _local3.x), (_local4.y - _local3.y));
_local9.normal.SetV(m0.normal);
_local9.separation = _local5.separation;
_local9.id.key = _local5.id._key;
_arg1.Remove(_local9);
};
_local2++;
};
}
override public function GetManifolds():Array{
return (m_manifolds);
}
public static function Destroy(_arg1:b2Contact, _arg2):void{
}
public static function Create(_arg1:b2Shape, _arg2:b2Shape, _arg3):b2Contact{
return (new b2PolyAndCircleContact(_arg1, _arg2));
}
}
}//package Box2D.Dynamics.Contacts
Section 47
//b2PolygonContact (Box2D.Dynamics.Contacts.b2PolygonContact)
package Box2D.Dynamics.Contacts {
import Box2D.Dynamics.*;
import Box2D.Common.Math.*;
import Box2D.Collision.*;
import Box2D.Collision.Shapes.*;
import Box2D.Common.*;
public class b2PolygonContact extends b2Contact {
private var m_manifolds:Array;
private var m0:b2Manifold;
public var m_manifold:b2Manifold;
private static const s_evalCP:b2ContactPoint = new b2ContactPoint();
public function b2PolygonContact(_arg1:b2Shape, _arg2:b2Shape):void{
m0 = new b2Manifold();
m_manifolds = [new b2Manifold()];
super(_arg1, _arg2);
m_manifold = m_manifolds[0];
m_manifold.pointCount = 0;
}
override public function Evaluate(_arg1:b2ContactListener):void{
var _local2:b2Vec2;
var _local3:b2Vec2;
var _local4:b2ManifoldPoint;
var _local7:b2ContactPoint;
var _local8:int;
var _local10:b2ManifoldPoint;
var _local11:Boolean;
var _local12:uint;
var _local13:int;
var _local5:b2Body = m_shape1.m_body;
var _local6:b2Body = m_shape2.m_body;
m0.Set(m_manifold);
b2Collision.b2CollidePolygons(m_manifold, (m_shape1 as b2PolygonShape), _local5.m_xf, (m_shape2 as b2PolygonShape), _local6.m_xf);
var _local9:Array = [false, false];
_local7 = s_evalCP;
_local7.shape1 = m_shape1;
_local7.shape2 = m_shape2;
_local7.friction = m_friction;
_local7.restitution = m_restitution;
if (m_manifold.pointCount > 0){
_local8 = 0;
while (_local8 < m_manifold.pointCount) {
_local10 = m_manifold.points[_local8];
_local10.normalImpulse = 0;
_local10.tangentImpulse = 0;
_local11 = false;
_local12 = _local10.id._key;
_local13 = 0;
while (_local13 < m0.pointCount) {
if (_local9[_local13] == true){
} else {
_local4 = m0.points[_local13];
if (_local4.id._key == _local12){
_local9[_local13] = true;
_local10.normalImpulse = _local4.normalImpulse;
_local10.tangentImpulse = _local4.tangentImpulse;
_local11 = true;
if (_arg1 != null){
_local7.position = _local5.GetWorldPoint(_local10.localPoint1);
_local2 = _local5.GetLinearVelocityFromLocalPoint(_local10.localPoint1);
_local3 = _local6.GetLinearVelocityFromLocalPoint(_local10.localPoint2);
_local7.velocity.Set((_local3.x - _local2.x), (_local3.y - _local2.y));
_local7.normal.SetV(m_manifold.normal);
_local7.separation = _local10.separation;
_local7.id.key = _local12;
_arg1.Persist(_local7);
};
break;
};
};
_local13++;
};
if ((((_local11 == false)) && (!((_arg1 == null))))){
_local7.position = _local5.GetWorldPoint(_local10.localPoint1);
_local2 = _local5.GetLinearVelocityFromLocalPoint(_local10.localPoint1);
_local3 = _local6.GetLinearVelocityFromLocalPoint(_local10.localPoint2);
_local7.velocity.Set((_local3.x - _local2.x), (_local3.y - _local2.y));
_local7.normal.SetV(m_manifold.normal);
_local7.separation = _local10.separation;
_local7.id.key = _local12;
_arg1.Add(_local7);
};
_local8++;
};
m_manifoldCount = 1;
} else {
m_manifoldCount = 0;
};
if (_arg1 == null){
return;
};
_local8 = 0;
while (_local8 < m0.pointCount) {
if (_local9[_local8]){
} else {
_local4 = m0.points[_local8];
_local7.position = _local5.GetWorldPoint(_local4.localPoint1);
_local2 = _local5.GetLinearVelocityFromLocalPoint(_local4.localPoint1);
_local3 = _local6.GetLinearVelocityFromLocalPoint(_local4.localPoint2);
_local7.velocity.Set((_local3.x - _local2.x), (_local3.y - _local2.y));
_local7.normal.SetV(m0.normal);
_local7.separation = _local4.separation;
_local7.id.key = _local4.id._key;
_arg1.Remove(_local7);
};
_local8++;
};
}
override public function GetManifolds():Array{
return (m_manifolds);
}
public static function Destroy(_arg1:b2Contact, _arg2):void{
}
public static function Create(_arg1:b2Shape, _arg2:b2Shape, _arg3):b2Contact{
return (new b2PolygonContact(_arg1, _arg2));
}
}
}//package Box2D.Dynamics.Contacts
Section 48
//b2DistanceJoint (Box2D.Dynamics.Joints.b2DistanceJoint)
package Box2D.Dynamics.Joints {
import Box2D.Dynamics.*;
import Box2D.Common.Math.*;
import Box2D.Common.*;
public class b2DistanceJoint extends b2Joint {
public var m_localAnchor1:b2Vec2;
public var m_localAnchor2:b2Vec2;
public var m_bias:Number;
public var m_gamma:Number;
public var m_u:b2Vec2;
public var m_mass:Number;
public var m_impulse:Number;
public var m_dampingRatio:Number;
public var m_frequencyHz:Number;
public var m_length:Number;
public function b2DistanceJoint(_arg1:b2DistanceJointDef){
var _local2:b2Mat22;
var _local3:Number;
var _local4:Number;
m_localAnchor1 = new b2Vec2();
m_localAnchor2 = new b2Vec2();
m_u = new b2Vec2();
super(_arg1);
m_localAnchor1.SetV(_arg1.localAnchor1);
m_localAnchor2.SetV(_arg1.localAnchor2);
m_length = _arg1.length;
m_frequencyHz = _arg1.frequencyHz;
m_dampingRatio = _arg1.dampingRatio;
m_impulse = 0;
m_gamma = 0;
m_bias = 0;
m_inv_dt = 0;
}
override public function GetAnchor1():b2Vec2{
return (m_body1.GetWorldPoint(m_localAnchor1));
}
override public function GetAnchor2():b2Vec2{
return (m_body2.GetWorldPoint(m_localAnchor2));
}
override public function InitVelocityConstraints(_arg1:b2TimeStep):void{
var _local2:b2Mat22;
var _local3:Number;
var _local4:b2Body;
var _local5:b2Body;
var _local6:Number;
var _local8:Number;
var _local14:Number;
var _local15:Number;
var _local16:Number;
var _local17:Number;
var _local18:Number;
var _local19:Number;
m_inv_dt = _arg1.inv_dt;
_local4 = m_body1;
_local5 = m_body2;
_local2 = _local4.m_xf.R;
_local6 = (m_localAnchor1.x - _local4.m_sweep.localCenter.x);
var _local7:Number = (m_localAnchor1.y - _local4.m_sweep.localCenter.y);
_local3 = ((_local2.col1.x * _local6) + (_local2.col2.x * _local7));
_local7 = ((_local2.col1.y * _local6) + (_local2.col2.y * _local7));
_local6 = _local3;
_local2 = _local5.m_xf.R;
_local8 = (m_localAnchor2.x - _local5.m_sweep.localCenter.x);
var _local9:Number = (m_localAnchor2.y - _local5.m_sweep.localCenter.y);
_local3 = ((_local2.col1.x * _local8) + (_local2.col2.x * _local9));
_local9 = ((_local2.col1.y * _local8) + (_local2.col2.y * _local9));
_local8 = _local3;
m_u.x = (((_local5.m_sweep.c.x + _local8) - _local4.m_sweep.c.x) - _local6);
m_u.y = (((_local5.m_sweep.c.y + _local9) - _local4.m_sweep.c.y) - _local7);
var _local10:Number = Math.sqrt(((m_u.x * m_u.x) + (m_u.y * m_u.y)));
if (_local10 > b2Settings.b2_linearSlop){
m_u.Multiply((1 / _local10));
} else {
m_u.SetZero();
};
var _local11:Number = ((_local6 * m_u.y) - (_local7 * m_u.x));
var _local12:Number = ((_local8 * m_u.y) - (_local9 * m_u.x));
var _local13:Number = (((_local4.m_invMass + ((_local4.m_invI * _local11) * _local11)) + _local5.m_invMass) + ((_local5.m_invI * _local12) * _local12));
m_mass = (1 / _local13);
if (m_frequencyHz > 0){
_local14 = (_local10 - m_length);
_local15 = ((2 * Math.PI) * m_frequencyHz);
_local16 = (((2 * m_mass) * m_dampingRatio) * _local15);
_local17 = ((m_mass * _local15) * _local15);
m_gamma = (1 / (_arg1.dt * (_local16 + (_arg1.dt * _local17))));
m_bias = (((_local14 * _arg1.dt) * _local17) * m_gamma);
m_mass = (1 / (_local13 + m_gamma));
};
if (_arg1.warmStarting){
m_impulse = (m_impulse * _arg1.dtRatio);
_local18 = (m_impulse * m_u.x);
_local19 = (m_impulse * m_u.y);
_local4.m_linearVelocity.x = (_local4.m_linearVelocity.x - (_local4.m_invMass * _local18));
_local4.m_linearVelocity.y = (_local4.m_linearVelocity.y - (_local4.m_invMass * _local19));
_local4.m_angularVelocity = (_local4.m_angularVelocity - (_local4.m_invI * ((_local6 * _local19) - (_local7 * _local18))));
_local5.m_linearVelocity.x = (_local5.m_linearVelocity.x + (_local5.m_invMass * _local18));
_local5.m_linearVelocity.y = (_local5.m_linearVelocity.y + (_local5.m_invMass * _local19));
_local5.m_angularVelocity = (_local5.m_angularVelocity + (_local5.m_invI * ((_local8 * _local19) - (_local9 * _local18))));
} else {
m_impulse = 0;
};
}
override public function GetReactionTorque():Number{
return (0);
}
override public function GetReactionForce():b2Vec2{
var _local1:b2Vec2 = new b2Vec2();
_local1.SetV(m_u);
_local1.Multiply((m_inv_dt * m_impulse));
return (_local1);
}
override public function SolvePositionConstraints():Boolean{
var _local1:b2Mat22;
if (m_frequencyHz > 0){
return (true);
};
var _local2:b2Body = m_body1;
var _local3:b2Body = m_body2;
_local1 = _local2.m_xf.R;
var _local4:Number = (m_localAnchor1.x - _local2.m_sweep.localCenter.x);
var _local5:Number = (m_localAnchor1.y - _local2.m_sweep.localCenter.y);
var _local6:Number = ((_local1.col1.x * _local4) + (_local1.col2.x * _local5));
_local5 = ((_local1.col1.y * _local4) + (_local1.col2.y * _local5));
_local4 = _local6;
_local1 = _local3.m_xf.R;
var _local7:Number = (m_localAnchor2.x - _local3.m_sweep.localCenter.x);
var _local8:Number = (m_localAnchor2.y - _local3.m_sweep.localCenter.y);
_local6 = ((_local1.col1.x * _local7) + (_local1.col2.x * _local8));
_local8 = ((_local1.col1.y * _local7) + (_local1.col2.y * _local8));
_local7 = _local6;
var _local9:Number = (((_local3.m_sweep.c.x + _local7) - _local2.m_sweep.c.x) - _local4);
var _local10:Number = (((_local3.m_sweep.c.y + _local8) - _local2.m_sweep.c.y) - _local5);
var _local11:Number = Math.sqrt(((_local9 * _local9) + (_local10 * _local10)));
_local9 = (_local9 / _local11);
_local10 = (_local10 / _local11);
var _local12:Number = (_local11 - m_length);
_local12 = b2Math.b2Clamp(_local12, -(b2Settings.b2_maxLinearCorrection), b2Settings.b2_maxLinearCorrection);
var _local13:Number = (-(m_mass) * _local12);
m_u.Set(_local9, _local10);
var _local14:Number = (_local13 * m_u.x);
var _local15:Number = (_local13 * m_u.y);
_local2.m_sweep.c.x = (_local2.m_sweep.c.x - (_local2.m_invMass * _local14));
_local2.m_sweep.c.y = (_local2.m_sweep.c.y - (_local2.m_invMass * _local15));
_local2.m_sweep.a = (_local2.m_sweep.a - (_local2.m_invI * ((_local4 * _local15) - (_local5 * _local14))));
_local3.m_sweep.c.x = (_local3.m_sweep.c.x + (_local3.m_invMass * _local14));
_local3.m_sweep.c.y = (_local3.m_sweep.c.y + (_local3.m_invMass * _local15));
_local3.m_sweep.a = (_local3.m_sweep.a + (_local3.m_invI * ((_local7 * _local15) - (_local8 * _local14))));
_local2.SynchronizeTransform();
_local3.SynchronizeTransform();
return ((b2Math.b2Abs(_local12) < b2Settings.b2_linearSlop));
}
override public function SolveVelocityConstraints(_arg1:b2TimeStep):void{
var _local2:b2Mat22;
var _local3:b2Body = m_body1;
var _local4:b2Body = m_body2;
_local2 = _local3.m_xf.R;
var _local5:Number = (m_localAnchor1.x - _local3.m_sweep.localCenter.x);
var _local6:Number = (m_localAnchor1.y - _local3.m_sweep.localCenter.y);
var _local7:Number = ((_local2.col1.x * _local5) + (_local2.col2.x * _local6));
_local6 = ((_local2.col1.y * _local5) + (_local2.col2.y * _local6));
_local5 = _local7;
_local2 = _local4.m_xf.R;
var _local8:Number = (m_localAnchor2.x - _local4.m_sweep.localCenter.x);
var _local9:Number = (m_localAnchor2.y - _local4.m_sweep.localCenter.y);
_local7 = ((_local2.col1.x * _local8) + (_local2.col2.x * _local9));
_local9 = ((_local2.col1.y * _local8) + (_local2.col2.y * _local9));
_local8 = _local7;
var _local10:Number = (_local3.m_linearVelocity.x + (-(_local3.m_angularVelocity) * _local6));
var _local11:Number = (_local3.m_linearVelocity.y + (_local3.m_angularVelocity * _local5));
var _local12:Number = (_local4.m_linearVelocity.x + (-(_local4.m_angularVelocity) * _local9));
var _local13:Number = (_local4.m_linearVelocity.y + (_local4.m_angularVelocity * _local8));
var _local14:Number = ((m_u.x * (_local12 - _local10)) + (m_u.y * (_local13 - _local11)));
var _local15:Number = (-(m_mass) * ((_local14 + m_bias) + (m_gamma * m_impulse)));
m_impulse = (m_impulse + _local15);
var _local16:Number = (_local15 * m_u.x);
var _local17:Number = (_local15 * m_u.y);
_local3.m_linearVelocity.x = (_local3.m_linearVelocity.x - (_local3.m_invMass * _local16));
_local3.m_linearVelocity.y = (_local3.m_linearVelocity.y - (_local3.m_invMass * _local17));
_local3.m_angularVelocity = (_local3.m_angularVelocity - (_local3.m_invI * ((_local5 * _local17) - (_local6 * _local16))));
_local4.m_linearVelocity.x = (_local4.m_linearVelocity.x + (_local4.m_invMass * _local16));
_local4.m_linearVelocity.y = (_local4.m_linearVelocity.y + (_local4.m_invMass * _local17));
_local4.m_angularVelocity = (_local4.m_angularVelocity + (_local4.m_invI * ((_local8 * _local17) - (_local9 * _local16))));
}
}
}//package Box2D.Dynamics.Joints
Section 49
//b2DistanceJointDef (Box2D.Dynamics.Joints.b2DistanceJointDef)
package Box2D.Dynamics.Joints {
import Box2D.Dynamics.*;
import Box2D.Common.Math.*;
public class b2DistanceJointDef extends b2JointDef {
public var localAnchor1:b2Vec2;
public var length:Number;
public var dampingRatio:Number;
public var localAnchor2:b2Vec2;
public var frequencyHz:Number;
public function b2DistanceJointDef(){
localAnchor1 = new b2Vec2();
localAnchor2 = new b2Vec2();
super();
type = b2Joint.e_distanceJoint;
length = 1;
frequencyHz = 0;
dampingRatio = 0;
}
public function Initialize(_arg1:b2Body, _arg2:b2Body, _arg3:b2Vec2, _arg4:b2Vec2):void{
body1 = _arg1;
body2 = _arg2;
localAnchor1.SetV(body1.GetLocalPoint(_arg3));
localAnchor2.SetV(body2.GetLocalPoint(_arg4));
var _local5:Number = (_arg4.x - _arg3.x);
var _local6:Number = (_arg4.y - _arg3.y);
length = Math.sqrt(((_local5 * _local5) + (_local6 * _local6)));
frequencyHz = 0;
dampingRatio = 0;
}
}
}//package Box2D.Dynamics.Joints
Section 50
//b2GearJoint (Box2D.Dynamics.Joints.b2GearJoint)
package Box2D.Dynamics.Joints {
import Box2D.Dynamics.*;
import Box2D.Common.Math.*;
import Box2D.Common.*;
public class b2GearJoint extends b2Joint {
public var m_ground2:b2Body;
public var m_groundAnchor1:b2Vec2;
public var m_groundAnchor2:b2Vec2;
public var m_localAnchor1:b2Vec2;
public var m_localAnchor2:b2Vec2;
public var m_ratio:Number;
public var m_revolute2:b2RevoluteJoint;
public var m_force:Number;
public var m_mass:Number;
public var m_prismatic2:b2PrismaticJoint;
public var m_ground1:b2Body;
public var m_revolute1:b2RevoluteJoint;
public var m_prismatic1:b2PrismaticJoint;
public var m_constant:Number;
public var m_J:b2Jacobian;
public function b2GearJoint(_arg1:b2GearJointDef){
var _local4:Number;
var _local5:Number;
m_groundAnchor1 = new b2Vec2();
m_groundAnchor2 = new b2Vec2();
m_localAnchor1 = new b2Vec2();
m_localAnchor2 = new b2Vec2();
m_J = new b2Jacobian();
super(_arg1);
var _local2:int = _arg1.joint1.m_type;
var _local3:int = _arg1.joint2.m_type;
m_revolute1 = null;
m_prismatic1 = null;
m_revolute2 = null;
m_prismatic2 = null;
m_ground1 = _arg1.joint1.m_body1;
m_body1 = _arg1.joint1.m_body2;
if (_local2 == b2Joint.e_revoluteJoint){
m_revolute1 = (_arg1.joint1 as b2RevoluteJoint);
m_groundAnchor1.SetV(m_revolute1.m_localAnchor1);
m_localAnchor1.SetV(m_revolute1.m_localAnchor2);
_local4 = m_revolute1.GetJointAngle();
} else {
m_prismatic1 = (_arg1.joint1 as b2PrismaticJoint);
m_groundAnchor1.SetV(m_prismatic1.m_localAnchor1);
m_localAnchor1.SetV(m_prismatic1.m_localAnchor2);
_local4 = m_prismatic1.GetJointTranslation();
};
m_ground2 = _arg1.joint2.m_body1;
m_body2 = _arg1.joint2.m_body2;
if (_local3 == b2Joint.e_revoluteJoint){
m_revolute2 = (_arg1.joint2 as b2RevoluteJoint);
m_groundAnchor2.SetV(m_revolute2.m_localAnchor1);
m_localAnchor2.SetV(m_revolute2.m_localAnchor2);
_local5 = m_revolute2.GetJointAngle();
} else {
m_prismatic2 = (_arg1.joint2 as b2PrismaticJoint);
m_groundAnchor2.SetV(m_prismatic2.m_localAnchor1);
m_localAnchor2.SetV(m_prismatic2.m_localAnchor2);
_local5 = m_prismatic2.GetJointTranslation();
};
m_ratio = _arg1.ratio;
m_constant = (_local4 + (m_ratio * _local5));
m_force = 0;
}
override public function GetAnchor1():b2Vec2{
return (m_body1.GetWorldPoint(m_localAnchor1));
}
override public function GetAnchor2():b2Vec2{
return (m_body2.GetWorldPoint(m_localAnchor2));
}
override public function InitVelocityConstraints(_arg1:b2TimeStep):void{
var _local6:Number;
var _local7:Number;
var _local8:Number;
var _local9:Number;
var _local10:b2Mat22;
var _local11:b2Vec2;
var _local12:Number;
var _local13:Number;
var _local15:Number;
var _local2:b2Body = m_ground1;
var _local3:b2Body = m_ground2;
var _local4:b2Body = m_body1;
var _local5:b2Body = m_body2;
var _local14:Number = 0;
m_J.SetZero();
if (m_revolute1){
m_J.angular1 = -1;
_local14 = (_local14 + _local4.m_invI);
} else {
_local10 = _local2.m_xf.R;
_local11 = m_prismatic1.m_localXAxis1;
_local6 = ((_local10.col1.x * _local11.x) + (_local10.col2.x * _local11.y));
_local7 = ((_local10.col1.y * _local11.x) + (_local10.col2.y * _local11.y));
_local10 = _local4.m_xf.R;
_local8 = (m_localAnchor1.x - _local4.m_sweep.localCenter.x);
_local9 = (m_localAnchor1.y - _local4.m_sweep.localCenter.y);
_local13 = ((_local10.col1.x * _local8) + (_local10.col2.x * _local9));
_local9 = ((_local10.col1.y * _local8) + (_local10.col2.y * _local9));
_local8 = _local13;
_local12 = ((_local8 * _local7) - (_local9 * _local6));
m_J.linear1.Set(-(_local6), -(_local7));
m_J.angular1 = -(_local12);
_local14 = (_local14 + (_local4.m_invMass + ((_local4.m_invI * _local12) * _local12)));
};
if (m_revolute2){
m_J.angular2 = -(m_ratio);
_local14 = (_local14 + ((m_ratio * m_ratio) * _local5.m_invI));
} else {
_local10 = _local3.m_xf.R;
_local11 = m_prismatic2.m_localXAxis1;
_local6 = ((_local10.col1.x * _local11.x) + (_local10.col2.x * _local11.y));
_local7 = ((_local10.col1.y * _local11.x) + (_local10.col2.y * _local11.y));
_local10 = _local5.m_xf.R;
_local8 = (m_localAnchor2.x - _local5.m_sweep.localCenter.x);
_local9 = (m_localAnchor2.y - _local5.m_sweep.localCenter.y);
_local13 = ((_local10.col1.x * _local8) + (_local10.col2.x * _local9));
_local9 = ((_local10.col1.y * _local8) + (_local10.col2.y * _local9));
_local8 = _local13;
_local12 = ((_local8 * _local7) - (_local9 * _local6));
m_J.linear2.Set((-(m_ratio) * _local6), (-(m_ratio) * _local7));
m_J.angular2 = (-(m_ratio) * _local12);
_local14 = (_local14 + ((m_ratio * m_ratio) * (_local5.m_invMass + ((_local5.m_invI * _local12) * _local12))));
};
m_mass = (1 / _local14);
if (_arg1.warmStarting){
_local15 = (_arg1.dt * m_force);
_local4.m_linearVelocity.x = (_local4.m_linearVelocity.x + ((_local4.m_invMass * _local15) * m_J.linear1.x));
_local4.m_linearVelocity.y = (_local4.m_linearVelocity.y + ((_local4.m_invMass * _local15) * m_J.linear1.y));
_local4.m_angularVelocity = (_local4.m_angularVelocity + ((_local4.m_invI * _local15) * m_J.angular1));
_local5.m_linearVelocity.x = (_local5.m_linearVelocity.x + ((_local5.m_invMass * _local15) * m_J.linear2.x));
_local5.m_linearVelocity.y = (_local5.m_linearVelocity.y + ((_local5.m_invMass * _local15) * m_J.linear2.y));
_local5.m_angularVelocity = (_local5.m_angularVelocity + ((_local5.m_invI * _local15) * m_J.angular2));
} else {
m_force = 0;
};
}
override public function GetReactionTorque():Number{
var _local1:b2Mat22 = m_body2.m_xf.R;
var _local2:Number = (m_localAnchor1.x - m_body2.m_sweep.localCenter.x);
var _local3:Number = (m_localAnchor1.y - m_body2.m_sweep.localCenter.y);
var _local4:Number = ((_local1.col1.x * _local2) + (_local1.col2.x * _local3));
_local3 = ((_local1.col1.y * _local2) + (_local1.col2.y * _local3));
_local2 = _local4;
_local4 = ((m_force * m_J.angular2) - ((_local2 * (m_force * m_J.linear2.y)) - (_local3 * (m_force * m_J.linear2.x))));
return (_local4);
}
override public function GetReactionForce():b2Vec2{
var _local1:b2Vec2 = new b2Vec2((m_force * m_J.linear2.x), (m_force * m_J.linear2.y));
return (_local1);
}
override public function SolvePositionConstraints():Boolean{
var _local4:Number;
var _local5:Number;
var _local1:Number = 0;
var _local2:b2Body = m_body1;
var _local3:b2Body = m_body2;
if (m_revolute1){
_local4 = m_revolute1.GetJointAngle();
} else {
_local4 = m_prismatic1.GetJointTranslation();
};
if (m_revolute2){
_local5 = m_revolute2.GetJointAngle();
} else {
_local5 = m_prismatic2.GetJointTranslation();
};
var _local6:Number = (m_constant - (_local4 + (m_ratio * _local5)));
var _local7:Number = (-(m_mass) * _local6);
_local2.m_sweep.c.x = (_local2.m_sweep.c.x + ((_local2.m_invMass * _local7) * m_J.linear1.x));
_local2.m_sweep.c.y = (_local2.m_sweep.c.y + ((_local2.m_invMass * _local7) * m_J.linear1.y));
_local2.m_sweep.a = (_local2.m_sweep.a + ((_local2.m_invI * _local7) * m_J.angular1));
_local3.m_sweep.c.x = (_local3.m_sweep.c.x + ((_local3.m_invMass * _local7) * m_J.linear2.x));
_local3.m_sweep.c.y = (_local3.m_sweep.c.y + ((_local3.m_invMass * _local7) * m_J.linear2.y));
_local3.m_sweep.a = (_local3.m_sweep.a + ((_local3.m_invI * _local7) * m_J.angular2));
_local2.SynchronizeTransform();
_local3.SynchronizeTransform();
return ((_local1 < b2Settings.b2_linearSlop));
}
public function GetRatio():Number{
return (m_ratio);
}
override public function SolveVelocityConstraints(_arg1:b2TimeStep):void{
var _local2:b2Body = m_body1;
var _local3:b2Body = m_body2;
var _local4:Number = m_J.Compute(_local2.m_linearVelocity, _local2.m_angularVelocity, _local3.m_linearVelocity, _local3.m_angularVelocity);
var _local5:Number = ((-(_arg1.inv_dt) * m_mass) * _local4);
m_force = (m_force + _local5);
var _local6:Number = (_arg1.dt * _local5);
_local2.m_linearVelocity.x = (_local2.m_linearVelocity.x + ((_local2.m_invMass * _local6) * m_J.linear1.x));
_local2.m_linearVelocity.y = (_local2.m_linearVelocity.y + ((_local2.m_invMass * _local6) * m_J.linear1.y));
_local2.m_angularVelocity = (_local2.m_angularVelocity + ((_local2.m_invI * _local6) * m_J.angular1));
_local3.m_linearVelocity.x = (_local3.m_linearVelocity.x + ((_local3.m_invMass * _local6) * m_J.linear2.x));
_local3.m_linearVelocity.y = (_local3.m_linearVelocity.y + ((_local3.m_invMass * _local6) * m_J.linear2.y));
_local3.m_angularVelocity = (_local3.m_angularVelocity + ((_local3.m_invI * _local6) * m_J.angular2));
}
}
}//package Box2D.Dynamics.Joints
Section 51
//b2GearJointDef (Box2D.Dynamics.Joints.b2GearJointDef)
package Box2D.Dynamics.Joints {
public class b2GearJointDef extends b2JointDef {
public var joint1:b2Joint;
public var joint2:b2Joint;
public var ratio:Number;
public function b2GearJointDef(){
type = b2Joint.e_gearJoint;
joint1 = null;
joint2 = null;
ratio = 1;
}
}
}//package Box2D.Dynamics.Joints
Section 52
//b2Jacobian (Box2D.Dynamics.Joints.b2Jacobian)
package Box2D.Dynamics.Joints {
import Box2D.Common.Math.*;
public class b2Jacobian {
public var linear1:b2Vec2;
public var linear2:b2Vec2;
public var angular1:Number;
public var angular2:Number;
public function b2Jacobian(){
linear1 = new b2Vec2();
linear2 = new b2Vec2();
super();
}
public function Set(_arg1:b2Vec2, _arg2:Number, _arg3:b2Vec2, _arg4:Number):void{
linear1.SetV(_arg1);
angular1 = _arg2;
linear2.SetV(_arg3);
angular2 = _arg4;
}
public function SetZero():void{
linear1.SetZero();
angular1 = 0;
linear2.SetZero();
angular2 = 0;
}
public function Compute(_arg1:b2Vec2, _arg2:Number, _arg3:b2Vec2, _arg4:Number):Number{
return ((((((linear1.x * _arg1.x) + (linear1.y * _arg1.y)) + (angular1 * _arg2)) + ((linear2.x * _arg3.x) + (linear2.y * _arg3.y))) + (angular2 * _arg4)));
}
}
}//package Box2D.Dynamics.Joints
Section 53
//b2Joint (Box2D.Dynamics.Joints.b2Joint)
package Box2D.Dynamics.Joints {
import Box2D.Dynamics.*;
import Box2D.Common.Math.*;
public class b2Joint {
public var m_islandFlag:Boolean;
public var m_body1:b2Body;
public var m_prev:b2Joint;
public var m_next:b2Joint;
public var m_type:int;
public var m_collideConnected:Boolean;
public var m_node1:b2JointEdge;
public var m_node2:b2JointEdge;
public var m_inv_dt:Number;
public var m_userData;
public var m_body2:b2Body;
public static const e_unknownJoint:int = 0;
public static const e_inactiveLimit:int = 0;
public static const e_atUpperLimit:int = 2;
public static const e_atLowerLimit:int = 1;
public static const e_gearJoint:int = 6;
public static const e_revoluteJoint:int = 1;
public static const e_equalLimits:int = 3;
public static const e_distanceJoint:int = 3;
public static const e_pulleyJoint:int = 4;
public static const e_prismaticJoint:int = 2;
public static const e_mouseJoint:int = 5;
public function b2Joint(_arg1:b2JointDef){
m_node1 = new b2JointEdge();
m_node2 = new b2JointEdge();
super();
m_type = _arg1.type;
m_prev = null;
m_next = null;
m_body1 = _arg1.body1;
m_body2 = _arg1.body2;
m_collideConnected = _arg1.collideConnected;
m_islandFlag = false;
m_userData = _arg1.userData;
}
public function GetBody2():b2Body{
return (m_body2);
}
public function GetAnchor1():b2Vec2{
return (null);
}
public function GetAnchor2():b2Vec2{
return (null);
}
public function GetNext():b2Joint{
return (m_next);
}
public function GetType():int{
return (m_type);
}
public function InitVelocityConstraints(_arg1:b2TimeStep):void{
}
public function GetReactionTorque():Number{
return (0);
}
public function GetUserData(){
return (m_userData);
}
public function GetReactionForce():b2Vec2{
return (null);
}
public function SolvePositionConstraints():Boolean{
return (false);
}
public function SetUserData(_arg1):void{
m_userData = _arg1;
}
public function GetBody1():b2Body{
return (m_body1);
}
public function SolveVelocityConstraints(_arg1:b2TimeStep):void{
}
public function InitPositionConstraints():void{
}
public static function Destroy(_arg1:b2Joint, _arg2):void{
}
public static function Create(_arg1:b2JointDef, _arg2):b2Joint{
var _local3:b2Joint;
switch (_arg1.type){
case e_distanceJoint:
_local3 = new b2DistanceJoint((_arg1 as b2DistanceJointDef));
break;
case e_mouseJoint:
_local3 = new b2MouseJoint((_arg1 as b2MouseJointDef));
break;
case e_prismaticJoint:
_local3 = new b2PrismaticJoint((_arg1 as b2PrismaticJointDef));
break;
case e_revoluteJoint:
_local3 = new b2RevoluteJoint((_arg1 as b2RevoluteJointDef));
break;
case e_pulleyJoint:
_local3 = new b2PulleyJoint((_arg1 as b2PulleyJointDef));
break;
case e_gearJoint:
_local3 = new b2GearJoint((_arg1 as b2GearJointDef));
break;
default:
break;
};
return (_local3);
}
}
}//package Box2D.Dynamics.Joints
Section 54
//b2JointDef (Box2D.Dynamics.Joints.b2JointDef)
package Box2D.Dynamics.Joints {
import Box2D.Dynamics.*;
public class b2JointDef {
public var body2:b2Body;
public var type:int;
public var userData;
public var collideConnected:Boolean;
public var body1:b2Body;
public function b2JointDef(){
type = b2Joint.e_unknownJoint;
userData = null;
body1 = null;
body2 = null;
collideConnected = false;
}
}
}//package Box2D.Dynamics.Joints
Section 55
//b2JointEdge (Box2D.Dynamics.Joints.b2JointEdge)
package Box2D.Dynamics.Joints {
import Box2D.Dynamics.*;
public class b2JointEdge {
public var other:b2Body;
public var next:b2JointEdge;
public var prev:b2JointEdge;
public var joint:b2Joint;
}
}//package Box2D.Dynamics.Joints
Section 56
//b2MouseJoint (Box2D.Dynamics.Joints.b2MouseJoint)
package Box2D.Dynamics.Joints {
import Box2D.Dynamics.*;
import Box2D.Common.Math.*;
import Box2D.Common.*;
public class b2MouseJoint extends b2Joint {
private var K1:b2Mat22;
private var K:b2Mat22;
public var m_beta:Number;
public var m_mass:b2Mat22;
private var K2:b2Mat22;
public var m_target:b2Vec2;
public var m_gamma:Number;
public var m_impulse:b2Vec2;
public var m_C:b2Vec2;
public var m_localAnchor:b2Vec2;
public var m_maxForce:Number;
public function b2MouseJoint(_arg1:b2MouseJointDef){
var _local3:Number;
K = new b2Mat22();
K1 = new b2Mat22();
K2 = new b2Mat22();
m_localAnchor = new b2Vec2();
m_target = new b2Vec2();
m_impulse = new b2Vec2();
m_mass = new b2Mat22();
m_C = new b2Vec2();
super(_arg1);
m_target.SetV(_arg1.target);
var _local2:Number = (m_target.x - m_body2.m_xf.position.x);
_local3 = (m_target.y - m_body2.m_xf.position.y);
var _local4:b2Mat22 = m_body2.m_xf.R;
m_localAnchor.x = ((_local2 * _local4.col1.x) + (_local3 * _local4.col1.y));
m_localAnchor.y = ((_local2 * _local4.col2.x) + (_local3 * _local4.col2.y));
m_maxForce = _arg1.maxForce;
m_impulse.SetZero();
var _local5:Number = m_body2.m_mass;
var _local6:Number = ((2 * b2Settings.b2_pi) * _arg1.frequencyHz);
var _local7:Number = (((2 * _local5) * _arg1.dampingRatio) * _local6);
var _local8:Number = ((_arg1.timeStep * _local5) * (_local6 * _local6));
m_gamma = (1 / (_local7 + _local8));
m_beta = (_local8 / (_local7 + _local8));
}
public function SetTarget(_arg1:b2Vec2):void{
if (m_body2.IsSleeping()){
m_body2.WakeUp();
};
m_target = _arg1;
}
override public function GetAnchor2():b2Vec2{
return (m_body2.GetWorldPoint(m_localAnchor));
}
override public function InitVelocityConstraints(_arg1:b2TimeStep):void{
var _local2:b2Body;
var _local3:b2Mat22;
var _local4:Number;
var _local5:Number;
var _local7:Number;
var _local8:Number;
_local2 = m_body2;
_local3 = _local2.m_xf.R;
_local4 = (m_localAnchor.x - _local2.m_sweep.localCenter.x);
_local5 = (m_localAnchor.y - _local2.m_sweep.localCenter.y);
var _local6:Number = ((_local3.col1.x * _local4) + (_local3.col2.x * _local5));
_local5 = ((_local3.col1.y * _local4) + (_local3.col2.y * _local5));
_local4 = _local6;
_local7 = _local2.m_invMass;
_local8 = _local2.m_invI;
K1.col1.x = _local7;
K1.col2.x = 0;
K1.col1.y = 0;
K1.col2.y = _local7;
K2.col1.x = ((_local8 * _local5) * _local5);
K2.col2.x = ((-(_local8) * _local4) * _local5);
K2.col1.y = ((-(_local8) * _local4) * _local5);
K2.col2.y = ((_local8 * _local4) * _local4);
K.SetM(K1);
K.AddM(K2);
K.col1.x = (K.col1.x + m_gamma);
K.col2.y = (K.col2.y + m_gamma);
K.Invert(m_mass);
m_C.x = ((_local2.m_sweep.c.x + _local4) - m_target.x);
m_C.y = ((_local2.m_sweep.c.y + _local5) - m_target.y);
_local2.m_angularVelocity = (_local2.m_angularVelocity * 0.98);
var _local9:Number = (_arg1.dt * m_impulse.x);
var _local10:Number = (_arg1.dt * m_impulse.y);
_local2.m_linearVelocity.x = (_local2.m_linearVelocity.x + (_local7 * _local9));
_local2.m_linearVelocity.y = (_local2.m_linearVelocity.y + (_local7 * _local10));
_local2.m_angularVelocity = (_local2.m_angularVelocity + (_local8 * ((_local4 * _local10) - (_local5 * _local9))));
}
override public function GetAnchor1():b2Vec2{
return (m_target);
}
override public function GetReactionTorque():Number{
return (0);
}
override public function GetReactionForce():b2Vec2{
return (m_impulse);
}
override public function SolvePositionConstraints():Boolean{
return (true);
}
override public function SolveVelocityConstraints(_arg1:b2TimeStep):void{
var _local3:b2Mat22;
var _local4:Number;
var _local5:Number;
var _local2:b2Body = m_body2;
_local3 = _local2.m_xf.R;
var _local6:Number = (m_localAnchor.x - _local2.m_sweep.localCenter.x);
var _local7:Number = (m_localAnchor.y - _local2.m_sweep.localCenter.y);
_local4 = ((_local3.col1.x * _local6) + (_local3.col2.x * _local7));
_local7 = ((_local3.col1.y * _local6) + (_local3.col2.y * _local7));
_local6 = _local4;
var _local8:Number = (_local2.m_linearVelocity.x + (-(_local2.m_angularVelocity) * _local7));
var _local9:Number = (_local2.m_linearVelocity.y + (_local2.m_angularVelocity * _local6));
_local3 = m_mass;
_local4 = ((_local8 + ((m_beta * _arg1.inv_dt) * m_C.x)) + ((m_gamma * _arg1.dt) * m_impulse.x));
_local5 = ((_local9 + ((m_beta * _arg1.inv_dt) * m_C.y)) + ((m_gamma * _arg1.dt) * m_impulse.y));
var _local10:Number = (-(_arg1.inv_dt) * ((_local3.col1.x * _local4) + (_local3.col2.x * _local5)));
var _local11:Number = (-(_arg1.inv_dt) * ((_local3.col1.y * _local4) + (_local3.col2.y * _local5)));
var _local12:Number = m_impulse.x;
var _local13:Number = m_impulse.y;
m_impulse.x = (m_impulse.x + _local10);
m_impulse.y = (m_impulse.y + _local11);
var _local14:Number = m_impulse.Length();
if (_local14 > m_maxForce){
m_impulse.Multiply((m_maxForce / _local14));
};
_local10 = (m_impulse.x - _local12);
_local11 = (m_impulse.y - _local13);
var _local15:Number = (_arg1.dt * _local10);
var _local16:Number = (_arg1.dt * _local11);
_local2.m_linearVelocity.x = (_local2.m_linearVelocity.x + (_local2.m_invMass * _local15));
_local2.m_linearVelocity.y = (_local2.m_linearVelocity.y + (_local2.m_invMass * _local16));
_local2.m_angularVelocity = (_local2.m_angularVelocity + (_local2.m_invI * ((_local6 * _local16) - (_local7 * _local15))));
}
}
}//package Box2D.Dynamics.Joints
Section 57
//b2MouseJointDef (Box2D.Dynamics.Joints.b2MouseJointDef)
package Box2D.Dynamics.Joints {
import Box2D.Common.Math.*;
public class b2MouseJointDef extends b2JointDef {
public var timeStep:Number;
public var target:b2Vec2;
public var maxForce:Number;
public var dampingRatio:Number;
public var frequencyHz:Number;
public function b2MouseJointDef(){
target = new b2Vec2();
super();
type = b2Joint.e_mouseJoint;
maxForce = 0;
frequencyHz = 5;
dampingRatio = 0.7;
timeStep = (1 / 60);
}
}
}//package Box2D.Dynamics.Joints
Section 58
//b2PrismaticJoint (Box2D.Dynamics.Joints.b2PrismaticJoint)
package Box2D.Dynamics.Joints {
import Box2D.Dynamics.*;
import Box2D.Common.Math.*;
import Box2D.Common.*;
public class b2PrismaticJoint extends b2Joint {
public var m_limitForce:Number;
public var m_lowerTranslation:Number;
public var m_localXAxis1:b2Vec2;
public var m_refAngle:Number;
public var m_torque:Number;
public var m_motorForce:Number;
public var m_enableLimit:Boolean;
public var m_angularMass:Number;
public var m_maxMotorForce:Number;
public var m_localYAxis1:b2Vec2;
public var m_force:Number;
public var m_motorMass:Number;
public var m_upperTranslation:Number;
public var m_localAnchor1:b2Vec2;
public var m_localAnchor2:b2Vec2;
public var m_limitState:int;
public var m_linearMass:Number;
public var m_motorJacobian:b2Jacobian;
public var m_limitPositionImpulse:Number;
public var m_motorSpeed:Number;
public var m_enableMotor:Boolean;
public var m_linearJacobian:b2Jacobian;
public function b2PrismaticJoint(_arg1:b2PrismaticJointDef){
var _local2:b2Mat22;
var _local3:Number;
var _local4:Number;
m_localAnchor1 = new b2Vec2();
m_localAnchor2 = new b2Vec2();
m_localXAxis1 = new b2Vec2();
m_localYAxis1 = new b2Vec2();
m_linearJacobian = new b2Jacobian();
m_motorJacobian = new b2Jacobian();
super(_arg1);
m_localAnchor1.SetV(_arg1.localAnchor1);
m_localAnchor2.SetV(_arg1.localAnchor2);
m_localXAxis1.SetV(_arg1.localAxis1);
m_localYAxis1.x = -(m_localXAxis1.y);
m_localYAxis1.y = m_localXAxis1.x;
m_refAngle = _arg1.referenceAngle;
m_linearJacobian.SetZero();
m_linearMass = 0;
m_force = 0;
m_angularMass = 0;
m_torque = 0;
m_motorJacobian.SetZero();
m_motorMass = 0;
m_motorForce = 0;
m_limitForce = 0;
m_limitPositionImpulse = 0;
m_lowerTranslation = _arg1.lowerTranslation;
m_upperTranslation = _arg1.upperTranslation;
m_maxMotorForce = _arg1.maxMotorForce;
m_motorSpeed = _arg1.motorSpeed;
m_enableLimit = _arg1.enableLimit;
m_enableMotor = _arg1.enableMotor;
}
override public function SolveVelocityConstraints(_arg1:b2TimeStep):void{
var _local8:Number;
var _local15:Number;
var _local16:Number;
var _local17:Number;
var _local18:Number;
var _local19:Number;
var _local2:b2Body = m_body1;
var _local3:b2Body = m_body2;
var _local4:Number = _local2.m_invMass;
var _local5:Number = _local3.m_invMass;
var _local6:Number = _local2.m_invI;
var _local7:Number = _local3.m_invI;
var _local9:Number = m_linearJacobian.Compute(_local2.m_linearVelocity, _local2.m_angularVelocity, _local3.m_linearVelocity, _local3.m_angularVelocity);
var _local10:Number = ((-(_arg1.inv_dt) * m_linearMass) * _local9);
m_force = (m_force + _local10);
var _local11:Number = (_arg1.dt * _local10);
_local2.m_linearVelocity.x = (_local2.m_linearVelocity.x + ((_local4 * _local11) * m_linearJacobian.linear1.x));
_local2.m_linearVelocity.y = (_local2.m_linearVelocity.y + ((_local4 * _local11) * m_linearJacobian.linear1.y));
_local2.m_angularVelocity = (_local2.m_angularVelocity + ((_local6 * _local11) * m_linearJacobian.angular1));
_local3.m_linearVelocity.x = (_local3.m_linearVelocity.x + ((_local5 * _local11) * m_linearJacobian.linear2.x));
_local3.m_linearVelocity.y = (_local3.m_linearVelocity.y + ((_local5 * _local11) * m_linearJacobian.linear2.y));
_local3.m_angularVelocity = (_local3.m_angularVelocity + ((_local7 * _local11) * m_linearJacobian.angular2));
var _local12:Number = (_local3.m_angularVelocity - _local2.m_angularVelocity);
var _local13:Number = ((-(_arg1.inv_dt) * m_angularMass) * _local12);
m_torque = (m_torque + _local13);
var _local14:Number = (_arg1.dt * _local13);
_local2.m_angularVelocity = (_local2.m_angularVelocity - (_local6 * _local14));
_local3.m_angularVelocity = (_local3.m_angularVelocity + (_local7 * _local14));
if (((m_enableMotor) && (!((m_limitState == e_equalLimits))))){
_local15 = (m_motorJacobian.Compute(_local2.m_linearVelocity, _local2.m_angularVelocity, _local3.m_linearVelocity, _local3.m_angularVelocity) - m_motorSpeed);
_local16 = ((-(_arg1.inv_dt) * m_motorMass) * _local15);
_local17 = m_motorForce;
m_motorForce = b2Math.b2Clamp((m_motorForce + _local16), -(m_maxMotorForce), m_maxMotorForce);
_local16 = (m_motorForce - _local17);
_local11 = (_arg1.dt * _local16);
_local2.m_linearVelocity.x = (_local2.m_linearVelocity.x + ((_local4 * _local11) * m_motorJacobian.linear1.x));
_local2.m_linearVelocity.y = (_local2.m_linearVelocity.y + ((_local4 * _local11) * m_motorJacobian.linear1.y));
_local2.m_angularVelocity = (_local2.m_angularVelocity + ((_local6 * _local11) * m_motorJacobian.angular1));
_local3.m_linearVelocity.x = (_local3.m_linearVelocity.x + ((_local5 * _local11) * m_motorJacobian.linear2.x));
_local3.m_linearVelocity.y = (_local3.m_linearVelocity.y + ((_local5 * _local11) * m_motorJacobian.linear2.y));
_local3.m_angularVelocity = (_local3.m_angularVelocity + ((_local7 * _local11) * m_motorJacobian.angular2));
};
if (((m_enableLimit) && (!((m_limitState == e_inactiveLimit))))){
_local18 = m_motorJacobian.Compute(_local2.m_linearVelocity, _local2.m_angularVelocity, _local3.m_linearVelocity, _local3.m_angularVelocity);
_local19 = ((-(_arg1.inv_dt) * m_motorMass) * _local18);
if (m_limitState == e_equalLimits){
m_limitForce = (m_limitForce + _local19);
} else {
if (m_limitState == e_atLowerLimit){
_local8 = m_limitForce;
m_limitForce = b2Math.b2Max((m_limitForce + _local19), 0);
_local19 = (m_limitForce - _local8);
} else {
if (m_limitState == e_atUpperLimit){
_local8 = m_limitForce;
m_limitForce = b2Math.b2Min((m_limitForce + _local19), 0);
_local19 = (m_limitForce - _local8);
};
};
};
_local11 = (_arg1.dt * _local19);
_local2.m_linearVelocity.x = (_local2.m_linearVelocity.x + ((_local4 * _local11) * m_motorJacobian.linear1.x));
_local2.m_linearVelocity.y = (_local2.m_linearVelocity.y + ((_local4 * _local11) * m_motorJacobian.linear1.y));
_local2.m_angularVelocity = (_local2.m_angularVelocity + ((_local6 * _local11) * m_motorJacobian.angular1));
_local3.m_linearVelocity.x = (_local3.m_linearVelocity.x + ((_local5 * _local11) * m_motorJacobian.linear2.x));
_local3.m_linearVelocity.y = (_local3.m_linearVelocity.y + ((_local5 * _local11) * m_motorJacobian.linear2.y));
_local3.m_angularVelocity = (_local3.m_angularVelocity + ((_local7 * _local11) * m_motorJacobian.angular2));
};
}
override public function GetAnchor1():b2Vec2{
return (m_body1.GetWorldPoint(m_localAnchor1));
}
override public function GetAnchor2():b2Vec2{
return (m_body2.GetWorldPoint(m_localAnchor2));
}
public function GetUpperLimit():Number{
return (m_upperTranslation);
}
public function GetLowerLimit():Number{
return (m_lowerTranslation);
}
public function EnableMotor(_arg1:Boolean):void{
m_enableMotor = _arg1;
}
public function GetJointTranslation():Number{
var _local3:b2Mat22;
var _local1:b2Body = m_body1;
var _local2:b2Body = m_body2;
var _local4:b2Vec2 = _local1.GetWorldPoint(m_localAnchor1);
var _local5:b2Vec2 = _local2.GetWorldPoint(m_localAnchor2);
var _local6:Number = (_local5.x - _local4.x);
var _local7:Number = (_local5.y - _local4.y);
var _local8:b2Vec2 = _local1.GetWorldVector(m_localXAxis1);
var _local9:Number = ((_local8.x * _local6) + (_local8.y * _local7));
return (_local9);
}
public function GetMotorSpeed():Number{
return (m_motorSpeed);
}
override public function GetReactionForce():b2Vec2{
var _local1:b2Mat22 = m_body1.m_xf.R;
var _local2:Number = (m_limitForce * ((_local1.col1.x * m_localXAxis1.x) + (_local1.col2.x * m_localXAxis1.y)));
var _local3:Number = (m_limitForce * ((_local1.col1.y * m_localXAxis1.x) + (_local1.col2.y * m_localXAxis1.y)));
var _local4:Number = (m_force * ((_local1.col1.x * m_localYAxis1.x) + (_local1.col2.x * m_localYAxis1.y)));
var _local5:Number = (m_force * ((_local1.col1.y * m_localYAxis1.x) + (_local1.col2.y * m_localYAxis1.y)));
return (new b2Vec2(((m_limitForce * _local2) + (m_force * _local4)), ((m_limitForce * _local3) + (m_force * _local5))));
}
override public function SolvePositionConstraints():Boolean{
var _local1:Number;
var _local2:Number;
var _local9:b2Mat22;
var _local10:Number;
var _local29:Number;
var _local30:Number;
var _local31:Number;
var _local32:Number;
var _local3:b2Body = m_body1;
var _local4:b2Body = m_body2;
var _local5:Number = _local3.m_invMass;
var _local6:Number = _local4.m_invMass;
var _local7:Number = _local3.m_invI;
var _local8:Number = _local4.m_invI;
_local9 = _local3.m_xf.R;
var _local11:Number = (m_localAnchor1.x - _local3.m_sweep.localCenter.x);
var _local12:Number = (m_localAnchor1.y - _local3.m_sweep.localCenter.y);
_local10 = ((_local9.col1.x * _local11) + (_local9.col2.x * _local12));
_local12 = ((_local9.col1.y * _local11) + (_local9.col2.y * _local12));
_local11 = _local10;
_local9 = _local4.m_xf.R;
var _local13:Number = (m_localAnchor2.x - _local4.m_sweep.localCenter.x);
var _local14:Number = (m_localAnchor2.y - _local4.m_sweep.localCenter.y);
_local10 = ((_local9.col1.x * _local13) + (_local9.col2.x * _local14));
_local14 = ((_local9.col1.y * _local13) + (_local9.col2.y * _local14));
_local13 = _local10;
var _local15:Number = (_local3.m_sweep.c.x + _local11);
var _local16:Number = (_local3.m_sweep.c.y + _local12);
var _local17:Number = (_local4.m_sweep.c.x + _local13);
var _local18:Number = (_local4.m_sweep.c.y + _local14);
var _local19:Number = (_local17 - _local15);
var _local20:Number = (_local18 - _local16);
_local9 = _local3.m_xf.R;
var _local21:Number = ((_local9.col1.x * m_localYAxis1.x) + (_local9.col2.x * m_localYAxis1.y));
var _local22:Number = ((_local9.col1.y * m_localYAxis1.x) + (_local9.col2.y * m_localYAxis1.y));
var _local23:Number = ((_local21 * _local19) + (_local22 * _local20));
_local23 = b2Math.b2Clamp(_local23, -(b2Settings.b2_maxLinearCorrection), b2Settings.b2_maxLinearCorrection);
var _local24:Number = (-(m_linearMass) * _local23);
_local3.m_sweep.c.x = (_local3.m_sweep.c.x + ((_local5 * _local24) * m_linearJacobian.linear1.x));
_local3.m_sweep.c.y = (_local3.m_sweep.c.y + ((_local5 * _local24) * m_linearJacobian.linear1.y));
_local3.m_sweep.a = (_local3.m_sweep.a + ((_local7 * _local24) * m_linearJacobian.angular1));
_local4.m_sweep.c.x = (_local4.m_sweep.c.x + ((_local6 * _local24) * m_linearJacobian.linear2.x));
_local4.m_sweep.c.y = (_local4.m_sweep.c.y + ((_local6 * _local24) * m_linearJacobian.linear2.y));
_local4.m_sweep.a = (_local4.m_sweep.a + ((_local8 * _local24) * m_linearJacobian.angular2));
var _local25:Number = b2Math.b2Abs(_local23);
var _local26:Number = ((_local4.m_sweep.a - _local3.m_sweep.a) - m_refAngle);
_local26 = b2Math.b2Clamp(_local26, -(b2Settings.b2_maxAngularCorrection), b2Settings.b2_maxAngularCorrection);
var _local27:Number = (-(m_angularMass) * _local26);
_local3.m_sweep.a = (_local3.m_sweep.a - (_local3.m_invI * _local27));
_local4.m_sweep.a = (_local4.m_sweep.a + (_local4.m_invI * _local27));
_local3.SynchronizeTransform();
_local4.SynchronizeTransform();
var _local28:Number = b2Math.b2Abs(_local26);
if (((m_enableLimit) && (!((m_limitState == e_inactiveLimit))))){
_local9 = _local3.m_xf.R;
_local11 = (m_localAnchor1.x - _local3.m_sweep.localCenter.x);
_local12 = (m_localAnchor1.y - _local3.m_sweep.localCenter.y);
_local10 = ((_local9.col1.x * _local11) + (_local9.col2.x * _local12));
_local12 = ((_local9.col1.y * _local11) + (_local9.col2.y * _local12));
_local11 = _local10;
_local9 = _local4.m_xf.R;
_local13 = (m_localAnchor2.x - _local4.m_sweep.localCenter.x);
_local14 = (m_localAnchor2.y - _local4.m_sweep.localCenter.y);
_local10 = ((_local9.col1.x * _local13) + (_local9.col2.x * _local14));
_local14 = ((_local9.col1.y * _local13) + (_local9.col2.y * _local14));
_local13 = _local10;
_local15 = (_local3.m_sweep.c.x + _local11);
_local16 = (_local3.m_sweep.c.y + _local12);
_local17 = (_local4.m_sweep.c.x + _local13);
_local18 = (_local4.m_sweep.c.y + _local14);
_local19 = (_local17 - _local15);
_local20 = (_local18 - _local16);
_local9 = _local3.m_xf.R;
_local29 = ((_local9.col1.x * m_localXAxis1.x) + (_local9.col2.x * m_localXAxis1.y));
_local30 = ((_local9.col1.y * m_localXAxis1.x) + (_local9.col2.y * m_localXAxis1.y));
_local31 = ((_local29 * _local19) + (_local30 * _local20));
_local32 = 0;
if (m_limitState == e_equalLimits){
_local1 = b2Math.b2Clamp(_local31, -(b2Settings.b2_maxLinearCorrection), b2Settings.b2_maxLinearCorrection);
_local32 = (-(m_motorMass) * _local1);
_local25 = b2Math.b2Max(_local25, b2Math.b2Abs(_local26));
} else {
if (m_limitState == e_atLowerLimit){
_local1 = (_local31 - m_lowerTranslation);
_local25 = b2Math.b2Max(_local25, -(_local1));
_local1 = b2Math.b2Clamp((_local1 + b2Settings.b2_linearSlop), -(b2Settings.b2_maxLinearCorrection), 0);
_local32 = (-(m_motorMass) * _local1);
_local2 = m_limitPositionImpulse;
m_limitPositionImpulse = b2Math.b2Max((m_limitPositionImpulse + _local32), 0);
_local32 = (m_limitPositionImpulse - _local2);
} else {
if (m_limitState == e_atUpperLimit){
_local1 = (_local31 - m_upperTranslation);
_local25 = b2Math.b2Max(_local25, _local1);
_local1 = b2Math.b2Clamp((_local1 - b2Settings.b2_linearSlop), 0, b2Settings.b2_maxLinearCorrection);
_local32 = (-(m_motorMass) * _local1);
_local2 = m_limitPositionImpulse;
m_limitPositionImpulse = b2Math.b2Min((m_limitPositionImpulse + _local32), 0);
_local32 = (m_limitPositionImpulse - _local2);
};
};
};
_local3.m_sweep.c.x = (_local3.m_sweep.c.x + ((_local5 * _local32) * m_motorJacobian.linear1.x));
_local3.m_sweep.c.y = (_local3.m_sweep.c.y + ((_local5 * _local32) * m_motorJacobian.linear1.y));
_local3.m_sweep.a = (_local3.m_sweep.a + ((_local7 * _local32) * m_motorJacobian.angular1));
_local4.m_sweep.c.x = (_local4.m_sweep.c.x + ((_local6 * _local32) * m_motorJacobian.linear2.x));
_local4.m_sweep.c.y = (_local4.m_sweep.c.y + ((_local6 * _local32) * m_motorJacobian.linear2.y));
_local4.m_sweep.a = (_local4.m_sweep.a + ((_local8 * _local32) * m_motorJacobian.angular2));
_local3.SynchronizeTransform();
_local4.SynchronizeTransform();
};
return ((((_local25 <= b2Settings.b2_linearSlop)) && ((_local28 <= b2Settings.b2_angularSlop))));
}
public function SetMotorSpeed(_arg1:Number):void{
m_motorSpeed = _arg1;
}
public function GetJointSpeed():Number{
var _local3:b2Mat22;
var _local1:b2Body = m_body1;
var _local2:b2Body = m_body2;
_local3 = _local1.m_xf.R;
var _local4:Number = (m_localAnchor1.x - _local1.m_sweep.localCenter.x);
var _local5:Number = (m_localAnchor1.y - _local1.m_sweep.localCenter.y);
var _local6:Number = ((_local3.col1.x * _local4) + (_local3.col2.x * _local5));
_local5 = ((_local3.col1.y * _local4) + (_local3.col2.y * _local5));
_local4 = _local6;
_local3 = _local2.m_xf.R;
var _local7:Number = (m_localAnchor2.x - _local2.m_sweep.localCenter.x);
var _local8:Number = (m_localAnchor2.y - _local2.m_sweep.localCenter.y);
_local6 = ((_local3.col1.x * _local7) + (_local3.col2.x * _local8));
_local8 = ((_local3.col1.y * _local7) + (_local3.col2.y * _local8));
_local7 = _local6;
var _local9:Number = (_local1.m_sweep.c.x + _local4);
var _local10:Number = (_local1.m_sweep.c.y + _local5);
var _local11:Number = (_local2.m_sweep.c.x + _local7);
var _local12:Number = (_local2.m_sweep.c.y + _local8);
var _local13:Number = (_local11 - _local9);
var _local14:Number = (_local12 - _local10);
var _local15:b2Vec2 = _local1.GetWorldVector(m_localXAxis1);
var _local16:b2Vec2 = _local1.m_linearVelocity;
var _local17:b2Vec2 = _local2.m_linearVelocity;
var _local18:Number = _local1.m_angularVelocity;
var _local19:Number = _local2.m_angularVelocity;
var _local20:Number = (((_local13 * (-(_local18) * _local15.y)) + (_local14 * (_local18 * _local15.x))) + ((_local15.x * (((_local17.x + (-(_local19) * _local8)) - _local16.x) - (-(_local18) * _local5))) + (_local15.y * (((_local17.y + (_local19 * _local7)) - _local16.y) - (_local18 * _local4)))));
return (_local20);
}
override public function InitVelocityConstraints(_arg1:b2TimeStep):void{
var _local4:b2Mat22;
var _local5:Number;
var _local18:Number;
var _local19:Number;
var _local20:Number;
var _local21:Number;
var _local22:Number;
var _local23:Number;
var _local24:Number;
var _local25:Number;
var _local26:Number;
var _local27:Number;
var _local28:Number;
var _local2:b2Body = m_body1;
var _local3:b2Body = m_body2;
_local4 = _local2.m_xf.R;
var _local6:Number = (m_localAnchor1.x - _local2.m_sweep.localCenter.x);
var _local7:Number = (m_localAnchor1.y - _local2.m_sweep.localCenter.y);
_local5 = ((_local4.col1.x * _local6) + (_local4.col2.x * _local7));
_local7 = ((_local4.col1.y * _local6) + (_local4.col2.y * _local7));
_local6 = _local5;
_local4 = _local3.m_xf.R;
var _local8:Number = (m_localAnchor2.x - _local3.m_sweep.localCenter.x);
var _local9:Number = (m_localAnchor2.y - _local3.m_sweep.localCenter.y);
_local5 = ((_local4.col1.x * _local8) + (_local4.col2.x * _local9));
_local9 = ((_local4.col1.y * _local8) + (_local4.col2.y * _local9));
_local8 = _local5;
var _local10:Number = _local2.m_invMass;
var _local11:Number = _local3.m_invMass;
var _local12:Number = _local2.m_invI;
var _local13:Number = _local3.m_invI;
_local4 = _local2.m_xf.R;
var _local14:Number = ((_local4.col1.x * m_localYAxis1.x) + (_local4.col2.x * m_localYAxis1.y));
var _local15:Number = ((_local4.col1.y * m_localYAxis1.x) + (_local4.col2.y * m_localYAxis1.y));
var _local16:Number = ((_local3.m_sweep.c.x + _local8) - _local2.m_sweep.c.x);
var _local17:Number = ((_local3.m_sweep.c.y + _local9) - _local2.m_sweep.c.y);
m_linearJacobian.linear1.x = -(_local14);
m_linearJacobian.linear1.y = -(_local15);
m_linearJacobian.linear2.x = _local14;
m_linearJacobian.linear2.y = _local15;
m_linearJacobian.angular1 = -(((_local16 * _local15) - (_local17 * _local14)));
m_linearJacobian.angular2 = ((_local8 * _local15) - (_local9 * _local14));
m_linearMass = (((_local10 + ((_local12 * m_linearJacobian.angular1) * m_linearJacobian.angular1)) + _local11) + ((_local13 * m_linearJacobian.angular2) * m_linearJacobian.angular2));
m_linearMass = (1 / m_linearMass);
m_angularMass = (_local12 + _local13);
if (m_angularMass > Number.MIN_VALUE){
m_angularMass = (1 / m_angularMass);
};
if (((m_enableLimit) || (m_enableMotor))){
_local4 = _local2.m_xf.R;
_local18 = ((_local4.col1.x * m_localXAxis1.x) + (_local4.col2.x * m_localXAxis1.y));
_local19 = ((_local4.col1.y * m_localXAxis1.x) + (_local4.col2.y * m_localXAxis1.y));
m_motorJacobian.linear1.x = -(_local18);
m_motorJacobian.linear1.y = -(_local19);
m_motorJacobian.linear2.x = _local18;
m_motorJacobian.linear2.y = _local19;
m_motorJacobian.angular1 = -(((_local16 * _local19) - (_local17 * _local18)));
m_motorJacobian.angular2 = ((_local8 * _local19) - (_local9 * _local18));
m_motorMass = (((_local10 + ((_local12 * m_motorJacobian.angular1) * m_motorJacobian.angular1)) + _local11) + ((_local13 * m_motorJacobian.angular2) * m_motorJacobian.angular2));
m_motorMass = (1 / m_motorMass);
if (m_enableLimit){
_local20 = (_local16 - _local6);
_local21 = (_local17 - _local7);
_local22 = ((_local18 * _local20) + (_local19 * _local21));
if (b2Math.b2Abs((m_upperTranslation - m_lowerTranslation)) < (2 * b2Settings.b2_linearSlop)){
m_limitState = e_equalLimits;
} else {
if (_local22 <= m_lowerTranslation){
if (m_limitState != e_atLowerLimit){
m_limitForce = 0;
};
m_limitState = e_atLowerLimit;
} else {
if (_local22 >= m_upperTranslation){
if (m_limitState != e_atUpperLimit){
m_limitForce = 0;
};
m_limitState = e_atUpperLimit;
} else {
m_limitState = e_inactiveLimit;
m_limitForce = 0;
};
};
};
};
};
if (m_enableMotor == false){
m_motorForce = 0;
};
if (m_enableLimit == false){
m_limitForce = 0;
};
if (_arg1.warmStarting){
_local23 = (_arg1.dt * ((m_force * m_linearJacobian.linear1.x) + ((m_motorForce + m_limitForce) * m_motorJacobian.linear1.x)));
_local24 = (_arg1.dt * ((m_force * m_linearJacobian.linear1.y) + ((m_motorForce + m_limitForce) * m_motorJacobian.linear1.y)));
_local25 = (_arg1.dt * ((m_force * m_linearJacobian.linear2.x) + ((m_motorForce + m_limitForce) * m_motorJacobian.linear2.x)));
_local26 = (_arg1.dt * ((m_force * m_linearJacobian.linear2.y) + ((m_motorForce + m_limitForce) * m_motorJacobian.linear2.y)));
_local27 = (_arg1.dt * (((m_force * m_linearJacobian.angular1) - m_torque) + ((m_motorForce + m_limitForce) * m_motorJacobian.angular1)));
_local28 = (_arg1.dt * (((m_force * m_linearJacobian.angular2) + m_torque) + ((m_motorForce + m_limitForce) * m_motorJacobian.angular2)));
_local2.m_linearVelocity.x = (_local2.m_linearVelocity.x + (_local10 * _local23));
_local2.m_linearVelocity.y = (_local2.m_linearVelocity.y + (_local10 * _local24));
_local2.m_angularVelocity = (_local2.m_angularVelocity + (_local12 * _local27));
_local3.m_linearVelocity.x = (_local3.m_linearVelocity.x + (_local11 * _local25));
_local3.m_linearVelocity.y = (_local3.m_linearVelocity.y + (_local11 * _local26));
_local3.m_angularVelocity = (_local3.m_angularVelocity + (_local13 * _local28));
} else {
m_force = 0;
m_torque = 0;
m_limitForce = 0;
m_motorForce = 0;
};
m_limitPositionImpulse = 0;
}
public function GetMotorForce():Number{
return (m_motorForce);
}
public function EnableLimit(_arg1:Boolean):void{
m_enableLimit = _arg1;
}
public function SetMaxMotorForce(_arg1:Number):void{
m_maxMotorForce = _arg1;
}
override public function GetReactionTorque():Number{
return (m_torque);
}
public function IsLimitEnabled():Boolean{
return (m_enableLimit);
}
public function IsMotorEnabled():Boolean{
return (m_enableMotor);
}
public function SetLimits(_arg1:Number, _arg2:Number):void{
m_lowerTranslation = _arg1;
m_upperTranslation = _arg2;
}
}
}//package Box2D.Dynamics.Joints
Section 59
//b2PrismaticJointDef (Box2D.Dynamics.Joints.b2PrismaticJointDef)
package Box2D.Dynamics.Joints {
import Box2D.Dynamics.*;
import Box2D.Common.Math.*;
public class b2PrismaticJointDef extends b2JointDef {
public var motorSpeed:Number;
public var localAxis1:b2Vec2;
public var referenceAngle:Number;
public var upperTranslation:Number;
public var localAnchor1:b2Vec2;
public var localAnchor2:b2Vec2;
public var enableLimit:Boolean;
public var enableMotor:Boolean;
public var maxMotorForce:Number;
public var lowerTranslation:Number;
public function b2PrismaticJointDef(){
localAnchor1 = new b2Vec2();
localAnchor2 = new b2Vec2();
localAxis1 = new b2Vec2();
super();
type = b2Joint.e_prismaticJoint;
localAxis1.Set(1, 0);
referenceAngle = 0;
enableLimit = false;
lowerTranslation = 0;
upperTranslation = 0;
enableMotor = false;
maxMotorForce = 0;
motorSpeed = 0;
}
public function Initialize(_arg1:b2Body, _arg2:b2Body, _arg3:b2Vec2, _arg4:b2Vec2):void{
body1 = _arg1;
body2 = _arg2;
localAnchor1 = body1.GetLocalPoint(_arg3);
localAnchor2 = body2.GetLocalPoint(_arg3);
localAxis1 = body1.GetLocalVector(_arg4);
referenceAngle = (body2.GetAngle() - body1.GetAngle());
}
}
}//package Box2D.Dynamics.Joints
Section 60
//b2PulleyJoint (Box2D.Dynamics.Joints.b2PulleyJoint)
package Box2D.Dynamics.Joints {
import Box2D.Dynamics.*;
import Box2D.Common.Math.*;
import Box2D.Common.*;
public class b2PulleyJoint extends b2Joint {
public var m_limitState1:int;
public var m_limitState2:int;
public var m_ground:b2Body;
public var m_maxLength2:Number;
public var m_maxLength1:Number;
public var m_limitPositionImpulse1:Number;
public var m_limitPositionImpulse2:Number;
public var m_force:Number;
public var m_constant:Number;
public var m_positionImpulse:Number;
public var m_state:int;
public var m_ratio:Number;
public var m_groundAnchor1:b2Vec2;
public var m_groundAnchor2:b2Vec2;
public var m_localAnchor1:b2Vec2;
public var m_localAnchor2:b2Vec2;
public var m_limitMass1:Number;
public var m_limitMass2:Number;
public var m_pulleyMass:Number;
public var m_u1:b2Vec2;
public var m_limitForce1:Number;
public var m_limitForce2:Number;
public var m_u2:b2Vec2;
public static const b2_minPulleyLength:Number = 2;
public function b2PulleyJoint(_arg1:b2PulleyJointDef){
var _local2:b2Mat22;
var _local3:Number;
var _local4:Number;
m_groundAnchor1 = new b2Vec2();
m_groundAnchor2 = new b2Vec2();
m_localAnchor1 = new b2Vec2();
m_localAnchor2 = new b2Vec2();
m_u1 = new b2Vec2();
m_u2 = new b2Vec2();
super(_arg1);
m_ground = m_body1.m_world.m_groundBody;
m_groundAnchor1.x = (_arg1.groundAnchor1.x - m_ground.m_xf.position.x);
m_groundAnchor1.y = (_arg1.groundAnchor1.y - m_ground.m_xf.position.y);
m_groundAnchor2.x = (_arg1.groundAnchor2.x - m_ground.m_xf.position.x);
m_groundAnchor2.y = (_arg1.groundAnchor2.y - m_ground.m_xf.position.y);
m_localAnchor1.SetV(_arg1.localAnchor1);
m_localAnchor2.SetV(_arg1.localAnchor2);
m_ratio = _arg1.ratio;
m_constant = (_arg1.length1 + (m_ratio * _arg1.length2));
m_maxLength1 = b2Math.b2Min(_arg1.maxLength1, (m_constant - (m_ratio * b2_minPulleyLength)));
m_maxLength2 = b2Math.b2Min(_arg1.maxLength2, ((m_constant - b2_minPulleyLength) / m_ratio));
m_force = 0;
m_limitForce1 = 0;
m_limitForce2 = 0;
}
public function GetGroundAnchor2():b2Vec2{
var _local1:b2Vec2 = m_ground.m_xf.position.Copy();
_local1.Add(m_groundAnchor2);
return (_local1);
}
override public function GetAnchor1():b2Vec2{
return (m_body1.GetWorldPoint(m_localAnchor1));
}
override public function GetAnchor2():b2Vec2{
return (m_body2.GetWorldPoint(m_localAnchor2));
}
override public function GetReactionForce():b2Vec2{
var _local1:b2Vec2 = m_u2.Copy();
_local1.Multiply(m_force);
return (_local1);
}
override public function SolvePositionConstraints():Boolean{
var _local3:b2Mat22;
var _local8:Number;
var _local9:Number;
var _local10:Number;
var _local11:Number;
var _local12:Number;
var _local13:Number;
var _local14:Number;
var _local15:Number;
var _local16:Number;
var _local17:Number;
var _local18:Number;
var _local19:Number;
var _local20:Number;
var _local21:Number;
var _local22:Number;
var _local1:b2Body = m_body1;
var _local2:b2Body = m_body2;
var _local4:Number = (m_ground.m_xf.position.x + m_groundAnchor1.x);
var _local5:Number = (m_ground.m_xf.position.y + m_groundAnchor1.y);
var _local6:Number = (m_ground.m_xf.position.x + m_groundAnchor2.x);
var _local7:Number = (m_ground.m_xf.position.y + m_groundAnchor2.y);
var _local23:Number = 0;
if (m_state == e_atUpperLimit){
_local3 = _local1.m_xf.R;
_local8 = (m_localAnchor1.x - _local1.m_sweep.localCenter.x);
_local9 = (m_localAnchor1.y - _local1.m_sweep.localCenter.y);
_local22 = ((_local3.col1.x * _local8) + (_local3.col2.x * _local9));
_local9 = ((_local3.col1.y * _local8) + (_local3.col2.y * _local9));
_local8 = _local22;
_local3 = _local2.m_xf.R;
_local10 = (m_localAnchor2.x - _local2.m_sweep.localCenter.x);
_local11 = (m_localAnchor2.y - _local2.m_sweep.localCenter.y);
_local22 = ((_local3.col1.x * _local10) + (_local3.col2.x * _local11));
_local11 = ((_local3.col1.y * _local10) + (_local3.col2.y * _local11));
_local10 = _local22;
_local12 = (_local1.m_sweep.c.x + _local8);
_local13 = (_local1.m_sweep.c.y + _local9);
_local14 = (_local2.m_sweep.c.x + _local10);
_local15 = (_local2.m_sweep.c.y + _local11);
m_u1.Set((_local12 - _local4), (_local13 - _local5));
m_u2.Set((_local14 - _local6), (_local15 - _local7));
_local16 = m_u1.Length();
_local17 = m_u2.Length();
if (_local16 > b2Settings.b2_linearSlop){
m_u1.Multiply((1 / _local16));
} else {
m_u1.SetZero();
};
if (_local17 > b2Settings.b2_linearSlop){
m_u2.Multiply((1 / _local17));
} else {
m_u2.SetZero();
};
_local18 = ((m_constant - _local16) - (m_ratio * _local17));
_local23 = b2Math.b2Max(_local23, -(_local18));
_local18 = b2Math.b2Clamp((_local18 + b2Settings.b2_linearSlop), -(b2Settings.b2_maxLinearCorrection), 0);
_local19 = (-(m_pulleyMass) * _local18);
_local20 = m_positionImpulse;
m_positionImpulse = b2Math.b2Max(0, (m_positionImpulse + _local19));
_local19 = (m_positionImpulse - _local20);
_local12 = (-(_local19) * m_u1.x);
_local13 = (-(_local19) * m_u1.y);
_local14 = ((-(m_ratio) * _local19) * m_u2.x);
_local15 = ((-(m_ratio) * _local19) * m_u2.y);
_local1.m_sweep.c.x = (_local1.m_sweep.c.x + (_local1.m_invMass * _local12));
_local1.m_sweep.c.y = (_local1.m_sweep.c.y + (_local1.m_invMass * _local13));
_local1.m_sweep.a = (_local1.m_sweep.a + (_local1.m_invI * ((_local8 * _local13) - (_local9 * _local12))));
_local2.m_sweep.c.x = (_local2.m_sweep.c.x + (_local2.m_invMass * _local14));
_local2.m_sweep.c.y = (_local2.m_sweep.c.y + (_local2.m_invMass * _local15));
_local2.m_sweep.a = (_local2.m_sweep.a + (_local2.m_invI * ((_local10 * _local15) - (_local11 * _local14))));
_local1.SynchronizeTransform();
_local2.SynchronizeTransform();
};
if (m_limitState1 == e_atUpperLimit){
_local3 = _local1.m_xf.R;
_local8 = (m_localAnchor1.x - _local1.m_sweep.localCenter.x);
_local9 = (m_localAnchor1.y - _local1.m_sweep.localCenter.y);
_local22 = ((_local3.col1.x * _local8) + (_local3.col2.x * _local9));
_local9 = ((_local3.col1.y * _local8) + (_local3.col2.y * _local9));
_local8 = _local22;
_local12 = (_local1.m_sweep.c.x + _local8);
_local13 = (_local1.m_sweep.c.y + _local9);
m_u1.Set((_local12 - _local4), (_local13 - _local5));
_local16 = m_u1.Length();
if (_local16 > b2Settings.b2_linearSlop){
m_u1.x = (m_u1.x * (1 / _local16));
m_u1.y = (m_u1.y * (1 / _local16));
} else {
m_u1.SetZero();
};
_local18 = (m_maxLength1 - _local16);
_local23 = b2Math.b2Max(_local23, -(_local18));
_local18 = b2Math.b2Clamp((_local18 + b2Settings.b2_linearSlop), -(b2Settings.b2_maxLinearCorrection), 0);
_local19 = (-(m_limitMass1) * _local18);
_local21 = m_limitPositionImpulse1;
m_limitPositionImpulse1 = b2Math.b2Max(0, (m_limitPositionImpulse1 + _local19));
_local19 = (m_limitPositionImpulse1 - _local21);
_local12 = (-(_local19) * m_u1.x);
_local13 = (-(_local19) * m_u1.y);
_local1.m_sweep.c.x = (_local1.m_sweep.c.x + (_local1.m_invMass * _local12));
_local1.m_sweep.c.y = (_local1.m_sweep.c.y + (_local1.m_invMass * _local13));
_local1.m_sweep.a = (_local1.m_sweep.a + (_local1.m_invI * ((_local8 * _local13) - (_local9 * _local12))));
_local1.SynchronizeTransform();
};
if (m_limitState2 == e_atUpperLimit){
_local3 = _local2.m_xf.R;
_local10 = (m_localAnchor2.x - _local2.m_sweep.localCenter.x);
_local11 = (m_localAnchor2.y - _local2.m_sweep.localCenter.y);
_local22 = ((_local3.col1.x * _local10) + (_local3.col2.x * _local11));
_local11 = ((_local3.col1.y * _local10) + (_local3.col2.y * _local11));
_local10 = _local22;
_local14 = (_local2.m_sweep.c.x + _local10);
_local15 = (_local2.m_sweep.c.y + _local11);
m_u2.Set((_local14 - _local6), (_local15 - _local7));
_local17 = m_u2.Length();
if (_local17 > b2Settings.b2_linearSlop){
m_u2.x = (m_u2.x * (1 / _local17));
m_u2.y = (m_u2.y * (1 / _local17));
} else {
m_u2.SetZero();
};
_local18 = (m_maxLength2 - _local17);
_local23 = b2Math.b2Max(_local23, -(_local18));
_local18 = b2Math.b2Clamp((_local18 + b2Settings.b2_linearSlop), -(b2Settings.b2_maxLinearCorrection), 0);
_local19 = (-(m_limitMass2) * _local18);
_local21 = m_limitPositionImpulse2;
m_limitPositionImpulse2 = b2Math.b2Max(0, (m_limitPositionImpulse2 + _local19));
_local19 = (m_limitPositionImpulse2 - _local21);
_local14 = (-(_local19) * m_u2.x);
_local15 = (-(_local19) * m_u2.y);
_local2.m_sweep.c.x = (_local2.m_sweep.c.x + (_local2.m_invMass * _local14));
_local2.m_sweep.c.y = (_local2.m_sweep.c.y + (_local2.m_invMass * _local15));
_local2.m_sweep.a = (_local2.m_sweep.a + (_local2.m_invI * ((_local10 * _local15) - (_local11 * _local14))));
_local2.SynchronizeTransform();
};
return ((_local23 < b2Settings.b2_linearSlop));
}
override public function InitVelocityConstraints(_arg1:b2TimeStep):void{
var _local4:b2Mat22;
var _local23:Number;
var _local24:Number;
var _local25:Number;
var _local26:Number;
var _local2:b2Body = m_body1;
var _local3:b2Body = m_body2;
_local4 = _local2.m_xf.R;
var _local5:Number = (m_localAnchor1.x - _local2.m_sweep.localCenter.x);
var _local6:Number = (m_localAnchor1.y - _local2.m_sweep.localCenter.y);
var _local7:Number = ((_local4.col1.x * _local5) + (_local4.col2.x * _local6));
_local6 = ((_local4.col1.y * _local5) + (_local4.col2.y * _local6));
_local5 = _local7;
_local4 = _local3.m_xf.R;
var _local8:Number = (m_localAnchor2.x - _local3.m_sweep.localCenter.x);
var _local9:Number = (m_localAnchor2.y - _local3.m_sweep.localCenter.y);
_local7 = ((_local4.col1.x * _local8) + (_local4.col2.x * _local9));
_local9 = ((_local4.col1.y * _local8) + (_local4.col2.y * _local9));
_local8 = _local7;
var _local10:Number = (_local2.m_sweep.c.x + _local5);
var _local11:Number = (_local2.m_sweep.c.y + _local6);
var _local12:Number = (_local3.m_sweep.c.x + _local8);
var _local13:Number = (_local3.m_sweep.c.y + _local9);
var _local14:Number = (m_ground.m_xf.position.x + m_groundAnchor1.x);
var _local15:Number = (m_ground.m_xf.position.y + m_groundAnchor1.y);
var _local16:Number = (m_ground.m_xf.position.x + m_groundAnchor2.x);
var _local17:Number = (m_ground.m_xf.position.y + m_groundAnchor2.y);
m_u1.Set((_local10 - _local14), (_local11 - _local15));
m_u2.Set((_local12 - _local16), (_local13 - _local17));
var _local18:Number = m_u1.Length();
var _local19:Number = m_u2.Length();
if (_local18 > b2Settings.b2_linearSlop){
m_u1.Multiply((1 / _local18));
} else {
m_u1.SetZero();
};
if (_local19 > b2Settings.b2_linearSlop){
m_u2.Multiply((1 / _local19));
} else {
m_u2.SetZero();
};
var _local20:Number = ((m_constant - _local18) - (m_ratio * _local19));
if (_local20 > 0){
m_state = e_inactiveLimit;
m_force = 0;
} else {
m_state = e_atUpperLimit;
m_positionImpulse = 0;
};
if (_local18 < m_maxLength1){
m_limitState1 = e_inactiveLimit;
m_limitForce1 = 0;
} else {
m_limitState1 = e_atUpperLimit;
m_limitPositionImpulse1 = 0;
};
if (_local19 < m_maxLength2){
m_limitState2 = e_inactiveLimit;
m_limitForce2 = 0;
} else {
m_limitState2 = e_atUpperLimit;
m_limitPositionImpulse2 = 0;
};
var _local21:Number = ((_local5 * m_u1.y) - (_local6 * m_u1.x));
var _local22:Number = ((_local8 * m_u2.y) - (_local9 * m_u2.x));
m_limitMass1 = (_local2.m_invMass + ((_local2.m_invI * _local21) * _local21));
m_limitMass2 = (_local3.m_invMass + ((_local3.m_invI * _local22) * _local22));
m_pulleyMass = (m_limitMass1 + ((m_ratio * m_ratio) * m_limitMass2));
m_limitMass1 = (1 / m_limitMass1);
m_limitMass2 = (1 / m_limitMass2);
m_pulleyMass = (1 / m_pulleyMass);
if (_arg1.warmStarting){
_local23 = ((_arg1.dt * (-(m_force) - m_limitForce1)) * m_u1.x);
_local24 = ((_arg1.dt * (-(m_force) - m_limitForce1)) * m_u1.y);
_local25 = ((_arg1.dt * ((-(m_ratio) * m_force) - m_limitForce2)) * m_u2.x);
_local26 = ((_arg1.dt * ((-(m_ratio) * m_force) - m_limitForce2)) * m_u2.y);
_local2.m_linearVelocity.x = (_local2.m_linearVelocity.x + (_local2.m_invMass * _local23));
_local2.m_linearVelocity.y = (_local2.m_linearVelocity.y + (_local2.m_invMass * _local24));
_local2.m_angularVelocity = (_local2.m_angularVelocity + (_local2.m_invI * ((_local5 * _local24) - (_local6 * _local23))));
_local3.m_linearVelocity.x = (_local3.m_linearVelocity.x + (_local3.m_invMass * _local25));
_local3.m_linearVelocity.y = (_local3.m_linearVelocity.y + (_local3.m_invMass * _local26));
_local3.m_angularVelocity = (_local3.m_angularVelocity + (_local3.m_invI * ((_local8 * _local26) - (_local9 * _local25))));
} else {
m_force = 0;
m_limitForce1 = 0;
m_limitForce2 = 0;
};
}
override public function GetReactionTorque():Number{
return (0);
}
public function GetRatio():Number{
return (m_ratio);
}
override public function SolveVelocityConstraints(_arg1:b2TimeStep):void{
var _local4:b2Mat22;
var _local10:Number;
var _local11:Number;
var _local12:Number;
var _local13:Number;
var _local14:Number;
var _local15:Number;
var _local16:Number;
var _local17:Number;
var _local18:Number;
var _local19:Number;
var _local20:Number;
var _local2:b2Body = m_body1;
var _local3:b2Body = m_body2;
_local4 = _local2.m_xf.R;
var _local5:Number = (m_localAnchor1.x - _local2.m_sweep.localCenter.x);
var _local6:Number = (m_localAnchor1.y - _local2.m_sweep.localCenter.y);
var _local7:Number = ((_local4.col1.x * _local5) + (_local4.col2.x * _local6));
_local6 = ((_local4.col1.y * _local5) + (_local4.col2.y * _local6));
_local5 = _local7;
_local4 = _local3.m_xf.R;
var _local8:Number = (m_localAnchor2.x - _local3.m_sweep.localCenter.x);
var _local9:Number = (m_localAnchor2.y - _local3.m_sweep.localCenter.y);
_local7 = ((_local4.col1.x * _local8) + (_local4.col2.x * _local9));
_local9 = ((_local4.col1.y * _local8) + (_local4.col2.y * _local9));
_local8 = _local7;
if (m_state == e_atUpperLimit){
_local10 = (_local2.m_linearVelocity.x + (-(_local2.m_angularVelocity) * _local6));
_local11 = (_local2.m_linearVelocity.y + (_local2.m_angularVelocity * _local5));
_local12 = (_local3.m_linearVelocity.x + (-(_local3.m_angularVelocity) * _local9));
_local13 = (_local3.m_linearVelocity.y + (_local3.m_angularVelocity * _local8));
_local18 = (-(((m_u1.x * _local10) + (m_u1.y * _local11))) - (m_ratio * ((m_u2.x * _local12) + (m_u2.y * _local13))));
_local19 = ((-(_arg1.inv_dt) * m_pulleyMass) * _local18);
_local20 = m_force;
m_force = b2Math.b2Max(0, (m_force + _local19));
_local19 = (m_force - _local20);
_local14 = ((-(_arg1.dt) * _local19) * m_u1.x);
_local15 = ((-(_arg1.dt) * _local19) * m_u1.y);
_local16 = (((-(_arg1.dt) * m_ratio) * _local19) * m_u2.x);
_local17 = (((-(_arg1.dt) * m_ratio) * _local19) * m_u2.y);
_local2.m_linearVelocity.x = (_local2.m_linearVelocity.x + (_local2.m_invMass * _local14));
_local2.m_linearVelocity.y = (_local2.m_linearVelocity.y + (_local2.m_invMass * _local15));
_local2.m_angularVelocity = (_local2.m_angularVelocity + (_local2.m_invI * ((_local5 * _local15) - (_local6 * _local14))));
_local3.m_linearVelocity.x = (_local3.m_linearVelocity.x + (_local3.m_invMass * _local16));
_local3.m_linearVelocity.y = (_local3.m_linearVelocity.y + (_local3.m_invMass * _local17));
_local3.m_angularVelocity = (_local3.m_angularVelocity + (_local3.m_invI * ((_local8 * _local17) - (_local9 * _local16))));
};
if (m_limitState1 == e_atUpperLimit){
_local10 = (_local2.m_linearVelocity.x + (-(_local2.m_angularVelocity) * _local6));
_local11 = (_local2.m_linearVelocity.y + (_local2.m_angularVelocity * _local5));
_local18 = -(((m_u1.x * _local10) + (m_u1.y * _local11)));
_local19 = ((-(_arg1.inv_dt) * m_limitMass1) * _local18);
_local20 = m_limitForce1;
m_limitForce1 = b2Math.b2Max(0, (m_limitForce1 + _local19));
_local19 = (m_limitForce1 - _local20);
_local14 = ((-(_arg1.dt) * _local19) * m_u1.x);
_local15 = ((-(_arg1.dt) * _local19) * m_u1.y);
_local2.m_linearVelocity.x = (_local2.m_linearVelocity.x + (_local2.m_invMass * _local14));
_local2.m_linearVelocity.y = (_local2.m_linearVelocity.y + (_local2.m_invMass * _local15));
_local2.m_angularVelocity = (_local2.m_angularVelocity + (_local2.m_invI * ((_local5 * _local15) - (_local6 * _local14))));
};
if (m_limitState2 == e_atUpperLimit){
_local12 = (_local3.m_linearVelocity.x + (-(_local3.m_angularVelocity) * _local9));
_local13 = (_local3.m_linearVelocity.y + (_local3.m_angularVelocity * _local8));
_local18 = -(((m_u2.x * _local12) + (m_u2.y * _local13)));
_local19 = ((-(_arg1.inv_dt) * m_limitMass2) * _local18);
_local20 = m_limitForce2;
m_limitForce2 = b2Math.b2Max(0, (m_limitForce2 + _local19));
_local19 = (m_limitForce2 - _local20);
_local16 = ((-(_arg1.dt) * _local19) * m_u2.x);
_local17 = ((-(_arg1.dt) * _local19) * m_u2.y);
_local3.m_linearVelocity.x = (_local3.m_linearVelocity.x + (_local3.m_invMass * _local16));
_local3.m_linearVelocity.y = (_local3.m_linearVelocity.y + (_local3.m_invMass * _local17));
_local3.m_angularVelocity = (_local3.m_angularVelocity + (_local3.m_invI * ((_local8 * _local17) - (_local9 * _local16))));
};
}
public function GetLength1():Number{
var _local1:b2Vec2 = m_body1.GetWorldPoint(m_localAnchor1);
var _local2:Number = (m_ground.m_xf.position.x + m_groundAnchor1.x);
var _local3:Number = (m_ground.m_xf.position.y + m_groundAnchor1.y);
var _local4:Number = (_local1.x - _local2);
var _local5:Number = (_local1.y - _local3);
return (Math.sqrt(((_local4 * _local4) + (_local5 * _local5))));
}
public function GetLength2():Number{
var _local1:b2Vec2 = m_body2.GetWorldPoint(m_localAnchor2);
var _local2:Number = (m_ground.m_xf.position.x + m_groundAnchor2.x);
var _local3:Number = (m_ground.m_xf.position.y + m_groundAnchor2.y);
var _local4:Number = (_local1.x - _local2);
var _local5:Number = (_local1.y - _local3);
return (Math.sqrt(((_local4 * _local4) + (_local5 * _local5))));
}
public function GetGroundAnchor1():b2Vec2{
var _local1:b2Vec2 = m_ground.m_xf.position.Copy();
_local1.Add(m_groundAnchor1);
return (_local1);
}
}
}//package Box2D.Dynamics.Joints
Section 61
//b2PulleyJointDef (Box2D.Dynamics.Joints.b2PulleyJointDef)
package Box2D.Dynamics.Joints {
import Box2D.Dynamics.*;
import Box2D.Common.Math.*;
public class b2PulleyJointDef extends b2JointDef {
public var maxLength1:Number;
public var maxLength2:Number;
public var length1:Number;
public var localAnchor1:b2Vec2;
public var localAnchor2:b2Vec2;
public var groundAnchor1:b2Vec2;
public var groundAnchor2:b2Vec2;
public var ratio:Number;
public var length2:Number;
public function b2PulleyJointDef(){
groundAnchor1 = new b2Vec2();
groundAnchor2 = new b2Vec2();
localAnchor1 = new b2Vec2();
localAnchor2 = new b2Vec2();
super();
type = b2Joint.e_pulleyJoint;
groundAnchor1.Set(-1, 1);
groundAnchor2.Set(1, 1);
localAnchor1.Set(-1, 0);
localAnchor2.Set(1, 0);
length1 = 0;
maxLength1 = 0;
length2 = 0;
maxLength2 = 0;
ratio = 1;
collideConnected = true;
}
public function Initialize(_arg1:b2Body, _arg2:b2Body, _arg3:b2Vec2, _arg4:b2Vec2, _arg5:b2Vec2, _arg6:b2Vec2, _arg7:Number):void{
body1 = _arg1;
body2 = _arg2;
groundAnchor1.SetV(_arg3);
groundAnchor2.SetV(_arg4);
localAnchor1 = body1.GetLocalPoint(_arg5);
localAnchor2 = body2.GetLocalPoint(_arg6);
var _local8:Number = (_arg5.x - _arg3.x);
var _local9:Number = (_arg5.y - _arg3.y);
length1 = Math.sqrt(((_local8 * _local8) + (_local9 * _local9)));
var _local10:Number = (_arg6.x - _arg4.x);
var _local11:Number = (_arg6.y - _arg4.y);
length2 = Math.sqrt(((_local10 * _local10) + (_local11 * _local11)));
ratio = _arg7;
var _local12:Number = (length1 + (ratio * length2));
maxLength1 = (_local12 - (ratio * b2PulleyJoint.b2_minPulleyLength));
maxLength2 = ((_local12 - b2PulleyJoint.b2_minPulleyLength) / ratio);
}
}
}//package Box2D.Dynamics.Joints
Section 62
//b2RevoluteJoint (Box2D.Dynamics.Joints.b2RevoluteJoint)
package Box2D.Dynamics.Joints {
import Box2D.Dynamics.*;
import Box2D.Common.Math.*;
import Box2D.Common.*;
public class b2RevoluteJoint extends b2Joint {
public var m_limitForce:Number;
public var m_pivotMass:b2Mat22;
public var m_motorForce:Number;
public var m_enableLimit:Boolean;
public var m_limitState:int;
public var m_motorMass:Number;
public var m_localAnchor1:b2Vec2;
public var m_localAnchor2:b2Vec2;
private var K1:b2Mat22;
private var K2:b2Mat22;
private var K3:b2Mat22;
private var K:b2Mat22;
public var m_pivotForce:b2Vec2;
public var m_enableMotor:Boolean;
public var m_referenceAngle:Number;
public var m_limitPositionImpulse:Number;
public var m_motorSpeed:Number;
public var m_upperAngle:Number;
public var m_lowerAngle:Number;
public var m_maxMotorTorque:Number;
public static var tImpulse:b2Vec2 = new b2Vec2();
public function b2RevoluteJoint(_arg1:b2RevoluteJointDef){
K = new b2Mat22();
K1 = new b2Mat22();
K2 = new b2Mat22();
K3 = new b2Mat22();
m_localAnchor1 = new b2Vec2();
m_localAnchor2 = new b2Vec2();
m_pivotForce = new b2Vec2();
m_pivotMass = new b2Mat22();
super(_arg1);
m_localAnchor1.SetV(_arg1.localAnchor1);
m_localAnchor2.SetV(_arg1.localAnchor2);
m_referenceAngle = _arg1.referenceAngle;
m_pivotForce.Set(0, 0);
m_motorForce = 0;
m_limitForce = 0;
m_limitPositionImpulse = 0;
m_lowerAngle = _arg1.lowerAngle;
m_upperAngle = _arg1.upperAngle;
m_maxMotorTorque = _arg1.maxMotorTorque;
m_motorSpeed = _arg1.motorSpeed;
m_enableLimit = _arg1.enableLimit;
m_enableMotor = _arg1.enableMotor;
}
override public function SolveVelocityConstraints(_arg1:b2TimeStep):void{
var _local4:b2Mat22;
var _local5:Number;
var _local10:Number;
var _local16:Number;
var _local17:Number;
var _local18:Number;
var _local19:Number;
var _local20:Number;
var _local21:Number;
var _local2:b2Body = m_body1;
var _local3:b2Body = m_body2;
_local4 = _local2.m_xf.R;
var _local6:Number = (m_localAnchor1.x - _local2.m_sweep.localCenter.x);
var _local7:Number = (m_localAnchor1.y - _local2.m_sweep.localCenter.y);
_local5 = ((_local4.col1.x * _local6) + (_local4.col2.x * _local7));
_local7 = ((_local4.col1.y * _local6) + (_local4.col2.y * _local7));
_local6 = _local5;
_local4 = _local3.m_xf.R;
var _local8:Number = (m_localAnchor2.x - _local3.m_sweep.localCenter.x);
var _local9:Number = (m_localAnchor2.y - _local3.m_sweep.localCenter.y);
_local5 = ((_local4.col1.x * _local8) + (_local4.col2.x * _local9));
_local9 = ((_local4.col1.y * _local8) + (_local4.col2.y * _local9));
_local8 = _local5;
var _local11:Number = (((_local3.m_linearVelocity.x + (-(_local3.m_angularVelocity) * _local9)) - _local2.m_linearVelocity.x) - (-(_local2.m_angularVelocity) * _local7));
var _local12:Number = (((_local3.m_linearVelocity.y + (_local3.m_angularVelocity * _local8)) - _local2.m_linearVelocity.y) - (_local2.m_angularVelocity * _local6));
var _local13:Number = (-(_arg1.inv_dt) * ((m_pivotMass.col1.x * _local11) + (m_pivotMass.col2.x * _local12)));
var _local14:Number = (-(_arg1.inv_dt) * ((m_pivotMass.col1.y * _local11) + (m_pivotMass.col2.y * _local12)));
m_pivotForce.x = (m_pivotForce.x + _local13);
m_pivotForce.y = (m_pivotForce.y + _local14);
var _local15:Number = (_arg1.dt * _local13);
_local16 = (_arg1.dt * _local14);
_local2.m_linearVelocity.x = (_local2.m_linearVelocity.x - (_local2.m_invMass * _local15));
_local2.m_linearVelocity.y = (_local2.m_linearVelocity.y - (_local2.m_invMass * _local16));
_local2.m_angularVelocity = (_local2.m_angularVelocity - (_local2.m_invI * ((_local6 * _local16) - (_local7 * _local15))));
_local3.m_linearVelocity.x = (_local3.m_linearVelocity.x + (_local3.m_invMass * _local15));
_local3.m_linearVelocity.y = (_local3.m_linearVelocity.y + (_local3.m_invMass * _local16));
_local3.m_angularVelocity = (_local3.m_angularVelocity + (_local3.m_invI * ((_local8 * _local16) - (_local9 * _local15))));
if (((m_enableMotor) && (!((m_limitState == e_equalLimits))))){
_local17 = ((_local3.m_angularVelocity - _local2.m_angularVelocity) - m_motorSpeed);
_local18 = ((-(_arg1.inv_dt) * m_motorMass) * _local17);
_local19 = m_motorForce;
m_motorForce = b2Math.b2Clamp((m_motorForce + _local18), -(m_maxMotorTorque), m_maxMotorTorque);
_local18 = (m_motorForce - _local19);
_local2.m_angularVelocity = (_local2.m_angularVelocity - ((_local2.m_invI * _arg1.dt) * _local18));
_local3.m_angularVelocity = (_local3.m_angularVelocity + ((_local3.m_invI * _arg1.dt) * _local18));
};
if (((m_enableLimit) && (!((m_limitState == e_inactiveLimit))))){
_local20 = (_local3.m_angularVelocity - _local2.m_angularVelocity);
_local21 = ((-(_arg1.inv_dt) * m_motorMass) * _local20);
if (m_limitState == e_equalLimits){
m_limitForce = (m_limitForce + _local21);
} else {
if (m_limitState == e_atLowerLimit){
_local10 = m_limitForce;
m_limitForce = b2Math.b2Max((m_limitForce + _local21), 0);
_local21 = (m_limitForce - _local10);
} else {
if (m_limitState == e_atUpperLimit){
_local10 = m_limitForce;
m_limitForce = b2Math.b2Min((m_limitForce + _local21), 0);
_local21 = (m_limitForce - _local10);
};
};
};
_local2.m_angularVelocity = (_local2.m_angularVelocity - ((_local2.m_invI * _arg1.dt) * _local21));
_local3.m_angularVelocity = (_local3.m_angularVelocity + ((_local3.m_invI * _arg1.dt) * _local21));
};
}
override public function GetAnchor1():b2Vec2{
return (m_body1.GetWorldPoint(m_localAnchor1));
}
override public function GetAnchor2():b2Vec2{
return (m_body2.GetWorldPoint(m_localAnchor2));
}
public function GetUpperLimit():Number{
return (m_upperAngle);
}
public function GetLowerLimit():Number{
return (m_lowerAngle);
}
public function EnableMotor(_arg1:Boolean):void{
m_enableMotor = _arg1;
}
public function GetMotorSpeed():Number{
return (m_motorSpeed);
}
override public function GetReactionForce():b2Vec2{
return (m_pivotForce);
}
override public function SolvePositionConstraints():Boolean{
var _local1:Number;
var _local2:Number;
var _local6:b2Mat22;
var _local25:Number;
var _local26:Number;
var _local3:b2Body = m_body1;
var _local4:b2Body = m_body2;
var _local5:Number = 0;
_local6 = _local3.m_xf.R;
var _local7:Number = (m_localAnchor1.x - _local3.m_sweep.localCenter.x);
var _local8:Number = (m_localAnchor1.y - _local3.m_sweep.localCenter.y);
var _local9:Number = ((_local6.col1.x * _local7) + (_local6.col2.x * _local8));
_local8 = ((_local6.col1.y * _local7) + (_local6.col2.y * _local8));
_local7 = _local9;
_local6 = _local4.m_xf.R;
var _local10:Number = (m_localAnchor2.x - _local4.m_sweep.localCenter.x);
var _local11:Number = (m_localAnchor2.y - _local4.m_sweep.localCenter.y);
_local9 = ((_local6.col1.x * _local10) + (_local6.col2.x * _local11));
_local11 = ((_local6.col1.y * _local10) + (_local6.col2.y * _local11));
_local10 = _local9;
var _local12:Number = (_local3.m_sweep.c.x + _local7);
var _local13:Number = (_local3.m_sweep.c.y + _local8);
var _local14:Number = (_local4.m_sweep.c.x + _local10);
var _local15:Number = (_local4.m_sweep.c.y + _local11);
var _local16:Number = (_local14 - _local12);
var _local17:Number = (_local15 - _local13);
_local5 = Math.sqrt(((_local16 * _local16) + (_local17 * _local17)));
var _local18:Number = _local3.m_invMass;
var _local19:Number = _local4.m_invMass;
var _local20:Number = _local3.m_invI;
var _local21:Number = _local4.m_invI;
K1.col1.x = (_local18 + _local19);
K1.col2.x = 0;
K1.col1.y = 0;
K1.col2.y = (_local18 + _local19);
K2.col1.x = ((_local20 * _local8) * _local8);
K2.col2.x = ((-(_local20) * _local7) * _local8);
K2.col1.y = ((-(_local20) * _local7) * _local8);
K2.col2.y = ((_local20 * _local7) * _local7);
K3.col1.x = ((_local21 * _local11) * _local11);
K3.col2.x = ((-(_local21) * _local10) * _local11);
K3.col1.y = ((-(_local21) * _local10) * _local11);
K3.col2.y = ((_local21 * _local10) * _local10);
K.SetM(K1);
K.AddM(K2);
K.AddM(K3);
K.Solve(tImpulse, -(_local16), -(_local17));
var _local22:Number = tImpulse.x;
var _local23:Number = tImpulse.y;
_local3.m_sweep.c.x = (_local3.m_sweep.c.x - (_local3.m_invMass * _local22));
_local3.m_sweep.c.y = (_local3.m_sweep.c.y - (_local3.m_invMass * _local23));
_local3.m_sweep.a = (_local3.m_sweep.a - (_local3.m_invI * ((_local7 * _local23) - (_local8 * _local22))));
_local4.m_sweep.c.x = (_local4.m_sweep.c.x + (_local4.m_invMass * _local22));
_local4.m_sweep.c.y = (_local4.m_sweep.c.y + (_local4.m_invMass * _local23));
_local4.m_sweep.a = (_local4.m_sweep.a + (_local4.m_invI * ((_local10 * _local23) - (_local11 * _local22))));
_local3.SynchronizeTransform();
_local4.SynchronizeTransform();
var _local24:Number = 0;
if (((m_enableLimit) && (!((m_limitState == e_inactiveLimit))))){
_local25 = ((_local4.m_sweep.a - _local3.m_sweep.a) - m_referenceAngle);
_local26 = 0;
if (m_limitState == e_equalLimits){
_local2 = b2Math.b2Clamp(_local25, -(b2Settings.b2_maxAngularCorrection), b2Settings.b2_maxAngularCorrection);
_local26 = (-(m_motorMass) * _local2);
_local24 = b2Math.b2Abs(_local2);
} else {
if (m_limitState == e_atLowerLimit){
_local2 = (_local25 - m_lowerAngle);
_local24 = b2Math.b2Max(0, -(_local2));
_local2 = b2Math.b2Clamp((_local2 + b2Settings.b2_angularSlop), -(b2Settings.b2_maxAngularCorrection), 0);
_local26 = (-(m_motorMass) * _local2);
_local1 = m_limitPositionImpulse;
m_limitPositionImpulse = b2Math.b2Max((m_limitPositionImpulse + _local26), 0);
_local26 = (m_limitPositionImpulse - _local1);
} else {
if (m_limitState == e_atUpperLimit){
_local2 = (_local25 - m_upperAngle);
_local24 = b2Math.b2Max(0, _local2);
_local2 = b2Math.b2Clamp((_local2 - b2Settings.b2_angularSlop), 0, b2Settings.b2_maxAngularCorrection);
_local26 = (-(m_motorMass) * _local2);
_local1 = m_limitPositionImpulse;
m_limitPositionImpulse = b2Math.b2Min((m_limitPositionImpulse + _local26), 0);
_local26 = (m_limitPositionImpulse - _local1);
};
};
};
_local3.m_sweep.a = (_local3.m_sweep.a - (_local3.m_invI * _local26));
_local4.m_sweep.a = (_local4.m_sweep.a + (_local4.m_invI * _local26));
_local3.SynchronizeTransform();
_local4.SynchronizeTransform();
};
return ((((_local5 <= b2Settings.b2_linearSlop)) && ((_local24 <= b2Settings.b2_angularSlop))));
}
public function SetMotorSpeed(_arg1:Number):void{
m_motorSpeed = _arg1;
}
public function GetJointSpeed():Number{
return ((m_body2.m_angularVelocity - m_body1.m_angularVelocity));
}
public function SetMaxMotorTorque(_arg1:Number):void{
m_maxMotorTorque = _arg1;
}
public function GetJointAngle():Number{
return (((m_body2.m_sweep.a - m_body1.m_sweep.a) - m_referenceAngle));
}
public function GetMotorTorque():Number{
return (m_motorForce);
}
override public function InitVelocityConstraints(_arg1:b2TimeStep):void{
var _local2:b2Body;
var _local3:b2Body;
var _local4:b2Mat22;
var _local5:Number;
var _local7:Number;
var _local14:Number;
_local2 = m_body1;
_local3 = m_body2;
_local4 = _local2.m_xf.R;
var _local6:Number = (m_localAnchor1.x - _local2.m_sweep.localCenter.x);
_local7 = (m_localAnchor1.y - _local2.m_sweep.localCenter.y);
_local5 = ((_local4.col1.x * _local6) + (_local4.col2.x * _local7));
_local7 = ((_local4.col1.y * _local6) + (_local4.col2.y * _local7));
_local6 = _local5;
_local4 = _local3.m_xf.R;
var _local8:Number = (m_localAnchor2.x - _local3.m_sweep.localCenter.x);
var _local9:Number = (m_localAnchor2.y - _local3.m_sweep.localCenter.y);
_local5 = ((_local4.col1.x * _local8) + (_local4.col2.x * _local9));
_local9 = ((_local4.col1.y * _local8) + (_local4.col2.y * _local9));
_local8 = _local5;
var _local10:Number = _local2.m_invMass;
var _local11:Number = _local3.m_invMass;
var _local12:Number = _local2.m_invI;
var _local13:Number = _local3.m_invI;
K1.col1.x = (_local10 + _local11);
K1.col2.x = 0;
K1.col1.y = 0;
K1.col2.y = (_local10 + _local11);
K2.col1.x = ((_local12 * _local7) * _local7);
K2.col2.x = ((-(_local12) * _local6) * _local7);
K2.col1.y = ((-(_local12) * _local6) * _local7);
K2.col2.y = ((_local12 * _local6) * _local6);
K3.col1.x = ((_local13 * _local9) * _local9);
K3.col2.x = ((-(_local13) * _local8) * _local9);
K3.col1.y = ((-(_local13) * _local8) * _local9);
K3.col2.y = ((_local13 * _local8) * _local8);
K.SetM(K1);
K.AddM(K2);
K.AddM(K3);
K.Invert(m_pivotMass);
m_motorMass = (1 / (_local12 + _local13));
if (m_enableMotor == false){
m_motorForce = 0;
};
if (m_enableLimit){
_local14 = ((_local3.m_sweep.a - _local2.m_sweep.a) - m_referenceAngle);
if (b2Math.b2Abs((m_upperAngle - m_lowerAngle)) < (2 * b2Settings.b2_angularSlop)){
m_limitState = e_equalLimits;
} else {
if (_local14 <= m_lowerAngle){
if (m_limitState != e_atLowerLimit){
m_limitForce = 0;
};
m_limitState = e_atLowerLimit;
} else {
if (_local14 >= m_upperAngle){
if (m_limitState != e_atUpperLimit){
m_limitForce = 0;
};
m_limitState = e_atUpperLimit;
} else {
m_limitState = e_inactiveLimit;
m_limitForce = 0;
};
};
};
} else {
m_limitForce = 0;
};
if (_arg1.warmStarting){
_local2.m_linearVelocity.x = (_local2.m_linearVelocity.x - ((_arg1.dt * _local10) * m_pivotForce.x));
_local2.m_linearVelocity.y = (_local2.m_linearVelocity.y - ((_arg1.dt * _local10) * m_pivotForce.y));
_local2.m_angularVelocity = (_local2.m_angularVelocity - ((_arg1.dt * _local12) * ((((_local6 * m_pivotForce.y) - (_local7 * m_pivotForce.x)) + m_motorForce) + m_limitForce)));
_local3.m_linearVelocity.x = (_local3.m_linearVelocity.x + ((_arg1.dt * _local11) * m_pivotForce.x));
_local3.m_linearVelocity.y = (_local3.m_linearVelocity.y + ((_arg1.dt * _local11) * m_pivotForce.y));
_local3.m_angularVelocity = (_local3.m_angularVelocity + ((_arg1.dt * _local13) * ((((_local8 * m_pivotForce.y) - (_local9 * m_pivotForce.x)) + m_motorForce) + m_limitForce)));
} else {
m_pivotForce.SetZero();
m_motorForce = 0;
m_limitForce = 0;
};
m_limitPositionImpulse = 0;
}
public function EnableLimit(_arg1:Boolean):void{
m_enableLimit = _arg1;
}
override public function GetReactionTorque():Number{
return (m_limitForce);
}
public function IsLimitEnabled():Boolean{
return (m_enableLimit);
}
public function IsMotorEnabled():Boolean{
return (m_enableMotor);
}
public function SetLimits(_arg1:Number, _arg2:Number):void{
m_lowerAngle = _arg1;
m_upperAngle = _arg2;
}
}
}//package Box2D.Dynamics.Joints
Section 63
//b2RevoluteJointDef (Box2D.Dynamics.Joints.b2RevoluteJointDef)
package Box2D.Dynamics.Joints {
import Box2D.Dynamics.*;
import Box2D.Common.Math.*;
public class b2RevoluteJointDef extends b2JointDef {
public var upperAngle:Number;
public var enableMotor:Boolean;
public var referenceAngle:Number;
public var motorSpeed:Number;
public var localAnchor1:b2Vec2;
public var localAnchor2:b2Vec2;
public var enableLimit:Boolean;
public var lowerAngle:Number;
public var maxMotorTorque:Number;
public function b2RevoluteJointDef(){
localAnchor1 = new b2Vec2();
localAnchor2 = new b2Vec2();
super();
type = b2Joint.e_revoluteJoint;
localAnchor1.Set(0, 0);
localAnchor2.Set(0, 0);
referenceAngle = 0;
lowerAngle = 0;
upperAngle = 0;
maxMotorTorque = 0;
motorSpeed = 0;
enableLimit = false;
enableMotor = false;
}
public function Initialize(_arg1:b2Body, _arg2:b2Body, _arg3:b2Vec2):void{
body1 = _arg1;
body2 = _arg2;
localAnchor1 = body1.GetLocalPoint(_arg3);
localAnchor2 = body2.GetLocalPoint(_arg3);
referenceAngle = (body2.GetAngle() - body1.GetAngle());
}
}
}//package Box2D.Dynamics.Joints
Section 64
//b2Body (Box2D.Dynamics.b2Body)
package Box2D.Dynamics {
import Box2D.Dynamics.Joints.*;
import Box2D.Common.Math.*;
import Box2D.Collision.Shapes.*;
import Box2D.Dynamics.Contacts.*;
public class b2Body {
public var m_next:b2Body;
public var m_xf:b2XForm;
public var m_contactList:b2ContactEdge;
public var m_angularVelocity:Number;
public var m_shapeList:b2Shape;
public var m_force:b2Vec2;
public var m_mass:Number;
public var m_sweep:b2Sweep;
public var m_torque:Number;
public var m_userData;
public var m_flags:uint;
public var m_world:b2World;
public var m_prev:b2Body;
public var m_invMass:Number;
public var m_type:int;
public var m_linearDamping:Number;
public var m_shapeCount:int;
public var m_angularDamping:Number;
public var m_invI:Number;
public var m_linearVelocity:b2Vec2;
public var m_sleepTime:Number;
public var m_jointList:b2JointEdge;
public var m_I:Number;
public static var e_fixedRotationFlag:uint = 64;
public static var e_frozenFlag:uint = 2;
public static var e_maxTypes:uint = 3;
public static var e_sleepFlag:uint = 8;
private static var s_massData:b2MassData = new b2MassData();
public static var e_bulletFlag:uint = 32;
public static var e_staticType:uint = 1;
public static var e_islandFlag:uint = 4;
public static var e_allowSleepFlag:uint = 16;
private static var s_xf1:b2XForm = new b2XForm();
public static var e_dynamicType:uint = 2;
public function b2Body(_arg1:b2BodyDef, _arg2:b2World){
m_xf = new b2XForm();
m_sweep = new b2Sweep();
m_linearVelocity = new b2Vec2();
m_force = new b2Vec2();
super();
m_flags = 0;
if (_arg1.isBullet){
m_flags = (m_flags | e_bulletFlag);
};
if (_arg1.fixedRotation){
m_flags = (m_flags | e_fixedRotationFlag);
};
if (_arg1.allowSleep){
m_flags = (m_flags | e_allowSleepFlag);
};
if (_arg1.isSleeping){
m_flags = (m_flags | e_sleepFlag);
};
m_world = _arg2;
m_xf.position.SetV(_arg1.position);
m_xf.R.Set(_arg1.angle);
m_sweep.localCenter.SetV(_arg1.massData.center);
m_sweep.t0 = 1;
m_sweep.a0 = (m_sweep.a = _arg1.angle);
var _local3:b2Mat22 = m_xf.R;
var _local4:b2Vec2 = m_sweep.localCenter;
m_sweep.c.x = ((_local3.col1.x * _local4.x) + (_local3.col2.x * _local4.y));
m_sweep.c.y = ((_local3.col1.y * _local4.x) + (_local3.col2.y * _local4.y));
m_sweep.c.x = (m_sweep.c.x + m_xf.position.x);
m_sweep.c.y = (m_sweep.c.y + m_xf.position.y);
m_sweep.c0.SetV(m_sweep.c);
m_jointList = null;
m_contactList = null;
m_prev = null;
m_next = null;
m_linearDamping = _arg1.linearDamping;
m_angularDamping = _arg1.angularDamping;
m_force.Set(0, 0);
m_torque = 0;
m_linearVelocity.SetZero();
m_angularVelocity = 0;
m_sleepTime = 0;
m_invMass = 0;
m_I = 0;
m_invI = 0;
m_mass = _arg1.massData.mass;
if (m_mass > 0){
m_invMass = (1 / m_mass);
};
if ((m_flags & b2Body.e_fixedRotationFlag) == 0){
m_I = _arg1.massData.I;
};
if (m_I > 0){
m_invI = (1 / m_I);
};
if ((((m_invMass == 0)) && ((m_invI == 0)))){
m_type = e_staticType;
} else {
m_type = e_dynamicType;
};
m_userData = _arg1.userData;
m_shapeList = null;
m_shapeCount = 0;
}
public function GetLinearVelocityFromWorldPoint(_arg1:b2Vec2):b2Vec2{
return (new b2Vec2((m_linearVelocity.x + (m_angularVelocity * (_arg1.y - m_sweep.c.y))), (m_linearVelocity.x - (m_angularVelocity * (_arg1.x - m_sweep.c.x)))));
}
public function SetLinearVelocity(_arg1:b2Vec2):void{
m_linearVelocity.SetV(_arg1);
}
public function WakeUp():void{
m_flags = (m_flags & ~(e_sleepFlag));
m_sleepTime = 0;
}
public function GetLocalCenter():b2Vec2{
return (m_sweep.localCenter);
}
public function ApplyTorque(_arg1:Number):void{
if (IsSleeping()){
WakeUp();
};
m_torque = (m_torque + _arg1);
}
public function IsFrozen():Boolean{
return (((m_flags & e_frozenFlag) == e_frozenFlag));
}
public function IsDynamic():Boolean{
return ((m_type == e_dynamicType));
}
public function GetLinearVelocity():b2Vec2{
return (m_linearVelocity);
}
public function SynchronizeTransform():void{
m_xf.R.Set(m_sweep.a);
var _local1:b2Mat22 = m_xf.R;
var _local2:b2Vec2 = m_sweep.localCenter;
m_xf.position.x = (m_sweep.c.x - ((_local1.col1.x * _local2.x) + (_local1.col2.x * _local2.y)));
m_xf.position.y = (m_sweep.c.y - ((_local1.col1.y * _local2.x) + (_local1.col2.y * _local2.y)));
}
public function GetInertia():Number{
return (m_I);
}
public function IsSleeping():Boolean{
return (((m_flags & e_sleepFlag) == e_sleepFlag));
}
public function SetMassFromShapes():void{
var _local1:b2Shape;
if (m_world.m_lock == true){
return;
};
m_mass = 0;
m_invMass = 0;
m_I = 0;
m_invI = 0;
var _local2:Number = 0;
var _local3:Number = 0;
var _local4:b2MassData = s_massData;
_local1 = m_shapeList;
while (_local1) {
_local1.ComputeMass(_local4);
m_mass = (m_mass + _local4.mass);
_local2 = (_local2 + (_local4.mass * _local4.center.x));
_local3 = (_local3 + (_local4.mass * _local4.center.y));
m_I = (m_I + _local4.I);
_local1 = _local1.m_next;
};
if (m_mass > 0){
m_invMass = (1 / m_mass);
_local2 = (_local2 * m_invMass);
_local3 = (_local3 * m_invMass);
};
if ((((m_I > 0)) && (((m_flags & e_fixedRotationFlag) == 0)))){
m_I = (m_I - (m_mass * ((_local2 * _local2) + (_local3 * _local3))));
m_invI = (1 / m_I);
} else {
m_I = 0;
m_invI = 0;
};
m_sweep.localCenter.Set(_local2, _local3);
var _local5:b2Mat22 = m_xf.R;
var _local6:b2Vec2 = m_sweep.localCenter;
m_sweep.c.x = ((_local5.col1.x * _local6.x) + (_local5.col2.x * _local6.y));
m_sweep.c.y = ((_local5.col1.y * _local6.x) + (_local5.col2.y * _local6.y));
m_sweep.c.x = (m_sweep.c.x + m_xf.position.x);
m_sweep.c.y = (m_sweep.c.y + m_xf.position.y);
m_sweep.c0.SetV(m_sweep.c);
_local1 = m_shapeList;
while (_local1) {
_local1.UpdateSweepRadius(m_sweep.localCenter);
_local1 = _local1.m_next;
};
var _local7:int = m_type;
if ((((m_invMass == 0)) && ((m_invI == 0)))){
m_type = e_staticType;
} else {
m_type = e_dynamicType;
};
if (_local7 != m_type){
_local1 = m_shapeList;
while (_local1) {
_local1.RefilterProxy(m_world.m_broadPhase, m_xf);
_local1 = _local1.m_next;
};
};
}
public function PutToSleep():void{
m_flags = (m_flags | e_sleepFlag);
m_sleepTime = 0;
m_linearVelocity.SetZero();
m_angularVelocity = 0;
m_force.SetZero();
m_torque = 0;
}
public function GetJointList():b2JointEdge{
return (m_jointList);
}
public function SetXForm(_arg1:b2Vec2, _arg2:Number):Boolean{
var _local3:b2Shape;
var _local7:Boolean;
if (m_world.m_lock == true){
return (true);
};
if (IsFrozen()){
return (false);
};
m_xf.R.Set(_arg2);
m_xf.position.SetV(_arg1);
var _local4:b2Mat22 = m_xf.R;
var _local5:b2Vec2 = m_sweep.localCenter;
m_sweep.c.x = ((_local4.col1.x * _local5.x) + (_local4.col2.x * _local5.y));
m_sweep.c.y = ((_local4.col1.y * _local5.x) + (_local4.col2.y * _local5.y));
m_sweep.c.x = (m_sweep.c.x + m_xf.position.x);
m_sweep.c.y = (m_sweep.c.y + m_xf.position.y);
m_sweep.c0.SetV(m_sweep.c);
m_sweep.a0 = (m_sweep.a = _arg2);
var _local6:Boolean;
_local3 = m_shapeList;
while (_local3) {
_local7 = _local3.Synchronize(m_world.m_broadPhase, m_xf, m_xf);
if (_local7 == false){
_local6 = true;
break;
};
_local3 = _local3.m_next;
};
if (_local6 == true){
m_flags = (m_flags | e_frozenFlag);
m_linearVelocity.SetZero();
m_angularVelocity = 0;
_local3 = m_shapeList;
while (_local3) {
_local3.DestroyProxy(m_world.m_broadPhase);
_local3 = _local3.m_next;
};
return (false);
};
m_world.m_broadPhase.Commit();
return (true);
}
public function GetLocalPoint(_arg1:b2Vec2):b2Vec2{
return (b2Math.b2MulXT(m_xf, _arg1));
}
public function ApplyForce(_arg1:b2Vec2, _arg2:b2Vec2):void{
if (IsSleeping()){
WakeUp();
};
m_force.x = (m_force.x + _arg1.x);
m_force.y = (m_force.y + _arg1.y);
m_torque = (m_torque + (((_arg2.x - m_sweep.c.x) * _arg1.y) - ((_arg2.y - m_sweep.c.y) * _arg1.x)));
}
public function SynchronizeShapes():Boolean{
var _local4:b2Shape;
var _local1:b2XForm = s_xf1;
_local1.R.Set(m_sweep.a0);
var _local2:b2Mat22 = _local1.R;
var _local3:b2Vec2 = m_sweep.localCenter;
_local1.position.x = (m_sweep.c0.x - ((_local2.col1.x * _local3.x) + (_local2.col2.x * _local3.y)));
_local1.position.y = (m_sweep.c0.y - ((_local2.col1.y * _local3.x) + (_local2.col2.y * _local3.y)));
var _local5:Boolean;
_local4 = m_shapeList;
while (_local4) {
_local5 = _local4.Synchronize(m_world.m_broadPhase, _local1, m_xf);
if (_local5 == false){
break;
};
_local4 = _local4.m_next;
};
if (_local5 == false){
m_flags = (m_flags | e_frozenFlag);
m_linearVelocity.SetZero();
m_angularVelocity = 0;
_local4 = m_shapeList;
while (_local4) {
_local4.DestroyProxy(m_world.m_broadPhase);
_local4 = _local4.m_next;
};
return (false);
};
return (true);
}
public function GetAngle():Number{
return (m_sweep.a);
}
public function GetXForm():b2XForm{
return (m_xf);
}
public function GetLinearVelocityFromLocalPoint(_arg1:b2Vec2):b2Vec2{
var _local2:b2Mat22 = m_xf.R;
var _local3:b2Vec2 = new b2Vec2(((_local2.col1.x * _arg1.x) + (_local2.col2.x * _arg1.y)), ((_local2.col1.y * _arg1.x) + (_local2.col2.y * _arg1.y)));
_local3.x = (_local3.x + m_xf.position.x);
_local3.y = (_local3.y + m_xf.position.y);
return (new b2Vec2((m_linearVelocity.x + (m_angularVelocity * (_local3.y - m_sweep.c.y))), (m_linearVelocity.x - (m_angularVelocity * (_local3.x - m_sweep.c.x)))));
}
public function GetNext():b2Body{
return (m_next);
}
public function GetMass():Number{
return (m_mass);
}
public function ApplyImpulse(_arg1:b2Vec2, _arg2:b2Vec2):void{
if (IsSleeping()){
WakeUp();
};
m_linearVelocity.x = (m_linearVelocity.x + (m_invMass * _arg1.x));
m_linearVelocity.y = (m_linearVelocity.y + (m_invMass * _arg1.y));
m_angularVelocity = (m_angularVelocity + (m_invI * (((_arg2.x - m_sweep.c.x) * _arg1.y) - ((_arg2.y - m_sweep.c.y) * _arg1.x))));
}
public function GetAngularVelocity():Number{
return (m_angularVelocity);
}
public function SetAngularVelocity(_arg1:Number):void{
m_angularVelocity = _arg1;
}
public function SetMass(_arg1:b2MassData):void{
var _local2:b2Shape;
if (m_world.m_lock == true){
return;
};
m_invMass = 0;
m_I = 0;
m_invI = 0;
m_mass = _arg1.mass;
if (m_mass > 0){
m_invMass = (1 / m_mass);
};
if ((m_flags & b2Body.e_fixedRotationFlag) == 0){
m_I = _arg1.I;
};
if (m_I > 0){
m_invI = (1 / m_I);
};
m_sweep.localCenter.SetV(_arg1.center);
var _local3:b2Mat22 = m_xf.R;
var _local4:b2Vec2 = m_sweep.localCenter;
m_sweep.c.x = ((_local3.col1.x * _local4.x) + (_local3.col2.x * _local4.y));
m_sweep.c.y = ((_local3.col1.y * _local4.x) + (_local3.col2.y * _local4.y));
m_sweep.c.x = (m_sweep.c.x + m_xf.position.x);
m_sweep.c.y = (m_sweep.c.y + m_xf.position.y);
m_sweep.c0.SetV(m_sweep.c);
_local2 = m_shapeList;
while (_local2) {
_local2.UpdateSweepRadius(m_sweep.localCenter);
_local2 = _local2.m_next;
};
var _local5:int = m_type;
if ((((m_invMass == 0)) && ((m_invI == 0)))){
m_type = e_staticType;
} else {
m_type = e_dynamicType;
};
if (_local5 != m_type){
_local2 = m_shapeList;
while (_local2) {
_local2.RefilterProxy(m_world.m_broadPhase, m_xf);
_local2 = _local2.m_next;
};
};
}
public function IsStatic():Boolean{
return ((m_type == e_staticType));
}
public function GetWorldVector(_arg1:b2Vec2):b2Vec2{
return (b2Math.b2MulMV(m_xf.R, _arg1));
}
public function GetShapeList():b2Shape{
return (m_shapeList);
}
public function Advance(_arg1:Number):void{
m_sweep.Advance(_arg1);
m_sweep.c.SetV(m_sweep.c0);
m_sweep.a = m_sweep.a0;
SynchronizeTransform();
}
public function SetBullet(_arg1:Boolean):void{
if (_arg1){
m_flags = (m_flags | e_bulletFlag);
} else {
m_flags = (m_flags & ~(e_bulletFlag));
};
}
public function CreateShape(_arg1:b2ShapeDef):b2Shape{
var _local2:b2Shape;
if (m_world.m_lock == true){
return (null);
};
_local2 = b2Shape.Create(_arg1, m_world.m_blockAllocator);
_local2.m_next = m_shapeList;
m_shapeList = _local2;
m_shapeCount++;
_local2.m_body = this;
_local2.CreateProxy(m_world.m_broadPhase, m_xf);
_local2.UpdateSweepRadius(m_sweep.localCenter);
return (_local2);
}
public function IsConnected(_arg1:b2Body):Boolean{
var _local2:b2JointEdge = m_jointList;
while (_local2) {
if (_local2.other == _arg1){
return ((_local2.joint.m_collideConnected == false));
};
_local2 = _local2.next;
};
return (false);
}
public function DestroyShape(_arg1:b2Shape):void{
if (m_world.m_lock == true){
return;
};
_arg1.DestroyProxy(m_world.m_broadPhase);
var _local2:b2Shape = m_shapeList;
var _local3:b2Shape;
var _local4:Boolean;
while (_local2 != null) {
if (_local2 == _arg1){
if (_local3){
_local3.m_next = _arg1.m_next;
} else {
m_shapeList = _arg1.m_next;
};
_local4 = true;
break;
};
_local3 = _local2;
_local2 = _local2.m_next;
};
_arg1.m_body = null;
_arg1.m_next = null;
m_shapeCount--;
b2Shape.Destroy(_arg1, m_world.m_blockAllocator);
}
public function GetUserData(){
return (m_userData);
}
public function IsBullet():Boolean{
return (((m_flags & e_bulletFlag) == e_bulletFlag));
}
public function GetWorldCenter():b2Vec2{
return (m_sweep.c);
}
public function AllowSleeping(_arg1:Boolean):void{
if (_arg1){
m_flags = (m_flags | e_allowSleepFlag);
} else {
m_flags = (m_flags & ~(e_allowSleepFlag));
WakeUp();
};
}
public function SetUserData(_arg1):void{
m_userData = _arg1;
}
public function GetLocalVector(_arg1:b2Vec2):b2Vec2{
return (b2Math.b2MulTMV(m_xf.R, _arg1));
}
public function GetWorldPoint(_arg1:b2Vec2):b2Vec2{
var _local2:b2Mat22 = m_xf.R;
var _local3:b2Vec2 = new b2Vec2(((_local2.col1.x * _arg1.x) + (_local2.col2.x * _arg1.y)), ((_local2.col1.y * _arg1.x) + (_local2.col2.y * _arg1.y)));
_local3.x = (_local3.x + m_xf.position.x);
_local3.y = (_local3.y + m_xf.position.y);
return (_local3);
}
public function GetWorld():b2World{
return (m_world);
}
public function GetPosition():b2Vec2{
return (m_xf.position);
}
}
}//package Box2D.Dynamics
Section 65
//b2BodyDef (Box2D.Dynamics.b2BodyDef)
package Box2D.Dynamics {
import Box2D.Common.Math.*;
import Box2D.Collision.Shapes.*;
public class b2BodyDef {
public var angularDamping:Number;
public var angle:Number;
public var isSleeping:Boolean;
public var position:b2Vec2;
public var isBullet:Boolean;
public var allowSleep:Boolean;
public var userData;
public var fixedRotation:Boolean;
public var linearDamping:Number;
public var massData:b2MassData;
public function b2BodyDef(){
massData = new b2MassData();
position = new b2Vec2();
super();
massData.center.SetZero();
massData.mass = 0;
massData.I = 0;
userData = null;
position.Set(0, 0);
angle = 0;
linearDamping = 0;
angularDamping = 0;
allowSleep = true;
isSleeping = false;
fixedRotation = false;
isBullet = false;
}
}
}//package Box2D.Dynamics
Section 66
//b2BoundaryListener (Box2D.Dynamics.b2BoundaryListener)
package Box2D.Dynamics {
public class b2BoundaryListener {
public function Violation(_arg1:b2Body):void{
}
}
}//package Box2D.Dynamics
Section 67
//b2ContactFilter (Box2D.Dynamics.b2ContactFilter)
package Box2D.Dynamics {
import Box2D.Collision.Shapes.*;
public class b2ContactFilter {
public static var b2_defaultFilter:b2ContactFilter = new (b2ContactFilter);
;
public function ShouldCollide(_arg1:b2Shape, _arg2:b2Shape):Boolean{
var _local3:b2FilterData = _arg1.GetFilterData();
var _local4:b2FilterData = _arg2.GetFilterData();
if ((((_local3.groupIndex == _local4.groupIndex)) && (!((_local3.groupIndex == 0))))){
return ((_local3.groupIndex > 0));
};
var _local5:Boolean = ((!(((_local3.maskBits & _local4.categoryBits) == 0))) && (!(((_local3.categoryBits & _local4.maskBits) == 0))));
return (_local5);
}
}
}//package Box2D.Dynamics
Section 68
//b2ContactListener (Box2D.Dynamics.b2ContactListener)
package Box2D.Dynamics {
import Box2D.Collision.*;
import Box2D.Dynamics.Contacts.*;
public class b2ContactListener {
public function Add(_arg1:b2ContactPoint):void{
}
public function Remove(_arg1:b2ContactPoint):void{
}
public function Persist(_arg1:b2ContactPoint):void{
}
public function Result(_arg1:b2ContactResult):void{
}
}
}//package Box2D.Dynamics
Section 69
//b2ContactManager (Box2D.Dynamics.b2ContactManager)
package Box2D.Dynamics {
import Box2D.Common.Math.*;
import Box2D.Collision.*;
import Box2D.Collision.Shapes.*;
import Box2D.Common.*;
import Box2D.Dynamics.Contacts.*;
public class b2ContactManager extends b2PairCallback {
public var m_world:b2World;
public var m_destroyImmediate:Boolean;
public var m_nullContact:b2NullContact;
private static const s_evalCP:b2ContactPoint = new b2ContactPoint();
public function b2ContactManager(){
m_nullContact = new b2NullContact();
super();
m_world = null;
m_destroyImmediate = false;
}
override public function PairRemoved(_arg1, _arg2, _arg3):void{
if (_arg3 == null){
return;
};
var _local4:b2Contact = (_arg3 as b2Contact);
if (_local4 == m_nullContact){
return;
};
Destroy(_local4);
}
public function Destroy(_arg1:b2Contact):void{
var _local7:b2Body;
var _local8:b2Body;
var _local9:Array;
var _local10:b2ContactPoint;
var _local11:int;
var _local12:b2Manifold;
var _local13:int;
var _local14:b2ManifoldPoint;
var _local15:b2Vec2;
var _local16:b2Vec2;
var _local2:b2Shape = _arg1.m_shape1;
var _local3:b2Shape = _arg1.m_shape2;
var _local4:int = _arg1.m_manifoldCount;
if ((((_local4 > 0)) && (m_world.m_contactListener))){
_local7 = _local2.m_body;
_local8 = _local3.m_body;
_local9 = _arg1.GetManifolds();
_local10 = s_evalCP;
_local10.shape1 = _arg1.m_shape1;
_local10.shape2 = _arg1.m_shape1;
_local10.friction = _arg1.m_friction;
_local10.restitution = _arg1.m_restitution;
_local11 = 0;
while (_local11 < _local4) {
_local12 = _local9[_local11];
_local10.normal.SetV(_local12.normal);
_local13 = 0;
while (_local13 < _local12.pointCount) {
_local14 = _local12.points[_local13];
_local10.position = _local7.GetWorldPoint(_local14.localPoint1);
_local15 = _local7.GetLinearVelocityFromLocalPoint(_local14.localPoint1);
_local16 = _local8.GetLinearVelocityFromLocalPoint(_local14.localPoint2);
_local10.velocity.Set((_local16.x - _local15.x), (_local16.y - _local15.y));
_local10.separation = _local14.separation;
_local10.id.key = _local14.id._key;
m_world.m_contactListener.Remove(_local10);
_local13++;
};
_local11++;
};
};
if (_arg1.m_prev){
_arg1.m_prev.m_next = _arg1.m_next;
};
if (_arg1.m_next){
_arg1.m_next.m_prev = _arg1.m_prev;
};
if (_arg1 == m_world.m_contactList){
m_world.m_contactList = _arg1.m_next;
};
var _local5:b2Body = _local2.m_body;
var _local6:b2Body = _local3.m_body;
if (_arg1.m_node1.prev){
_arg1.m_node1.prev.next = _arg1.m_node1.next;
};
if (_arg1.m_node1.next){
_arg1.m_node1.next.prev = _arg1.m_node1.prev;
};
if (_arg1.m_node1 == _local5.m_contactList){
_local5.m_contactList = _arg1.m_node1.next;
};
if (_arg1.m_node2.prev){
_arg1.m_node2.prev.next = _arg1.m_node2.next;
};
if (_arg1.m_node2.next){
_arg1.m_node2.next.prev = _arg1.m_node2.prev;
};
if (_arg1.m_node2 == _local6.m_contactList){
_local6.m_contactList = _arg1.m_node2.next;
};
b2Contact.Destroy(_arg1, m_world.m_blockAllocator);
m_world.m_contactCount--;
}
override public function PairAdded(_arg1, _arg2){
var _local3:b2Shape = (_arg1 as b2Shape);
var _local4:b2Shape = (_arg2 as b2Shape);
var _local5:b2Body = _local3.m_body;
var _local6:b2Body = _local4.m_body;
if (((_local5.IsStatic()) && (_local6.IsStatic()))){
return (m_nullContact);
};
if (_local3.m_body == _local4.m_body){
return (m_nullContact);
};
if (_local6.IsConnected(_local5)){
return (m_nullContact);
};
if (((!((m_world.m_contactFilter == null))) && ((m_world.m_contactFilter.ShouldCollide(_local3, _local4) == false)))){
return (m_nullContact);
};
var _local7:b2Contact = b2Contact.Create(_local3, _local4, m_world.m_blockAllocator);
if (_local7 == null){
return (m_nullContact);
};
_local3 = _local7.m_shape1;
_local4 = _local7.m_shape2;
_local5 = _local3.m_body;
_local6 = _local4.m_body;
_local7.m_prev = null;
_local7.m_next = m_world.m_contactList;
if (m_world.m_contactList != null){
m_world.m_contactList.m_prev = _local7;
};
m_world.m_contactList = _local7;
_local7.m_node1.contact = _local7;
_local7.m_node1.other = _local6;
_local7.m_node1.prev = null;
_local7.m_node1.next = _local5.m_contactList;
if (_local5.m_contactList != null){
_local5.m_contactList.prev = _local7.m_node1;
};
_local5.m_contactList = _local7.m_node1;
_local7.m_node2.contact = _local7;
_local7.m_node2.other = _local5;
_local7.m_node2.prev = null;
_local7.m_node2.next = _local6.m_contactList;
if (_local6.m_contactList != null){
_local6.m_contactList.prev = _local7.m_node2;
};
_local6.m_contactList = _local7.m_node2;
m_world.m_contactCount++;
return (_local7);
}
public function Collide():void{
var _local2:b2Body;
var _local3:b2Body;
var _local1:b2Contact = m_world.m_contactList;
while (_local1) {
_local2 = _local1.m_shape1.m_body;
_local3 = _local1.m_shape2.m_body;
if (((_local2.IsSleeping()) && (_local3.IsSleeping()))){
} else {
_local1.Update(m_world.m_contactListener);
};
_local1 = _local1.m_next;
};
}
}
}//package Box2D.Dynamics
Section 70
//b2DebugDraw (Box2D.Dynamics.b2DebugDraw)
package Box2D.Dynamics {
import flash.display.*;
import Box2D.Common.Math.*;
import Box2D.Collision.*;
import Box2D.Collision.Shapes.*;
import Box2D.Common.*;
import Box2D.Dynamics.Contacts.*;
public class b2DebugDraw {
public var m_xformScale:Number;// = 1
public var m_fillAlpha:Number;// = 1
public var m_alpha:Number;// = 1
public var m_drawFlags:uint;
public var m_lineThickness:Number;// = 1
public var m_drawScale:Number;// = 1
public var m_sprite:Sprite;
public static var e_coreShapeBit:uint = 4;
public static var e_shapeBit:uint = 1;
public static var e_centerOfMassBit:uint = 64;
public static var e_aabbBit:uint = 8;
public static var e_obbBit:uint = 16;
public static var e_pairBit:uint = 32;
public static var e_jointBit:uint = 2;
public function b2DebugDraw(){
m_drawFlags = 0;
}
public function ClearFlags(_arg1:uint):void{
m_drawFlags = (m_drawFlags & ~(_arg1));
}
public function SetFlags(_arg1:uint):void{
m_drawFlags = _arg1;
}
public function AppendFlags(_arg1:uint):void{
m_drawFlags = (m_drawFlags | _arg1);
}
public function DrawSegment(_arg1:b2Vec2, _arg2:b2Vec2, _arg3:b2Color):void{
m_sprite.graphics.lineStyle(m_lineThickness, _arg3.color, m_alpha);
m_sprite.graphics.moveTo((_arg1.x * m_drawScale), (_arg1.y * m_drawScale));
m_sprite.graphics.lineTo((_arg2.x * m_drawScale), (_arg2.y * m_drawScale));
}
public function DrawSolidPolygon(_arg1:Array, _arg2:int, _arg3:b2Color):void{
m_sprite.graphics.lineStyle(m_lineThickness, _arg3.color, m_alpha);
m_sprite.graphics.moveTo((_arg1[0].x * m_drawScale), (_arg1[0].y * m_drawScale));
m_sprite.graphics.beginFill(_arg3.color, m_fillAlpha);
var _local4 = 1;
while (_local4 < _arg2) {
m_sprite.graphics.lineTo((_arg1[_local4].x * m_drawScale), (_arg1[_local4].y * m_drawScale));
_local4++;
};
m_sprite.graphics.lineTo((_arg1[0].x * m_drawScale), (_arg1[0].y * m_drawScale));
m_sprite.graphics.endFill();
}
public function DrawCircle(_arg1:b2Vec2, _arg2:Number, _arg3:b2Color):void{
m_sprite.graphics.lineStyle(m_lineThickness, _arg3.color, m_alpha);
m_sprite.graphics.drawCircle((_arg1.x * m_drawScale), (_arg1.y * m_drawScale), (_arg2 * m_drawScale));
}
public function DrawPolygon(_arg1:Array, _arg2:int, _arg3:b2Color):void{
m_sprite.graphics.lineStyle(m_lineThickness, _arg3.color, m_alpha);
m_sprite.graphics.moveTo((_arg1[0].x * m_drawScale), (_arg1[0].y * m_drawScale));
var _local4 = 1;
while (_local4 < _arg2) {
m_sprite.graphics.lineTo((_arg1[_local4].x * m_drawScale), (_arg1[_local4].y * m_drawScale));
_local4++;
};
m_sprite.graphics.lineTo((_arg1[0].x * m_drawScale), (_arg1[0].y * m_drawScale));
}
public function DrawSolidCircle(_arg1:b2Vec2, _arg2:Number, _arg3:b2Vec2, _arg4:b2Color):void{
m_sprite.graphics.lineStyle(m_lineThickness, _arg4.color, m_alpha);
m_sprite.graphics.moveTo(0, 0);
m_sprite.graphics.beginFill(_arg4.color, m_fillAlpha);
m_sprite.graphics.drawCircle((_arg1.x * m_drawScale), (_arg1.y * m_drawScale), (_arg2 * m_drawScale));
m_sprite.graphics.endFill();
m_sprite.graphics.moveTo((_arg1.x * m_drawScale), (_arg1.y * m_drawScale));
m_sprite.graphics.lineTo(((_arg1.x + (_arg3.x * _arg2)) * m_drawScale), ((_arg1.y + (_arg3.y * _arg2)) * m_drawScale));
}
public function GetFlags():uint{
return (m_drawFlags);
}
public function DrawXForm(_arg1:b2XForm):void{
m_sprite.graphics.lineStyle(m_lineThickness, 0xFF0000, m_alpha);
m_sprite.graphics.moveTo((_arg1.position.x * m_drawScale), (_arg1.position.y * m_drawScale));
m_sprite.graphics.lineTo(((_arg1.position.x + (m_xformScale * _arg1.R.col1.x)) * m_drawScale), ((_arg1.position.y + (m_xformScale * _arg1.R.col1.y)) * m_drawScale));
m_sprite.graphics.lineStyle(m_lineThickness, 0xFF00, m_alpha);
m_sprite.graphics.moveTo((_arg1.position.x * m_drawScale), (_arg1.position.y * m_drawScale));
m_sprite.graphics.lineTo(((_arg1.position.x + (m_xformScale * _arg1.R.col2.x)) * m_drawScale), ((_arg1.position.y + (m_xformScale * _arg1.R.col2.y)) * m_drawScale));
}
}
}//package Box2D.Dynamics
Section 71
//b2DestructionListener (Box2D.Dynamics.b2DestructionListener)
package Box2D.Dynamics {
import Box2D.Dynamics.Joints.*;
import Box2D.Collision.Shapes.*;
public class b2DestructionListener {
public function SayGoodbyeShape(_arg1:b2Shape):void{
}
public function SayGoodbyeJoint(_arg1:b2Joint):void{
}
}
}//package Box2D.Dynamics
Section 72
//b2Island (Box2D.Dynamics.b2Island)
package Box2D.Dynamics {
import Box2D.Dynamics.Joints.*;
import Box2D.Common.Math.*;
import Box2D.Collision.*;
import Box2D.Common.*;
import Box2D.Dynamics.Contacts.*;
public class b2Island {
public var m_listener:b2ContactListener;
public var m_positionIterationCount:int;
public var m_bodyCapacity:int;
public var m_bodies:Array;
public var m_joints:Array;
public var m_jointCapacity:int;
public var m_contactCount:int;
public var m_contacts:Array;
public var m_contactCapacity:int;
public var m_jointCount:int;
public var m_allocator;
public var m_bodyCount:int;
private static var s_reportCR:b2ContactResult = new b2ContactResult();
public function b2Island(_arg1:int, _arg2:int, _arg3:int, _arg4, _arg5:b2ContactListener){
var _local6:int;
super();
m_bodyCapacity = _arg1;
m_contactCapacity = _arg2;
m_jointCapacity = _arg3;
m_bodyCount = 0;
m_contactCount = 0;
m_jointCount = 0;
m_allocator = _arg4;
m_listener = _arg5;
m_bodies = new Array(_arg1);
_local6 = 0;
while (_local6 < _arg1) {
m_bodies[_local6] = null;
_local6++;
};
m_contacts = new Array(_arg2);
_local6 = 0;
while (_local6 < _arg2) {
m_contacts[_local6] = null;
_local6++;
};
m_joints = new Array(_arg3);
_local6 = 0;
while (_local6 < _arg3) {
m_joints[_local6] = null;
_local6++;
};
m_positionIterationCount = 0;
}
public function AddBody(_arg1:b2Body):void{
var _local2 = m_bodyCount++;
m_bodies[_local2] = _arg1;
}
public function AddJoint(_arg1:b2Joint):void{
var _local2 = m_jointCount++;
m_joints[_local2] = _arg1;
}
public function Report(_arg1:Array):void{
var _local2:b2Mat22;
var _local3:b2Vec2;
var _local5:b2Contact;
var _local6:b2ContactConstraint;
var _local7:b2ContactResult;
var _local8:b2Body;
var _local9:int;
var _local10:Array;
var _local11:int;
var _local12:b2Manifold;
var _local13:int;
var _local14:b2ManifoldPoint;
var _local15:b2ContactConstraintPoint;
if (m_listener == null){
return;
};
var _local4:int;
while (_local4 < m_contactCount) {
_local5 = m_contacts[_local4];
_local6 = _arg1[_local4];
_local7 = s_reportCR;
_local7.shape1 = _local5.m_shape1;
_local7.shape2 = _local5.m_shape2;
_local8 = _local7.shape1.m_body;
_local9 = _local5.m_manifoldCount;
_local10 = _local5.GetManifolds();
_local11 = 0;
while (_local11 < _local9) {
_local12 = _local10[_local11];
_local7.normal.SetV(_local12.normal);
_local13 = 0;
while (_local13 < _local12.pointCount) {
_local14 = _local12.points[_local13];
_local15 = _local6.points[_local13];
_local7.position = _local8.GetWorldPoint(_local14.localPoint1);
_local7.normalImpulse = _local15.normalImpulse;
_local7.tangentImpulse = _local15.tangentImpulse;
_local7.id.key = _local14.id.key;
m_listener.Result(_local7);
_local13++;
};
_local11++;
};
_local4++;
};
}
public function AddContact(_arg1:b2Contact):void{
var _local2 = m_contactCount++;
m_contacts[_local2] = _arg1;
}
public function Solve(_arg1:b2TimeStep, _arg2:b2Vec2, _arg3:Boolean, _arg4:Boolean):void{
var _local5:int;
var _local6:b2Body;
var _local7:b2Joint;
var _local9:int;
var _local10:Boolean;
var _local11:Boolean;
var _local12:Boolean;
var _local13:Number;
var _local14:Number;
var _local15:Number;
_local5 = 0;
while (_local5 < m_bodyCount) {
_local6 = m_bodies[_local5];
if (_local6.IsStatic()){
} else {
_local6.m_linearVelocity.x = (_local6.m_linearVelocity.x + (_arg1.dt * (_arg2.x + (_local6.m_invMass * _local6.m_force.x))));
_local6.m_linearVelocity.y = (_local6.m_linearVelocity.y + (_arg1.dt * (_arg2.y + (_local6.m_invMass * _local6.m_force.y))));
_local6.m_angularVelocity = (_local6.m_angularVelocity + ((_arg1.dt * _local6.m_invI) * _local6.m_torque));
_local6.m_force.SetZero();
_local6.m_torque = 0;
_local6.m_linearVelocity.Multiply(b2Math.b2Clamp((1 - (_arg1.dt * _local6.m_linearDamping)), 0, 1));
_local6.m_angularVelocity = (_local6.m_angularVelocity * b2Math.b2Clamp((1 - (_arg1.dt * _local6.m_angularDamping)), 0, 1));
if (_local6.m_linearVelocity.LengthSquared() > b2Settings.b2_maxLinearVelocitySquared){
_local6.m_linearVelocity.Normalize();
_local6.m_linearVelocity.x = (_local6.m_linearVelocity.x * b2Settings.b2_maxLinearVelocity);
_local6.m_linearVelocity.y = (_local6.m_linearVelocity.y * b2Settings.b2_maxLinearVelocity);
};
if ((_local6.m_angularVelocity * _local6.m_angularVelocity) > b2Settings.b2_maxAngularVelocitySquared){
if (_local6.m_angularVelocity < 0){
_local6.m_angularVelocity = -(b2Settings.b2_maxAngularVelocity);
} else {
_local6.m_angularVelocity = b2Settings.b2_maxAngularVelocity;
};
};
};
_local5++;
};
var _local8:b2ContactSolver = new b2ContactSolver(_arg1, m_contacts, m_contactCount, m_allocator);
_local8.InitVelocityConstraints(_arg1);
_local5 = 0;
while (_local5 < m_jointCount) {
_local7 = m_joints[_local5];
_local7.InitVelocityConstraints(_arg1);
_local5++;
};
_local5 = 0;
while (_local5 < _arg1.maxIterations) {
_local8.SolveVelocityConstraints();
_local9 = 0;
while (_local9 < m_jointCount) {
_local7 = m_joints[_local9];
_local7.SolveVelocityConstraints(_arg1);
_local9++;
};
_local5++;
};
_local8.FinalizeVelocityConstraints();
_local5 = 0;
while (_local5 < m_bodyCount) {
_local6 = m_bodies[_local5];
if (_local6.IsStatic()){
} else {
_local6.m_sweep.c0.SetV(_local6.m_sweep.c);
_local6.m_sweep.a0 = _local6.m_sweep.a;
_local6.m_sweep.c.x = (_local6.m_sweep.c.x + (_arg1.dt * _local6.m_linearVelocity.x));
_local6.m_sweep.c.y = (_local6.m_sweep.c.y + (_arg1.dt * _local6.m_linearVelocity.y));
_local6.m_sweep.a = (_local6.m_sweep.a + (_arg1.dt * _local6.m_angularVelocity));
_local6.SynchronizeTransform();
};
_local5++;
};
if (_arg3){
_local5 = 0;
while (_local5 < m_jointCount) {
_local7 = m_joints[_local5];
_local7.InitPositionConstraints();
_local5++;
};
m_positionIterationCount = 0;
while (m_positionIterationCount < _arg1.maxIterations) {
_local10 = _local8.SolvePositionConstraints(b2Settings.b2_contactBaumgarte);
_local11 = true;
_local5 = 0;
while (_local5 < m_jointCount) {
_local7 = m_joints[_local5];
_local12 = _local7.SolvePositionConstraints();
_local11 = ((_local11) && (_local12));
_local5++;
};
if (((_local10) && (_local11))){
break;
};
m_positionIterationCount++;
};
};
Report(_local8.m_constraints);
if (_arg4){
_local13 = Number.MAX_VALUE;
_local14 = (b2Settings.b2_linearSleepTolerance * b2Settings.b2_linearSleepTolerance);
_local15 = (b2Settings.b2_angularSleepTolerance * b2Settings.b2_angularSleepTolerance);
_local5 = 0;
while (_local5 < m_bodyCount) {
_local6 = m_bodies[_local5];
if (_local6.m_invMass == 0){
} else {
if ((_local6.m_flags & b2Body.e_allowSleepFlag) == 0){
_local6.m_sleepTime = 0;
_local13 = 0;
};
if (((((((_local6.m_flags & b2Body.e_allowSleepFlag) == 0)) || (((_local6.m_angularVelocity * _local6.m_angularVelocity) > _local15)))) || ((b2Math.b2Dot(_local6.m_linearVelocity, _local6.m_linearVelocity) > _local14)))){
_local6.m_sleepTime = 0;
_local13 = 0;
} else {
_local6.m_sleepTime = (_local6.m_sleepTime + _arg1.dt);
_local13 = b2Math.b2Min(_local13, _local6.m_sleepTime);
};
};
_local5++;
};
if (_local13 >= b2Settings.b2_timeToSleep){
_local5 = 0;
while (_local5 < m_bodyCount) {
_local6 = m_bodies[_local5];
m_bodies[_local5].m_flags = (_local6.m_flags | b2Body.e_sleepFlag);
_local6.m_linearVelocity.SetZero();
_local6.m_angularVelocity = 0;
_local5++;
};
};
};
}
public function Clear():void{
m_bodyCount = 0;
m_contactCount = 0;
m_jointCount = 0;
}
public function SolveTOI(_arg1:b2TimeStep):void{
var _local2:int;
var _local5:b2Body;
var _local6:Boolean;
var _local3:b2ContactSolver = new b2ContactSolver(_arg1, m_contacts, m_contactCount, m_allocator);
_local2 = 0;
while (_local2 < _arg1.maxIterations) {
_local3.SolveVelocityConstraints();
_local2++;
};
_local2 = 0;
while (_local2 < m_bodyCount) {
_local5 = m_bodies[_local2];
if (_local5.IsStatic()){
} else {
_local5.m_sweep.c0.SetV(_local5.m_sweep.c);
_local5.m_sweep.a0 = _local5.m_sweep.a;
_local5.m_sweep.c.x = (_local5.m_sweep.c.x + (_arg1.dt * _local5.m_linearVelocity.x));
_local5.m_sweep.c.y = (_local5.m_sweep.c.y + (_arg1.dt * _local5.m_linearVelocity.y));
_local5.m_sweep.a = (_local5.m_sweep.a + (_arg1.dt * _local5.m_angularVelocity));
_local5.SynchronizeTransform();
};
_local2++;
};
var _local4:Number = 0.75;
_local2 = 0;
while (_local2 < _arg1.maxIterations) {
_local6 = _local3.SolvePositionConstraints(_local4);
if (_local6){
break;
};
_local2++;
};
Report(_local3.m_constraints);
}
}
}//package Box2D.Dynamics
Section 73
//b2TimeStep (Box2D.Dynamics.b2TimeStep)
package Box2D.Dynamics {
public class b2TimeStep {
public var warmStarting:Boolean;
public var positionCorrection:Boolean;
public var dt:Number;
public var maxIterations:int;
public var dtRatio:Number;
public var inv_dt:Number;
}
}//package Box2D.Dynamics
Section 74
//b2World (Box2D.Dynamics.b2World)
package Box2D.Dynamics {
import Box2D.Dynamics.Joints.*;
import Box2D.Common.Math.*;
import Box2D.Collision.*;
import Box2D.Collision.Shapes.*;
import Box2D.Common.*;
import Box2D.Dynamics.Contacts.*;
public class b2World {
public var m_inv_dt0:Number;
public var m_boundaryListener:b2BoundaryListener;
public var m_contactList:b2Contact;
public var m_blockAllocator;
public var m_contactListener:b2ContactListener;
public var m_allowSleep:Boolean;
public var m_broadPhase:b2BroadPhase;
public var m_destructionListener:b2DestructionListener;
public var m_jointCount:int;
public var m_bodyCount:int;
public var m_lock:Boolean;
public var m_positionIterationCount:int;
public var m_groundBody:b2Body;
public var m_contactCount:int;
public var m_debugDraw:b2DebugDraw;
public var m_contactFilter:b2ContactFilter;
public var m_bodyList:b2Body;
public var m_stackAllocator;
public var m_jointList:b2Joint;
public var m_gravity:b2Vec2;
public var m_contactManager:b2ContactManager;
private static var s_jointColor:b2Color = new b2Color(0.5, 0.8, 0.8);
public static var m_continuousPhysics:Boolean;
public static var m_warmStarting:Boolean;
private static var s_coreColor:b2Color = new b2Color(0.9, 0.6, 0.6);
public static var m_positionCorrection:Boolean;
private static var s_xf:b2XForm = new b2XForm();
public function b2World(_arg1:b2AABB, _arg2:b2Vec2, _arg3:Boolean){
m_contactManager = new b2ContactManager();
super();
m_destructionListener = null;
m_boundaryListener = null;
m_contactFilter = b2ContactFilter.b2_defaultFilter;
m_contactListener = null;
m_debugDraw = null;
m_bodyList = null;
m_contactList = null;
m_jointList = null;
m_bodyCount = 0;
m_contactCount = 0;
m_jointCount = 0;
m_positionCorrection = true;
m_warmStarting = true;
m_continuousPhysics = true;
m_allowSleep = _arg3;
m_gravity = _arg2;
m_lock = false;
m_inv_dt0 = 0;
m_contactManager.m_world = this;
m_broadPhase = new b2BroadPhase(_arg1, m_contactManager);
var _local4:b2BodyDef = new b2BodyDef();
m_groundBody = CreateBody(_local4);
}
public function DrawJoint(_arg1:b2Joint):void{
var _local11:b2PulleyJoint;
var _local12:b2Vec2;
var _local13:b2Vec2;
var _local2:b2Body = _arg1.m_body1;
var _local3:b2Body = _arg1.m_body2;
var _local4:b2XForm = _local2.m_xf;
var _local5:b2XForm = _local3.m_xf;
var _local6:b2Vec2 = _local4.position;
var _local7:b2Vec2 = _local5.position;
var _local8:b2Vec2 = _arg1.GetAnchor1();
var _local9:b2Vec2 = _arg1.GetAnchor2();
var _local10:b2Color = s_jointColor;
switch (_arg1.m_type){
case b2Joint.e_distanceJoint:
m_debugDraw.DrawSegment(_local8, _local9, _local10);
break;
case b2Joint.e_pulleyJoint:
_local11 = (_arg1 as b2PulleyJoint);
_local12 = _local11.GetGroundAnchor1();
_local13 = _local11.GetGroundAnchor2();
m_debugDraw.DrawSegment(_local12, _local8, _local10);
m_debugDraw.DrawSegment(_local13, _local9, _local10);
m_debugDraw.DrawSegment(_local12, _local13, _local10);
break;
case b2Joint.e_mouseJoint:
m_debugDraw.DrawSegment(_local8, _local9, _local10);
break;
default:
if (_local2 != m_groundBody){
m_debugDraw.DrawSegment(_local6, _local8, _local10);
};
m_debugDraw.DrawSegment(_local8, _local9, _local10);
if (_local3 != m_groundBody){
m_debugDraw.DrawSegment(_local7, _local9, _local10);
};
};
}
public function Refilter(_arg1:b2Shape):void{
_arg1.RefilterProxy(m_broadPhase, _arg1.m_body.m_xf);
}
public function SetDebugDraw(_arg1:b2DebugDraw):void{
m_debugDraw = _arg1;
}
public function SetContinuousPhysics(_arg1:Boolean):void{
m_continuousPhysics = _arg1;
}
public function GetProxyCount():int{
return (m_broadPhase.m_proxyCount);
}
public function DrawDebugData():void{
var _local2:int;
var _local3:b2Body;
var _local4:b2Shape;
var _local5:b2Joint;
var _local6:b2BroadPhase;
var _local11:b2XForm;
var _local15:Boolean;
var _local16:uint;
var _local17:b2Pair;
var _local18:b2Proxy;
var _local19:b2Proxy;
var _local20:b2Vec2;
var _local21:b2Vec2;
var _local22:b2Proxy;
var _local23:b2PolygonShape;
var _local24:b2OBB;
var _local25:b2Vec2;
var _local26:b2Mat22;
var _local27:b2Vec2;
var _local28:Number;
if (m_debugDraw == null){
return;
};
m_debugDraw.m_sprite.graphics.clear();
var _local1:uint = m_debugDraw.GetFlags();
var _local7:b2Vec2 = new b2Vec2();
var _local8:b2Vec2 = new b2Vec2();
var _local9:b2Vec2 = new b2Vec2();
var _local10:b2Color = new b2Color(0, 0, 0);
var _local12:b2AABB = new b2AABB();
var _local13:b2AABB = new b2AABB();
var _local14:Array = [new b2Vec2(), new b2Vec2(), new b2Vec2(), new b2Vec2()];
if ((_local1 & b2DebugDraw.e_shapeBit)){
_local15 = ((_local1 & b2DebugDraw.e_coreShapeBit) == b2DebugDraw.e_coreShapeBit);
_local3 = m_bodyList;
while (_local3) {
_local11 = _local3.m_xf;
_local4 = _local3.GetShapeList();
while (_local4) {
if (_local3.IsStatic()){
DrawShape(_local4, _local11, new b2Color(0.5, 0.9, 0.5), _local15);
} else {
if (_local3.IsSleeping()){
DrawShape(_local4, _local11, new b2Color(0.5, 0.5, 0.9), _local15);
} else {
DrawShape(_local4, _local11, new b2Color(0.9, 0.9, 0.9), _local15);
};
};
_local4 = _local4.m_next;
};
_local3 = _local3.m_next;
};
};
if ((_local1 & b2DebugDraw.e_jointBit)){
_local5 = m_jointList;
while (_local5) {
DrawJoint(_local5);
_local5 = _local5.m_next;
};
};
if ((_local1 & b2DebugDraw.e_pairBit)){
_local6 = m_broadPhase;
_local7.Set((1 / _local6.m_quantizationFactor.x), (1 / _local6.m_quantizationFactor.y));
_local10.Set(0.9, 0.9, 0.3);
_local2 = 0;
while (_local2 < b2Pair.b2_tableCapacity) {
_local16 = _local6.m_pairManager.m_hashTable[_local2];
while (_local16 != b2Pair.b2_nullPair) {
_local17 = _local6.m_pairManager.m_pairs[_local16];
_local18 = _local6.m_proxyPool[_local17.proxyId1];
_local19 = _local6.m_proxyPool[_local17.proxyId2];
_local12.lowerBound.x = (_local6.m_worldAABB.lowerBound.x + (_local7.x * _local6.m_bounds[0][_local18.lowerBounds[0]].value));
_local12.lowerBound.y = (_local6.m_worldAABB.lowerBound.y + (_local7.y * _local6.m_bounds[1][_local18.lowerBounds[1]].value));
_local12.upperBound.x = (_local6.m_worldAABB.lowerBound.x + (_local7.x * _local6.m_bounds[0][_local18.upperBounds[0]].value));
_local12.upperBound.y = (_local6.m_worldAABB.lowerBound.y + (_local7.y * _local6.m_bounds[1][_local18.upperBounds[1]].value));
_local13.lowerBound.x = (_local6.m_worldAABB.lowerBound.x + (_local7.x * _local6.m_bounds[0][_local19.lowerBounds[0]].value));
_local13.lowerBound.y = (_local6.m_worldAABB.lowerBound.y + (_local7.y * _local6.m_bounds[1][_local19.lowerBounds[1]].value));
_local13.upperBound.x = (_local6.m_worldAABB.lowerBound.x + (_local7.x * _local6.m_bounds[0][_local19.upperBounds[0]].value));
_local13.upperBound.y = (_local6.m_worldAABB.lowerBound.y + (_local7.y * _local6.m_bounds[1][_local19.upperBounds[1]].value));
_local8.x = (0.5 * (_local12.lowerBound.x + _local12.upperBound.x));
_local8.y = (0.5 * (_local12.lowerBound.y + _local12.upperBound.y));
_local9.x = (0.5 * (_local13.lowerBound.x + _local13.upperBound.x));
_local9.y = (0.5 * (_local13.lowerBound.y + _local13.upperBound.y));
m_debugDraw.DrawSegment(_local8, _local9, _local10);
_local16 = _local17.next;
};
_local2++;
};
};
if ((_local1 & b2DebugDraw.e_aabbBit)){
_local6 = m_broadPhase;
_local20 = _local6.m_worldAABB.lowerBound;
_local21 = _local6.m_worldAABB.upperBound;
_local7.Set((1 / _local6.m_quantizationFactor.x), (1 / _local6.m_quantizationFactor.y));
_local10.Set(0.9, 0.3, 0.9);
_local2 = 0;
while (_local2 < b2Settings.b2_maxProxies) {
_local22 = _local6.m_proxyPool[_local2];
if (_local22.IsValid() == false){
} else {
_local12.lowerBound.x = (_local20.x + (_local7.x * _local6.m_bounds[0][_local22.lowerBounds[0]].value));
_local12.lowerBound.y = (_local20.y + (_local7.y * _local6.m_bounds[1][_local22.lowerBounds[1]].value));
_local12.upperBound.x = (_local20.x + (_local7.x * _local6.m_bounds[0][_local22.upperBounds[0]].value));
_local12.upperBound.y = (_local20.y + (_local7.y * _local6.m_bounds[1][_local22.upperBounds[1]].value));
_local14[0].Set(_local12.lowerBound.x, _local12.lowerBound.y);
_local14[1].Set(_local12.upperBound.x, _local12.lowerBound.y);
_local14[2].Set(_local12.upperBound.x, _local12.upperBound.y);
_local14[3].Set(_local12.lowerBound.x, _local12.upperBound.y);
m_debugDraw.DrawPolygon(_local14, 4, _local10);
};
_local2++;
};
_local14[0].Set(_local20.x, _local20.y);
_local14[1].Set(_local21.x, _local20.y);
_local14[2].Set(_local21.x, _local21.y);
_local14[3].Set(_local20.x, _local21.y);
m_debugDraw.DrawPolygon(_local14, 4, new b2Color(0.3, 0.9, 0.9));
};
if ((_local1 & b2DebugDraw.e_obbBit)){
_local10.Set(0.5, 0.3, 0.5);
_local3 = m_bodyList;
while (_local3) {
_local11 = _local3.m_xf;
_local4 = _local3.GetShapeList();
while (_local4) {
if (_local4.m_type != b2Shape.e_polygonShape){
} else {
_local23 = (_local4 as b2PolygonShape);
_local24 = _local23.GetOBB();
_local25 = _local24.extents;
_local14[0].Set(-(_local25.x), -(_local25.y));
_local14[1].Set(_local25.x, -(_local25.y));
_local14[2].Set(_local25.x, _local25.y);
_local14[3].Set(-(_local25.x), _local25.y);
_local2 = 0;
while (_local2 < 4) {
_local26 = _local24.R;
_local27 = _local14[_local2];
_local28 = (_local24.center.x + ((_local26.col1.x * _local27.x) + (_local26.col2.x * _local27.y)));
_local14[_local2].y = (_local24.center.y + ((_local26.col1.y * _local27.x) + (_local26.col2.y * _local27.y)));
_local14[_local2].x = _local28;
_local26 = _local11.R;
_local28 = (_local11.position.x + ((_local26.col1.x * _local27.x) + (_local26.col2.x * _local27.y)));
_local14[_local2].y = (_local11.position.y + ((_local26.col1.y * _local27.x) + (_local26.col2.y * _local27.y)));
_local14[_local2].x = _local28;
_local2++;
};
m_debugDraw.DrawPolygon(_local14, 4, _local10);
};
_local4 = _local4.m_next;
};
_local3 = _local3.m_next;
};
};
if ((_local1 & b2DebugDraw.e_centerOfMassBit)){
_local3 = m_bodyList;
while (_local3) {
_local11 = s_xf;
_local11.R = _local3.m_xf.R;
_local11.position = _local3.GetWorldCenter();
m_debugDraw.DrawXForm(_local11);
_local3 = _local3.m_next;
};
};
}
public function DestroyBody(_arg1:b2Body):void{
var _local4:b2JointEdge;
var _local5:b2Shape;
if (m_lock == true){
return;
};
var _local2:b2JointEdge = _arg1.m_jointList;
while (_local2) {
_local4 = _local2;
_local2 = _local2.next;
if (m_destructionListener){
m_destructionListener.SayGoodbyeJoint(_local4.joint);
};
DestroyJoint(_local4.joint);
};
var _local3:b2Shape = _arg1.m_shapeList;
while (_local3) {
_local5 = _local3;
_local3 = _local3.m_next;
if (m_destructionListener){
m_destructionListener.SayGoodbyeShape(_local5);
};
_local5.DestroyProxy(m_broadPhase);
b2Shape.Destroy(_local5, m_blockAllocator);
};
if (_arg1.m_prev){
_arg1.m_prev.m_next = _arg1.m_next;
};
if (_arg1.m_next){
_arg1.m_next.m_prev = _arg1.m_prev;
};
if (_arg1 == m_bodyList){
m_bodyList = _arg1.m_next;
};
m_bodyCount--;
}
public function SetContactFilter(_arg1:b2ContactFilter):void{
m_contactFilter = _arg1;
}
public function GetGroundBody():b2Body{
return (m_groundBody);
}
public function DrawShape(_arg1:b2Shape, _arg2:b2XForm, _arg3:b2Color, _arg4:Boolean):void{
var _local6:b2CircleShape;
var _local7:b2Vec2;
var _local8:Number;
var _local9:b2Vec2;
var _local10:int;
var _local11:b2PolygonShape;
var _local12:int;
var _local13:Array;
var _local14:Array;
var _local15:Array;
var _local5:b2Color = s_coreColor;
switch (_arg1.m_type){
case b2Shape.e_circleShape:
_local6 = (_arg1 as b2CircleShape);
_local7 = b2Math.b2MulX(_arg2, _local6.m_localPosition);
_local8 = _local6.m_radius;
_local9 = _arg2.R.col1;
m_debugDraw.DrawSolidCircle(_local7, _local8, _local9, _arg3);
if (_arg4){
m_debugDraw.DrawCircle(_local7, (_local8 - b2Settings.b2_toiSlop), _local5);
};
break;
case b2Shape.e_polygonShape:
_local11 = (_arg1 as b2PolygonShape);
_local12 = _local11.GetVertexCount();
_local13 = _local11.GetVertices();
_local14 = new Array(b2Settings.b2_maxPolygonVertices);
_local10 = 0;
while (_local10 < _local12) {
_local14[_local10] = b2Math.b2MulX(_arg2, _local13[_local10]);
_local10++;
};
m_debugDraw.DrawSolidPolygon(_local14, _local12, _arg3);
if (_arg4){
_local15 = _local11.GetCoreVertices();
_local10 = 0;
while (_local10 < _local12) {
_local14[_local10] = b2Math.b2MulX(_arg2, _local15[_local10]);
_local10++;
};
m_debugDraw.DrawPolygon(_local14, _local12, _local5);
};
break;
};
}
public function GetContactCount():int{
return (m_contactCount);
}
public function Solve(_arg1:b2TimeStep):void{
var _local2:b2Body;
var _local9:int;
var _local10:int;
var _local11:b2Body;
var _local12:b2ContactEdge;
var _local13:b2JointEdge;
var _local14:Boolean;
m_positionIterationCount = 0;
var _local3:b2Island = new b2Island(m_bodyCount, m_contactCount, m_jointCount, m_stackAllocator, m_contactListener);
_local2 = m_bodyList;
while (_local2) {
_local2.m_flags = (_local2.m_flags & ~(b2Body.e_islandFlag));
_local2 = _local2.m_next;
};
var _local4:b2Contact = m_contactList;
while (_local4) {
_local4.m_flags = (_local4.m_flags & ~(b2Contact.e_islandFlag));
_local4 = _local4.m_next;
};
var _local5:b2Joint = m_jointList;
while (_local5) {
_local5.m_islandFlag = false;
_local5 = _local5.m_next;
};
var _local6:int = m_bodyCount;
var _local7:Array = new Array(_local6);
var _local8:b2Body = m_bodyList;
while (_local8) {
if ((_local8.m_flags & ((b2Body.e_islandFlag | b2Body.e_sleepFlag) | b2Body.e_frozenFlag))){
} else {
if (_local8.IsStatic()){
} else {
_local3.Clear();
_local9 = 0;
var _temp1 = _local9;
_local9 = (_local9 + 1);
var _local15 = _temp1;
_local7[_local15] = _local8;
_local8.m_flags = (_local8.m_flags | b2Body.e_islandFlag);
while (_local9 > 0) {
--_local9;
_local2 = _local7[_local9];
_local3.AddBody(_local2);
_local2.m_flags = (_local2.m_flags & ~(b2Body.e_sleepFlag));
if (_local2.IsStatic()){
} else {
_local12 = _local2.m_contactList;
while (_local12) {
if ((_local12.contact.m_flags & (b2Contact.e_islandFlag | b2Contact.e_nonSolidFlag))){
} else {
if (_local12.contact.m_manifoldCount == 0){
} else {
_local3.AddContact(_local12.contact);
_local12.contact.m_flags = (_local12.contact.m_flags | b2Contact.e_islandFlag);
_local11 = _local12.other;
if ((_local11.m_flags & b2Body.e_islandFlag)){
} else {
var _temp2 = _local9;
_local9 = (_local9 + 1);
var _local16 = _temp2;
_local7[_local16] = _local11;
_local11.m_flags = (_local11.m_flags | b2Body.e_islandFlag);
};
};
};
_local12 = _local12.next;
};
_local13 = _local2.m_jointList;
while (_local13) {
if (_local13.joint.m_islandFlag == true){
} else {
_local3.AddJoint(_local13.joint);
_local13.joint.m_islandFlag = true;
_local11 = _local13.other;
if ((_local11.m_flags & b2Body.e_islandFlag)){
} else {
var _temp3 = _local9;
_local9 = (_local9 + 1);
_local16 = _temp3;
_local7[_local16] = _local11;
_local11.m_flags = (_local11.m_flags | b2Body.e_islandFlag);
};
};
_local13 = _local13.next;
};
};
};
_local3.Solve(_arg1, m_gravity, m_positionCorrection, m_allowSleep);
if (_local3.m_positionIterationCount > m_positionIterationCount){
m_positionIterationCount = _local3.m_positionIterationCount;
};
_local10 = 0;
while (_local10 < _local3.m_bodyCount) {
_local2 = _local3.m_bodies[_local10];
if (_local2.IsStatic()){
_local2.m_flags = (_local2.m_flags & ~(b2Body.e_islandFlag));
};
_local10++;
};
};
};
_local8 = _local8.m_next;
};
_local2 = m_bodyList;
while (_local2) {
if ((_local2.m_flags & (b2Body.e_sleepFlag | b2Body.e_frozenFlag))){
} else {
if (_local2.IsStatic()){
} else {
_local14 = _local2.SynchronizeShapes();
if ((((_local14 == false)) && (!((m_boundaryListener == null))))){
m_boundaryListener.Violation(_local2);
};
};
};
_local2 = _local2.m_next;
};
m_broadPhase.Commit();
}
public function Query(_arg1:b2AABB, _arg2:Array, _arg3:int):int{
var _local4:Array = new Array(_arg3);
var _local5:int = m_broadPhase.QueryAABB(_arg1, _local4, _arg3);
var _local6:int;
while (_local6 < _local5) {
_arg2[_local6] = _local4[_local6];
_local6++;
};
return (_local5);
}
public function SetGravity(_arg1:b2Vec2):void{
m_gravity = _arg1;
}
public function SolveTOI(_arg1:b2TimeStep):void{
var _local2:b2Body;
var _local3:b2Shape;
var _local4:b2Shape;
var _local5:b2Body;
var _local6:b2Body;
var _local7:b2ContactEdge;
var _local11:b2Contact;
var _local12:b2Contact;
var _local13:Number;
var _local14:b2Body;
var _local15:int;
var _local16:b2TimeStep;
var _local17:int;
var _local18:Number;
var _local19:Number;
var _local20:b2Body;
var _local21:Boolean;
var _local8:b2Island = new b2Island(m_bodyCount, b2Settings.b2_maxTOIContactsPerIsland, 0, m_stackAllocator, m_contactListener);
var _local9:int = m_bodyCount;
var _local10:Array = new Array(_local9);
_local2 = m_bodyList;
while (_local2) {
_local2.m_flags = (_local2.m_flags & ~(b2Body.e_islandFlag));
_local2.m_sweep.t0 = 0;
_local2 = _local2.m_next;
};
_local11 = m_contactList;
while (_local11) {
_local11.m_flags = (_local11.m_flags & ~((b2Contact.e_toiFlag | b2Contact.e_islandFlag)));
_local11 = _local11.m_next;
};
while (true) {
_local12 = null;
_local13 = 1;
_local11 = m_contactList;
for (;_local11;(_local11 = _local11.m_next)) {
if ((_local11.m_flags & (b2Contact.e_slowFlag | b2Contact.e_nonSolidFlag))){
} else {
_local18 = 1;
if ((_local11.m_flags & b2Contact.e_toiFlag)){
_local18 = _local11.m_toi;
} else {
_local3 = _local11.m_shape1;
_local4 = _local11.m_shape2;
_local5 = _local3.m_body;
_local6 = _local4.m_body;
if (((((_local5.IsStatic()) || (_local5.IsSleeping()))) && (((_local6.IsStatic()) || (_local6.IsSleeping()))))){
continue;
};
_local19 = _local5.m_sweep.t0;
if (_local5.m_sweep.t0 < _local6.m_sweep.t0){
_local19 = _local6.m_sweep.t0;
_local5.m_sweep.Advance(_local19);
} else {
if (_local6.m_sweep.t0 < _local5.m_sweep.t0){
_local19 = _local5.m_sweep.t0;
_local6.m_sweep.Advance(_local19);
};
};
_local18 = b2TimeOfImpact.TimeOfImpact(_local11.m_shape1, _local5.m_sweep, _local11.m_shape2, _local6.m_sweep);
if ((((_local18 > 0)) && ((_local18 < 1)))){
_local18 = (((1 - _local18) * _local19) + _local18);
if (_local18 > 1){
_local18 = 1;
};
};
_local11.m_toi = _local18;
_local11.m_flags = (_local11.m_flags | b2Contact.e_toiFlag);
};
if ((((Number.MIN_VALUE < _local18)) && ((_local18 < _local13)))){
_local12 = _local11;
_local13 = _local18;
};
};
};
if ((((_local12 == null)) || (((1 - (100 * Number.MIN_VALUE)) < _local13)))){
break;
};
_local3 = _local12.m_shape1;
_local4 = _local12.m_shape2;
_local5 = _local3.m_body;
_local6 = _local4.m_body;
_local5.Advance(_local13);
_local6.Advance(_local13);
_local12.Update(m_contactListener);
_local12.m_flags = (_local12.m_flags & ~(b2Contact.e_toiFlag));
if (_local12.m_manifoldCount == 0){
} else {
_local14 = _local5;
if (_local14.IsStatic()){
_local14 = _local6;
};
_local8.Clear();
_local15 = 0;
var _temp1 = _local15;
_local15 = (_local15 + 1);
var _local22 = _temp1;
_local10[_local22] = _local14;
_local14.m_flags = (_local14.m_flags | b2Body.e_islandFlag);
while (_local15 > 0) {
--_local15;
_local2 = _local10[_local15];
_local8.AddBody(_local2);
_local2.m_flags = (_local2.m_flags & ~(b2Body.e_sleepFlag));
if (_local2.IsStatic()){
} else {
_local7 = _local2.m_contactList;
while (_local7) {
if (_local8.m_contactCount == _local8.m_contactCapacity){
} else {
if ((_local7.contact.m_flags & ((b2Contact.e_islandFlag | b2Contact.e_slowFlag) | b2Contact.e_nonSolidFlag))){
} else {
if (_local7.contact.m_manifoldCount == 0){
} else {
_local8.AddContact(_local7.contact);
_local7.contact.m_flags = (_local7.contact.m_flags | b2Contact.e_islandFlag);
_local20 = _local7.other;
if ((_local20.m_flags & b2Body.e_islandFlag)){
} else {
if (_local20.IsStatic() == false){
_local20.Advance(_local13);
_local20.WakeUp();
};
var _temp2 = _local15;
_local15 = (_local15 + 1);
var _local23 = _temp2;
_local10[_local23] = _local20;
_local20.m_flags = (_local20.m_flags | b2Body.e_islandFlag);
};
};
};
};
_local7 = _local7.next;
};
};
};
_local16 = new b2TimeStep();
_local16.dt = ((1 - _local13) * _arg1.dt);
_local16.inv_dt = (1 / _local16.dt);
_local16.maxIterations = _arg1.maxIterations;
_local8.SolveTOI(_local16);
_local17 = 0;
while (_local17 < _local8.m_bodyCount) {
_local2 = _local8.m_bodies[_local17];
_local2.m_flags = (_local2.m_flags & ~(b2Body.e_islandFlag));
if ((_local2.m_flags & (b2Body.e_sleepFlag | b2Body.e_frozenFlag))){
} else {
if (_local2.IsStatic()){
} else {
_local21 = _local2.SynchronizeShapes();
if ((((_local21 == false)) && (!((m_boundaryListener == null))))){
m_boundaryListener.Violation(_local2);
};
_local7 = _local2.m_contactList;
while (_local7) {
_local7.contact.m_flags = (_local7.contact.m_flags & ~(b2Contact.e_toiFlag));
_local7 = _local7.next;
};
};
};
_local17++;
};
_local17 = 0;
while (_local17 < _local8.m_contactCount) {
_local11 = _local8.m_contacts[_local17];
_local8.m_contacts[_local17].m_flags = (_local11.m_flags & ~((b2Contact.e_toiFlag | b2Contact.e_islandFlag)));
_local17++;
};
m_broadPhase.Commit();
};
};
}
public function GetJointList():b2Joint{
return (m_jointList);
}
public function GetBodyList():b2Body{
return (m_bodyList);
}
public function GetPairCount():int{
return (m_broadPhase.m_pairManager.m_pairCount);
}
public function Validate():void{
m_broadPhase.Validate();
}
public function SetWarmStarting(_arg1:Boolean):void{
m_warmStarting = _arg1;
}
public function SetPositionCorrection(_arg1:Boolean):void{
m_positionCorrection = _arg1;
}
public function CreateJoint(_arg1:b2JointDef):b2Joint{
var _local3:b2Body;
var _local4:b2Shape;
var _local2:b2Joint = b2Joint.Create(_arg1, m_blockAllocator);
_local2.m_prev = null;
_local2.m_next = m_jointList;
if (m_jointList){
m_jointList.m_prev = _local2;
};
m_jointList = _local2;
m_jointCount++;
_local2.m_node1.joint = _local2;
_local2.m_node1.other = _local2.m_body2;
_local2.m_node1.prev = null;
_local2.m_node1.next = _local2.m_body1.m_jointList;
if (_local2.m_body1.m_jointList){
_local2.m_body1.m_jointList.prev = _local2.m_node1;
};
_local2.m_body1.m_jointList = _local2.m_node1;
_local2.m_node2.joint = _local2;
_local2.m_node2.other = _local2.m_body1;
_local2.m_node2.prev = null;
_local2.m_node2.next = _local2.m_body2.m_jointList;
if (_local2.m_body2.m_jointList){
_local2.m_body2.m_jointList.prev = _local2.m_node2;
};
_local2.m_body2.m_jointList = _local2.m_node2;
if (_arg1.collideConnected == false){
_local3 = ((_arg1.body1.m_shapeCount < _arg1.body2.m_shapeCount)) ? _arg1.body1 : _arg1.body2;
_local4 = _local3.m_shapeList;
while (_local4) {
_local4.RefilterProxy(m_broadPhase, _local3.m_xf);
_local4 = _local4.m_next;
};
};
return (_local2);
}
public function DestroyJoint(_arg1:b2Joint):void{
var _local5:b2Body;
var _local6:b2Shape;
var _local2:Boolean = _arg1.m_collideConnected;
if (_arg1.m_prev){
_arg1.m_prev.m_next = _arg1.m_next;
};
if (_arg1.m_next){
_arg1.m_next.m_prev = _arg1.m_prev;
};
if (_arg1 == m_jointList){
m_jointList = _arg1.m_next;
};
var _local3:b2Body = _arg1.m_body1;
var _local4:b2Body = _arg1.m_body2;
_local3.WakeUp();
_local4.WakeUp();
if (_arg1.m_node1.prev){
_arg1.m_node1.prev.next = _arg1.m_node1.next;
};
if (_arg1.m_node1.next){
_arg1.m_node1.next.prev = _arg1.m_node1.prev;
};
if (_arg1.m_node1 == _local3.m_jointList){
_local3.m_jointList = _arg1.m_node1.next;
};
_arg1.m_node1.prev = null;
_arg1.m_node1.next = null;
if (_arg1.m_node2.prev){
_arg1.m_node2.prev.next = _arg1.m_node2.next;
};
if (_arg1.m_node2.next){
_arg1.m_node2.next.prev = _arg1.m_node2.prev;
};
if (_arg1.m_node2 == _local4.m_jointList){
_local4.m_jointList = _arg1.m_node2.next;
};
_arg1.m_node2.prev = null;
_arg1.m_node2.next = null;
b2Joint.Destroy(_arg1, m_blockAllocator);
m_jointCount--;
if (_local2 == false){
_local5 = ((_local3.m_shapeCount < _local4.m_shapeCount)) ? _local3 : _local4;
_local6 = _local5.m_shapeList;
while (_local6) {
_local6.RefilterProxy(m_broadPhase, _local5.m_xf);
_local6 = _local6.m_next;
};
};
}
public function SetContactListener(_arg1:b2ContactListener):void{
m_contactListener = _arg1;
}
public function CreateBody(_arg1:b2BodyDef):b2Body{
if (m_lock == true){
return (null);
};
var _local2:b2Body = new b2Body(_arg1, this);
_local2.m_prev = null;
_local2.m_next = m_bodyList;
if (m_bodyList){
m_bodyList.m_prev = _local2;
};
m_bodyList = _local2;
m_bodyCount++;
return (_local2);
}
public function SetBoundaryListener(_arg1:b2BoundaryListener):void{
m_boundaryListener = _arg1;
}
public function SetDestructionListener(_arg1:b2DestructionListener):void{
m_destructionListener = _arg1;
}
public function Step(_arg1:Number, _arg2:int):void{
m_lock = true;
var _local3:b2TimeStep = new b2TimeStep();
_local3.dt = _arg1;
_local3.maxIterations = _arg2;
if (_arg1 > 0){
_local3.inv_dt = (1 / _arg1);
} else {
_local3.inv_dt = 0;
};
_local3.dtRatio = (m_inv_dt0 * _arg1);
_local3.positionCorrection = m_positionCorrection;
_local3.warmStarting = m_warmStarting;
m_contactManager.Collide();
if (_local3.dt > 0){
Solve(_local3);
};
if (((m_continuousPhysics) && ((_local3.dt > 0)))){
SolveTOI(_local3);
};
DrawDebugData();
m_inv_dt0 = _local3.inv_dt;
m_lock = false;
}
public function GetBodyCount():int{
return (m_bodyCount);
}
public function GetJointCount():int{
return (m_jointCount);
}
}
}//package Box2D.Dynamics
Section 75
//Particle (Classes.Particles.Particle)
package Classes.Particles {
import flash.display.*;
import flash.geom.*;
public final class Particle {
private var colourTransform:ColorTransform;
private var bright:int;
private var rotSin:Number;
private var friction:Number;
private var dyingCnt:int;
private var cos:Function;
private var mabsX:Number;
private var speedY:Number;
private var sprite_dustParticle:Sprite;
private var velocityX:Number;
private var velocityY:Number;
private var mainFunc:Function;
private var scrollRectangle:Rectangle;
private var mabsY:Number;
private var rotCos:Number;
private var glassParticleMC:Class;
private var main:Main;
private var wreckage2MC:Class;
private var sprite:Sprite;
private var spriteRect:Rectangle;
private var colour:uint;
private var particleSparkMC:Class;
private var gravity:Number;
private var crashDustMC:Class;
private var rotSpeed:Number;
private var sprite_percentage:Sprite;
public var spritePos:Point;
private var sin:Function;
private var spritePlayField:Sprite;
private var scorePercentageMC:Class;
private var sprite_spark:Sprite;
private var rect:Rectangle;
private var wreckage2:MovieClip;
private var wreckage3:MovieClip;
private var gh:int;
private var currentWreckageSprite:MovieClip;
private var sprite_dust:Sprite;
private var dustParticleMC:Class;
private var speedX:Number;
private var wreckage1:MovieClip;
private var gw:int;
private var pi:Number;// = 3.14159265358979
private var wreckage1MC:Class;
private var wreckage3MC:Class;
public function Particle():void{
crashDustMC = Particle_crashDustMC;
glassParticleMC = Particle_glassParticleMC;
particleSparkMC = Particle_particleSparkMC;
wreckage1MC = Particle_wreckage1MC;
wreckage2MC = Particle_wreckage2MC;
wreckage3MC = Particle_wreckage3MC;
dustParticleMC = Particle_dustParticleMC;
scorePercentageMC = Particle_scorePercentageMC;
sin = Math.sin;
cos = Math.cos;
super();
main = Main.getInstance();
spritePlayField = main.getInitObj().getPlayField().sprites;
spritePos = new Point();
spriteRect = new Rectangle(0, 0, 9, 9);
sprite = new glassParticleMC();
sprite_dust = new crashDustMC();
sprite_dust["anim"].gotoAndStop(1);
sprite_dust.alpha = 0.9;
sprite_dust.name = ("dust" + (Math.random() * 9999999));
sprite_spark = new particleSparkMC();
sprite_spark.name = ("spark" + (Math.random() * 9999999));
sprite_percentage = new scorePercentageMC();
sprite_percentage.cacheAsBitmap = true;
sprite_percentage.name = ("percentage" + (Math.random() * 9999999));
wreckage1 = new wreckage1MC();
wreckage1.gotoAndStop(1);
wreckage1.name = ("wreckage1" + (Math.random() * 9999999));
wreckage2 = new wreckage2MC();
wreckage2.gotoAndStop(1);
wreckage2.name = ("wreckage2" + (Math.random() * 9999999));
wreckage3 = new wreckage3MC();
wreckage3.gotoAndStop(1);
wreckage3.name = ("wreckage3" + (Math.random() * 9999999));
sprite_dustParticle = new dustParticleMC();
sprite_dustParticle["anim"].gotoAndStop(1);
sprite_dustParticle.name = ("dustP" + (Math.random() * 9999999));
gw = 640;
gh = 480;
}
private function mainloop_wreckage():Boolean{
spriteRect.x = (spriteRect.x + velocityX);
spriteRect.y = (spriteRect.y + velocityY);
spriteRect.y = (spriteRect.y + gravity);
gravity = (gravity + 0.2);
if (spriteRect.y > 425){
if (currentWreckageSprite.parent != null){
spritePlayField.removeChild(currentWreckageSprite);
};
mainFunc = mainloop_waitingToDie;
return (true);
};
speedX = (speedX * friction);
velocityX = (rotSin * speedX);
currentWreckageSprite.rotation = (currentWreckageSprite.rotation + rotSpeed);
currentWreckageSprite.x = spriteRect.x;
currentWreckageSprite.y = spriteRect.y;
return (true);
}
public function init(_arg1:Point, _arg2:int, _arg3:String="particle", _arg4:Number=0):void{
var _local7:Number;
spriteRect.x = _arg1.x;
spriteRect.y = _arg1.y;
speedX = (speedY = (Math.random() * _arg2));
var _local5:int = (Math.random() * 360);
var _local6:Number = ((_local5 / 180) * pi);
rotSin = sin(_local6);
rotCos = cos(_local6);
velocityX = (rotSin * speedX);
velocityY = (rotCos * speedY);
friction = 0.97;
gravity = 0;
if (_arg3 == "particle"){
sprite.scaleX = (sprite.scaleY = (((Math.random() * 90) + 10) / 100));
rotSpeed = ((Math.random() * 20) - 10);
sprite.x = spriteRect.x;
sprite.y = spriteRect.y;
spritePlayField.addChild(sprite);
mainFunc = mainloop_normal;
} else {
if (_arg3 == "spark"){
sprite_spark.alpha = 1;
sprite_spark.width = Math.floor(((Math.random() * 16) + 8));
sprite_spark.x = spriteRect.x;
sprite_spark.y = spriteRect.y;
sprite_spark.rotation = _local5;
spritePlayField.addChild(sprite_spark);
mainFunc = mainloop_spark;
} else {
if (_arg3 == "wreckage"){
_local7 = Math.floor((Math.random() * 100));
if (_local7 < 33){
currentWreckageSprite = wreckage1;
} else {
if (_local7 > 66){
currentWreckageSprite = wreckage2;
} else {
currentWreckageSprite = wreckage3;
};
};
currentWreckageSprite.scaleX = (currentWreckageSprite.scaleY = (((Math.random() * 90) + 10) / 100));
rotSpeed = ((Math.random() * 20) - 10);
currentWreckageSprite.gotoAndPlay(1);
currentWreckageSprite.x = spriteRect.x;
currentWreckageSprite.y = spriteRect.y;
spritePlayField.addChild(currentWreckageSprite);
mainFunc = mainloop_wreckage;
} else {
if (_arg3 == "dustParticle"){
sprite_dustParticle.x = spriteRect.x;
sprite_dustParticle.y = spriteRect.y;
sprite_dustParticle["anim"].gotoAndPlay(1);
sprite_dustParticle.rotation = (Math.random() * 360);
spritePlayField.addChild(sprite_dustParticle);
mainFunc = mainloop_dustParticle;
} else {
if (_arg3 == "percent"){
sprite_percentage["score"].text = (_arg4 + "%");
sprite_percentage.x = spriteRect.x;
sprite_percentage.y = spriteRect.y;
sprite_percentage.alpha = 1;
velocityY = 0;
spritePlayField.addChild(sprite_percentage);
mainFunc = mainloop_percent;
} else {
sprite_dust.x = spriteRect.x;
sprite_dust.y = spriteRect.y;
sprite_dust["anim"].gotoAndPlay(1);
sprite_dust.rotation = (Math.random() * 360);
spritePlayField.addChild(sprite_dust);
mainFunc = mainloop_dust;
};
};
};
};
};
}
private function mainloop_normal():Boolean{
spriteRect.x = (spriteRect.x + velocityX);
spriteRect.y = (spriteRect.y + velocityY);
spriteRect.y = (spriteRect.y + gravity);
gravity = (gravity + 0.2);
if (spriteRect.y <= 0){
if (sprite.parent != null){
spritePlayField.removeChild(sprite);
};
mainFunc = mainloop_waitingToDie;
return (true);
};
if (spriteRect.y > 425){
if (sprite.parent != null){
spritePlayField.removeChild(sprite);
};
mainFunc = mainloop_waitingToDie;
return (true);
};
speedX = (speedX * friction);
velocityX = (rotSin * speedX);
sprite.rotation = (sprite.rotation + rotSpeed);
sprite.x = spriteRect.x;
sprite.y = spriteRect.y;
return (true);
}
private function mainloop_dustParticle():Boolean{
if (sprite_dustParticle["anim"].currentFrame == sprite_dustParticle["anim"].totalFrames){
if (sprite_dustParticle.parent != null){
spritePlayField.removeChild(sprite_dustParticle);
};
sprite_dustParticle["anim"].gotoAndStop(1);
mainFunc = mainloop_waitingToDie;
};
return (true);
}
private function mainloop_spark():Boolean{
spriteRect.x = (spriteRect.x + velocityX);
spriteRect.y = (spriteRect.y + velocityY);
if (spriteRect.y > 425){
spritePlayField.removeChild(sprite_spark);
mainFunc = mainloop_waitingToDie;
return (true);
};
velocityX = (rotCos * speedX);
velocityY = (rotSin * speedY);
sprite_spark.alpha = (sprite_spark.alpha - 0.02);
if (sprite_spark.alpha < 0){
spritePlayField.removeChild(sprite_spark);
mainFunc = mainloop_waitingToDie;
return (true);
};
sprite_spark.x = spriteRect.x;
sprite_spark.y = spriteRect.y;
return (true);
}
public function particleMainloop():Boolean{
return (mainFunc());
}
private function mainloop_waitingToDie():Boolean{
return (false);
}
private function mainloop_dust():Boolean{
if (sprite_dust["anim"].currentFrame == sprite_dust["anim"].totalFrames){
spritePlayField.removeChild(sprite_dust);
sprite_dust["anim"].gotoAndStop(1);
mainFunc = mainloop_waitingToDie;
};
return (true);
}
private function mainloop_percent():Boolean{
if (velocityY > 80){
if (sprite_percentage.alpha > 0){
sprite_percentage.alpha = (sprite_percentage.alpha - 0.2);
} else {
if (sprite_percentage.parent != null){
spritePlayField.removeChild(sprite_percentage);
mainFunc = mainloop_waitingToDie;
};
};
} else {
sprite_percentage.y--;
velocityY++;
};
return (true);
}
public function houseKeeping():void{
if (sprite.parent != null){
spritePlayField.removeChild(sprite);
};
if (sprite_dust.parent != null){
spritePlayField.removeChild(sprite_dust);
};
if (wreckage1.parent != null){
spritePlayField.removeChild(wreckage1);
};
if (wreckage2.parent != null){
spritePlayField.removeChild(wreckage2);
};
if (wreckage3.parent != null){
spritePlayField.removeChild(wreckage3);
};
if (sprite_spark.parent != null){
spritePlayField.removeChild(sprite_spark);
};
if (sprite_dustParticle.parent != null){
spritePlayField.removeChild(sprite_dustParticle);
};
if (sprite_percentage.parent != null){
spritePlayField.removeChild(sprite_percentage);
};
sprite.visible = false;
sprite_dust.visible = false;
wreckage1.visible = false;
wreckage2.visible = false;
wreckage3.visible = false;
sprite_spark.visible = false;
sprite_dustParticle.visible = false;
sprite_percentage.visible = false;
}
}
}//package Classes.Particles
Section 76
//Particle_crashDustMC (Classes.Particles.Particle_crashDustMC)
package Classes.Particles {
import flash.display.*;
import mx.core.*;
public class Particle_crashDustMC extends SpriteAsset {
public var description:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var retryButton:DisplayObject;
public var spilLogo:DisplayObject;
public var anim:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var colourButtons:DisplayObject;
public var leftRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var star21:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var muteRollOver:DisplayObject;
public var reflection:DisplayObject;
public var photo:DisplayObject;
public var startButton:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var scroller:DisplayObject;
public var wheel3:DisplayObject;
public var hitAreaMC:DisplayObject;
public var padLock:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var liveryPhotoAnim:DisplayObject;
public var photoHolder:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var score:DisplayObject;
public var pauseGhosted:DisplayObject;
public var par:DisplayObject;
public var muteButton:DisplayObject;
public var pauseButton:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock15:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var cardHolder:DisplayObject;
public var weightStat:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var levelSelectButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var tryAndGetTween:DisplayObject;
public var backButton:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock23:DisplayObject;
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var omgTextTween:DisplayObject;
public var padlock22:DisplayObject;
public var pauseRollOver:DisplayObject;
public var glassCenter:DisplayObject;
public var button22:DisplayObject;
public var fireworks:DisplayObject;
public var truckRamp:DisplayObject;
public var resetGhosted:DisplayObject;
public var rightRollOver:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var liveryButton:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var button7:DisplayObject;
public var selectButton:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var resetRollOver:DisplayObject;
public var resetButton:DisplayObject;
public var photoAnim:DisplayObject;
public var topSpeedStat:DisplayObject;
public var flag:DisplayObject;
public var target:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var dragger:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock6:DisplayObject;
public var linkButton:DisplayObject;
public var padlock2:DisplayObject;
public var best:DisplayObject;
public var wireFrame:DisplayObject;
public var star12:DisplayObject;
public var star15:DisplayObject;
public var dateText:DisplayObject;
}
}//package Classes.Particles
Section 77
//Particle_dustParticleMC (Classes.Particles.Particle_dustParticleMC)
package Classes.Particles {
import flash.display.*;
import mx.core.*;
public class Particle_dustParticleMC extends SpriteAsset {
public var description:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var retryButton:DisplayObject;
public var spilLogo:DisplayObject;
public var anim:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var colourButtons:DisplayObject;
public var leftRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var star21:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var muteRollOver:DisplayObject;
public var reflection:DisplayObject;
public var photo:DisplayObject;
public var startButton:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var scroller:DisplayObject;
public var wheel3:DisplayObject;
public var hitAreaMC:DisplayObject;
public var padLock:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var liveryPhotoAnim:DisplayObject;
public var photoHolder:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var score:DisplayObject;
public var pauseGhosted:DisplayObject;
public var par:DisplayObject;
public var muteButton:DisplayObject;
public var pauseButton:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock15:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var cardHolder:DisplayObject;
public var weightStat:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var levelSelectButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var tryAndGetTween:DisplayObject;
public var backButton:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock23:DisplayObject;
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var omgTextTween:DisplayObject;
public var padlock22:DisplayObject;
public var pauseRollOver:DisplayObject;
public var glassCenter:DisplayObject;
public var button22:DisplayObject;
public var fireworks:DisplayObject;
public var truckRamp:DisplayObject;
public var resetGhosted:DisplayObject;
public var rightRollOver:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var liveryButton:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var button7:DisplayObject;
public var selectButton:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var resetRollOver:DisplayObject;
public var resetButton:DisplayObject;
public var photoAnim:DisplayObject;
public var topSpeedStat:DisplayObject;
public var flag:DisplayObject;
public var target:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var dragger:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock6:DisplayObject;
public var linkButton:DisplayObject;
public var padlock2:DisplayObject;
public var best:DisplayObject;
public var wireFrame:DisplayObject;
public var star12:DisplayObject;
public var star15:DisplayObject;
public var dateText:DisplayObject;
}
}//package Classes.Particles
Section 78
//Particle_glassParticleMC (Classes.Particles.Particle_glassParticleMC)
package Classes.Particles {
import flash.display.*;
import mx.core.*;
public class Particle_glassParticleMC extends SpriteAsset {
public var description:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var retryButton:DisplayObject;
public var spilLogo:DisplayObject;
public var anim:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var colourButtons:DisplayObject;
public var leftRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var star21:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var muteRollOver:DisplayObject;
public var reflection:DisplayObject;
public var photo:DisplayObject;
public var startButton:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var scroller:DisplayObject;
public var wheel3:DisplayObject;
public var hitAreaMC:DisplayObject;
public var padLock:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var liveryPhotoAnim:DisplayObject;
public var photoHolder:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var score:DisplayObject;
public var pauseGhosted:DisplayObject;
public var par:DisplayObject;
public var muteButton:DisplayObject;
public var pauseButton:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock15:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var cardHolder:DisplayObject;
public var weightStat:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var levelSelectButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var tryAndGetTween:DisplayObject;
public var backButton:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock23:DisplayObject;
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var omgTextTween:DisplayObject;
public var padlock22:DisplayObject;
public var pauseRollOver:DisplayObject;
public var glassCenter:DisplayObject;
public var button22:DisplayObject;
public var fireworks:DisplayObject;
public var truckRamp:DisplayObject;
public var resetGhosted:DisplayObject;
public var rightRollOver:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var liveryButton:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var button7:DisplayObject;
public var selectButton:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var resetRollOver:DisplayObject;
public var resetButton:DisplayObject;
public var photoAnim:DisplayObject;
public var topSpeedStat:DisplayObject;
public var flag:DisplayObject;
public var target:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var dragger:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock6:DisplayObject;
public var linkButton:DisplayObject;
public var padlock2:DisplayObject;
public var best:DisplayObject;
public var wireFrame:DisplayObject;
public var star12:DisplayObject;
public var star15:DisplayObject;
public var dateText:DisplayObject;
}
}//package Classes.Particles
Section 79
//Particle_particleSparkMC (Classes.Particles.Particle_particleSparkMC)
package Classes.Particles {
import flash.display.*;
import mx.core.*;
public class Particle_particleSparkMC extends SpriteAsset {
public var description:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var retryButton:DisplayObject;
public var spilLogo:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var colourButtons:DisplayObject;
public var leftRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var muteRollOver:DisplayObject;
public var reflection:DisplayObject;
public var photo:DisplayObject;
public var startButton:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var scroller:DisplayObject;
public var wheel3:DisplayObject;
public var hitAreaMC:DisplayObject;
public var padLock:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var liveryPhotoAnim:DisplayObject;
public var photoHolder:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var score:DisplayObject;
public var pauseGhosted:DisplayObject;
public var par:DisplayObject;
public var muteButton:DisplayObject;
public var pauseButton:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock15:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var cardHolder:DisplayObject;
public var weightStat:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var levelSelectButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var tryAndGetTween:DisplayObject;
public var backButton:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock23:DisplayObject;
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var omgTextTween:DisplayObject;
public var padlock22:DisplayObject;
public var pauseRollOver:DisplayObject;
public var glassCenter:DisplayObject;
public var button22:DisplayObject;
public var fireworks:DisplayObject;
public var truckRamp:DisplayObject;
public var resetGhosted:DisplayObject;
public var rightRollOver:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var liveryButton:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var button7:DisplayObject;
public var selectButton:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var resetRollOver:DisplayObject;
public var resetButton:DisplayObject;
public var photoAnim:DisplayObject;
public var topSpeedStat:DisplayObject;
public var flag:DisplayObject;
public var target:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var dragger:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock6:DisplayObject;
public var linkButton:DisplayObject;
public var padlock2:DisplayObject;
public var best:DisplayObject;
public var wireFrame:DisplayObject;
public var star12:DisplayObject;
public var star15:DisplayObject;
public var dateText:DisplayObject;
}
}//package Classes.Particles
Section 80
//Particle_scorePercentageMC (Classes.Particles.Particle_scorePercentageMC)
package Classes.Particles {
import flash.display.*;
import mx.core.*;
public class Particle_scorePercentageMC extends SpriteAsset {
public var description:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var retryButton:DisplayObject;
public var spilLogo:DisplayObject;
public var anim:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var colourButtons:DisplayObject;
public var leftRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var star21:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var muteRollOver:DisplayObject;
public var reflection:DisplayObject;
public var photo:DisplayObject;
public var startButton:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var scroller:DisplayObject;
public var wheel3:DisplayObject;
public var hitAreaMC:DisplayObject;
public var padLock:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var liveryPhotoAnim:DisplayObject;
public var photoHolder:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var score:DisplayObject;
public var pauseGhosted:DisplayObject;
public var par:DisplayObject;
public var muteButton:DisplayObject;
public var pauseButton:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock15:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var cardHolder:DisplayObject;
public var weightStat:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var levelSelectButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var tryAndGetTween:DisplayObject;
public var backButton:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock23:DisplayObject;
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var omgTextTween:DisplayObject;
public var padlock22:DisplayObject;
public var pauseRollOver:DisplayObject;
public var glassCenter:DisplayObject;
public var button22:DisplayObject;
public var fireworks:DisplayObject;
public var truckRamp:DisplayObject;
public var resetGhosted:DisplayObject;
public var rightRollOver:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var liveryButton:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var button7:DisplayObject;
public var selectButton:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var resetRollOver:DisplayObject;
public var resetButton:DisplayObject;
public var photoAnim:DisplayObject;
public var topSpeedStat:DisplayObject;
public var flag:DisplayObject;
public var target:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var dragger:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock6:DisplayObject;
public var linkButton:DisplayObject;
public var padlock2:DisplayObject;
public var best:DisplayObject;
public var wireFrame:DisplayObject;
public var star12:DisplayObject;
public var star15:DisplayObject;
public var dateText:DisplayObject;
}
}//package Classes.Particles
Section 81
//Particle_wreckage1MC (Classes.Particles.Particle_wreckage1MC)
package Classes.Particles {
import flash.display.*;
import mx.core.*;
public class Particle_wreckage1MC extends MovieClipAsset {
public var description:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var retryButton:DisplayObject;
public var spilLogo:DisplayObject;
public var anim:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var colourButtons:DisplayObject;
public var leftRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var star21:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var muteRollOver:DisplayObject;
public var reflection:DisplayObject;
public var photo:DisplayObject;
public var startButton:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var scroller:DisplayObject;
public var wheel3:DisplayObject;
public var hitAreaMC:DisplayObject;
public var padLock:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var liveryPhotoAnim:DisplayObject;
public var photoHolder:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var score:DisplayObject;
public var pauseGhosted:DisplayObject;
public var par:DisplayObject;
public var muteButton:DisplayObject;
public var pauseButton:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock15:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var cardHolder:DisplayObject;
public var weightStat:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var levelSelectButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var tryAndGetTween:DisplayObject;
public var backButton:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock23:DisplayObject;
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var omgTextTween:DisplayObject;
public var padlock22:DisplayObject;
public var pauseRollOver:DisplayObject;
public var glassCenter:DisplayObject;
public var button22:DisplayObject;
public var fireworks:DisplayObject;
public var truckRamp:DisplayObject;
public var resetGhosted:DisplayObject;
public var rightRollOver:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var liveryButton:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var button7:DisplayObject;
public var selectButton:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var resetRollOver:DisplayObject;
public var resetButton:DisplayObject;
public var photoAnim:DisplayObject;
public var topSpeedStat:DisplayObject;
public var flag:DisplayObject;
public var target:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var dragger:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock6:DisplayObject;
public var linkButton:DisplayObject;
public var padlock2:DisplayObject;
public var best:DisplayObject;
public var wireFrame:DisplayObject;
public var star12:DisplayObject;
public var star15:DisplayObject;
public var dateText:DisplayObject;
}
}//package Classes.Particles
Section 82
//Particle_wreckage2MC (Classes.Particles.Particle_wreckage2MC)
package Classes.Particles {
import flash.display.*;
import mx.core.*;
public class Particle_wreckage2MC extends MovieClipAsset {
public var description:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var retryButton:DisplayObject;
public var spilLogo:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var colourButtons:DisplayObject;
public var leftRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var muteRollOver:DisplayObject;
public var reflection:DisplayObject;
public var photo:DisplayObject;
public var startButton:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var scroller:DisplayObject;
public var wheel3:DisplayObject;
public var hitAreaMC:DisplayObject;
public var padLock:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var liveryPhotoAnim:DisplayObject;
public var photoHolder:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var score:DisplayObject;
public var pauseGhosted:DisplayObject;
public var par:DisplayObject;
public var muteButton:DisplayObject;
public var pauseButton:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock15:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var cardHolder:DisplayObject;
public var weightStat:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var levelSelectButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var tryAndGetTween:DisplayObject;
public var backButton:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock23:DisplayObject;
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var omgTextTween:DisplayObject;
public var padlock22:DisplayObject;
public var pauseRollOver:DisplayObject;
public var glassCenter:DisplayObject;
public var button22:DisplayObject;
public var fireworks:DisplayObject;
public var truckRamp:DisplayObject;
public var resetGhosted:DisplayObject;
public var rightRollOver:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var liveryButton:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var button7:DisplayObject;
public var selectButton:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var resetRollOver:DisplayObject;
public var resetButton:DisplayObject;
public var photoAnim:DisplayObject;
public var topSpeedStat:DisplayObject;
public var flag:DisplayObject;
public var target:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var dragger:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock6:DisplayObject;
public var linkButton:DisplayObject;
public var padlock2:DisplayObject;
public var best:DisplayObject;
public var wireFrame:DisplayObject;
public var star12:DisplayObject;
public var star15:DisplayObject;
public var dateText:DisplayObject;
}
}//package Classes.Particles
Section 83
//Particle_wreckage3MC (Classes.Particles.Particle_wreckage3MC)
package Classes.Particles {
import flash.display.*;
import mx.core.*;
public class Particle_wreckage3MC extends MovieClipAsset {
public var description:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var retryButton:DisplayObject;
public var spilLogo:DisplayObject;
public var anim:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var colourButtons:DisplayObject;
public var leftRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var star21:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var muteRollOver:DisplayObject;
public var reflection:DisplayObject;
public var photo:DisplayObject;
public var startButton:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var scroller:DisplayObject;
public var wheel3:DisplayObject;
public var hitAreaMC:DisplayObject;
public var padLock:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var liveryPhotoAnim:DisplayObject;
public var photoHolder:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var score:DisplayObject;
public var pauseGhosted:DisplayObject;
public var par:DisplayObject;
public var muteButton:DisplayObject;
public var pauseButton:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock15:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var cardHolder:DisplayObject;
public var weightStat:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var levelSelectButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var tryAndGetTween:DisplayObject;
public var backButton:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock23:DisplayObject;
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var omgTextTween:DisplayObject;
public var padlock22:DisplayObject;
public var pauseRollOver:DisplayObject;
public var glassCenter:DisplayObject;
public var button22:DisplayObject;
public var fireworks:DisplayObject;
public var truckRamp:DisplayObject;
public var resetGhosted:DisplayObject;
public var rightRollOver:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var liveryButton:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var button7:DisplayObject;
public var selectButton:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var resetRollOver:DisplayObject;
public var resetButton:DisplayObject;
public var photoAnim:DisplayObject;
public var topSpeedStat:DisplayObject;
public var flag:DisplayObject;
public var target:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var dragger:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock6:DisplayObject;
public var linkButton:DisplayObject;
public var padlock2:DisplayObject;
public var best:DisplayObject;
public var wireFrame:DisplayObject;
public var star12:DisplayObject;
public var star15:DisplayObject;
public var dateText:DisplayObject;
}
}//package Classes.Particles
Section 84
//ParticleHandler (Classes.Particles.ParticleHandler)
package Classes.Particles {
import flash.display.*;
import flash.geom.*;
import de.polygonal.ds.*;
public class ParticleHandler {
private var spritePool:DLinkedList;
private var activeParticles:Array;
private var scrollRectangle:Rectangle;
private var mainMovie:DisplayObject;
private var main:Main;
private var stage:Stage;
public function ParticleHandler(){
main = Main.getInstance();
mainMovie = main.getMainMovie();
stage = main.getStage();
spritePool = new DLinkedList();
activeParticles = new Array();
}
public function createDust(_arg1:Point):void{
var _local2:Particle;
if (spritePool.isEmpty() == true){
_local2 = new Particle();
} else {
_local2 = spritePool.removeTail();
};
_local2.init(_arg1, 0, "dust");
activeParticles.unshift(_local2);
}
public function houseKeeping():void{
var _local1:Particle;
for each (_local1 in activeParticles) {
_local1.houseKeeping();
spritePool.append(_local1);
};
for each (_local1 in spritePool) {
_local1.houseKeeping();
};
}
public function init():void{
activeParticles = new Array();
}
public function createParticles(_arg1:Point, _arg2:int, _arg3:int=4, _arg4:String="particle"):void{
var _local5:Particle;
var _local6 = -1;
while (++_local6 < _arg3) {
if (spritePool.isEmpty() == true){
_local5 = new Particle();
} else {
_local5 = spritePool.removeTail();
};
_local5.init(_arg1, _arg2, _arg4);
activeParticles.unshift(_local5);
};
}
public function createDustParticle(_arg1:Point):void{
var _local2:Particle;
if (spritePool.isEmpty() == true){
_local2 = new Particle();
} else {
_local2 = spritePool.removeTail();
};
_local2.init(_arg1, 0, "dustParticle");
activeParticles.unshift(_local2);
}
public function mainloop():void{
var _local1:Particle;
var _local2 = -1;
for each (_local1 in activeParticles) {
_local2++;
if (_local1.particleMainloop() == false){
spritePool.append(_local1);
activeParticles.splice(_local2, 1);
};
};
}
public function createScorePercentage(_arg1:Point, _arg2:Number):void{
var _local3:Particle;
if (spritePool.isEmpty() == true){
_local3 = new Particle();
} else {
_local3 = spritePool.removeTail();
};
_local3.init(_arg1, 0, "percent", _arg2);
activeParticles.unshift(_local3);
}
}
}//package Classes.Particles
Section 85
//Attract (Classes.Attract)
package Classes {
import flash.display.*;
import flash.events.*;
import gs.*;
import com.gamingyourway.Utils.*;
import flash.text.*;
public class Attract {
private var bestLevel:int;
private var levelSelectButtons_storage:Array;
private var backButton:MovieClip;
private var level_location:TextField;
private var flag2BM:Class;
private var playField:Sprite;
private var countryID:int;
private var startButton:MovieClip;
private var levelSelectMC:Class;
private var flagHolder:Sprite;
private var soundHandler:SoundHandler;
private var attractMode:Sprite;
private var flag1:Bitmap;
private var flag2:Bitmap;
private var flag3:Bitmap;
private var flag4:Bitmap;
private var creditsPage:Sprite;
private var flagHandler:Flag;
private var flag1BM:Class;
private var flag5BM:Class;
private var attractMC:Class;
private var flag5:Bitmap;
private var padlockStorage:Array;
private var playField_hud:Sprite;
private var level_par:TextField;
private var creditsButton:MovieClip;
private var hostingdomain:String;
private var flag4BM:Class;
private var flagHolder_credits:Sprite;
private var creditsPageMC:Class;
private var levelSelect:Sprite;
private var main:Main;
private var level_best:TextField;
private var sponsorsPage:String;// = "http://www.agame.com"
private var starStorage:Array;
private var linkButton:MovieClip;
private var flag3BM:Class;
private var mainMovie:DisplayObject;
private var stage:Stage;
public function Attract(){
var _local2:MovieClip;
var _local8:String;
var _local9:Number;
attractMC = Attract_attractMC;
levelSelectMC = Attract_levelSelectMC;
creditsPageMC = Attract_creditsPageMC;
flag1BM = Attract_flag1BM;
flag2BM = Attract_flag2BM;
flag3BM = Attract_flag3BM;
flag4BM = Attract_flag4BM;
flag5BM = Attract_flag5BM;
super();
main = Main.getInstance();
mainMovie = main.getMainMovie();
stage = main.getStage();
soundHandler = main.getInitObj().getSoundHandler();
flagHandler = new Flag();
attractMode = new attractMC();
creditsButton = attractMode["creditsButton"];
creditsButton.gotoAndStop(1);
startButton = attractMode["startButton"];
startButton.gotoAndStop(1);
linkButton = attractMode["linkButton"];
linkButton.gotoAndStop(1);
playField = main.getInitObj().getPlayField().attract;
playField_hud = main.getInitObj().getPlayField().hud;
levelSelect = new levelSelectMC();
levelSelect.blendMode = BlendMode.LAYER;
creditsPage = new creditsPageMC();
creditsPage.blendMode = BlendMode.LAYER;
backButton = creditsPage["backButton"];
flagHolder_credits = creditsPage["flagHolder"];
flagHolder_credits.scaleX = (flagHolder_credits.scaleY = 2);
starStorage = new Array();
var _local1:Sprite = levelSelect["star3"];
starStorage.push(_local1);
_local1 = levelSelect["star5"];
starStorage.push(_local1);
_local1 = levelSelect["star7"];
starStorage.push(_local1);
_local1 = levelSelect["star9"];
starStorage.push(_local1);
_local1 = levelSelect["star12"];
starStorage.push(_local1);
_local1 = levelSelect["star15"];
starStorage.push(_local1);
_local1 = levelSelect["star16"];
starStorage.push(_local1);
_local1 = levelSelect["star18"];
starStorage.push(_local1);
_local1 = levelSelect["star21"];
starStorage.push(_local1);
_local1 = levelSelect["star23"];
starStorage.push(_local1);
levelSelectButtons_storage = new Array();
var _local3:int;
while (++_local3 != 26) {
_local2 = levelSelect[("button" + _local3)];
_local2.gotoAndStop(1);
levelSelectButtons_storage.push(_local2);
};
padlockStorage = new Array();
_local3 = 1;
while (++_local3 != 26) {
_local2 = levelSelect[("padlock" + _local3)];
_local2.gotoAndStop(1);
padlockStorage.push(_local2);
};
level_location = levelSelect["location"];
level_par = levelSelect["par"];
level_best = levelSelect["best"];
flagHolder = levelSelect["flagHolder"];
flagHolder.scaleX = (flagHolder.scaleY = 1.5);
flag1 = new flag1BM();
flag2 = new flag2BM();
flag3 = new flag3BM();
flag4 = new flag4BM();
flag5 = new flag5BM();
var _local4:MovieClip = linkButton["spilLogo"];
var _local5:String = stage.loaderInfo.url;
if (_local5.lastIndexOf("_agame") != -1){
_local4.gotoAndStop(1);
sponsorsPage = "http://www.agame.com";
} else {
if (_local5.lastIndexOf("_spielen") != -1){
_local4.gotoAndStop(6);
sponsorsPage = "http://www.Spielen.com";
} else {
if (_local5.lastIndexOf("_jeu") != -1){
_local4.gotoAndStop(5);
sponsorsPage = "http://www.Jeu.fr";
} else {
if (_local5.lastIndexOf("_spelNL") != -1){
_local4.gotoAndStop(4);
sponsorsPage = "http://www.Spel.nl";
} else {
if (_local5.lastIndexOf("_gamesCOID") != -1){
_local4.gotoAndStop(13);
sponsorsPage = "http://www.Games.co.id";
} else {
if (_local5.lastIndexOf("_spelaSE") != -1){
_local4.gotoAndStop(22);
sponsorsPage = "http://www.Spela.se";
} else {
if (_local5.lastIndexOf("_egames") != -1){
_local4.gotoAndStop(44);
sponsorsPage = "http://www.Egames.jp";
} else {
if (_local5.lastIndexOf("_zapjuegos") != -1){
_local4.gotoAndStop(3);
sponsorsPage = "http://www.Zapjuegos.com";
} else {
if (_local5.lastIndexOf("_clickjogos") != -1){
_local4.gotoAndStop(7);
sponsorsPage = "http://www.Clickjogos.com";
} else {
if (_local5.lastIndexOf("_gameCN") != -1){
_local4.gotoAndStop(2);
sponsorsPage = "http://www.game.com.cn";
} else {
if (_local5.lastIndexOf("_flashgames") != -1){
_local4.gotoAndStop(11);
sponsorsPage = "http://www.Flashgames.ru";
} else {
if (_local5.lastIndexOf("_gioco") != -1){
_local4.gotoAndStop(23);
sponsorsPage = "http://www.Gioco.it";
} else {
if (_local5.lastIndexOf("_gry") != -1){
_local4.gotoAndStop(21);
sponsorsPage = "http://www.Gry.pl";
} else {
if (_local5.lastIndexOf("_ojogos") != -1){
_local4.gotoAndStop(25);
sponsorsPage = "http://www.ojogos.com.br";
} else {
_local4.gotoAndStop(1);
};
};
};
};
};
};
};
};
};
};
};
};
};
};
var _local6:String = stage.loaderInfo.url;
var _local7:Number = _local6.indexOf("http://");
if (_local7 == -1){
hostingdomain = "offline_play";
} else {
_local8 = _local6.slice((_local7 + 6));
_local9 = _local8.indexOf("/");
hostingdomain = _local8.slice(0, _local9);
};
preInit();
}
public function stopFlagForTheHud():void{
flagHandler.stop();
}
public function destroyFlagForTheHud():void{
flagHandler.houseKeeping();
}
private function initPadlock(_arg1:MovieClip):void{
_arg1.useHandCursor = false;
_arg1.buttonMode = true;
_arg1.enabled = true;
_arg1.mouseChildren = false;
}
private function killPadlock(_arg1:MovieClip):void{
_arg1.visible = false;
}
private function creditsButtonPressed(_arg1:MouseEvent):void{
soundHandler.play_buttonClick();
createUnionJackForTheHud(flagHolder_credits);
creditsPage.alpha = 0;
attractMode.addChild(creditsPage);
initButton(backButton, backButton_pressed);
TweenLite.to(creditsPage, 0.5, {alpha:1});
}
public function init():void{
playField.addChild(attractMode);
titleButtons_init();
}
public function levelSelectCall():void{
levelSelect_Init();
}
private function killButton(_arg1:MovieClip, _arg2:Function, _arg3:Function=null, _arg4:Function=null):void{
_arg1.useHandCursor = false;
_arg1.buttonMode = false;
_arg1.gotoAndStop(1);
_arg1.removeEventListener(MouseEvent.CLICK, _arg2);
if (_arg3 != null){
_arg1.removeEventListener(MouseEvent.MOUSE_OVER, _arg3);
};
if (_arg4 != null){
_arg1.removeEventListener(MouseEvent.MOUSE_OUT, _arg4);
};
}
private function levelSelected(_arg1:MouseEvent):void{
var _local4:MovieClip;
soundHandler.play_buttonClick();
var _local2:Number = getButtonNumber(_arg1);
main.getInitObj().getGameController().level = _local2;
_local2--;
var _local3:int = Math.floor((_local2 / 5));
main.getInitObj().getGameController().getScroller().setCountry(_local3);
main.getInitObj().getGameController().getLevelPlotter().setCountry(_local3);
var _local5 = -1;
while (++_local5 != 25) {
_local4 = levelSelectButtons_storage[_local5];
killButton(_local4, levelSelected, levelSelect_rollOver, levelSelect_rollOut);
};
flagHandler.stop();
soundHandler.fadeIn_mod2Init();
levelSelect.addEventListener(Event.ENTER_FRAME, fadeDownLevelSelect);
}
public function createFlagForTheHud(_arg1:Sprite):void{
var _local2:int = Math.floor((main.getInitObj().getGameController().level / 5));
if (_local2 == 0){
flagHandler.init(flag1, _arg1);
} else {
if (_local2 == 1){
flagHandler.init(flag2, _arg1);
} else {
if (_local2 == 2){
flagHandler.init(flag3, _arg1);
} else {
if (_local2 == 3){
flagHandler.init(flag4, _arg1);
} else {
flagHandler.init(flag5, _arg1);
};
};
};
};
flagHandler.triggerMainLoop();
}
public function preInit():void{
soundHandler.startMod();
init();
}
private function startButtonPressed(_arg1:MouseEvent):void{
soundHandler.play_buttonClick();
titleButtons_kill();
main.getInitObj().getGameController().startGame();
levelSelect_Init();
}
public function createUnionJackForTheHud(_arg1:Sprite):void{
flagHandler.init(flag4, _arg1);
flagHandler.triggerMainLoop();
}
private function initButton(_arg1:MovieClip, _arg2:Function, _arg3:Function=null, _arg4:Function=null):void{
_arg1.useHandCursor = true;
_arg1.buttonMode = true;
_arg1.enabled = true;
_arg1.mouseChildren = true;
_arg1.gotoAndStop(1);
_arg1.addEventListener(MouseEvent.CLICK, _arg2);
if (_arg3 != null){
_arg1.addEventListener(MouseEvent.MOUSE_OVER, _arg3);
};
if (_arg4 != null){
_arg1.addEventListener(MouseEvent.MOUSE_OUT, _arg4);
};
}
private function creditsRemoved():void{
destroyFlagForTheHud();
attractMode.removeChild(creditsPage);
}
private function levelSelect_Init():void{
var _local1:MovieClip;
var _local3:Sprite;
var _local2 = -1;
while (++_local2 != 25) {
_local1 = levelSelectButtons_storage[_local2];
initButton(_local1, levelSelected, levelSelect_rollOver, levelSelect_rollOut);
};
bestLevel = main.getInitObj().getGameController().bestLevel;
_local2 = -1;
while (++_local2 != (bestLevel - 1)) {
_local1 = padlockStorage[_local2];
killPadlock(_local1);
};
_local2 = -1;
var _local4:int = starStorage.length;
while (++_local2 != _local4) {
_local3 = starStorage[_local2];
_local3.visible = !(main.getInitObj().getGameController().getCarData().testForCollectedStar(_local2));
_local3.mouseChildren = true;
_local3.mouseEnabled = false;
};
var _local5:Number = bestLevel;
_local5--;
level_location.text = main.getInitObj().getLevelData().getLevelLocation(Math.floor((_local5 / 5)));
level_par.text = (main.getInitObj().getLevelData().getParData(_local5).toString() + "%");
level_best.text = (main.getInitObj().getLevelData().getPlayersBest(_local5).toString() + "%");
countryID = Math.floor((_local5 / 5));
main.getInitObj().getGameController().getScroller().setCountry(countryID);
main.getInitObj().getGameController().getLevelPlotter().setCountry(countryID);
if (countryID == 0){
flagHandler.init(flag1, flagHolder);
} else {
if (countryID == 1){
flagHandler.init(flag2, flagHolder);
} else {
if (countryID == 2){
flagHandler.init(flag3, flagHolder);
} else {
if (countryID == 3){
flagHandler.init(flag4, flagHolder);
} else {
flagHandler.init(flag5, flagHolder);
};
};
};
};
flagHandler.triggerMainLoop();
levelSelect.alpha = 1;
playField_hud.addChild(levelSelect);
}
public function toString():String{
return ("Attract");
}
private function fadeDownLevelSelect(_arg1:Event):void{
levelSelect.alpha = (levelSelect.alpha - 0.1);
if (levelSelect.alpha <= 0){
levelSelect.removeEventListener(Event.ENTER_FRAME, fadeDownLevelSelect);
playField_hud.removeChild(levelSelect);
main.getInitObj().getGameController().continueGame();
};
}
private function titleButtons_init():void{
initButton(startButton, startButtonPressed);
initButton(creditsButton, creditsButtonPressed);
initButton(linkButton, linkButtonPressed);
}
private function getButtonNumber(_arg1:MouseEvent):Number{
var _local2:MovieClip = (_arg1.target as MovieClip);
var _local3:String = _local2.name;
var _local4:Number = _local3.indexOf("on");
var _local5:String = _local3.slice((_local4 + 2));
return (Number(_local5));
}
private function levelSelect_rollOver(_arg1:MouseEvent):void{
var _local2:Number = getButtonNumber(_arg1);
_local2--;
level_location.text = main.getInitObj().getLevelData().getLevelLocation(Math.floor((_local2 / 5)));
level_par.text = (main.getInitObj().getLevelData().getParData(_local2).toString() + "%");
level_best.text = (main.getInitObj().getLevelData().getPlayersBest(_local2).toString() + "%");
}
private function linkButtonPressed(_arg1:MouseEvent):void{
soundHandler.play_buttonClick();
var _local2 = (((sponsorsPage + "/?utm_medium=brandedgames_external&utm_campaign=DestroyAllCars&utm_source=") + hostingdomain) + "&utm_content=button_mainscreen_moregames");
Web.getURL(_local2, "_blank");
}
private function titleButtons_kill():void{
killButton(startButton, startButtonPressed);
killButton(creditsButton, creditsButtonPressed);
killButton(linkButton, linkButtonPressed);
}
private function backButton_pressed(_arg1:MouseEvent):void{
soundHandler.play_buttonClick();
stopFlagForTheHud();
killButton(backButton, backButton_pressed);
TweenLite.to(creditsPage, 0.5, {alpha:0, onComplete:creditsRemoved});
}
private function levelSelect_rollOut(_arg1:MouseEvent):void{
var _local2:Number = bestLevel;
_local2--;
level_location.text = main.getInitObj().getLevelData().getLevelLocation(Math.floor((_local2 / 5)));
level_par.text = (main.getInitObj().getLevelData().getParData(_local2).toString() + "%");
level_best.text = (main.getInitObj().getLevelData().getPlayersBest(_local2).toString() + "%");
}
public function houseKeeping():void{
playField.removeChild(attractMode);
}
}
}//package Classes
Section 86
//Attract_attractMC (Classes.Attract_attractMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Attract_attractMC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var padlock22:DisplayObject;
public var button22:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var startButton:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var creditsButton:DisplayObject;
public var loadedButton:DisplayObject;
public var par:DisplayObject;
public var location:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock6:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock2:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var linkButton:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock13:DisplayObject;
public var padlock15:DisplayObject;
public var best:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var button23:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock19:DisplayObject;
public var padlock23:DisplayObject;
}
}//package Classes
Section 87
//Attract_creditsPageMC (Classes.Attract_creditsPageMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Attract_creditsPageMC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var padlock22:DisplayObject;
public var star18:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var startButton:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var creditsButton:DisplayObject;
public var loadedButton:DisplayObject;
public var par:DisplayObject;
public var location:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock6:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock2:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var linkButton:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock13:DisplayObject;
public var padlock15:DisplayObject;
public var best:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock19:DisplayObject;
public var padlock23:DisplayObject;
}
}//package Classes
Section 88
//Attract_flag1BM (Classes.Attract_flag1BM)
package Classes {
import flash.display.*;
import mx.core.*;
public class Attract_flag1BM extends BitmapAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var padlock22:DisplayObject;
public var button22:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var startButton:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var creditsButton:DisplayObject;
public var loadedButton:DisplayObject;
public var par:DisplayObject;
public var location:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock6:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock2:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var linkButton:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock13:DisplayObject;
public var padlock15:DisplayObject;
public var best:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var button23:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock19:DisplayObject;
public var padlock23:DisplayObject;
}
}//package Classes
Section 89
//Attract_flag2BM (Classes.Attract_flag2BM)
package Classes {
import flash.display.*;
import mx.core.*;
public class Attract_flag2BM extends BitmapAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var button15:DisplayObject;
public var padlock22:DisplayObject;
public var button22:DisplayObject;
public var spilLogo:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var loadedButton:DisplayObject;
public var par:DisplayObject;
public var location:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock6:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var padlock2:DisplayObject;
public var button16:DisplayObject;
public var button17:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var padlock12:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock13:DisplayObject;
public var padlock15:DisplayObject;
public var best:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var button23:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock19:DisplayObject;
public var padlock23:DisplayObject;
}
}//package Classes
Section 90
//Attract_flag3BM (Classes.Attract_flag3BM)
package Classes {
import flash.display.*;
import mx.core.*;
public class Attract_flag3BM extends BitmapAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var button15:DisplayObject;
public var padlock22:DisplayObject;
public var button22:DisplayObject;
public var spilLogo:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var loadedButton:DisplayObject;
public var par:DisplayObject;
public var location:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock6:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var padlock2:DisplayObject;
public var button16:DisplayObject;
public var button17:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var padlock12:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock13:DisplayObject;
public var padlock15:DisplayObject;
public var best:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var button23:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock19:DisplayObject;
public var padlock23:DisplayObject;
}
}//package Classes
Section 91
//Attract_flag4BM (Classes.Attract_flag4BM)
package Classes {
import flash.display.*;
import mx.core.*;
public class Attract_flag4BM extends BitmapAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var padlock22:DisplayObject;
public var star18:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var startButton:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var creditsButton:DisplayObject;
public var loadedButton:DisplayObject;
public var par:DisplayObject;
public var location:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock6:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock2:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var linkButton:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock13:DisplayObject;
public var padlock15:DisplayObject;
public var best:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock19:DisplayObject;
public var padlock23:DisplayObject;
}
}//package Classes
Section 92
//Attract_flag5BM (Classes.Attract_flag5BM)
package Classes {
import flash.display.*;
import mx.core.*;
public class Attract_flag5BM extends BitmapAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var padlock22:DisplayObject;
public var button22:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var startButton:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var creditsButton:DisplayObject;
public var loadedButton:DisplayObject;
public var par:DisplayObject;
public var location:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock6:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock2:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var linkButton:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock13:DisplayObject;
public var padlock15:DisplayObject;
public var best:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var button23:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock19:DisplayObject;
public var padlock23:DisplayObject;
}
}//package Classes
Section 93
//Attract_levelSelectMC (Classes.Attract_levelSelectMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Attract_levelSelectMC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var button15:DisplayObject;
public var padlock22:DisplayObject;
public var button22:DisplayObject;
public var spilLogo:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var loadedButton:DisplayObject;
public var par:DisplayObject;
public var location:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock6:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var padlock2:DisplayObject;
public var button16:DisplayObject;
public var button17:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var padlock12:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock13:DisplayObject;
public var padlock15:DisplayObject;
public var best:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var button23:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock19:DisplayObject;
public var padlock23:DisplayObject;
}
}//package Classes
Section 94
//CameraFlashHandler (Classes.CameraFlashHandler)
package Classes {
import flash.display.*;
import flash.events.*;
public class CameraFlashHandler {
private var cameraFlashMC:Class;
private var playField:Sprite;
private var mainMovie:DisplayObject;
private var activeFlashes:Array;
private var main:Main;
private var stage:Stage;
public function CameraFlashHandler(){
cameraFlashMC = CameraFlashHandler_cameraFlashMC;
super();
main = Main.getInstance();
mainMovie = main.getMainMovie();
stage = main.getStage();
playField = main.getInitObj().getPlayField().scroller_stadium;
}
private function mainloop_camera(_arg1:Event):void{
var _local2:MovieClip = (_arg1.target as MovieClip);
if (_local2.currentFrame == _local2.totalFrames){
_local2.removeEventListener(Event.ENTER_FRAME, mainloop_camera);
playField.removeChild(_local2);
};
}
public function toString():String{
return ("Scroller");
}
public function requestPhotos():void{
var _local1:MovieClip;
var _local2:int = (Math.floor((Math.random() * 3)) + 3);
var _local3 = -1;
while (++_local3 != _local2) {
_local1 = new cameraFlashMC();
_local1.blendMode = BlendMode.ADD;
(_local1.gotoAndPlay(Math.floor((Math.random() * 8))) + 1);
_local1.x = ((playField.x + 600) + Math.floor((Math.random() * 640)));
_local1.y = (196 + Math.floor((Math.random() * (300 - 196))));
_local1.rotation = (Math.random() * 360);
_local1.addEventListener(Event.ENTER_FRAME, mainloop_camera);
playField.addChild(_local1);
};
}
}
}//package Classes
Section 95
//CameraFlashHandler_cameraFlashMC (Classes.CameraFlashHandler_cameraFlashMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class CameraFlashHandler_cameraFlashMC extends MovieClipAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var padlock22:DisplayObject;
public var star18:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var startButton:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var creditsButton:DisplayObject;
public var loadedButton:DisplayObject;
public var par:DisplayObject;
public var location:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock6:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock2:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var linkButton:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock13:DisplayObject;
public var padlock15:DisplayObject;
public var best:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock19:DisplayObject;
public var padlock23:DisplayObject;
}
}//package Classes
Section 96
//CarCoords (Classes.CarCoords)
package Classes {
public class CarCoords {
public var car2Coords:Array;
public var car4Coords:Array;
public var car6Coords:Array;
public var car8Coords:Array;
public var car1Coords_stack:Array;
public var car2Coords_stack:Array;
public var car3Coords_stack:Array;
public var car4Coords_stack:Array;
public var car5Coords_stack:Array;
public var car6Coords_stack:Array;
public var car7Coords_stack:Array;
public var car8Coords_stack:Array;
public var car9Coords_stack:Array;
public var car11Coords:Array;
public var car10Coords_stack:Array;
public var car11Coords_stack:Array;
public var car12Coords_stack:Array;
public var car13Coords_stack:Array;
public var car14Coords_stack:Array;
public var coordsStorage_stack:Array;
public var car1Coords:Array;
public var car3Coords:Array;
public var car5Coords:Array;
public var car7Coords:Array;
public var car9Coords:Array;
public var carWeightStorage:Array;
public var car10Coords:Array;
public var car12Coords:Array;
public var coordsStorage:Array;
public function CarCoords(){
car1Coords = [[66, 0, 44, 43, 112, 15, 24, 28, 28, 13, 32, 4, 2, 15, 24, 24, 139, 17, 32, 2, 172, 21, 17, 21, 55, 16, 10, 12, 35, 16, 10, 12, 140, 22, 10, 8, 160, 22, 10, 8], [36, 35, 24, 145, 35, 24], [46, 22, 8, 20, 151, 22, 8, 20]];
car2Coords = [[53, 1, 56, 27, 110, 20, 67, 4, 170, 28, 7, 17, 59, 30, 76, 16, 20, 18, 31, 5, 5, 13, 13, 34, 49, 18, 10, 12, 29, 18, 10, 12, 135, 24, 10, 8, 155, 24, 10, 8], [40, 40, 24, 146, 40, 24], [40, 26, 8, 16, 146, 26, 8, 16]];
car3Coords = [[30, 3, 59, 20, 91, 20, 55, 4, 44, 32, 70, 17, 7, 22, 8, 26, 144, 32, 4, 17, 18, 24, 6, 4, 34, 24, 6, 4, 117, 26, 6, 4, 133, 26, 6, 4], [26, 35, 24, 124, 35, 24], [25, 22, 8, 25, 124, 22, 8, 25]];
car4Coords = [[33, 3, 68, 17, 103, 16, 57, 3, 162, 21, 11, 18, 58, 25, 68, 18, 2, 22, 24, 18, 132, 24, 6, 8], [38, 35, 24, 139, 35, 24], [38, 20, 8, 20, 139, 22, 8, 18]];
car5Coords = [[12, 10, 127, 42, 141, 44, 59, 8, 206, 50, 22, 26, 76, 56, 95, 16, 2, 56, 40, 14, 179, 54, 6, 4], [54, 90, 26, 186, 90, 26], [54, 53, 8, 16, 186, 54, 8, 14]];
car6Coords = [[54, 3, 72, 52, 129, 26, 50, 8, 19, 10, 33, 21, 2, 18, 10, 32, 149, 34, 6, 6], [30, 60, 28, 156, 60, 28], [30, 33, 8, 22, 156, 35, 8, 22]];
car7Coords = [[7, 9, 164, 73, 174, 56, 19, 26, 62, 86, 90, 19, 6, 86, 21, 16, 158, 84, 6, 6, 174, 84, 6, 6, 34, 84, 6, 6, 50, 84, 6, 6], [41, 130, 25, 165, 130, 25], [41, 86, 8, 18, 165, 86, 8, 18]];
car8Coords = [[14, 3, 84, 37, 99, 30, 61, 10, 155, 42, 12, 16, 60, 42, 58, 17, 1, 17, 11, 43], [38, 90, 28, 135, 90, 28], [38, 41, 8, 21, 135, 41, 8, 21]];
car9Coords = [[38, 3, 96, 24, 136, 19, 57, 8, 175, 32, 21, 14, 61, 31, 85, 11, 3, 16, 29, 29], [44, 90, 25, 156, 90, 25], [44, 29, 8, 14, 156, 29, 8, 14]];
car10Coords = [[25, 3, 102, 40, 128, 28, 53, 12, 168, 42, 16, 16, 56, 50, 81, 9, 3, 12, 19, 45, 141, 42, 6, 6], [35, 90, 25, 148, 90, 25], [35, 45, 8, 14, 148, 42, 8, 16]];
car11Coords = [[14, 3, 138, 55, 154, 35, 49, 23, 185, 60, 19, 14, 63, 62, 85, 14, 2, 63, 28, 12], [42, 90, 25, 162, 90, 25], [42, 59, 8, 18, 162, 58, 8, 18]];
car12Coords = [[10, 3, 154, 46, 167, 14, 14, 53, 58, 52, 68, 14, 2, 52, 16, 16], [35, 90, 26, 137, 90, 26], [35, 50, 8, 16, 137, 50, 8, 16]];
car1Coords_stack = [[5, 15, 55, 20, 63, 2, 58, 40, 123, 18, 65, 21], [36, 35, 24, 145, 35, 24]];
car2Coords_stack = [[51, 2, 75, 43, 127, 20, 52, 26, 4, 14, 45, 32], [34, 36, 24, 139, 36, 24]];
car3Coords_stack = [[27, 4, 73, 44, 102, 21, 45, 27, 7, 17, 17, 32], [18, 35, 24, 117, 35, 24]];
car4Coords_stack = [[37, 3, 68, 13, 10, 16, 159, 24], [32, 31, 24, 133, 31, 24]];
car5Coords_stack = [[12, 10, 123, 62, 137, 46, 84, 26], [45, 60, 26, 176, 60, 26]];
car6Coords_stack = [[53, 2, 75, 56, 130, 25, 50, 11, 20, 10, 31, 22, 2, 21, 13, 37], [18, 40, 32, 146, 40, 32]];
car7Coords_stack = [[7, 9, 157, 94, 168, 64, 24, 39], [41, 100, 25, 165, 100, 25]];
car8Coords_stack = [[7, 2, 99, 59, 107, 27, 55, 34], [26, 48, 32, 123, 48, 32]];
car9Coords_stack = [[47, 0, 85, 44, 135, 19, 60, 28, 1, 16, 43, 29], [34, 34, 25, 146, 34, 25]];
car10Coords_stack = [[22, 1, 100, 58, 125, 21, 57, 37, 2, 26, 18, 34], [26, 50, 25, 139, 50, 25]];
car11Coords_stack = [[12, 3, 140, 72, 155, 31, 49, 45], [34, 64, 25, 154, 65, 25]];
car12Coords_stack = [[6, 3, 155, 65, 165, 15, 17, 53], [26, 53, 29, 129, 53, 29]];
car13Coords_stack = [[46, 3, 90, 50, 138, 23, 65, 30, 5, 24, 39, 29], [42, 42, 25, 152, 42, 25]];
car14Coords_stack = [[50, 2, 80, 14, 4, 17, 188, 23], [39, 30, 24, 145, 30, 24]];
carWeightStorage = new Array(38, 35, 35, 33, 32, 30, 28, 38, 36, 37, 37, 35, 32, 31);
super();
coordsStorage = new Array();
coordsStorage.push(car1Coords, car2Coords, car3Coords, car4Coords, car5Coords, car6Coords, car7Coords, car8Coords, car9Coords, car10Coords, car11Coords, car12Coords);
coordsStorage_stack = new Array();
coordsStorage_stack.push(car1Coords_stack, car2Coords_stack, car3Coords_stack, car4Coords_stack, car5Coords_stack, car6Coords_stack, car7Coords_stack, car8Coords_stack, car9Coords_stack, car10Coords_stack, car11Coords_stack, car12Coords_stack, car13Coords_stack, car14Coords_stack);
}
public function getCarWeight(_arg1:int):int{
return (carWeightStorage[(_arg1 - 1)]);
}
public function getPolyData(_arg1:int):Array{
return (coordsStorage[(_arg1 - 1)]);
}
public function getPolyData_stack(_arg1:int):Array{
return (coordsStorage_stack[(_arg1 - 1)]);
}
}
}//package Classes
Section 97
//CarData (Classes.CarData)
package Classes {
public class CarData {
private var lockedCars:Array;
private var currentLivery:Array;
private var lockedCarIDs:Array;
private var cookies:Cookies;
private var lockedCarsLevels:Array;
private var currentLivery_forPositioning:Array;
private var main:Main;
public var highestUnlockedLivery:int;// = 1
private var storage:Array;
public function CarData(){
storage = new Array(["'69 Rodge Larger", "The Larger is a classic American muscle car and a favourite of stunt drivers.", 0, 90, 40, 60, 55], ["'83 MBW N3", "The MBW is a powerful car with a history of success racing on and off-road.", 4, 80, 50, 50, 55], ["'81 Leno 5 Turbo", "With acceleration like a bat out of hell the Leno 5 is a boy racers fantasy.", 1, 80, 100, 25, 65], ["'63 Curvy Tingray", "A stylish car plus powerful engine. It flies with it's aerodynamic design.", 0, 90, 85, 40, 90], ["'79 Citrus DS", "A French design classic. This estate version is used by emergency services.", 1, 50, 40, 70, 80], ["'92 Dumb V", "The Dumb V, or 'Dumber' is a solid and heavy vehicle with a powerful engine.", 4, 60, 40, 100, 60], ["'88 Ice-Cream Van", "Ice Cream, you scream, we all scream for ice cream. Slow, but fun to crash.", 4, 20, 25, 75, 90], ["'82 Suki Jeep", "With great handling and 4 wheel drive, the Suki Jeep can handle any slope.", 2, 70, 60, 70, 60], ["'90 Hexus", "A luxury Japanese car, combining big comfort with a big engine.", 2, 60, 55, 75, 50], ["'63 London Taxi", "Known as the 'Hackney Carriage' the sixties cab is comfortbale and stylish.", 3, 25, 20, 80, 100], ["'84 Bored Transit", "Every man with a van's choice. The transit has moved half the world.", 3, 35, 35, 100, 20], ["'65 Wolksvagen Van", "A retro classic camper van designed for familes but loved by hippies.", 4, 40, 45, 80, 90]);
lockedCars = new Array(false, false, true, true, true, true, true, true, true, true, true, true);
lockedCarsLevels = new Array(3, 5, 7, 9, 12, 15, 16, 18, 21, 23);
lockedCarIDs = new Array(4, 6, 3, 5, 9, 8, 10, 11, 12, 7);
currentLivery = new Array(1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1);
currentLivery_forPositioning = new Array(1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1);
super();
main = Main.getInstance();
cookies = main.getInitObj().getCookies();
lockedCars = cookies.lockedCars;
currentLivery = cookies.currentLivery;
currentLivery_forPositioning = cookies.currentLivery_forPositioning;
highestUnlockedLivery = cookies.highestUnlockedLivery;
}
public function testForNewlyUnlockedCar(_arg1:int):Boolean{
var _local2:int = getUnlockedCarNumber(_arg1);
if (lockedCars[(_local2 - 1)] == true){
lockedCars[(_local2 - 1)] = false;
cookies.lockedCars = lockedCars;
cookies.saveAll();
return (true);
};
return (false);
}
public function setCurrentLivery(_arg1:int, _arg2:int):void{
currentLivery[_arg1] = _arg2;
cookies.currentLivery = currentLivery;
cookies.saveAll();
}
public function getCurrentLivery(_arg1:int):int{
return (currentLivery[_arg1]);
}
public function getCurrentLivery_forPositioning(_arg1:int):int{
return (currentLivery_forPositioning[_arg1]);
}
public function getlockedCarLevelFlag(_arg1:int):Boolean{
var _local2 = -1;
var _local3:int = lockedCarsLevels.length;
while (++_local2 != _local3) {
if (_arg1 == lockedCarsLevels[_local2]){
return (true);
};
};
return (false);
}
public function getUnlockedCarNumber(_arg1:int):int{
var _local2 = -1;
var _local3:int = lockedCarsLevels.length;
while (++_local2 != _local3) {
if (_arg1 == lockedCarsLevels[_local2]){
break;
};
};
return (lockedCarIDs[_local2]);
}
public function setCurrentLivery_forPositioning(_arg1:int, _arg2:int):void{
currentLivery_forPositioning[_arg1] = _arg2;
cookies.currentLivery_forPositioning = currentLivery_forPositioning;
cookies.saveAll();
}
public function getCarData(_arg1:int):Array{
return (storage[_arg1]);
}
public function testForCollectedStar(_arg1:int):Boolean{
return (lockedCars[(lockedCarIDs[_arg1] - 1)]);
}
public function getLockedCars(_arg1:int):Boolean{
return (lockedCars[_arg1]);
}
}
}//package Classes
Section 98
//CardHandler (Classes.CardHandler)
package Classes {
import flash.display.*;
import flash.events.*;
import gs.*;
public class CardHandler {
private var card3MC:Class;
private var card10MC:Class;
private var stage:Stage;
private var cardScroller_leftButton:MovieClip;
private var cardScroller_rightButton:MovieClip;
private var card1:Sprite;
private var card2:Sprite;
private var card3:Sprite;
private var cardScroller_leftButtonMC:Class;
private var card5:Sprite;
private var playField:Sprite;
private var card7:Sprite;
private var card8:Sprite;
private var card9:Sprite;
private var card4:Sprite;
private var card6:Sprite;
private var gameController:GameController;
private var card10:Sprite;
private var card11:Sprite;
private var card12:Sprite;
private var card2MC:Class;
private var soundHandler:SoundHandler;
private var card6MC:Class;
private var cardsBackgroundMC:Class;
private var cardStorage:Array;
private var selectButton:MovieClip;
private var cardNestedStorage:Array;
private var newCarText:MovieClip;
private var cardScroller_rightButtonMC:Class;
private var card1MC:Class;
private var card5MC:Class;
private var card9MC:Class;
private var cardNested10:Sprite;
private var card12MC:Class;
private var cardNested12:Sprite;
private var cardNested11:Sprite;
private var liveryScrollingFlag:Boolean;
private var carData:CarData;
private var cardMC:Class;
private var carWonFlag:Boolean;
private var newCarTextMC:Class;
private var main:Main;
private var card4MC:Class;
private var card8MC:Class;
private var highestUnlockedLivery:int;
private var card11MC:Class;
private var fireWorkHolderMC:Class;
private var cardScroller_selectButtonMC:Class;
private var cardNested1:Sprite;
private var cardNested2:Sprite;
private var cardNested3:Sprite;
private var cardNested4:Sprite;
private var cardNested5:Sprite;
private var cardNested6:Sprite;
private var cardNested7:Sprite;
private var cardNested8:Sprite;
private var cardNested9:Sprite;
private var fireWorkHolder:Sprite;
private var mainMovie:DisplayObject;
private var cardsBackground:Sprite;
private var card7MC:Class;
public function CardHandler(){
cardMC = CardHandler_cardMC;
card1MC = CardHandler_card1MC;
card2MC = CardHandler_card2MC;
card3MC = CardHandler_card3MC;
card4MC = CardHandler_card4MC;
card5MC = CardHandler_card5MC;
card6MC = CardHandler_card6MC;
card7MC = CardHandler_card7MC;
card8MC = CardHandler_card8MC;
card9MC = CardHandler_card9MC;
card10MC = CardHandler_card10MC;
card11MC = CardHandler_card11MC;
card12MC = CardHandler_card12MC;
cardsBackgroundMC = CardHandler_cardsBackgroundMC;
cardScroller_selectButtonMC = CardHandler_cardScroller_selectButtonMC;
cardScroller_leftButtonMC = CardHandler_cardScroller_leftButtonMC;
cardScroller_rightButtonMC = CardHandler_cardScroller_rightButtonMC;
newCarTextMC = CardHandler_newCarTextMC;
fireWorkHolderMC = CardHandler_fireWorkHolderMC;
super();
main = Main.getInstance();
mainMovie = main.getMainMovie();
stage = main.getStage();
gameController = main.getInitObj().getGameController();
carData = gameController.getCarData();
soundHandler = main.getInitObj().getSoundHandler();
playField = new Sprite();
cardsBackground = new cardsBackgroundMC();
selectButton = new cardScroller_selectButtonMC();
selectButton.x = 21;
selectButton.y = 431;
selectButton.gotoAndStop(1);
cardScroller_leftButton = new cardScroller_leftButtonMC();
cardScroller_leftButton.x = 242;
cardScroller_leftButton.y = 397;
cardScroller_leftButton.gotoAndStop(1);
cardScroller_rightButton = new cardScroller_rightButtonMC();
cardScroller_rightButton.x = 364;
cardScroller_rightButton.y = 397;
cardScroller_rightButton.gotoAndStop(1);
cardsBackground.addChild(selectButton);
cardsBackground.addChild(cardScroller_leftButton);
cardsBackground.addChild(cardScroller_rightButton);
newCarText = new newCarTextMC();
newCarText.x = 320;
newCarText.y = 32;
newCarText.gotoAndStop(1);
fireWorkHolder = new fireWorkHolderMC();
card1 = new card1MC();
cardNested1 = new cardMC();
card1["cardHolder"].addChild(cardNested1);
cardNested1.name = "cardMC1";
card2 = new card2MC();
cardNested2 = new cardMC();
card2["cardHolder"].addChild(cardNested2);
cardNested2.name = "cardMC2";
card3 = new card3MC();
cardNested3 = new cardMC();
card3["cardHolder"].addChild(cardNested3);
cardNested3.name = "cardMC3";
card4 = new card4MC();
cardNested4 = new cardMC();
card4["cardHolder"].addChild(cardNested4);
cardNested4.name = "cardMC4";
card5 = new card5MC();
cardNested5 = new cardMC();
card5["cardHolder"].addChild(cardNested5);
cardNested5.name = "cardMC5";
card6 = new card6MC();
cardNested6 = new cardMC();
card6["cardHolder"].addChild(cardNested6);
cardNested6.name = "cardMC6";
card7 = new card7MC();
cardNested7 = new cardMC();
card7["cardHolder"].addChild(cardNested7);
cardNested7.name = "cardMC7";
card8 = new card8MC();
cardNested8 = new cardMC();
card8["cardHolder"].addChild(cardNested8);
cardNested8.name = "cardMC8";
card9 = new card9MC();
cardNested9 = new cardMC();
card9["cardHolder"].addChild(cardNested9);
cardNested9.name = "cardMC9";
card10 = new card10MC();
cardNested10 = new cardMC();
card10["cardHolder"].addChild(cardNested10);
cardNested10.name = "cardMC10";
card11 = new card11MC();
cardNested11 = new cardMC();
card11["cardHolder"].addChild(cardNested11);
cardNested11.name = "cardMC11";
card12 = new card12MC();
cardNested12 = new cardMC();
card12["cardHolder"].addChild(cardNested12);
cardNested12.name = "cardMC12";
cardStorage = new Array();
cardStorage.push(card1, card2, card3, card4, card5, card6, card7, card8, card9, card10, card11, card12);
cardNestedStorage = new Array();
cardNestedStorage.push(cardNested1, cardNested2, cardNested3, cardNested4, cardNested5, cardNested6, cardNested7, cardNested8, cardNested9, cardNested10, cardNested11, cardNested12);
var _local1 = -1;
while (++_local1 != 12) {
playField.addChild(cardStorage[_local1]);
};
populateData();
}
private function leftButton_newLiveryWon(_arg1:MouseEvent):void{
var _local10:int;
if (liveryScrollingFlag == true){
return;
};
soundHandler.play_buttonClick();
var _local2:Number = getCardID(_arg1);
var _local3:int = (_local2 - 1);
var _local4:Sprite = cardStorage[_local3];
var _local5:Sprite = _local4["scroller"];
var _local6:Sprite = _local4["reflection"];
if (_local5.x < 38){
_local10 = (_local5.x + 250);
TweenLite.to(_local5, 0.5, {x:_local10});
TweenLite.to(_local6, 0.5, {x:_local10, onComplete:liveryStoppedScrolling});
liveryScrollingFlag = true;
if ((_local5.x + 250) >= 38){
killButton((_arg1.target as MovieClip), leftButton_newLiveryWon);
};
};
var _local7:Sprite = cardNestedStorage[_local3];
var _local8:Sprite = _local7["colourButtons"];
var _local9:MovieClip = _local8["rightButton"];
initButton(_local9, rightButton_newLiveryWon);
}
private function setUpScroller():void{
var _local1:Sprite;
var _local5:Sprite;
var _local6:Sprite;
var _local7:MovieClip;
var _local8:MovieClip;
var _local9:MovieClip;
var _local10:int;
playField.x = 205;
playField.y = 84;
var _local2 = 395;
var _local3:int;
var _local4 = -1;
while (++_local4 != 12) {
_local1 = cardStorage[_local4];
_local1.x = _local3;
_local1.y = 0;
_local3 = (_local3 + _local2);
_local1["lockedText"].visible = carData.getLockedCars(_local4);
_local1["scroller"].x = (38 - ((carData.getCurrentLivery_forPositioning(_local4) - 1) * 250));
_local1["reflection"].x = _local1["scroller"].x;
};
_local4 = -1;
while (++_local4 != 12) {
_local5 = cardNestedStorage[_local4];
_local6 = _local5["colourButtons"];
_local6.visible = true;
_local7 = _local6["doneButton"];
initButton(_local7, doneButtonPressed_newLiveryWon);
_local8 = _local6["leftButton"];
_local1 = cardStorage[_local4];
if (_local1["scroller"].x < 38){
initButton(_local8, leftButton_newLiveryWon);
} else {
_local8.gotoAndStop(1);
};
_local9 = _local6["rightButton"];
initButton(_local9, rightButton_newLiveryWon);
};
cardsBackground.alpha = 0;
playField.alpha = 0;
playField.blendMode = BlendMode.LAYER;
initButton(selectButton, selectButton_pressed_newLiveryWon);
if (carWonFlag == true){
initButton(cardScroller_leftButton, cardScroller_leftButton_pressed_newLiveryWon);
_local10 = carData.getUnlockedCarNumber(gameController.level);
playField.x = (playField.x - ((_local10 - 1) * 395));
soundHandler.play_fireworks();
stage.addChild(fireWorkHolder);
};
initButton(cardScroller_rightButton, cardScroller_rightButton_pressed_newLiveryWon);
stage.addChild(cardsBackground);
stage.addChild(playField);
stage.addEventListener(Event.ENTER_FRAME, fadeInScroller);
}
private function selectButton_pressed_newLiveryWon(_arg1:Event):void{
var _local2:Sprite;
var _local3:Sprite;
var _local4:MovieClip;
var _local5:MovieClip;
var _local6:MovieClip;
soundHandler.play_buttonClick();
killButton(selectButton, selectButton_pressed_newLiveryWon);
killButton(cardScroller_leftButton, cardScroller_leftButton_pressed_newLiveryWon);
killButton(cardScroller_rightButton, cardScroller_rightButton_pressed_newLiveryWon);
if (carWonFlag == true){
stage.removeChild(fireWorkHolder);
};
var _local7 = -1;
while (++_local7 != 12) {
_local2 = cardNestedStorage[_local7];
_local3 = _local2["colourButtons"];
_local4 = _local3["doneButton"];
killButton(_local4, doneButtonPressed_newLiveryWon);
_local5 = _local3["leftButton"];
killButton(_local5, leftButton_newLiveryWon);
_local6 = _local3["rightButton"];
killButton(_local6, rightButton_newLiveryWon);
};
stage.addEventListener(Event.ENTER_FRAME, fadeOutScroller);
}
private function doneButtonPressed_newLiveryWon(_arg1:MouseEvent):void{
soundHandler.play_liverySelected();
var _local2:Number = getCardID(_arg1);
var _local3:Sprite = cardStorage[(_local2 - 1)];
var _local4:Sprite = _local3["scroller"];
var _local5:int = (_local4.x - 38);
_local5 = (_local5 / 250);
_local5 = Math.abs(_local5);
_local4["tick"].x = (148 + (_local5 * 250));
_local5++;
gameController.getCarData().setCurrentLivery_forPositioning((_local2 - 1), _local5);
if (_local5 == 1){
_local5 = 1;
} else {
if (_local5 == 2){
_local5 = 3;
} else {
if (_local5 == 3){
_local5 = 5;
} else {
_local5 = 7;
};
};
};
gameController.getCarData().setCurrentLivery((_local2 - 1), _local5);
if (carWonFlag == true){
removeColourSelector((_local2 - 1));
};
}
private function fadeInScroller(_arg1:Event):void{
if (cardsBackground.alpha >= 1){
cardsBackground.alpha = 1;
playField.alpha = 1;
stage.removeEventListener(Event.ENTER_FRAME, fadeInScroller);
if (carWonFlag == true){
stage.addChild(newCarText);
newCarText.gotoAndPlay(1);
newCarText.addEventListener(Event.ENTER_FRAME, waitingForNewCarTextToFinish);
};
} else {
cardsBackground.alpha = (cardsBackground.alpha + 0.2);
playField.alpha = (playField.alpha + 0.2);
};
}
private function cardScroller_rightButton_pressed_newLiveryWon(_arg1:Event):void{
soundHandler.play_buttonClick();
killButton(cardScroller_leftButton, cardScroller_leftButton_pressed_newLiveryWon);
killButton(cardScroller_rightButton, cardScroller_rightButton_pressed_newLiveryWon);
var _local2:Number = (playField.x - 395);
TweenLite.to(playField, 0.5, {x:_local2, onComplete:reinstallButtons});
}
private function killButton(_arg1:MovieClip, _arg2:Function, _arg3:Function=null, _arg4:Function=null):void{
_arg1.useHandCursor = false;
_arg1.buttonMode = false;
_arg1.gotoAndStop(1);
_arg1.removeEventListener(MouseEvent.CLICK, _arg2);
if (_arg3 != null){
_arg1.removeEventListener(MouseEvent.MOUSE_OVER, _arg3);
_arg1.removeEventListener(MouseEvent.MOUSE_OUT, _arg4);
};
}
private function getCardID(_arg1:MouseEvent):int{
var _local2:MovieClip = (_arg1.target as MovieClip);
var _local3:String = _local2.parent.parent.name;
var _local4:int = _local3.indexOf("MC");
_local4 = (_local4 + 2);
var _local5:String = _local3.substring(_local4);
var _local6:Number = Number(_local5);
return (_local6);
}
public function carWon():void{
highestUnlockedLivery = carData.highestUnlockedLivery;
liveryScrollingFlag = false;
carWonFlag = true;
setUpScroller();
}
private function cardScroller_leftButton_pressed_newLiveryWon(_arg1:Event):void{
soundHandler.play_buttonClick();
killButton(cardScroller_leftButton, cardScroller_leftButton_pressed_newLiveryWon);
killButton(cardScroller_rightButton, cardScroller_rightButton_pressed_newLiveryWon);
var _local2:Number = (playField.x + 395);
TweenLite.to(playField, 0.5, {x:_local2, onComplete:reinstallButtons});
}
private function reinstallButtons():void{
if (playField.x < 0){
initButton(cardScroller_leftButton, cardScroller_leftButton_pressed_newLiveryWon);
};
if (playField.x > -4140){
initButton(cardScroller_rightButton, cardScroller_rightButton_pressed_newLiveryWon);
};
}
private function initButton(_arg1:MovieClip, _arg2:Function, _arg3:Function=null, _arg4:Function=null):void{
_arg1.useHandCursor = true;
_arg1.buttonMode = true;
_arg1.enabled = true;
_arg1.mouseChildren = true;
_arg1.gotoAndStop(1);
_arg1.addEventListener(MouseEvent.CLICK, _arg2);
if (_arg3 != null){
_arg1.addEventListener(MouseEvent.MOUSE_OVER, _arg3);
_arg1.addEventListener(MouseEvent.MOUSE_OUT, _arg4);
};
}
public function toString():String{
return ("CardHandler");
}
private function removeColourSelector(_arg1:int):void{
var _local2:Sprite = cardNestedStorage[_arg1];
var _local3:Sprite = _local2["colourButtons"];
_local3.visible = false;
var _local4:MovieClip = _local3["rightButton"];
killButton(_local4, rightButton_newLiveryWon);
var _local5:MovieClip = _local3["leftButton"];
killButton(_local5, leftButton_newLiveryWon);
var _local6:MovieClip = _local3["doneButton"];
killButton(_local6, doneButtonPressed_newLiveryWon);
}
private function fadeOutScroller(_arg1:Event):void{
if (cardsBackground.alpha <= 0){
soundHandler.stop_fireworks();
stage.removeChild(cardsBackground);
stage.removeChild(playField);
cardsBackground.alpha = 1;
playField.alpha = 1;
stage.removeEventListener(Event.ENTER_FRAME, fadeOutScroller);
if (carWonFlag == true){
gameController.newlyWonCarSeen();
} else {
gameController.newLiverySelected();
};
} else {
cardsBackground.alpha = (cardsBackground.alpha - 0.2);
playField.alpha = (playField.alpha - 0.2);
};
}
public function newLiveryWon():void{
highestUnlockedLivery = carData.highestUnlockedLivery;
liveryScrollingFlag = false;
carWonFlag = false;
setUpScroller();
}
private function populateData():void{
var _local1:Sprite;
var _local2:Sprite;
var _local3:Array;
var _local4:Sprite;
var _local5 = -1;
while (++_local5 != 12) {
_local3 = carData.getCarData(_local5);
_local1 = cardNestedStorage[_local5];
_local1["carName"].text = _local3[0];
_local1["description"].text = _local3[1];
_local1["flag"].gotoAndStop((_local3[2] + 1));
_local1["topSpeedStat"].scaleX = (_local3[3] / 100);
_local1["accelerationStat"].scaleX = (_local3[4] / 100);
_local1["weightStat"].scaleX = (_local3[5] / 100);
_local1["styleStat"].scaleX = (_local3[6] / 100);
_local2 = cardStorage[_local5];
_local2["lockedText"].visible = carData.getLockedCars(_local5);
};
}
private function waitingForNewCarTextToFinish(_arg1:Event):void{
if (newCarText.currentFrame == newCarText.totalFrames){
newCarText.gotoAndStop(1);
newCarText.removeEventListener(Event.ENTER_FRAME, waitingForNewCarTextToFinish);
};
}
private function rightButton_newLiveryWon(_arg1:MouseEvent):void{
var _local10:int;
if (liveryScrollingFlag == true){
return;
};
soundHandler.play_buttonClick();
var _local2:Number = getCardID(_arg1);
var _local3:int = (_local2 - 1);
var _local4:Sprite = cardStorage[_local3];
var _local5:Sprite = _local4["scroller"];
var _local6:Sprite = _local4["reflection"];
if (_local5.x > (38 - ((highestUnlockedLivery - 1) * 250))){
_local10 = (_local5.x - 250);
TweenLite.to(_local5, 0.5, {x:_local10});
TweenLite.to(_local6, 0.5, {x:_local10, onComplete:liveryStoppedScrolling});
liveryScrollingFlag = true;
if (_local10 <= (38 - (highestUnlockedLivery * 250))){
killButton((_arg1.target as MovieClip), rightButton_newLiveryWon);
};
};
var _local7:Sprite = cardNestedStorage[_local3];
var _local8:Sprite = _local7["colourButtons"];
var _local9:MovieClip = _local8["leftButton"];
initButton(_local9, leftButton_newLiveryWon);
}
private function liveryStoppedScrolling():void{
liveryScrollingFlag = false;
}
}
}//package Classes
Section 99
//CardHandler_card10MC (Classes.CardHandler_card10MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class CardHandler_card10MC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var star21:DisplayObject;
public var linkButton:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var padlock22:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock2:DisplayObject;
public var padlock6:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock15:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 100
//CardHandler_card11MC (Classes.CardHandler_card11MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class CardHandler_card11MC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var star21:DisplayObject;
public var linkButton:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var padlock22:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock2:DisplayObject;
public var padlock6:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock15:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 101
//CardHandler_card12MC (Classes.CardHandler_card12MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class CardHandler_card12MC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var star21:DisplayObject;
public var linkButton:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var padlock22:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock2:DisplayObject;
public var padlock6:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock15:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 102
//CardHandler_card1MC (Classes.CardHandler_card1MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class CardHandler_card1MC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var star21:DisplayObject;
public var linkButton:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var padlock22:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock2:DisplayObject;
public var padlock6:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock15:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 103
//CardHandler_card2MC (Classes.CardHandler_card2MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class CardHandler_card2MC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var star21:DisplayObject;
public var linkButton:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var padlock22:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock2:DisplayObject;
public var padlock6:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock15:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 104
//CardHandler_card3MC (Classes.CardHandler_card3MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class CardHandler_card3MC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var star21:DisplayObject;
public var linkButton:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var padlock22:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock2:DisplayObject;
public var padlock6:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock15:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 105
//CardHandler_card4MC (Classes.CardHandler_card4MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class CardHandler_card4MC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var star21:DisplayObject;
public var linkButton:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var padlock22:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock2:DisplayObject;
public var padlock6:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock15:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 106
//CardHandler_card5MC (Classes.CardHandler_card5MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class CardHandler_card5MC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var padlock22:DisplayObject;
public var star18:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var startButton:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var lockedText:DisplayObject;
public var creditsButton:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock2:DisplayObject;
public var location:DisplayObject;
public var padlock6:DisplayObject;
public var padlock3:DisplayObject;
public var padlock9:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button10:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var linkButton:DisplayObject;
public var cardHolder:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var button17:DisplayObject;
public var padlock15:DisplayObject;
public var best:DisplayObject;
public var padlock13:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock19:DisplayObject;
public var padlock23:DisplayObject;
}
}//package Classes
Section 107
//CardHandler_card6MC (Classes.CardHandler_card6MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class CardHandler_card6MC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var star21:DisplayObject;
public var linkButton:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var padlock22:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock2:DisplayObject;
public var padlock6:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock15:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 108
//CardHandler_card7MC (Classes.CardHandler_card7MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class CardHandler_card7MC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var padlock22:DisplayObject;
public var star18:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var startButton:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var lockedText:DisplayObject;
public var creditsButton:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock2:DisplayObject;
public var location:DisplayObject;
public var padlock6:DisplayObject;
public var padlock3:DisplayObject;
public var padlock9:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button10:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var linkButton:DisplayObject;
public var cardHolder:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var button17:DisplayObject;
public var padlock15:DisplayObject;
public var best:DisplayObject;
public var padlock13:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock19:DisplayObject;
public var padlock23:DisplayObject;
}
}//package Classes
Section 109
//CardHandler_card8MC (Classes.CardHandler_card8MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class CardHandler_card8MC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var star21:DisplayObject;
public var linkButton:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var padlock22:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock2:DisplayObject;
public var padlock6:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock15:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 110
//CardHandler_card9MC (Classes.CardHandler_card9MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class CardHandler_card9MC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var star21:DisplayObject;
public var linkButton:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var padlock22:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock2:DisplayObject;
public var padlock6:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock15:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 111
//CardHandler_cardMC (Classes.CardHandler_cardMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class CardHandler_cardMC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var star21:DisplayObject;
public var linkButton:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var padlock22:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock2:DisplayObject;
public var padlock6:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock15:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 112
//CardHandler_cardsBackgroundMC (Classes.CardHandler_cardsBackgroundMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class CardHandler_cardsBackgroundMC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var star21:DisplayObject;
public var linkButton:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var padlock22:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock2:DisplayObject;
public var padlock6:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock15:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 113
//CardHandler_cardScroller_leftButtonMC (Classes.CardHandler_cardScroller_leftButtonMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class CardHandler_cardScroller_leftButtonMC extends MovieClipAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var star21:DisplayObject;
public var linkButton:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var padlock22:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock2:DisplayObject;
public var padlock6:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock15:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 114
//CardHandler_cardScroller_rightButtonMC (Classes.CardHandler_cardScroller_rightButtonMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class CardHandler_cardScroller_rightButtonMC extends MovieClipAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var star21:DisplayObject;
public var linkButton:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var padlock22:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock2:DisplayObject;
public var padlock6:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock15:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 115
//CardHandler_cardScroller_selectButtonMC (Classes.CardHandler_cardScroller_selectButtonMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class CardHandler_cardScroller_selectButtonMC extends MovieClipAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var star21:DisplayObject;
public var linkButton:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var padlock22:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock2:DisplayObject;
public var padlock6:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock15:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 116
//CardHandler_fireWorkHolderMC (Classes.CardHandler_fireWorkHolderMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class CardHandler_fireWorkHolderMC extends MovieClipAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var star21:DisplayObject;
public var linkButton:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var padlock22:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock2:DisplayObject;
public var padlock6:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock15:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 117
//CardHandler_newCarTextMC (Classes.CardHandler_newCarTextMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class CardHandler_newCarTextMC extends MovieClipAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var star21:DisplayObject;
public var linkButton:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var padlock22:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock2:DisplayObject;
public var padlock6:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock15:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 118
//ContactListener (Classes.ContactListener)
package Classes {
import Box2D.Dynamics.*;
import Box2D.Collision.*;
public class ContactListener extends b2ContactListener {
public var contactStorage:Array;
public function ContactListener(){
contactStorage = new Array();
}
override public function Add(_arg1:b2ContactPoint):void{
var _local2:Object = new Object();
_local2.body1 = _arg1.shape1.m_body;
if (_local2.body1.m_userData == null){
return;
};
_local2.body2 = _arg1.shape2.m_body;
if (_local2.body2.m_userData == null){
return;
};
_local2.force = (Math.abs(_arg1.velocity.x) + Math.abs(_arg1.velocity.y));
_local2.contactPoint = _arg1.position;
contactStorage.push(_local2);
}
}
}//package Classes
Section 119
//Cookies (Classes.Cookies)
package Classes {
import flash.display.*;
import flash.events.*;
import flash.net.*;
public class Cookies {
private var sharedObject:SharedObject;
public var cookiesLoadedFlag:Boolean;// = false
public var lockedCars:Array;
public var currentLivery:Array;
public var bestLevel:int;// = 1
public var volume:Number;// = 1
public var alreadyCompletedFlag:Boolean;// = false
public var currentLivery_forPositioning:Array;
private var cnt:int;
public var collectedLiveryLevels:Array;
public var alreadyCompleted100PercentFlag:Boolean;// = false
public var playersBest:Array;
public var highestUnlockedLivery:int;// = 1
public function Cookies(){
lockedCars = new Array(false, false, true, true, true, true, true, true, true, true, true, true);
currentLivery = new Array(1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1);
currentLivery_forPositioning = new Array(1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1);
playersBest = new Array(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
collectedLiveryLevels = new Array(false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false);
super();
sharedObject = SharedObject.getLocal("gywPresentsDACv11");
if (sharedObject.data["volume"] == null){
createFile();
} else {
loadAll();
};
}
public function loadAll():void{
volume = sharedObject.data["volume"];
bestLevel = sharedObject.data["bestLevel"];
lockedCars = sharedObject.data["lockedCars"];
currentLivery = sharedObject.data["currentLivery"];
currentLivery_forPositioning = sharedObject.data["currentLivery_forPositioning"];
playersBest = sharedObject.data["playersBest"];
collectedLiveryLevels = sharedObject.data["collectedLiveryLevels"];
highestUnlockedLivery = sharedObject.data["highestUnlockedLivery"];
alreadyCompletedFlag = sharedObject.data["alreadyCompletedFlag"];
alreadyCompleted100PercentFlag = sharedObject.data["alreadyCompleted100PercentFlag"];
cookiesLoadedFlag = true;
}
private function waitAFewFrames(_arg1:Event):void{
var _local2:Stage;
if (++cnt == 10){
_local2 = Main.getInstance().getStage();
_local2.removeEventListener(Event.ENTER_FRAME, waitAFewFrames);
cookiesLoadedFlag = true;
};
}
public function saveAll():void{
sharedObject.data["volume"] = volume;
sharedObject.data["bestLevel"] = bestLevel;
sharedObject.data["lockedCars"] = lockedCars;
sharedObject.data["currentLivery"] = currentLivery;
sharedObject.data["currentLivery_forPositioning"] = currentLivery_forPositioning;
sharedObject.data["playersBest"] = playersBest;
sharedObject.data["collectedLiveryLevels"] = collectedLiveryLevels;
sharedObject.data["highestUnlockedLivery"] = highestUnlockedLivery;
sharedObject.data["alreadyCompletedFlag"] = alreadyCompletedFlag;
sharedObject.data["alreadyCompleted100PercentFlag"] = alreadyCompleted100PercentFlag;
sharedObject.flush();
}
private function createFile():void{
saveAll();
cnt = 0;
var _local1:Stage = Main.getInstance().getStage();
_local1.addEventListener(Event.ENTER_FRAME, waitAFewFrames);
}
}
}//package Classes
Section 120
//Flag (Classes.Flag)
package Classes {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.filters.*;
public class Flag {
private var output:Bitmap;
private var width:Number;
private var flagHolder:Sprite;
private var mainMovie:DisplayObject;
private var light:BitmapData;
private var displacement:DisplacementMapFilter;
private var perlinNoiseOffset:Array;
private var source:Bitmap;
private var flagOffset:Point;
private var stage:Stage;
private var gray:ColorMatrixFilter;
private var height:Number;
private var flag:BitmapData;
private var perlinNoiseFallOff:BitmapData;
private var perlinNoiseSeed:Number;
private var lightContrast:ColorTransform;
private var main:Main;
private var bounds:Rectangle;
private var perlinNoiseBitmapData:BitmapData;
private static var IDENTITY:Matrix = new Matrix();
private static var ORIGIN:Point = new Point(0, 0);
public function Flag(){
main = Main.getInstance();
mainMovie = main.getMainMovie();
stage = main.getStage();
output = new Bitmap();
}
public function houseKeeping():void{
flagHolder.removeChild(output);
output.bitmapData.dispose();
}
public function stop():void{
source.removeEventListener(Event.ENTER_FRAME, mainloop);
}
private function assemble():void{
width = output.width;
height = output.height;
bounds = output.bitmapData.rect.clone();
flag = new BitmapData(width, height, true, 0);
flagOffset = new Point(((width - source.width) / 2), ((height - source.height) / 2));
createGrayFilter();
createPerlinNoiseFallOffGradient();
flag.copyPixels(source.bitmapData, source.bitmapData.rect, flagOffset);
perlinNoiseBitmapData = new BitmapData(width, height, false, 0);
perlinNoiseOffset = [new Point(), new Point()];
perlinNoiseSeed = Math.floor((Math.random() * 0x0100));
displacement = new DisplacementMapFilter(perlinNoiseBitmapData, ORIGIN, 2, 4, (0.125 * source.width), (0.2 * source.height), "ignore");
light = new BitmapData(width, height, true, 0);
lightContrast = new ColorTransform(4, 4, 4, 1, 0, 0, 0, 0);
}
public function triggerMainLoop():void{
source.addEventListener(Event.ENTER_FRAME, mainloop);
}
private function createPerlinNoiseFallOffGradient():void{
perlinNoiseFallOff = new BitmapData(width, height, true, 0);
var _local1:Sprite = new Sprite();
var _local2:Matrix = new Matrix();
_local2.createGradientBox((width - flagOffset.x), height, 0, flagOffset.x, 0);
_local1.graphics.beginGradientFill("linear", [0x8080, 0x8080], [99, 0], [0, 64], _local2);
_local1.graphics.moveTo(0, 0);
_local1.graphics.lineTo(width, 0);
_local1.graphics.lineTo(width, height);
_local1.graphics.lineTo(0, height);
_local1.graphics.lineTo(0, 0);
_local1.graphics.endFill();
perlinNoiseFallOff.draw(_local1);
}
public function mainloop(_arg1:Event):void{
output.bitmapData.fillRect(bounds, 0);
perlinNoiseOffset[0].x = (perlinNoiseOffset[0].x - (0.06 * source.width));
perlinNoiseOffset[1].x = (perlinNoiseOffset[1].x - (0.03 * source.height));
perlinNoiseBitmapData.perlinNoise((0.66 * source.width), (0.66 * source.height), 2, perlinNoiseSeed, false, true, 6, false, perlinNoiseOffset);
perlinNoiseBitmapData.copyPixels(perlinNoiseFallOff, bounds, ORIGIN, perlinNoiseFallOff, ORIGIN, true);
output.bitmapData.applyFilter(flag, bounds, ORIGIN, displacement);
light.copyPixels(perlinNoiseBitmapData, bounds, ORIGIN, output.bitmapData, ORIGIN);
light.applyFilter(light, bounds, ORIGIN, gray);
output.bitmapData.draw(light, IDENTITY, lightContrast, "multiply");
}
private function createGrayFilter():void{
gray = new ColorMatrixFilter([0, 0, 0.45, 0, 0, 0, 0, 0.45, 0, 0, 0, 0, 0.45, 0, 0, 0, 0, 0.45, 0.35, 0]);
}
public function init(_arg1:Bitmap, _arg2:Sprite):void{
source = _arg1;
output.bitmapData = new BitmapData((source.width + 50), (source.height + 50), true, 0);
assemble();
flagHolder = _arg2;
flagHolder.addChild(output);
}
public function toString():String{
return ("Flag");
}
}
}//package Classes
Section 121
//GameController (Classes.GameController)
package Classes {
import flash.display.*;
import flash.geom.*;
import Classes.Particles.*;
public class GameController {
public var level:int;
private var stage:Stage;
private var mainMovie:DisplayObject;
public var bestLevel:int;
private var cookies:Cookies;
private var score:int;
private var cardHandler:CardHandler;
private var carData:CarData;
private var numberOfCarsInStack:int;
private var numberOfDestroyedCars:int;
private var main:Main;
private var scroller:Scroller;
private var pausedFlag:Boolean;// = false
private var physics:Physics;
public var scorePercentage:Number;
private var transition:Transition;
private var rampHandler:RampHandler;
private var player:Player;
private var master:Master;
private var particleHandler:ParticleHandler;
private var hud:HUD;
private var levelPlotter:LevelPlotter;
private var levelPar:int;
private var cameraFlashHandler:CameraFlashHandler;
public function GameController(){
main = Main.getInstance();
mainMovie = main.getMainMovie();
stage = main.getStage();
cookies = main.getInitObj().getCookies();
hud = new HUD();
carData = new CarData();
}
public function getLevelPlotter():LevelPlotter{
return (levelPlotter);
}
public function speedSelected(_arg1:Number):void{
physics.startDriving(_arg1);
}
public function togglePause():void{
if (pausedFlag == false){
pausedFlag = true;
pause();
} else {
pausedFlag = false;
resume();
};
}
public function houseKeeping():void{
master.houseKeeping();
physics.houseKeeping();
player.houseKeeping();
rampHandler.houseKeeping();
particleHandler.houseKeeping();
hud.houseKeeping();
}
public function newlyWonCarSeen():void{
levelComplete();
}
public function getPhysics():Physics{
return (physics);
}
public function selectLevel_init():void{
houseKeeping();
scroller.init();
particleHandler.init();
master.start();
main.getInitObj().getAttract().levelSelectCall();
}
public function getCameraFlashHandler():CameraFlashHandler{
return (cameraFlashHandler);
}
public function levelFinished(_arg1:int):void{
master.houseKeeping();
particleHandler.houseKeeping();
hud.disablePauseButton();
hud.houseKeeping();
numberOfDestroyedCars = _arg1;
scorePercentage = Math.floor(((numberOfDestroyedCars / numberOfCarsInStack) * 100));
main.getInitObj().getLevelData().setPlayerBest((level - 1), scorePercentage);
levelPar = main.getInitObj().getLevelData().getParData((level - 1));
if (scorePercentage >= levelPar){
if (level == bestLevel){
if (bestLevel < 25){
bestLevel++;
cookies.bestLevel = bestLevel;
cookies.saveAll();
};
};
levelComplete();
} else {
levelFailed();
};
}
public function startSpeedSelection():void{
physics.startWheelSpinning();
player.startSpeedSelection();
}
public function carWon():void{
cardHandler.carWon();
}
public function newLiveryWon():void{
cardHandler.newLiveryWon();
}
public function carSelected():void{
physics.init();
}
public function getRampHandler():RampHandler{
return (rampHandler);
}
private function resume():void{
main.getInitObj().getPlayField().resume();
transition.releasePauseGrabScreen();
master.resume();
}
public function newLiverySelected():void{
hud.newLiverySelected();
}
private function pause():void{
master.houseKeeping();
transition.pauseGrabScreen();
main.getInitObj().getPlayField().pause();
}
public function getParticleHandler():ParticleHandler{
return (particleHandler);
}
public function startTransitionComplete():void{
main.getInitObj().getAttract().houseKeeping();
}
public function getScroller():Scroller{
return (scroller);
}
public function continueGame():void{
particleHandler.houseKeeping();
levelPlotter.init();
numberOfCarsInStack = levelPlotter.numberOfCarsInStack;
hud.init(main.getInitObj().getLevelData().getParData((level - 1)));
player.init();
rampHandler.init();
}
public function retryLevel():void{
transition.grabScreen(retryLevel_init);
}
public function retryLevel_init():void{
houseKeeping();
scroller.init();
particleHandler.init();
master.start();
continueGame();
}
public function rampSelected(_arg1:int):void{
physics.rampSelected(_arg1);
player.rampSelected();
}
public function disableReset():void{
hud.disableResetButton();
}
public function getHUD():HUD{
return (hud);
}
public function getTransition():Transition{
return (transition);
}
public function rampSelectStart():void{
physics.rampSelectStart();
rampHandler.rampSelectStart();
}
public function getPlayer():Player{
return (player);
}
private function levelComplete():void{
var _local1:int;
if (physics.carCollectedFlag == true){
physics.carCollectedFlag = false;
if (carData.testForNewlyUnlockedCar(level) == true){
main.getInitObj().getSoundHandler().fadeOut_mod2Init();
carWon();
return;
};
};
if (level == 25){
_local1 = main.getInitObj().getLevelData().getPlayersTotalPercentages();
if (cookies.alreadyCompletedFlag == false){
cookies.alreadyCompletedFlag = true;
if (_local1 == (100 * 25)){
cookies.alreadyCompleted100PercentFlag = true;
};
cookies.saveAll();
hud.gameComplete();
return;
} else {
if (cookies.alreadyCompleted100PercentFlag == false){
if (_local1 == (100 * 25)){
cookies.alreadyCompleted100PercentFlag = true;
};
cookies.saveAll();
hud.gameComplete();
return;
};
};
};
hud.levelComplete();
}
private function levelFailed():void{
hud.levelFailed();
}
public function selectLevel():void{
transition.grabScreen(selectLevel_init);
}
public function getCardHandler():CardHandler{
return (cardHandler);
}
public function toString():String{
return ("GameController");
}
public function getCarData():CarData{
return (carData);
}
public function startGame():void{
if (transition == null){
transition = new Transition();
cardHandler = new CardHandler();
scroller = new Scroller();
physics = new Physics();
player = new Player();
rampHandler = new RampHandler();
levelPlotter = new LevelPlotter();
particleHandler = new ParticleHandler();
master = new Master();
cameraFlashHandler = new CameraFlashHandler();
};
bestLevel = cookies.bestLevel;
scroller.init();
particleHandler.init();
master.start();
transition.grabScreen(startTransitionComplete);
}
public function showPercentageParticles(_arg1:Point, _arg2:int):void{
scorePercentage = Math.floor(((_arg2 / numberOfCarsInStack) * 100));
if (scorePercentage > 60){
main.getInitObj().getSoundHandler().play_crowdcheerairhornSFX();
};
particleHandler.createScorePercentage(_arg1, scorePercentage);
}
public function resetGame():void{
numberOfDestroyedCars = 0;
scorePercentage = 0;
houseKeeping();
if (pausedFlag == true){
pausedFlag = false;
main.getInitObj().getPlayField().resume();
transition.releasePauseGrabScreen();
};
levelFailed();
}
}
}//package Classes
Section 122
//HUD (Classes.HUD)
package Classes {
import flash.display.*;
import flash.events.*;
import flash.text.*;
public class HUD {
private var pauseRollOver:Sprite;
private var wellDoneTextMC:Class;
private var gameCompleteText:Sprite;
private var resetGhosted:Sprite;
private var muteRollOver:Sprite;
private var gameController:GameController;
private var soundHandler:SoundHandler;
private var spin180MC:Class;
private var retryButton_fail:MovieClip;
private var levelSelectButton_fail:MovieClip;
private var liveryButton:MovieClip;
private var doneButton:MovieClip;
private var flagHolder_complete:Sprite;
private var resetButton:Sprite;
private var callBack:Function;
private var spin180:MovieClip;
private var photoAnim:MovieClip;
private var resetRollOver:Sprite;
private var liveryPhotoAnim:MovieClip;
private var controlPanelMC:Class;
private var photoHolder:Sprite;
private var spin360MC:Class;
private var targetScore:Sprite;
private var flagHolder_wellDone:Sprite;
private var pauseGhosted:Sprite;
private var controlPanel:Sprite;
private var spin360:MovieClip;
private var muteButton:Sprite;
private var gameCompleteTextMC:Class;
private var main:Main;
private var levelFailedText:Sprite;
private var levelFailedTextMC:Class;
private var flagHolder_fail:Sprite;
private var pauseButton:Sprite;
private var wellDoneText:Sprite;
private var retryButton_complete:MovieClip;
private var carCollectedFlag:Boolean;
private var levelSelectButton_complete:MovieClip;
private var targetMC:Class;
private var tryAndGetTween:MovieClip;
private var omgTextTween:MovieClip;
private var mainMovie:DisplayObject;
private var stage:Stage;
public function HUD(){
wellDoneTextMC = HUD_wellDoneTextMC;
levelFailedTextMC = HUD_levelFailedTextMC;
gameCompleteTextMC = HUD_gameCompleteTextMC;
controlPanelMC = HUD_controlPanelMC;
spin180MC = HUD_spin180MC;
spin360MC = HUD_spin360MC;
targetMC = HUD_targetMC;
super();
main = Main.getInstance();
mainMovie = main.getMainMovie();
stage = main.getStage();
gameController = main.getInitObj().getGameController();
soundHandler = main.getInitObj().getSoundHandler();
wellDoneText = new wellDoneTextMC();
wellDoneText.blendMode = BlendMode.LAYER;
targetScore = new targetMC();
targetScore.y = 8;
targetScore.cacheAsBitmap = true;
photoAnim = wellDoneText["photoAnim"];
photoAnim.gotoAndStop(1);
photoHolder = photoAnim["photo"].photoHolder;
photoHolder.scaleX = (photoHolder.scaleY = 0.5);
var _local1:TextField = photoAnim["photo"].dateText;
var _local2:Date = new Date();
var _local3:Number = _local2.getDate();
var _local4:Number = (_local2.getMonth() + 1);
var _local5:Number = _local2.getFullYear();
_local1.text = ((((_local3 + "/") + _local4) + "/") + _local5);
liveryPhotoAnim = wellDoneText["liveryPhotoAnim"];
liveryPhotoAnim.gotoAndStop(1);
liveryButton = liveryPhotoAnim["photo"].liveryButton;
retryButton_complete = wellDoneText["retryButton"];
retryButton_complete.gotoAndStop(1);
levelSelectButton_complete = wellDoneText["levelSelectButton"];
levelSelectButton_complete.gotoAndStop(1);
flagHolder_wellDone = wellDoneText["flagHolder"];
flagHolder_wellDone.scaleX = (flagHolder_wellDone.scaleY = 1.5);
levelFailedText = new levelFailedTextMC();
levelFailedText.blendMode = BlendMode.LAYER;
retryButton_fail = levelFailedText["retryButton"];
retryButton_fail.gotoAndStop(1);
levelSelectButton_fail = levelFailedText["levelSelectButton"];
levelSelectButton_fail.gotoAndStop(1);
flagHolder_fail = levelFailedText["flagHolder"];
flagHolder_fail.scaleX = (flagHolder_fail.scaleY = 1.5);
spin180 = new spin180MC();
spin180.x = 320;
spin180.y = 84;
spin180.gotoAndStop(1);
spin360 = new spin360MC();
spin360.x = spin180.x;
spin360.y = 84;
spin360.gotoAndStop(1);
gameCompleteText = new gameCompleteTextMC();
tryAndGetTween = gameCompleteText["tryAndGetTween"];
tryAndGetTween.gotoAndStop(1);
omgTextTween = gameCompleteText["omgTextTween"];
omgTextTween.gotoAndStop(1);
doneButton = gameCompleteText["doneButton"];
doneButton.gotoAndStop(1);
flagHolder_complete = gameCompleteText["flagHolder"];
flagHolder_complete.scaleX = (flagHolder_complete.scaleY = 1.5);
controlPanel = new controlPanelMC();
controlPanel.x = 428;
controlPanel.y = 433;
stage.addChild(controlPanel);
muteButton = controlPanel["muteButton"];
muteRollOver = controlPanel["muteRollOver"];
muteRollOver.visible = false;
pauseButton = controlPanel["pauseButton"];
pauseRollOver = controlPanel["pauseRollOver"];
pauseRollOver.visible = false;
pauseGhosted = controlPanel["pauseGhosted"];
resetButton = controlPanel["resetButton"];
resetRollOver = controlPanel["resetRollOver"];
resetRollOver.visible = false;
resetGhosted = controlPanel["resetGhosted"];
muteButton_init();
}
private function muteButton_rollOut(_arg1:Event):void{
muteRollOver.visible = false;
}
private function muteButton_rollOver(_arg1:Event):void{
muteRollOver.visible = true;
}
private function tryAndGetTween_waiting(_arg1:Event):void{
if (tryAndGetTween.currentFrame == tryAndGetTween.totalFrames){
tryAndGetTween.gotoAndStop(tryAndGetTween.currentFrame);
tryAndGetTween.removeEventListener(Event.ENTER_FRAME, tryAndGetTween_waiting);
doneButtonInit();
};
}
private function omgTextTween_waiting(_arg1:Event):void{
if (omgTextTween.currentFrame == omgTextTween.totalFrames){
omgTextTween.gotoAndStop(omgTextTween.currentFrame);
omgTextTween.removeEventListener(Event.ENTER_FRAME, omgTextTween_waiting);
doneButtonInit();
};
}
private function fadedown_wellDoneText_liverySelected(_arg1:Event):void{
if (wellDoneText.alpha <= 0){
wellDoneText.removeEventListener(Event.ENTER_FRAME, fadedown_wellDoneText_liverySelected);
stage.removeChild(wellDoneText);
gameController.newLiveryWon();
} else {
wellDoneText.alpha = (wellDoneText.alpha - 0.2);
};
}
public function init(_arg1:int):void{
targetScore["target"].text = (_arg1 + "%");
stage.addChild(targetScore);
}
private function resetButton_rollOver(_arg1:Event):void{
resetRollOver.visible = true;
}
private function fadedown_gameCompleteText(_arg1:Event):void{
if (gameCompleteText.alpha <= 0){
stage.removeChild(gameCompleteText);
gameCompleteText.removeEventListener(Event.ENTER_FRAME, fadedown_gameCompleteText);
levelComplete();
} else {
gameCompleteText.alpha = (gameCompleteText.alpha - 0.2);
};
}
private function pauseButton_rollOut(_arg1:Event):void{
pauseRollOver.visible = false;
}
private function muteButton_init():void{
initButton((muteButton as MovieClip), muteButton_pressed, muteButton_rollOver, muteButton_rollOut);
}
private function pauseButton_init():void{
pauseGhosted.visible = false;
initButton((pauseButton as MovieClip), pauseButton_pressed, pauseButton_rollOver, pauseButton_rollOut);
}
private function liveryButton_pressed(_arg1:Event):void{
soundHandler.play_buttonClick();
killButton(liveryButton, liveryButton_pressed);
wellDoneText.addEventListener(Event.ENTER_FRAME, fadedown_wellDoneText_liverySelected);
}
private function photoAnim_check(_arg1:Event):void{
if (photoAnim.currentFrame == photoAnim.totalFrames){
photoAnim.gotoAndStop(photoAnim.currentFrame);
liveryPhotoAnim.gotoAndStop(liveryPhotoAnim.currentFrame);
photoAnim.removeEventListener(Event.ENTER_FRAME, photoAnim_check);
gameController.getTransition().cropPhoto(photoHolder);
photoHolder.addEventListener(Event.ENTER_FRAME, fadeInPhoto);
};
}
private function retryButton_fail_pressed(_arg1:MouseEvent):void{
soundHandler.play_buttonClick();
soundHandler.fadeIn_mod2Init();
killButton(retryButton_fail, retryButton_fail_pressed);
killButton(levelSelectButton_fail, levelSelectButton_fail_pressed);
main.getInitObj().getAttract().stopFlagForTheHud();
callBack = gameController.retryLevel;
levelFailedText.addEventListener(Event.ENTER_FRAME, fadedown_levelFailedText);
}
private function levelComplete_init():void{
initButton(retryButton_complete, retryButton_complete_pressed);
initButton(levelSelectButton_complete, levelSelectButton_complete_pressed);
}
private function killButton(_arg1:MovieClip, _arg2:Function, _arg3:Function=null, _arg4:Function=null):void{
_arg1.useHandCursor = false;
_arg1.buttonMode = false;
_arg1.gotoAndStop(1);
_arg1.removeEventListener(MouseEvent.CLICK, _arg2);
if (_arg3 != null){
_arg1.removeEventListener(MouseEvent.MOUSE_OVER, _arg3);
_arg1.removeEventListener(MouseEvent.MOUSE_OUT, _arg4);
};
}
private function fadeup_gameCompleteText(_arg1:Event):void{
if (gameCompleteText.alpha >= 1){
gameCompleteText.alpha = 1;
gameCompleteText.removeEventListener(Event.ENTER_FRAME, fadeup_gameCompleteText);
showGameCompleteMessage();
} else {
gameCompleteText.alpha = (gameCompleteText.alpha + 0.1);
};
}
private function resetButton_pressed(_arg1:Event):void{
soundHandler.play_buttonClick();
resetButton_kill();
pauseButton_kill();
if (gameController == null){
gameController = main.getInitObj().getGameController();
};
gameController.resetGame();
}
public function enablePauseButton():void{
pauseButton_init();
resetButton_init();
}
private function levelSelectButton_fail_pressed(_arg1:MouseEvent):void{
soundHandler.play_buttonClick();
killButton(retryButton_fail, retryButton_fail_pressed);
killButton(levelSelectButton_fail, levelSelectButton_fail_pressed);
main.getInitObj().getAttract().stopFlagForTheHud();
callBack = gameController.selectLevel;
levelFailedText.addEventListener(Event.ENTER_FRAME, fadedown_levelFailedText);
}
private function fadedown_wellDoneText(_arg1:Event):void{
if (wellDoneText.alpha <= 0){
wellDoneText.removeEventListener(Event.ENTER_FRAME, fadedown_wellDoneText);
main.getInitObj().getAttract().destroyFlagForTheHud();
gameController.getTransition().photoHouseKeeping(photoHolder);
photoAnim.gotoAndStop(1);
liveryPhotoAnim.gotoAndStop(1);
stage.removeChild(wellDoneText);
callBack();
} else {
wellDoneText.alpha = (wellDoneText.alpha - 0.05);
};
}
private function doneButton_pressed(_arg1:MouseEvent):void{
killButton(doneButton, doneButton_pressed);
gameCompleteText.addEventListener(Event.ENTER_FRAME, fadedown_gameCompleteText);
}
private function resetButton_init():void{
resetGhosted.visible = false;
initButton((resetButton as MovieClip), resetButton_pressed, resetButton_rollOver, resetButton_rollOut);
}
public function gameComplete():void{
if (gameController == null){
gameController = main.getInitObj().getGameController();
};
gameCompleteText.alpha = 0;
main.getInitObj().getAttract().createUnionJackForTheHud(flagHolder_complete);
soundHandler.play_fireworks();
stage.addChild(gameCompleteText);
soundHandler.fadeOut_mod2Init();
gameCompleteText.addEventListener(Event.ENTER_FRAME, fadeup_gameCompleteText);
}
public function disableResetButton():void{
resetButton_kill();
}
private function initButton(_arg1:MovieClip, _arg2:Function, _arg3:Function=null, _arg4:Function=null):void{
_arg1.useHandCursor = true;
_arg1.buttonMode = true;
_arg1.enabled = true;
_arg1.mouseChildren = true;
_arg1.gotoAndStop(1);
_arg1.addEventListener(MouseEvent.CLICK, _arg2);
if (_arg3 != null){
_arg1.addEventListener(MouseEvent.MOUSE_OVER, _arg3);
_arg1.addEventListener(MouseEvent.MOUSE_OUT, _arg4);
};
}
private function photoInit():void{
var _local2:Cookies;
photoHolder.alpha = 0;
photoAnim.gotoAndPlay(1);
var _local1:int = gameController.level;
if (main.getInitObj().getLevelData().isThisALiveryLevel(_local1) == true){
if (main.getInitObj().getLevelData().liveryAlreadyCollectedCheck(_local1) == false){
liveryPhotoAnim.visible = true;
liveryPhotoAnim.gotoAndPlay(1);
liveryButton_init();
gameController.getCarData().highestUnlockedLivery++;
_local2 = main.getInitObj().getCookies();
_local2.highestUnlockedLivery = gameController.getCarData().highestUnlockedLivery;
_local2.saveAll();
} else {
liveryPhotoAnim.visible = false;
liveryPhotoAnim.gotoAndStop(1);
};
} else {
liveryPhotoAnim.visible = false;
liveryPhotoAnim.gotoAndStop(1);
};
photoAnim.addEventListener(Event.ENTER_FRAME, photoAnim_check);
}
public function toString():String{
return ("Scroller");
}
private function pauseButton_kill():void{
pauseGhosted.visible = true;
killButton((pauseButton as MovieClip), pauseButton_pressed, pauseButton_rollOver, pauseButton_rollOut);
}
private function resetButton_kill():void{
resetGhosted.visible = true;
killButton((resetButton as MovieClip), resetButton_pressed, resetButton_rollOver, resetButton_rollOut);
}
private function doneButtonInit():void{
initButton(doneButton, doneButton_pressed);
}
private function handleSpinningText(_arg1:Event):void{
var _local2:MovieClip = (_arg1.target as MovieClip);
if (_local2.currentFrame == _local2.totalFrames){
_local2.gotoAndStop(_local2.totalFrames);
if (_local2.alpha > 0){
_local2.alpha = (_local2.alpha - 0.2);
} else {
_local2.removeEventListener(Event.ENTER_FRAME, handleSpinningText);
stage.removeChild(_local2);
};
return;
};
if (_local2.alpha < 1){
_local2.alpha = (_local2.alpha + 0.1);
_local2.y = (_local2.y + 4);
};
}
private function fadeup_levelFailedText(_arg1:Event):void{
if (levelFailedText.alpha >= 1){
levelFailedText.alpha = 1;
levelFailedText.removeEventListener(Event.ENTER_FRAME, fadeup_levelFailedText);
} else {
levelFailedText.alpha = (levelFailedText.alpha + 0.1);
};
}
private function muteButton_pressed(_arg1:Event):void{
var _local2:Cookies = main.getInitObj().getCookies();
_local2.volume = soundHandler.toggleSounds();
_local2.saveAll();
soundHandler.play_buttonClick();
}
private function pauseButton_rollOver(_arg1:Event):void{
pauseRollOver.visible = true;
}
private function fadedown_levelFailedText(_arg1:Event):void{
if (levelFailedText.alpha <= 0){
levelFailedText.removeEventListener(Event.ENTER_FRAME, fadedown_levelFailedText);
main.getInitObj().getAttract().destroyFlagForTheHud();
stage.removeChild(levelFailedText);
callBack();
} else {
levelFailedText.alpha = (levelFailedText.alpha - 0.05);
};
}
public function showSpinText(_arg1:int):void{
if (_arg1 == 1){
spin180.alpha = 0;
spin180.y = 84;
spin180.gotoAndPlay(1);
stage.addChild(spin180);
spin180.addEventListener(Event.ENTER_FRAME, handleSpinningText);
} else {
if (_arg1 == 2){
spin360.alpha = 0;
spin360.y = 84;
spin360.gotoAndPlay(1);
stage.addChild(spin360);
spin360.addEventListener(Event.ENTER_FRAME, handleSpinningText);
};
};
}
public function newLiverySelected():void{
liveryPhotoAnim.visible = false;
liveryPhotoAnim.gotoAndStop(1);
stage.addChild(wellDoneText);
wellDoneText.addEventListener(Event.ENTER_FRAME, fadeup_wellDoneText_afterLiverySelected);
}
private function resetButton_rollOut(_arg1:Event):void{
resetRollOver.visible = false;
}
private function pauseButton_pressed(_arg1:Event):void{
soundHandler.play_buttonClick();
if (gameController == null){
gameController = main.getInitObj().getGameController();
};
gameController.togglePause();
}
private function retryButton_complete_pressed(_arg1:MouseEvent):void{
soundHandler.play_buttonClick();
soundHandler.fadeIn_mod2Init();
soundHandler.stop_fireworks();
killButton(retryButton_complete, retryButton_complete_pressed);
killButton(levelSelectButton_complete, levelSelectButton_complete_pressed);
main.getInitObj().getAttract().stopFlagForTheHud();
callBack = gameController.retryLevel;
wellDoneText.addEventListener(Event.ENTER_FRAME, fadedown_wellDoneText);
}
public function disablePauseButton():void{
pauseButton_kill();
resetButton_kill();
}
private function levelFailed_init():void{
initButton(retryButton_fail, retryButton_fail_pressed);
initButton(levelSelectButton_fail, levelSelectButton_fail_pressed);
}
private function liveryButton_init():void{
initButton(liveryButton, liveryButton_pressed);
}
private function fadeup_wellDoneText_afterLiverySelected(_arg1:Event):void{
if (wellDoneText.alpha >= 1){
wellDoneText.alpha = 1;
wellDoneText.removeEventListener(Event.ENTER_FRAME, fadeup_wellDoneText_afterLiverySelected);
} else {
wellDoneText.alpha = (wellDoneText.alpha + 0.1);
};
}
private function levelSelectButton_complete_pressed(_arg1:MouseEvent):void{
soundHandler.play_buttonClick();
soundHandler.stop_fireworks();
killButton(retryButton_complete, retryButton_complete_pressed);
killButton(levelSelectButton_complete, levelSelectButton_complete_pressed);
main.getInitObj().getAttract().stopFlagForTheHud();
callBack = gameController.selectLevel;
wellDoneText.addEventListener(Event.ENTER_FRAME, fadedown_wellDoneText);
}
public function levelComplete():void{
if (gameController == null){
gameController = main.getInitObj().getGameController();
};
wellDoneText.alpha = 0;
main.getInitObj().getAttract().createFlagForTheHud(flagHolder_wellDone);
wellDoneText["score"].text = (gameController.scorePercentage + "%");
if (gameController.scorePercentage == 100){
wellDoneText["fireworks"].gotoAndPlay(1);
wellDoneText["fireworks"].visible = true;
soundHandler.play_fireworks();
} else {
wellDoneText["fireworks"].gotoAndStop(1);
wellDoneText["fireworks"].visible = false;
};
stage.addChild(wellDoneText);
levelComplete_init();
soundHandler.fadeOut_mod2Init();
wellDoneText.addEventListener(Event.ENTER_FRAME, fadeup_wellDoneText);
}
private function fadeup_wellDoneText(_arg1:Event):void{
if (wellDoneText.alpha >= 1){
wellDoneText.alpha = 1;
wellDoneText.removeEventListener(Event.ENTER_FRAME, fadeup_wellDoneText);
photoInit();
} else {
wellDoneText.alpha = (wellDoneText.alpha + 0.1);
};
}
public function levelFailed():void{
if (gameController == null){
gameController = main.getInitObj().getGameController();
};
levelFailedText.alpha = 0;
levelFailedText["score"].text = (gameController.scorePercentage + "%");
main.getInitObj().getAttract().createFlagForTheHud(flagHolder_fail);
stage.addChild(levelFailedText);
levelFailed_init();
gameController.getPlayer().reduceEngineVolume(0);
soundHandler.fadeOut_mod2Init();
levelFailedText.addEventListener(Event.ENTER_FRAME, fadeup_levelFailedText);
}
private function fadeInPhoto(_arg1:Event):void{
if (photoHolder.alpha >= 1){
photoHolder.alpha = 1;
photoHolder.removeEventListener(Event.ENTER_FRAME, fadeInPhoto);
} else {
photoHolder.alpha = (photoHolder.alpha + 0.01);
};
}
public function houseKeeping():void{
if (targetScore.parent != null){
stage.removeChild(targetScore);
};
}
private function showGameCompleteMessage():void{
var _local1:int = main.getInitObj().getLevelData().getPlayersTotalPercentages();
if (_local1 < (100 * 25)){
tryAndGetTween.gotoAndPlay(1);
tryAndGetTween.addEventListener(Event.ENTER_FRAME, tryAndGetTween_waiting);
} else {
omgTextTween.gotoAndPlay(1);
omgTextTween.addEventListener(Event.ENTER_FRAME, omgTextTween_waiting);
};
}
}
}//package Classes
Section 123
//HUD_controlPanelMC (Classes.HUD_controlPanelMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class HUD_controlPanelMC extends SpriteAsset {
public var description:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var spilLogo:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var colourButtons:DisplayObject;
public var leftRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var muteRollOver:DisplayObject;
public var reflection:DisplayObject;
public var startButton:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var scroller:DisplayObject;
public var wheel3:DisplayObject;
public var hitAreaMC:DisplayObject;
public var padLock:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var pauseGhosted:DisplayObject;
public var par:DisplayObject;
public var muteButton:DisplayObject;
public var pauseButton:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var cardHolder:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock14:DisplayObject;
public var padlock15:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock16:DisplayObject;
public var weightStat:DisplayObject;
public var button17:DisplayObject;
public var button21:DisplayObject;
public var button22:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var button20:DisplayObject;
public var glassCenter:DisplayObject;
public var backButton:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock23:DisplayObject;
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var padlock22:DisplayObject;
public var pauseRollOver:DisplayObject;
public var truckRamp:DisplayObject;
public var resetGhosted:DisplayObject;
public var rightRollOver:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var selectButton:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var resetRollOver:DisplayObject;
public var resetButton:DisplayObject;
public var topSpeedStat:DisplayObject;
public var flag:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock6:DisplayObject;
public var linkButton:DisplayObject;
public var padlock2:DisplayObject;
public var best:DisplayObject;
public var wireFrame:DisplayObject;
public var star12:DisplayObject;
public var star15:DisplayObject;
}
}//package Classes
Section 124
//HUD_gameCompleteTextMC (Classes.HUD_gameCompleteTextMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class HUD_gameCompleteTextMC extends SpriteAsset {
public var description:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var spilLogo:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var colourButtons:DisplayObject;
public var leftRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var muteRollOver:DisplayObject;
public var reflection:DisplayObject;
public var startButton:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var scroller:DisplayObject;
public var wheel3:DisplayObject;
public var hitAreaMC:DisplayObject;
public var padLock:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var pauseGhosted:DisplayObject;
public var par:DisplayObject;
public var muteButton:DisplayObject;
public var pauseButton:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var cardHolder:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock14:DisplayObject;
public var padlock15:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock16:DisplayObject;
public var weightStat:DisplayObject;
public var button17:DisplayObject;
public var button21:DisplayObject;
public var button22:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var button20:DisplayObject;
public var tryAndGetTween:DisplayObject;
public var backButton:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock23:DisplayObject;
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var omgTextTween:DisplayObject;
public var padlock22:DisplayObject;
public var pauseRollOver:DisplayObject;
public var glassCenter:DisplayObject;
public var truckRamp:DisplayObject;
public var resetGhosted:DisplayObject;
public var rightRollOver:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var selectButton:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var resetRollOver:DisplayObject;
public var resetButton:DisplayObject;
public var topSpeedStat:DisplayObject;
public var flag:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock6:DisplayObject;
public var linkButton:DisplayObject;
public var padlock2:DisplayObject;
public var best:DisplayObject;
public var wireFrame:DisplayObject;
public var star12:DisplayObject;
public var star15:DisplayObject;
}
}//package Classes
Section 125
//HUD_levelFailedTextMC (Classes.HUD_levelFailedTextMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class HUD_levelFailedTextMC extends SpriteAsset {
public var description:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var retryButton:DisplayObject;
public var spilLogo:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var colourButtons:DisplayObject;
public var leftRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var star12:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var muteRollOver:DisplayObject;
public var reflection:DisplayObject;
public var startButton:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var scroller:DisplayObject;
public var wheel3:DisplayObject;
public var hitAreaMC:DisplayObject;
public var padLock:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var score:DisplayObject;
public var pauseGhosted:DisplayObject;
public var par:DisplayObject;
public var muteButton:DisplayObject;
public var pauseButton:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var padlock13:DisplayObject;
public var padlock14:DisplayObject;
public var padlock15:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var button17:DisplayObject;
public var cardHolder:DisplayObject;
public var weightStat:DisplayObject;
public var padlock12:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var levelSelectButton:DisplayObject;
public var button23:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var tryAndGetTween:DisplayObject;
public var backButton:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock23:DisplayObject;
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var omgTextTween:DisplayObject;
public var padlock22:DisplayObject;
public var pauseRollOver:DisplayObject;
public var glassCenter:DisplayObject;
public var button22:DisplayObject;
public var truckRamp:DisplayObject;
public var resetGhosted:DisplayObject;
public var rightRollOver:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var selectButton:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var resetRollOver:DisplayObject;
public var resetButton:DisplayObject;
public var topSpeedStat:DisplayObject;
public var flag:DisplayObject;
public var target:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var padlock2:DisplayObject;
public var location:DisplayObject;
public var linkButton:DisplayObject;
public var best:DisplayObject;
public var wireFrame:DisplayObject;
public var star15:DisplayObject;
}
}//package Classes
Section 126
//HUD_spin180MC (Classes.HUD_spin180MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class HUD_spin180MC extends MovieClipAsset {
public var description:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var spilLogo:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var colourButtons:DisplayObject;
public var leftRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var muteRollOver:DisplayObject;
public var reflection:DisplayObject;
public var startButton:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var scroller:DisplayObject;
public var wheel3:DisplayObject;
public var hitAreaMC:DisplayObject;
public var padLock:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var pauseGhosted:DisplayObject;
public var par:DisplayObject;
public var muteButton:DisplayObject;
public var pauseButton:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var cardHolder:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var padlock13:DisplayObject;
public var padlock14:DisplayObject;
public var padlock15:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var button17:DisplayObject;
public var padlock16:DisplayObject;
public var weightStat:DisplayObject;
public var padlock12:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var button22:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var tryAndGetTween:DisplayObject;
public var backButton:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock23:DisplayObject;
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var omgTextTween:DisplayObject;
public var padlock22:DisplayObject;
public var pauseRollOver:DisplayObject;
public var glassCenter:DisplayObject;
public var truckRamp:DisplayObject;
public var resetGhosted:DisplayObject;
public var rightRollOver:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var selectButton:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var resetRollOver:DisplayObject;
public var resetButton:DisplayObject;
public var topSpeedStat:DisplayObject;
public var flag:DisplayObject;
public var target:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock6:DisplayObject;
public var linkButton:DisplayObject;
public var padlock2:DisplayObject;
public var best:DisplayObject;
public var wireFrame:DisplayObject;
public var star12:DisplayObject;
public var star15:DisplayObject;
}
}//package Classes
Section 127
//HUD_spin360MC (Classes.HUD_spin360MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class HUD_spin360MC extends MovieClipAsset {
public var description:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var retryButton:DisplayObject;
public var spilLogo:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var colourButtons:DisplayObject;
public var leftRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var muteRollOver:DisplayObject;
public var reflection:DisplayObject;
public var photo:DisplayObject;
public var startButton:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var scroller:DisplayObject;
public var wheel3:DisplayObject;
public var hitAreaMC:DisplayObject;
public var padLock:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var liveryPhotoAnim:DisplayObject;
public var photoHolder:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var score:DisplayObject;
public var pauseGhosted:DisplayObject;
public var par:DisplayObject;
public var muteButton:DisplayObject;
public var pauseButton:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock15:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var cardHolder:DisplayObject;
public var weightStat:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var levelSelectButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var tryAndGetTween:DisplayObject;
public var backButton:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock23:DisplayObject;
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var omgTextTween:DisplayObject;
public var padlock22:DisplayObject;
public var pauseRollOver:DisplayObject;
public var glassCenter:DisplayObject;
public var button22:DisplayObject;
public var fireworks:DisplayObject;
public var truckRamp:DisplayObject;
public var resetGhosted:DisplayObject;
public var rightRollOver:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var liveryButton:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var button7:DisplayObject;
public var selectButton:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var resetRollOver:DisplayObject;
public var resetButton:DisplayObject;
public var photoAnim:DisplayObject;
public var topSpeedStat:DisplayObject;
public var flag:DisplayObject;
public var target:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock6:DisplayObject;
public var linkButton:DisplayObject;
public var padlock2:DisplayObject;
public var best:DisplayObject;
public var wireFrame:DisplayObject;
public var star12:DisplayObject;
public var star15:DisplayObject;
public var dateText:DisplayObject;
}
}//package Classes
Section 128
//HUD_targetMC (Classes.HUD_targetMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class HUD_targetMC extends SpriteAsset {
public var description:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var spilLogo:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var colourButtons:DisplayObject;
public var leftRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var muteRollOver:DisplayObject;
public var reflection:DisplayObject;
public var startButton:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var scroller:DisplayObject;
public var wheel3:DisplayObject;
public var hitAreaMC:DisplayObject;
public var padLock:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var pauseGhosted:DisplayObject;
public var par:DisplayObject;
public var muteButton:DisplayObject;
public var pauseButton:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var cardHolder:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var padlock13:DisplayObject;
public var padlock14:DisplayObject;
public var padlock15:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var button17:DisplayObject;
public var padlock16:DisplayObject;
public var weightStat:DisplayObject;
public var padlock12:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var button22:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var tryAndGetTween:DisplayObject;
public var backButton:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock23:DisplayObject;
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var omgTextTween:DisplayObject;
public var padlock22:DisplayObject;
public var pauseRollOver:DisplayObject;
public var glassCenter:DisplayObject;
public var truckRamp:DisplayObject;
public var resetGhosted:DisplayObject;
public var rightRollOver:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var selectButton:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var resetRollOver:DisplayObject;
public var resetButton:DisplayObject;
public var topSpeedStat:DisplayObject;
public var flag:DisplayObject;
public var target:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock6:DisplayObject;
public var linkButton:DisplayObject;
public var padlock2:DisplayObject;
public var best:DisplayObject;
public var wireFrame:DisplayObject;
public var star12:DisplayObject;
public var star15:DisplayObject;
}
}//package Classes
Section 129
//HUD_wellDoneTextMC (Classes.HUD_wellDoneTextMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class HUD_wellDoneTextMC extends SpriteAsset {
public var description:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var retryButton:DisplayObject;
public var spilLogo:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var colourButtons:DisplayObject;
public var leftRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var muteRollOver:DisplayObject;
public var reflection:DisplayObject;
public var photo:DisplayObject;
public var startButton:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var scroller:DisplayObject;
public var wheel3:DisplayObject;
public var hitAreaMC:DisplayObject;
public var padLock:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var liveryPhotoAnim:DisplayObject;
public var photoHolder:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var score:DisplayObject;
public var pauseGhosted:DisplayObject;
public var par:DisplayObject;
public var muteButton:DisplayObject;
public var pauseButton:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock15:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var cardHolder:DisplayObject;
public var weightStat:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var levelSelectButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var tryAndGetTween:DisplayObject;
public var backButton:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock23:DisplayObject;
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var omgTextTween:DisplayObject;
public var padlock22:DisplayObject;
public var pauseRollOver:DisplayObject;
public var glassCenter:DisplayObject;
public var button22:DisplayObject;
public var fireworks:DisplayObject;
public var truckRamp:DisplayObject;
public var resetGhosted:DisplayObject;
public var rightRollOver:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var liveryButton:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var button7:DisplayObject;
public var selectButton:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var resetRollOver:DisplayObject;
public var resetButton:DisplayObject;
public var photoAnim:DisplayObject;
public var topSpeedStat:DisplayObject;
public var flag:DisplayObject;
public var target:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock6:DisplayObject;
public var linkButton:DisplayObject;
public var padlock2:DisplayObject;
public var best:DisplayObject;
public var wireFrame:DisplayObject;
public var star12:DisplayObject;
public var star15:DisplayObject;
public var dateText:DisplayObject;
}
}//package Classes
Section 130
//Init (Classes.Init)
package Classes {
import flash.display.*;
import flash.events.*;
import com.gamingyourway.Utils.*;
public class Init {
private var attract:Attract;
private var levelData:LevelData;
private var cookies:Cookies;
private var playField:PlayField;
private var gameController:GameController;
private var mainMovie:DisplayObject;
private var main:Main;
private var soundHandler:SoundHandler;
private var stage:Stage;
public function Init(){
main = Main.getInstance();
mainMovie = main.getMainMovie();
stage = main.getStage();
Key.initialize(stage);
soundHandler = new SoundHandler();
cookies = new Cookies();
levelData = new LevelData(cookies);
mainMovie.addEventListener(Event.ENTER_FRAME, waitingForCookiesToLoad);
}
public function getAttract():Attract{
return (attract);
}
public function waitingForCookiesToLoad(_arg1:Event):void{
if (cookies.cookiesLoadedFlag == true){
mainMovie.removeEventListener(Event.ENTER_FRAME, waitingForCookiesToLoad);
soundHandler.setVolume(cookies.volume);
playField = new PlayField();
gameController = new GameController();
attract = new Attract();
};
}
public function getLevelData():LevelData{
return (levelData);
}
public function getCookies():Cookies{
return (cookies);
}
public function getGameController():GameController{
return (gameController);
}
public function toString():String{
return ("Init");
}
public function getPlayField():PlayField{
return (playField);
}
public function getSoundHandler():SoundHandler{
return (soundHandler);
}
}
}//package Classes
Section 131
//LevelData (Classes.LevelData)
package Classes {
public class LevelData {
private var liveryLevels:Array;
private var levelData_location:Array;
private var collectedLiveryLevels:Array;
private var cookies:Cookies;
private var playersBest:Array;
private var main:Main;
private var parData:Array;
public function LevelData(_arg1:Cookies){
levelData_location = new Array("America", "France", "Japan", "UK", "Germany");
parData = new Array(80, 70, 70, 80, 80, 65, 70, 75, 60, 80, 80, 60, 70, 80, 85, 85, 85, 70, 70, 80, 80, 90, 85, 90, 80);
playersBest = new Array(0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0);
liveryLevels = new Array(false, true, false, false, false, false, false, true, false, false, false, false, false, false, false, false, true, false, false, false, false, false, false, false, false);
collectedLiveryLevels = new Array(false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false, false);
super();
main = Main.getInstance();
cookies = _arg1;
playersBest = cookies.playersBest;
}
public function getPlayersBest(_arg1:Number):Number{
return (playersBest[_arg1]);
}
public function getLevelLocation(_arg1:Number):String{
return (levelData_location[_arg1]);
}
public function setPlayerBest(_arg1:Number, _arg2:Number):void{
var _local3:Number = playersBest[_arg1];
if (_arg2 > _local3){
playersBest[_arg1] = _arg2;
cookies.playersBest = playersBest;
cookies.saveAll();
};
}
public function getPlayersTotalPercentages():int{
var _local1:int;
var _local2 = -1;
var _local3:int = playersBest.length;
while (++_local2 != _local3) {
_local1 = (_local1 + playersBest[_local2]);
};
return (_local1);
}
public function liveryAlreadyCollectedCheck(_arg1:int):Boolean{
var _local2:Boolean = collectedLiveryLevels[(_arg1 - 1)];
collectedLiveryLevels[(_arg1 - 1)] = true;
return (_local2);
}
public function isThisALiveryLevel(_arg1:int):Boolean{
return (liveryLevels[(_arg1 - 1)]);
}
public function getParData(_arg1:Number):Number{
return (parData[_arg1]);
}
}
}//package Classes
Section 132
//LevelPlotter (Classes.LevelPlotter)
package Classes {
import flash.display.*;
public class LevelPlotter {
private var main:Main;
private var backgroundMC:Class;
private var physics:Physics;
private var level:int;
private var backgroundImage:MovieClip;
private var stackData:Array;
private var stackDataHandler:StackData;
private var currentStackData:Array;
private var player:Player;
public var numberOfCarsInStack:int;
private var background:Sprite;
public var endMostCarXpos:int;
private var mainMovie:DisplayObject;
private var gameController:GameController;
private var stage:Stage;
public function LevelPlotter(){
backgroundMC = LevelPlotter_backgroundMC;
super();
main = Main.getInstance();
mainMovie = main.getMainMovie();
stage = main.getStage();
gameController = main.getInitObj().getGameController();
stackDataHandler = new StackData();
background = main.getInitObj().getPlayField().background;
background.cacheAsBitmap = true;
backgroundImage = new backgroundMC();
backgroundImage.gotoAndStop(1);
background.addChild(backgroundImage);
}
public function getCameraPosition():int{
return (stackDataHandler.getCameraPosition(level));
}
public function init():void{
var _local2:Array;
var _local3:Object;
if (player == null){
player = gameController.getPlayer();
physics = gameController.getPhysics();
};
level = gameController.level;
stackData = stackDataHandler.getStackData(level);
numberOfCarsInStack = stackData.length;
currentStackData = new Array();
var _local1:Object = new Object();
var _local4 = -1;
var _local5:int = numberOfCarsInStack;
while (++_local4 != _local5) {
_local2 = stackData[_local4];
_local1 = new Object();
_local1.carID = _local2[0];
_local1.carMCID = _local4;
_local1.carObject = player.getCarDataComplete(_local1.carID);
_local1.xpos = _local2[1];
_local1.ypos = _local2[2];
_local1.rotation = _local2[3];
_local1.frame = _local2[4];
currentStackData.push(_local1);
};
_local4 = -1;
while (++_local4 != _local5) {
physics.createNPCCar(currentStackData[_local4]);
};
physics.runMainloop();
endMostCarXpos = 0;
_local4 = -1;
while (++_local4 != _local5) {
_local2 = stackData[_local4];
if (_local2[1] > endMostCarXpos){
endMostCarXpos = _local2[1];
};
};
}
public function setCountry(_arg1:int):void{
backgroundImage.gotoAndStop((_arg1 + 1));
}
public function scrollRight():void{
var _local1:Number = 0.2;
if ((background.x - _local1) > -40){
background.x = (background.x - _local1);
} else {
background.x = -40;
};
}
public function toString():String{
return ("LevelPlotter");
}
public function scrollLeft():void{
var _local1:Number = 0.2;
if ((background.x + _local1) < 0){
background.x = (background.x + _local1);
} else {
background.x = 0;
};
}
}
}//package Classes
Section 133
//LevelPlotter_backgroundMC (Classes.LevelPlotter_backgroundMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class LevelPlotter_backgroundMC extends MovieClipAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var star21:DisplayObject;
public var linkButton:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var padlock22:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock2:DisplayObject;
public var padlock6:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock15:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 134
//Master (Classes.Master)
package Classes {
import flash.display.*;
import flash.events.*;
import Classes.Particles.*;
import flash.utils.*;
public class Master {
private var period:Number;
private var sleepTime:int;// = 0
private var physics:Physics;
private var afterTime:int;// = 0
private var timeDiff:int;// = 0
private var overSleepTime:int;// = 0
private var player:Player;
private var particleHandler:ParticleHandler;
private var beforeTime:int;// = 0
private var frameRate:int;// = 60
private var gameTimer:Timer;
private var excess:int;// = 0
private var mainMovie:DisplayObject;
private var main:Main;
private var gameController:GameController;
private var stage:Stage;
public function Master():void{
main = Main.getInstance();
mainMovie = main.getMainMovie();
stage = main.getStage();
gameController = main.getInitObj().getGameController();
period = (1000 / frameRate);
}
public function houseKeeping():void{
gameTimer.stop();
gameTimer.removeEventListener(TimerEvent.TIMER, mainloop);
}
private function mainloop(_arg1:TimerEvent):void{
beforeTime = getTimer();
overSleepTime = ((beforeTime - afterTime) - sleepTime);
player.mainloop();
physics.mainloop();
particleHandler.mainloop();
afterTime = getTimer();
timeDiff = (afterTime - beforeTime);
sleepTime = ((period - timeDiff) - overSleepTime);
if (sleepTime <= 0){
excess = (excess - sleepTime);
sleepTime = 2;
};
gameTimer.reset();
gameTimer.delay = sleepTime;
gameTimer.start();
if (excess > period){
excess = (excess - period);
};
}
public function start():void{
if (player == null){
player = gameController.getPlayer();
physics = gameController.getPhysics();
particleHandler = gameController.getParticleHandler();
};
beforeTime = getTimer();
afterTime = getTimer();
timeDiff = (afterTime - beforeTime);
sleepTime = ((period - timeDiff) - overSleepTime);
overSleepTime = ((beforeTime - afterTime) - sleepTime);
gameTimer = new Timer(period, 1);
gameTimer.addEventListener(TimerEvent.TIMER, mainloop);
gameTimer.start();
}
public function resume():void{
beforeTime = getTimer();
afterTime = getTimer();
timeDiff = (afterTime - beforeTime);
sleepTime = ((period - timeDiff) - overSleepTime);
overSleepTime = ((beforeTime - afterTime) - sleepTime);
gameTimer = new Timer(period, 1);
gameTimer.addEventListener(TimerEvent.TIMER, mainloop);
gameTimer.start();
}
public function toString():String{
return ("Master");
}
}
}//package Classes
Section 135
//Physics (Classes.Physics)
package Classes {
import flash.display.*;
import flash.geom.*;
import Classes.Particles.*;
import Box2D.Dynamics.*;
import Box2D.Dynamics.Joints.*;
import Box2D.Common.Math.*;
import Box2D.Collision.Shapes.*;
import com.gamingyourway.Physics.*;
public class Physics {
private var playerCar_frontWheel_body:b2Body;
private var playerChassis:Sprite;
private var npcContactListeners:Array;
private var player:Player;
private var cameraStopPosition:int;
private var carCoords:CarCoords;
private var playerCar_frontWheel_PrismaticJoint:b2PrismaticJoint;
private var playField:Sprite;
private var nudgeFlag:Boolean;
private var frontShock_body:b2Body;
private var mainFunc:Function;
private var playerCar_body:b2Body;
private var playerCar_frontWheel_DistanceJoint:b2DistanceJoint;
private var soundHandler:SoundHandler;
private var gameController:GameController;
private var playerCar_rearWheel_DistanceJoint:b2DistanceJoint;
private var newRotation:Number;
private var playerCar_frontWheel_circleDef:b2CircleDef;
private var playerCar_rearWheel_body:b2Body;
private var physScale:Number;// = 20
private var debugFlag:Boolean;// = false
private var playerCar_frontWheel_shape:b2Shape;
private var rampHitAreaMC:Sprite;
private var playerCar_rearWheel_shape:b2Shape;
private var waitingToFinishCount:int;
private var radToDeg:Number;// = 57.2957795130823
private var carBodyDensity:Number;// = 30
private var previousScrollXPos:Number;
private var dapiHolder:Sprite;
private var truck_body:b2Body;
private var world:b2World;
private var maxTorque:Number;// = 400
private var shocksDensity:Number;// = 10
private var b2dWrapper:B2Dwrapper;
private var playerCar_rearWheel_PrismaticJoint:b2PrismaticJoint;
private var numberOfDestroyedCars:int;
private var main:Main;
private var oldRotation:Number;
private var spinCnt:int;
private var rampCollisionFlag:Boolean;
private var rampCoords:RampCoords;
private var b2VecToPoint:Point;
private var motorSpeed:Number;
private var playerContactListener:ContactListener;
private var playerCar_rearWheel_circleDef:b2CircleDef;
private var playerCrashedSpeed:Number;
private var playerCar_frontWheel_RevoluteJoint:b2RevoluteJoint;
private var snapShotCnt:int;
private var totalRotation:Number;
private var rearShock_body:b2Body;
private var particleHandler:ParticleHandler;
private var playerCar_rearWheel_RevoluteJoint:b2RevoluteJoint;
private var mainMovie:DisplayObject;
public var carCollectedFlag:Boolean;
private var stage:Stage;
public function Physics(){
main = Main.getInstance();
mainMovie = main.getMainMovie();
stage = main.getStage();
gameController = main.getInitObj().getGameController();
soundHandler = main.getInitObj().getSoundHandler();
playField = main.getInitObj().getPlayField().sprites;
carCoords = new CarCoords();
rampCoords = new RampCoords();
b2dWrapper = new B2Dwrapper();
b2dWrapper.physicsScale = physScale;
b2dWrapper.timeStepValue = (1 / 30);
b2dWrapper.iterationsValue = 80;
b2dWrapper.createWorld(new Rectangle(0, -480, (0x0A00 * 2), (480 * 2)), new Point(0, 10), true);
b2dWrapper.createGround(new Point((0x0A00 * 2), 428), (0x0A00 * 2), 1, 1);
playerContactListener = new ContactListener();
b2dWrapper.createContactListener((playerContactListener as b2ContactListener));
if (debugFlag == true){
dapiHolder = new Sprite();
stage.addChild(dapiHolder);
b2dWrapper.toggleDebug(dapiHolder);
};
npcContactListeners = new Array();
mainFunc = nop;
}
private function createDistanceJoint(_arg1:b2Body, _arg2:Number, _arg3:b2Body, _arg4:Boolean=false):b2DistanceJoint{
var _local5:b2DistanceJointDef = new b2DistanceJointDef();
var _local6:b2Vec2 = _arg1.GetWorldCenter().Copy();
_local5.Initialize(_arg1, _arg3, _arg1.GetWorldCenter(), _arg3.GetWorldCenter());
_local5.localAnchor2.x = (_arg2 / physScale);
_local5.localAnchor2.y = (_arg3.GetWorldCenter().y + (8 / physScale));
_local5.collideConnected = true;
_local5.length = (8 / physScale);
return (b2dWrapper.createDistanceJoint(_local5));
}
public function startDriving(_arg1:Number):void{
playerCar_frontWheel_body.m_linearDamping = (1 - (186 / _arg1));
playerCar_rearWheel_body.m_linearDamping = (1 - (186 / _arg1));
playerCar_body.m_linearDamping = (1 - (186 / _arg1));
playerCar_body.WakeUp();
motorSpeed = (_arg1 * 300);
if (motorSpeed <= 500){
motorSpeed = 500;
};
var _local2:Number = (_arg1 / 185);
if (_local2 < 0.3){
_local2 = 0.3;
} else {
if (_local2 > 0.8){
_local2 = 0.8;
};
};
playerCar_frontWheel_shape.m_friction = _local2;
playerCar_rearWheel_shape.m_friction = _local2;
b2dWrapper.refilter(playerCar_frontWheel_shape);
b2dWrapper.refilter(playerCar_rearWheel_shape);
playerCar_body.ApplyImpulse(new b2Vec2((_arg1 * 12), 0), playerCar_body.GetWorldCenter());
oldRotation = (newRotation = playerChassis.rotation);
totalRotation = 0;
rampHitAreaMC = gameController.getRampHandler().getHitAreaMC();
rampCollisionFlag = false;
mainFunc = mainloop_driving;
}
public function init():void{
if (player == null){
player = gameController.getPlayer();
particleHandler = gameController.getParticleHandler();
};
numberOfDestroyedCars = 0;
waitingToFinishCount = 0;
spinCnt = 0;
snapShotCnt = 0;
carCollectedFlag = false;
cameraStopPosition = gameController.getLevelPlotter().getCameraPosition();
cameraStopPosition = (cameraStopPosition * -1);
var _local1:int = player.currentCarNumber;
playerChassis = player.getCurrentChassis();
playerChassis.visible = false;
playField.addChild(playerChassis);
createPlayerCar(_local1);
playerChassis.x = playerCar_body.m_userData.x;
playerChassis.y = playerCar_body.m_userData.y;
createTruckParts();
player.ensureTruckOnTopDepth();
nudgeFlag = false;
mainFunc = mainloop_fallingIntoPlace;
}
private function createShocks(_arg1:Point, _arg2:Point, _arg3:Rectangle, _arg4:Sprite):b2Body{
var _local5:Point = new Point((_arg2.x + _arg1.x), (_arg2.y + _arg1.y));
var _local6:b2PolygonDef = b2dWrapper.createPolygon(_arg3);
var _local7:b2BodyDef = new b2BodyDef();
_local7.userData = _arg4;
_local7.userData.x = _local5.x;
_local7.userData.y = _local5.y;
_local7.userData.width = Math.round(_arg3.width);
_local7.userData.height = Math.round(_arg3.height);
_local7.userData.name = "Wheel";
playField.addChild(_local7.userData);
b2dWrapper.position(_local7, _local5);
_local6.density = shocksDensity;
_local6.filter.groupIndex = -1;
var _local8:b2Body = b2dWrapper.addToWorld(_local7);
_local8.CreateShape(_local6);
_local8.SetMassFromShapes();
return (_local8);
}
public function startWheelSpinning():void{
b2dWrapper.destroyBody(truck_body);
playerCar_frontWheel_body.m_linearDamping = 1;
playerCar_rearWheel_body.m_linearDamping = 1;
playerCar_body.m_linearDamping = 1;
playerCar_frontWheel_body.m_linearVelocity = new b2Vec2(0, 0);
playerCar_rearWheel_body.m_linearVelocity = new b2Vec2(0, 0);
playerCar_body.m_linearVelocity = new b2Vec2(0, 0);
var _local1:b2Vec2 = new b2Vec2(0, 0);
playerCar_frontWheel_body.m_force = _local1;
playerCar_rearWheel_body.m_force = _local1;
playerCar_body.m_force = _local1;
playerCar_frontWheel_RevoluteJoint.EnableMotor(true);
playerCar_rearWheel_RevoluteJoint.EnableMotor(true);
playerCar_body.PutToSleep();
playerCar_frontWheel_body.WakeUp();
playerCar_rearWheel_body.WakeUp();
playerCar_frontWheel_shape.m_friction = 0;
playerCar_rearWheel_shape.m_friction = 0;
b2dWrapper.refilter(playerCar_frontWheel_shape);
b2dWrapper.refilter(playerCar_rearWheel_shape);
mainFunc = mainloop_wheelSpinning;
}
public function getRearWheelPos():Point{
var _local1:Point = new Point(playerCar_rearWheel_body.m_userData.x, playerCar_rearWheel_body.m_userData.y);
return (_local1);
}
private function createRamp(_arg1:int):void{
var _local2:Array = rampCoords.getPolyData(_arg1);
var _local3:int = _local2.length;
var _local4:b2BodyDef = new b2BodyDef();
var _local5:Point = gameController.getRampHandler().getRampPosition();
gameController.getRampHandler().getRampPosition().x = (_local5.x - 1);
_local5.y = (_local5.y + 1);
b2dWrapper.position(_local4, _local5);
var _local6:b2Body = b2dWrapper.addToWorld(_local4);
var _local7:Point = new Point();
var _local8:Point = new Point();
var _local9:Point = new Point();
var _local10:b2PolygonDef = new b2PolygonDef();
var _local11 = -1;
while (++_local11 != _local3) {
_local7.x = _local2[_local11][0];
_local7.y = _local2[_local11][1];
_local8.x = _local2[_local11][2];
_local8.y = _local2[_local11][3];
_local9.x = _local2[_local11][4];
_local9.y = _local2[_local11][5];
_local10 = b2dWrapper.createTriangle(_local7, _local8, _local9);
_local10.friction = 0;
_local10.restitution = 0;
_local6.CreateShape(_local10);
};
_local6.AllowSleeping(true);
_local6.SetMassFromShapes();
}
public function createNPCCar(_arg1:Object):Object{
var _local2:Object = new Object();
var _local3:Array = carCoords.getPolyData_stack(_arg1.carID);
var _local4:b2PolygonDef = new b2PolygonDef();
_local4.vertexCount = (_local3[0].length / 4);
carBodyDensity = _arg1.carObject.weight;
var _local5:b2BodyDef = new b2BodyDef();
_local5.userData = _arg1.carObject.carBody;
_local5.userData.gotoAndStop(_arg1.frame);
_local5.userData.graphics.lineStyle(_arg1.carMCID);
var _local6:Point = new Point(_arg1.xpos, _arg1.ypos);
_local5.userData.x = _local6.x;
_local5.userData.y = _local6.y;
b2dWrapper.position(_local5, _local6);
_local2.car_body = b2dWrapper.addToWorld(_local5);
var _local7 = -1;
var _local8:int;
var _local9:Rectangle = new Rectangle();
var _local10:Number = _local4.vertexCount;
while (++_local7 != _local10) {
_local9.x = _local3[0][_local8];
_local9.y = _local3[0][(_local8 + 1)];
_local9.width = _local3[0][(_local8 + 2)];
_local9.height = _local3[0][(_local8 + 3)];
_local4 = b2dWrapper.createPolygon(_local9);
_local4.density = carBodyDensity;
_local4.restitution = 0.3;
_local2.car_body.CreateShape(_local4);
_local8 = (_local8 + 4);
};
var _local11:Point = new Point(_local3[1][0], _local3[1][1]);
var _local12:Number = _local3[1][2];
var _local13:b2CircleDef = b2dWrapper.createCircle(_local11, _local12);
_local13.localPosition.x = (_local13.localPosition.x + ((_local11.x + (_local12 / 2)) / physScale));
_local13.localPosition.y = (_local13.localPosition.y + ((_local11.y + (_local12 / 2)) / physScale));
_local2.car_body.CreateShape(_local13);
_local11 = new Point(_local3[1][3], _local3[1][4]);
_local12 = _local3[1][5];
_local13 = b2dWrapper.createCircle(_local11, _local12);
_local13.localPosition.x = (_local13.localPosition.x + ((_local11.x + (_local12 / 2)) / physScale));
_local13.localPosition.y = (_local13.localPosition.y + ((_local11.y + (_local12 / 2)) / physScale));
_local2.car_body.CreateShape(_local13);
_local2.car_body.SetMassFromShapes();
_local2.car_body.SetXForm(_local2.car_body.GetWorldCenter(), ((_arg1.rotation / 180) * Math.PI));
_local2.car_body.AllowSleeping(true);
_local2.car_body.PutToSleep();
playField.addChild(_arg1.carObject.carBody);
return (_local2);
}
public function rampSelectStart():void{
mainFunc = nop;
}
private function mainloop_driving():void{
var _local2:Number;
var _local3:Number;
b2dWrapper.mainloop();
playerChassis.x = playerCar_body.m_userData.x;
playerChassis.y = playerCar_body.m_userData.y;
playerChassis.rotation = playerCar_body.m_userData.rotation;
playerCar_frontWheel_RevoluteJoint.SetMotorSpeed(motorSpeed);
playerCar_rearWheel_RevoluteJoint.SetMotorSpeed(motorSpeed);
playerCar_frontWheel_body.m_userData.rotation = (playerCar_frontWheel_body.m_userData.rotation + 5);
playerCar_rearWheel_body.m_userData.rotation = (playerCar_rearWheel_body.m_userData.rotation + 5);
newRotation = Math.abs(playerChassis.rotation);
var _local1:Number = Math.abs((newRotation - oldRotation));
totalRotation = (totalRotation + _local1);
if (totalRotation > 180){
totalRotation = (totalRotation - 180);
spinCnt++;
gameController.getHUD().showSpinText(spinCnt);
};
oldRotation = newRotation;
if (motorSpeed > 0){
previousScrollXPos = playField.x;
_local2 = 0;
playerCrashedSpeed = playerCar_body.GetLinearVelocity().x;
player.updateSpeedo(playerCrashedSpeed);
_local3 = ((playField.x - (((-(physScale) * playerCar_body.GetWorldCenter().x) + 320) - (playerCar_body.GetLinearVelocity().x * 3))) / 3);
if (_local3 > 0){
playField.x = (playField.x - _local3);
_local2 = (previousScrollXPos - playField.x);
player.scrollGame(_local2);
previousScrollXPos = playField.x;
playerCar_body.m_userData.reflection.x = (playerCar_body.m_userData.reflection.x - (_local2 * 0.5));
if (playerCar_body.m_userData.reflection.x < -200){
playerCar_body.m_userData.reflection.x = (playerCar_body.m_userData.reflection.x + 200);
};
if (debugFlag == true){
dapiHolder.x = (dapiHolder.x - ((dapiHolder.x - (((-(physScale) * playerCar_body.GetWorldCenter().x) + 320) - (playerCar_body.GetLinearVelocity().x * 3))) / 3));
};
};
if (rampCollisionFlag == true){
if (_local2 <= 2){
if (++waitingToFinishCount >= 60){
mainFunc = nop;
gameController.levelFinished(numberOfDestroyedCars);
return;
};
};
};
} else {
if (++snapShotCnt == 5){
gameController.getTransition().takeSnapShot(playerCar_body.GetPosition(), physScale);
};
if (playerCrashedSpeed > 5){
playerCrashedSpeed = (playerCrashedSpeed - 5);
} else {
playerCrashedSpeed = 0;
};
player.reduceEngineVolume(playerCrashedSpeed);
if (b2dWrapper.areOverHalfSleeping() == true){
if (++waitingToFinishCount >= 160){
mainFunc = nop;
gameController.levelFinished(numberOfDestroyedCars);
return;
};
} else {
if (++waitingToFinishCount >= 240){
mainFunc = nop;
gameController.levelFinished(numberOfDestroyedCars);
return;
};
};
if (cameraStopPosition < playField.x){
playField.x = (playField.x - 4);
player.scrollGame(4);
waitingToFinishCount--;
};
};
detectCollisions();
}
public function toString():String{
return ("Physics");
}
private function detectCollisions():void{
var _local1:Object;
var _local2:b2Body;
var _local3:b2Body;
var _local4:b2Body;
var _local5:Sprite;
var _local6:Point;
var _local7:Sprite;
var _local8:Point;
if (rampCollisionFlag == false){
if (playerCar_body.m_userData.hitAreaMC.hitTestObject(rampHitAreaMC)){
gameController.disableReset();
rampCollisionFlag = true;
player.killSpeedo();
gameController.getCameraFlashHandler().requestPhotos();
soundHandler.play_crowdcheersmall();
if (playerCar_body.GetMass() > 450){
playerCar_body.ApplyImpulse(new b2Vec2((motorSpeed / 5), -10), playerCar_body.GetWorldCenter());
};
};
};
while (playerContactListener.contactStorage[0]) {
_local1 = playerContactListener.contactStorage.pop();
if (rampCollisionFlag == true){
_local2 = _local1.body1;
_local3 = _local1.body2;
if ((((_local2.m_userData.name == "Wheel")) && ((_local3.m_userData.name == "Wheel")))){
return;
};
if (motorSpeed > 0){
b2dWrapper.destroyJoint(playerCar_frontWheel_RevoluteJoint);
b2dWrapper.destroyJoint(playerCar_rearWheel_RevoluteJoint);
playerCar_frontWheel_PrismaticJoint.m_enableMotor = false;
playerCar_frontWheel_PrismaticJoint.m_motorForce = 0;
playerCar_rearWheel_PrismaticJoint.m_enableMotor = false;
playerCar_rearWheel_PrismaticJoint.m_motorForce = 0;
playerCar_frontWheel_body.m_torque = 0;
playerCar_rearWheel_body.m_torque = 0;
playerCar_frontWheel_body.m_linearDamping = 1;
playerCar_rearWheel_body.m_linearDamping = 1;
playerCar_frontWheel_shape.m_friction = 0.1;
playerCar_frontWheel_shape.m_restitution = 0.5;
playerCar_rearWheel_shape.m_friction = 0.1;
playerCar_rearWheel_shape.m_restitution = 0.5;
playerCar_frontWheel_shape.m_density = 1;
playerCar_rearWheel_shape.m_density = 1;
b2dWrapper.refilter(playerCar_frontWheel_shape);
b2dWrapper.refilter(playerCar_rearWheel_shape);
playerCar_body.m_userData.nextFrame();
playerCar_body.ApplyImpulse(new b2Vec2(60, -((motorSpeed / 9))), playerCar_body.GetWorldCenter());
motorSpeed = 0;
_local5 = playerCar_body.m_userData["glassCenter"];
_local6 = playerCar_body.m_userData.localToGlobal(new Point(_local5.x, _local5.y));
playerCar_body.m_userData.localToGlobal(new Point(_local5.x, _local5.y)).x = (_local6.x + Math.abs(playField.x));
b2VecToPoint = new Point((_local1.contactPoint.x * physScale), (_local1.contactPoint.y * physScale));
particleHandler.createParticles(b2VecToPoint, 16, 30, "wreckage");
if ((((_local2.m_userData.width > 50)) || ((_local3.m_userData.width > 50)))){
particleHandler.createParticles(b2VecToPoint, 12, 10, "spark");
};
particleHandler.createParticles(_local6, 8, 18);
if (_local1.force > 30){
particleHandler.createDust(b2VecToPoint);
};
} else {
if (_local1.force > 20){
if ((((_local2.m_userData.width > 50)) && ((_local3.m_userData.width > 50)))){
b2VecToPoint = new Point((_local1.contactPoint.x * physScale), (_local1.contactPoint.y * physScale));
particleHandler.createParticles(b2VecToPoint, 16, 10, "spark");
particleHandler.createParticles(b2VecToPoint, 8, 10, "wreckage");
};
};
};
_local4 = null;
if (_local2.m_userData.name != "Wheel"){
_local4 = _local2;
} else {
if (_local3.m_userData.name != "Wheel"){
_local4 = _local3;
} else {
continue;
};
};
if (_local1.force < 10){
continue;
};
soundHandler.play_crashSound();
if ((_local4.m_userData.currentFrame & 1)){
_local4.m_userData.nextFrame();
if (_local4.m_userData.currentFrame == 14){
carCollectedFlag = true;
};
_local4.ApplyImpulse(new b2Vec2(20, (_local1.force * 12)), _local4.GetWorldCenter());
_local7 = _local4.m_userData["glassCenter"];
_local8 = _local4.m_userData.localToGlobal(new Point(_local7.x, _local7.y));
_local4.m_userData.localToGlobal(new Point(_local7.x, _local7.y)).x = (_local8.x + Math.abs(playField.x));
particleHandler.createParticles(_local8, 8, 10);
b2VecToPoint = new Point((_local1.contactPoint.x * physScale), (_local1.contactPoint.y * physScale));
particleHandler.createParticles(b2VecToPoint, 16, 5, "wreckage");
particleHandler.createDust(_local8);
numberOfDestroyedCars++;
gameController.getCameraFlashHandler().requestPhotos();
gameController.showPercentageParticles(_local8, numberOfDestroyedCars);
};
} else {
playerContactListener.contactStorage.length = 0;
};
};
}
public function runMainloop():void{
b2dWrapper.mainloop();
}
public function getFrontWheelPos():Point{
var _local1:Point = new Point(playerCar_frontWheel_body.m_userData.x, playerCar_frontWheel_body.m_userData.y);
return (_local1);
}
private function mainloop_wheelSpinning():void{
b2dWrapper.mainloop();
playerChassis.x = playerCar_body.m_userData.x;
playerChassis.y = playerCar_body.m_userData.y;
playerChassis.rotation = playerCar_body.m_userData.rotation;
playerCar_frontWheel_body.m_userData.rotation = (playerCar_frontWheel_body.m_userData.rotation + 5);
playerCar_rearWheel_body.m_userData.rotation = (playerCar_rearWheel_body.m_userData.rotation + 5);
playerCar_frontWheel_RevoluteJoint.SetMotorSpeed(100);
playerCar_rearWheel_RevoluteJoint.SetMotorSpeed(100);
}
private function createWheels(_arg1:Point, _arg2:Point, _arg3:Number, _arg4:Sprite):Object{
var _local5:Point = new Point((((_arg2.x + _arg1.x) + (_arg3 * 0.5)) - 2), (((_arg2.y + _arg1.y) + (_arg3 * 0.5)) + 4));
var _local6:b2CircleDef = b2dWrapper.createCircle(_arg1, _arg3);
var _local7:b2BodyDef = new b2BodyDef();
_local7.userData = _arg4;
_local7.userData.x = _local5.x;
_local7.userData.y = _local5.y;
_local7.userData.name = "Wheel";
playField.addChild(_local7.userData);
b2dWrapper.position(_local7, _local5);
var _local8:b2Body = b2dWrapper.addToWorld(_local7);
var _local9:b2Shape = _local8.CreateShape(_local6);
_local8.SetMassFromShapes();
var _local10:Object = {body:_local8, shape:_local9, shapeDef:_local6};
return (_local10);
}
private function createPlayerCar(_arg1:int):void{
var _local2:Array = carCoords.getPolyData(_arg1);
var _local3:b2PolygonDef = new b2PolygonDef();
_local3.vertexCount = (_local2[0].length / 4);
carBodyDensity = carCoords.getCarWeight(_arg1);
var _local4:b2BodyDef = new b2BodyDef();
_local4.userData = gameController.getPlayer().getCurrentCar();
var _local5:MovieClip = _local4.userData;
var _local6:Point = new Point(212, 220);
_local4.userData.x = _local6.x;
_local4.userData.y = _local6.y;
_local4.userData.name = "Wheel";
b2dWrapper.position(_local4, _local6);
playerCar_body = b2dWrapper.addToWorld(_local4);
var _local7 = -1;
var _local8:int;
var _local9:Rectangle = new Rectangle();
var _local10:Number = _local3.vertexCount;
while (++_local7 != _local10) {
_local9.x = _local2[0][_local8];
_local9.y = _local2[0][(_local8 + 1)];
_local9.width = _local2[0][(_local8 + 2)];
_local9.height = _local2[0][(_local8 + 3)];
_local3 = b2dWrapper.createPolygon(_local9);
_local3.density = carBodyDensity;
playerCar_body.CreateShape(_local3);
_local8 = (_local8 + 4);
};
playerCar_body.SetMassFromShapes();
_local8 = 0;
var _local11:Point = new Point(_local2[2][_local8], _local2[2][(_local8 + 1)]);
rearShock_body = createShocks(_local11, _local6, new Rectangle(0, 0, _local2[2][(_local8 + 2)], _local2[2][(_local8 + 3)]), player.getCurrentShock_rear());
_local8 = (_local8 + 4);
_local11 = new Point(_local2[2][_local8], _local2[2][(_local8 + 1)]);
frontShock_body = createShocks(_local11, _local6, new Rectangle(0, 0, _local2[2][(_local8 + 2)], _local2[2][(_local8 + 3)]), player.getCurrentShock_front());
var _local12:Point = new Point(_local2[1][0], _local2[1][1]);
var _local13:Number = _local2[1][2];
var _local14:Object = createWheels(_local12, _local6, _local13, player.getCurrentCarWheel_rear());
playerCar_rearWheel_body = _local14.body;
playerCar_rearWheel_shape = _local14.shape;
_local12 = new Point(_local2[1][3], _local2[1][4]);
_local13 = _local2[1][5];
_local14 = createWheels(_local12, _local6, _local13, player.getCurrentCarWheel_front());
playerCar_frontWheel_body = _local14.body;
playerCar_frontWheel_shape = _local14.shape;
playerCar_rearWheel_PrismaticJoint = createPrismaticJoint(rearShock_body, 13, playerCar_body, true);
playerCar_frontWheel_PrismaticJoint = createPrismaticJoint(frontShock_body, 15, playerCar_body, true);
playerCar_rearWheel_RevoluteJoint = createRevoluteJoint(rearShock_body, playerCar_rearWheel_body, true);
playerCar_frontWheel_RevoluteJoint = createRevoluteJoint(frontShock_body, playerCar_frontWheel_body, true);
playerCar_frontWheel_RevoluteJoint.SetMotorSpeed(0);
playerCar_rearWheel_RevoluteJoint.SetMotorSpeed(0);
playerCar_frontWheel_RevoluteJoint.SetMaxMotorTorque(maxTorque);
playerCar_rearWheel_RevoluteJoint.SetMaxMotorTorque(maxTorque);
playerCar_body.AllowSleeping(true);
playerCar_frontWheel_body.AllowSleeping(true);
playerCar_frontWheel_RevoluteJoint.EnableMotor(false);
playerCar_rearWheel_body.AllowSleeping(true);
playerCar_rearWheel_RevoluteJoint.EnableMotor(false);
_local5.visible = false;
playField.addChild(_local5);
}
private function createRevoluteJoint(_arg1:b2Body, _arg2:b2Body, _arg3:Boolean=false):b2RevoluteJoint{
var _local4:b2RevoluteJointDef = new b2RevoluteJointDef();
_local4.Initialize(_arg1, _arg2, _arg2.GetWorldCenter());
_local4.localAnchor1.x = (_arg1.GetLocalCenter().x + (0.5 / physScale));
_local4.localAnchor1.y = (_arg1.GetLocalCenter().y + (12 / physScale));
_local4.referenceAngle = 0;
_local4.lowerAngle = 0;
_local4.upperAngle = 0;
_local4.collideConnected = false;
_local4.enableMotor = _arg3;
return (b2dWrapper.createRevoluteJoint(_local4));
}
public function rampSelected(_arg1:int):void{
createRamp(_arg1);
}
private function nop():void{
}
public function mainloop():void{
mainFunc();
}
private function mainloop_fallingIntoPlace():void{
var _local2:Number;
var _local3:Number;
b2dWrapper.mainloop();
b2dWrapper.mainloop();
playerChassis.x = playerCar_body.m_userData.x;
playerChassis.y = playerCar_body.m_userData.y;
playerChassis.rotation = playerCar_body.m_userData.rotation;
if (playerCar_body.GetWorldCenter().y > 16){
if (nudgeFlag == false){
nudgeFlag = true;
playerCar_body.ApplyImpulse(new b2Vec2(1000, 0), playerCar_body.GetWorldCenter());
};
};
if (playerCar_body.GetWorldCenter().y > 15){
playerChassis.visible = true;
playerCar_body.m_userData.visible = true;
};
previousScrollXPos = playField.x;
if (previousScrollXPos <= -416){
_local2 = playerCar_body.GetLinearVelocity().x;
_local3 = playerCar_body.GetMass();
playerCar_body.ApplyImpulse(new b2Vec2((_local3 * -(_local2)), 0), playerCar_body.GetWorldCenter());
gameController.startSpeedSelection();
return;
};
var _local1:Number = ((playField.x - (((-(physScale) * playerCar_body.GetWorldCenter().x) + 320) - (playerCar_body.GetLinearVelocity().x * 3))) / 3);
if (_local1 > 0){
playField.x = (playField.x - _local1);
player.scrollGame((previousScrollXPos - playField.x));
previousScrollXPos = playField.x;
if (debugFlag == true){
dapiHolder.x = (dapiHolder.x - ((dapiHolder.x - (((-(physScale) * playerCar_body.GetWorldCenter().x) + 320) - (playerCar_body.GetLinearVelocity().x * 3))) / 3));
};
};
}
private function createTruckParts():void{
var _local1:b2BodyDef = new b2BodyDef();
truck_body = b2dWrapper.addToWorld(_local1);
var _local2:Rectangle = new Rectangle(202, 373, 280, 40);
var _local3:b2PolygonDef = b2dWrapper.createPolygon(_local2);
_local3.density = 0;
_local3.restitution = 0;
truck_body.CreateShape(_local3);
var _local4:Point = new Point(482, 373);
var _local5:Point = new Point(606, 424);
var _local6:Point = new Point(482, 424);
_local3 = b2dWrapper.createTriangle(_local4, _local5, _local6);
truck_body.CreateShape(_local3);
truck_body.SetMassFromShapes();
}
private function createPrismaticJoint(_arg1:b2Body, _arg2:Number, _arg3:b2Body, _arg4:Boolean=false):b2PrismaticJoint{
var _local5:b2PrismaticJointDef = new b2PrismaticJointDef();
_local5.Initialize(_arg1, _arg3, new b2Vec2(0, 0), new b2Vec2(0, 1));
var _local6:Number = (_local5.body1.GetWorldCenter().x * physScale);
var _local7:Number = ((_local5.body1.GetWorldCenter().y * physScale) - (_local5.body1.m_userData.height / 2));
_local5.localAnchor1 = _local5.body1.GetLocalPoint(new b2Vec2((_local6 / physScale), (_local7 / physScale)));
var _local8:b2Vec2 = _local5.body2.GetWorldPoint(new b2Vec2(0, 0));
var _local9:Number = (_local8.x * physScale);
_local9 = (_local9 + (_local6 - _local9));
var _local10:Number = (_local8.y * physScale);
_local10 = ((_local8.y * physScale) - (_local10 - _local7));
_local5.localAnchor2 = _local5.body2.GetLocalPoint(new b2Vec2((_local9 / physScale), (_local10 / physScale)));
_local5.referenceAngle = 0;
_local5.collideConnected = true;
if (_arg4 == true){
_local5.lowerTranslation = -((5 / physScale));
_local5.upperTranslation = 0;
_local5.maxMotorForce = 2000;
_local5.motorSpeed = 20000;
} else {
_local5.lowerTranslation = (_local5.upperTranslation = 0);
};
_local5.enableLimit = true;
_local5.enableMotor = _arg4;
return (b2dWrapper.createPrismaticJoint(_local5));
}
public function houseKeeping():void{
b2dWrapper.houseKeeping();
if (playerChassis.parent != null){
playField.removeChild(playerChassis);
};
if (debugFlag == true){
dapiHolder.graphics.clear();
};
}
}
}//package Classes
Section 136
//Player (Classes.Player)
package Classes {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import Classes.Particles.*;
import gs.*;
import flash.text.*;
import flash.filters.*;
public class Player {
private var car6Wheel_front:Sprite;
private var car5Chassis:Sprite;
private var helpText4MC:Class;
private var car8Wheel_rear:Sprite;
private var car5WheelMC:Class;
private var genericCnt:int;
private var speedText:TextField;
private var carShock_rear:Sprite;
private var car1ShockMC:Class;
private var car11Wheel_rear:Sprite;
private var car3ChassisMC:Class;
private var helpText4_flag:Boolean;// = false
private var playField:Sprite;
private var car12Wheel_front:Sprite;
private var mainFunc:Function;
private var car9Wheel_front:Sprite;
private var currentCarSound:int;
private var truckMC:Class;
private var car5MC:Class;
private var helpText3MC:Class;
private var numberOfCars:int;// = 12
private var scroller:Scroller;
private var car3Wheel_rear:Sprite;
private var car3Chassis:Sprite;
private var countDown:MovieClip;
private var car3WheelMC:Class;
private var scrollPos:int;
private var car5ChassisMC:Class;
private var padLock:Sprite;
private var truck:Sprite;
private var carSoundStorage:Array;
private var currentWheel_rear:Sprite;
private var speed:Number;
private var currentChassis:Sprite;
private var car4MC:Class;
private var car2Wheel_front:Sprite;
private var car10ChassisMC:Class;
private var truckRightButton:Sprite;
private var car1Chassis:Sprite;
private var car6Wheel_rear:Sprite;
private var car11Chassis:Sprite;
private var car1WheelMC:Class;
private var car7ChassisMC:Class;
private var car11WheelMC:Class;
private var speedoMC:Class;
private var truckRightButton_rollOver:Sprite;
private var needle:Sprite;
private var car8Chassis:Sprite;
private var car5Wheel_front:Sprite;
private var car8WheelMC:Class;
private var car11Wheel_front:Sprite;
private var dust:MovieClip;
private var car3MC:Class;
private var car8Wheel_front:Sprite;
public var currentCarNumber:int;// = 1
private var car1Wheel_rear:Sprite;
private var car12ChassisMC:Class;
private var mousePressedFlag:Boolean;
private var car14MC:Class;
private var car9Wheel_rear:Sprite;
private var car9ChassisMC:Class;
private var car1:MovieClip;
private var car2:MovieClip;
private var car3:MovieClip;
private var car4:MovieClip;
private var car5:MovieClip;
private var car6:MovieClip;
private var car7:MovieClip;
private var car8:MovieClip;
private var car9:MovieClip;
private var car6Chassis:Sprite;
private var car6WheelMC:Class;
private var car2MC:Class;
private var car12:MovieClip;
private var mainMovie:DisplayObject;
private var car10:MovieClip;
private var car2ChassisMC:Class;
private var car12Wheel_rear:Sprite;
private var stage:Stage;
private var car4Wheel_rear:Sprite;
private var car13MC:Class;
private var speedo:Sprite;
private var truckRamp:MovieClip;
private var currentWheel_front:Sprite;
private var currentShock_front:Sprite;
private var car11:MovieClip;
private var car4Chassis:Sprite;
private var car1Wheel_front:Sprite;
private var car4WheelMC:Class;
private var car1MC:Class;
private var gameController:GameController;
private var car9MC:Class;
private var car4ChassisMC:Class;
private var car4Wheel_front:Sprite;
private var soundHandler:SoundHandler;
private var car12MC:Class;
private var truckSelectButton:MovieClip;
private var car7Wheel_rear:Sprite;
private var car10Wheel_front:Sprite;
private var car10Wheel_rear:Sprite;
private var playField_hud:Sprite;
private var car7Wheel_front:Sprite;
private var car2Chassis:Sprite;
private var car12Chassis:Sprite;
private var car2WheelMC:Class;
private var dustRear:MovieClip;
private var truckLeftButton_rollOver:Sprite;
private var car8MC:Class;
private var car6ChassisMC:Class;
private var car12WheelMC:Class;
private var car2Wheel_rear:Sprite;
private var currentShock_rear:Sprite;
private var car11MC:Class;
private var wheelOnGroundYPos:Number;
private var car9WheelMC:Class;
private var helpText3_flag:Boolean;// = false
private var currentCar:MovieClip;
private var car9Chassis:Sprite;
private var countDownMC:Class;
private var car11ChassisMC:Class;
private var car10Chassis:Sprite;
private var car8ChassisMC:Class;
private var car7MC:Class;
private var car7Chassis:Sprite;
private var car10WheelMC:Class;
private var dustMC:Class;
private var car10MC:Class;
private var car7WheelMC:Class;
private var truckLeftButton:Sprite;
private var main:Main;
private var car1ChassisMC:Class;
private var car5Wheel_rear:Sprite;
private var particleHandler:ParticleHandler;
private var helpText3:Sprite;
private var car3Wheel_front:Sprite;
private var carShock_front:Sprite;
private var wireFrame:MovieClip;
private var helpText4:Sprite;
private var car6MC:Class;
public function Player(){
car1MC = Player_car1MC;
car1WheelMC = Player_car1WheelMC;
car1ShockMC = Player_car1ShockMC;
car1ChassisMC = Player_car1ChassisMC;
car2MC = Player_car2MC;
car2WheelMC = Player_car2WheelMC;
car2ChassisMC = Player_car2ChassisMC;
car3MC = Player_car3MC;
car3WheelMC = Player_car3WheelMC;
car3ChassisMC = Player_car3ChassisMC;
car4MC = Player_car4MC;
car4WheelMC = Player_car4WheelMC;
car4ChassisMC = Player_car4ChassisMC;
car5MC = Player_car5MC;
car5WheelMC = Player_car5WheelMC;
car5ChassisMC = Player_car5ChassisMC;
car6MC = Player_car6MC;
car6WheelMC = Player_car6WheelMC;
car6ChassisMC = Player_car6ChassisMC;
car7MC = Player_car7MC;
car7WheelMC = Player_car7WheelMC;
car7ChassisMC = Player_car7ChassisMC;
car8MC = Player_car8MC;
car8WheelMC = Player_car8WheelMC;
car8ChassisMC = Player_car8ChassisMC;
car9MC = Player_car9MC;
car9WheelMC = Player_car9WheelMC;
car9ChassisMC = Player_car9ChassisMC;
car10MC = Player_car10MC;
car10WheelMC = Player_car10WheelMC;
car10ChassisMC = Player_car10ChassisMC;
car11MC = Player_car11MC;
car11WheelMC = Player_car11WheelMC;
car11ChassisMC = Player_car11ChassisMC;
car12MC = Player_car12MC;
car12WheelMC = Player_car12WheelMC;
car12ChassisMC = Player_car12ChassisMC;
car13MC = Player_car13MC;
car14MC = Player_car14MC;
speedoMC = Player_speedoMC;
dustMC = Player_dustMC;
truckMC = Player_truckMC;
countDownMC = Player_countDownMC;
helpText3MC = Player_helpText3MC;
helpText4MC = Player_helpText4MC;
carSoundStorage = [3, 1, 2, 3, 4, 3, 4, 3, 1, 2, 4, 4];
super();
main = Main.getInstance();
mainMovie = main.getMainMovie();
stage = main.getStage();
playField = main.getInitObj().getPlayField().sprites;
playField_hud = main.getInitObj().getPlayField().hud;
gameController = main.getInitObj().getGameController();
scroller = gameController.getScroller();
soundHandler = main.getInitObj().getSoundHandler();
truck = new truckMC();
truck.blendMode = BlendMode.LAYER;
truck.y = 239;
wireFrame = truck["wireFrame"];
wireFrame.gotoAndStop(1);
padLock = truck["padLock"];
padLock.visible = false;
truckRamp = truck["truckRamp"];
truckRamp.gotoAndStop(1);
truckSelectButton = truck["selectButton"];
truckSelectButton.gotoAndStop(1);
truckLeftButton = truck["leftButton"];
truckRightButton = truck["rightButton"];
truckLeftButton_rollOver = truck["leftRollOver"];
truckRightButton_rollOver = truck["rightRollOver"];
speedo = new speedoMC();
speedo.x = 10;
speedo.y = 347;
needle = speedo["needle"];
speedText = speedo["speedText"];
helpText3 = new helpText3MC();
helpText3.x = 46;
helpText3.y = 45;
helpText4 = new helpText4MC();
helpText4.x = 26;
helpText4.y = 45;
dust = new dustMC();
dust.gotoAndStop(1);
dust.filters = new Array(new BlurFilter(8, 4, 1));
dustRear = new dustMC();
dustRear.gotoAndStop(1);
dustRear.filters = new Array(new BlurFilter(8, 4, 1));
countDown = new countDownMC();
countDown.x = 850;
countDown.y = 278;
countDown.gotoAndStop(1);
playField.addChild(countDown);
carShock_front = new car1ShockMC();
carShock_rear = new car1ShockMC();
car1 = new car1MC();
car1.gotoAndStop(1);
car1Wheel_front = new car1WheelMC();
car1Wheel_rear = new car1WheelMC();
car1Chassis = new car1ChassisMC();
car2 = new car2MC();
car2.gotoAndStop(1);
car2Wheel_front = new car2WheelMC();
car2Wheel_rear = new car2WheelMC();
car2Chassis = new car2ChassisMC();
car3 = new car3MC();
car3.gotoAndStop(1);
car3Wheel_front = new car3WheelMC();
car3Wheel_rear = new car3WheelMC();
car3Chassis = new car3ChassisMC();
car4 = new car4MC();
car4.gotoAndStop(1);
car4Wheel_front = new car4WheelMC();
car4Wheel_rear = new car4WheelMC();
car4Chassis = new car4ChassisMC();
car5 = new car5MC();
car5.gotoAndStop(1);
car5Wheel_front = new car5WheelMC();
car5Wheel_rear = new car5WheelMC();
car5Chassis = new car5ChassisMC();
car6 = new car6MC();
car6.gotoAndStop(1);
car6Wheel_front = new car6WheelMC();
car6Wheel_rear = new car6WheelMC();
car6Chassis = new car6ChassisMC();
car7 = new car7MC();
car7.gotoAndStop(1);
car7Wheel_front = new car7WheelMC();
car7Wheel_rear = new car7WheelMC();
car7Chassis = new car7ChassisMC();
car8 = new car8MC();
car8.gotoAndStop(1);
car8Wheel_front = new car8WheelMC();
car8Wheel_rear = new car8WheelMC();
car8Chassis = new car8ChassisMC();
car9 = new car9MC();
car9.gotoAndStop(1);
car9Wheel_front = new car9WheelMC();
car9Wheel_rear = new car9WheelMC();
car9Chassis = new car9ChassisMC();
car10 = new car10MC();
car10.gotoAndStop(1);
car10Wheel_front = new car10WheelMC();
car10Wheel_rear = new car10WheelMC();
car10Chassis = new car10ChassisMC();
car11 = new car11MC();
car11.gotoAndStop(1);
car11Wheel_front = new car11WheelMC();
car11Wheel_rear = new car11WheelMC();
car11Chassis = new car11ChassisMC();
car12 = new car12MC();
car12.gotoAndStop(1);
car12Wheel_front = new car12WheelMC();
car12Wheel_rear = new car12WheelMC();
car12Chassis = new car12ChassisMC();
mainFunc = mainloop_levelSelect;
}
private function truckLeftButton_rollOverEvent(_arg1:MouseEvent):void{
if (currentCarNumber > 1){
truckLeftButton_rollOver.visible = true;
};
}
private function mainloop_panningTowardsStart():void{
var _local1 = 24;
scroller.scrollLeft(_local1);
playField.x = (playField.x + _local1);
if (playField.x >= 0){
playField.x = 0;
mainFunc = nop;
truckbuttons_Init();
if (helpText3_flag == false){
helpText3_flag = true;
stage.addChild(helpText3);
};
};
}
public function startSpeedSelection():void{
startSpeedSelection_init();
}
private function speedSelected():void{
if (helpText4.parent != null){
stage.removeChild(helpText4);
};
gameController.getHUD().enablePauseButton();
mainFunc = mainloop_removeDust;
gameController.speedSelected(speed);
soundHandler.play_wheelSpin();
}
public function killSpeedo():void{
TweenLite.to(speedo, 0.2, {y:487, onComplete:removeSpeedo});
}
private function truckInit():void{
truck.x = 8;
truckRamp.gotoAndStop(1);
playField.addChild(truck);
truckLeftButton_rollOver.visible = false;
truckRightButton_rollOver.visible = false;
}
private function killButton(_arg1:MovieClip, _arg2:Function, _arg3:Function=null, _arg4:Function=null):void{
_arg1.useHandCursor = false;
_arg1.buttonMode = false;
_arg1.gotoAndStop(1);
_arg1.removeEventListener(MouseEvent.CLICK, _arg2);
if (_arg3 != null){
_arg1.removeEventListener(MouseEvent.MOUSE_OVER, _arg3);
};
if (_arg4 != null){
_arg1.removeEventListener(MouseEvent.MOUSE_OUT, _arg4);
};
}
private function removeCountDown():void{
playField_hud.removeChild(countDown);
}
private function mainloop_levelSelect():void{
scroller.scrollRight(12);
}
private function startSpeedSelection_init():void{
speedo.y = 487;
needle.rotation = -98;
speedText.text = "0";
playField_hud.addChild(speedo);
TweenLite.to(speedo, 0.5, {y:347, onComplete:speedoInit});
TweenLite.to(truck, 2, {x:-200, onComplete:killTruck});
var _local1:int = (playField.numChildren - 1);
if (playField.getChildIndex(countDown) < _local1){
playField.setChildIndex(countDown, _local1);
};
var _local2:Point = gameController.getPhysics().getFrontWheelPos();
dust.x = (_local2.x - 150);
dust.y = (_local2.y - 32);
dust.gotoAndPlay(1);
playField.addChild(dust);
_local2 = gameController.getPhysics().getRearWheelPos();
dustRear.x = (_local2.x - 150);
dustRear.y = (_local2.y - 32);
dustRear.gotoAndPlay(2);
playField.addChild(dustRear);
if (helpText4_flag == false){
helpText4_flag = true;
stage.addChild(helpText4);
};
}
private function decreaseSpeed(_arg1:MouseEvent):void{
mousePressedFlag = false;
}
private function speedoInit():void{
countDown.gotoAndPlay(1);
mainFunc = mainloop_handleCountdown;
speed = 0;
mousePressedFlag = false;
if (currentCarSound == 1){
soundHandler.start_engine1();
} else {
if (currentCarSound == 2){
soundHandler.start_engine2();
} else {
if (currentCarSound == 3){
soundHandler.start_engine3();
} else {
soundHandler.start_engine4();
};
};
};
stage.addEventListener(MouseEvent.MOUSE_DOWN, increaseSpeed);
stage.addEventListener(MouseEvent.MOUSE_UP, decreaseSpeed);
}
public function toString():String{
return ("Scroller");
}
private function setupCarData():void{
switch (currentCarNumber){
case 1:
currentCar = car1;
currentCar.gotoAndStop(1);
currentWheel_front = car1Wheel_front;
currentWheel_rear = car1Wheel_rear;
currentChassis = car1Chassis;
break;
case 2:
currentCar = car2;
currentCar.gotoAndStop(1);
currentWheel_front = car2Wheel_front;
currentWheel_rear = car2Wheel_rear;
currentChassis = car2Chassis;
break;
case 3:
currentCar = car3;
currentCar.gotoAndStop(1);
currentWheel_front = car3Wheel_front;
currentWheel_rear = car3Wheel_rear;
currentChassis = car3Chassis;
break;
case 4:
currentCar = car4;
currentCar.gotoAndStop(1);
currentWheel_front = car4Wheel_front;
currentWheel_rear = car4Wheel_rear;
currentChassis = car4Chassis;
break;
case 5:
currentCar = car5;
currentCar.gotoAndStop(1);
currentWheel_front = car5Wheel_front;
currentWheel_rear = car5Wheel_rear;
currentChassis = car5Chassis;
break;
case 6:
currentCar = car6;
currentCar.gotoAndStop(1);
currentWheel_front = car6Wheel_front;
currentWheel_rear = car6Wheel_rear;
currentChassis = car6Chassis;
break;
case 7:
currentCar = car7;
currentCar.gotoAndStop(1);
currentWheel_front = car7Wheel_front;
currentWheel_rear = car7Wheel_rear;
currentChassis = car7Chassis;
break;
case 8:
currentCar = car8;
currentCar.gotoAndStop(1);
currentWheel_front = car8Wheel_front;
currentWheel_rear = car8Wheel_rear;
currentChassis = car8Chassis;
break;
case 9:
currentCar = car9;
currentCar.gotoAndStop(1);
currentWheel_front = car9Wheel_front;
currentWheel_rear = car9Wheel_rear;
currentChassis = car9Chassis;
break;
case 10:
currentCar = car10;
currentCar.gotoAndStop(1);
currentWheel_front = car10Wheel_front;
currentWheel_rear = car10Wheel_rear;
currentChassis = car10Chassis;
break;
case 11:
currentCar = car11;
currentCar.gotoAndStop(1);
currentWheel_front = car11Wheel_front;
currentWheel_rear = car11Wheel_rear;
currentChassis = car11Chassis;
break;
case 12:
currentCar = car12;
currentCar.gotoAndStop(1);
currentWheel_front = car12Wheel_front;
currentWheel_rear = car12Wheel_rear;
currentChassis = car12Chassis;
break;
};
currentShock_front = carShock_front;
currentShock_rear = carShock_rear;
}
private function initButton(_arg1:MovieClip, _arg2:Function, _arg3:Function=null, _arg4:Function=null):void{
_arg1.useHandCursor = true;
_arg1.buttonMode = true;
_arg1.enabled = true;
_arg1.mouseChildren = true;
_arg1.gotoAndStop(1);
_arg1.addEventListener(MouseEvent.CLICK, _arg2);
if (_arg3 != null){
_arg1.addEventListener(MouseEvent.MOUSE_OVER, _arg3);
};
if (_arg4 != null){
_arg1.addEventListener(MouseEvent.MOUSE_OUT, _arg4);
};
}
private function truckRightButton_pressed(_arg1:MouseEvent):void{
if (currentCarNumber < numberOfCars){
currentCarNumber++;
wireFrame.gotoAndStop(currentCarNumber);
soundHandler.play_buttonClick();
};
padLock.visible = gameController.getCarData().getLockedCars((currentCarNumber - 1));
if (padLock.visible == true){
killButton(truckSelectButton, truckSelectButton_pressed);
} else {
initButton(truckSelectButton, truckSelectButton_pressed);
};
if (helpText3.parent != null){
stage.removeChild(helpText3);
};
}
public function scrollGame(_arg1:Number):void{
scroller.scrollRight(_arg1);
}
public function getCurrentCarWheel_rear():Sprite{
return (currentWheel_rear);
}
public function scrollLeft(_arg1:Number):void{
scroller.scrollLeft(_arg1);
}
private function truckRightButton_rollOverEvent(_arg1:MouseEvent):void{
if (currentCarNumber < numberOfCars){
truckRightButton_rollOver.visible = true;
};
}
public function reduceEngineVolume(_arg1:Number):void{
if (_arg1 == 0){
if (currentCarSound == 1){
soundHandler.stop_engine1();
} else {
if (currentCarSound == 2){
soundHandler.stop_engine2();
} else {
if (currentCarSound == 3){
soundHandler.stop_engine3();
} else {
soundHandler.stop_engine4();
};
};
};
} else {
if (currentCarSound == 1){
soundHandler.fadeOut_engine1(speed);
} else {
if (currentCarSound == 2){
soundHandler.fadeOut_engine2(speed);
} else {
if (currentCarSound == 3){
soundHandler.fadeOut_engine3(speed);
} else {
soundHandler.fadeOut_engine4(speed);
};
};
};
};
}
private function mainloop_waitingForTruckRampAnim():void{
if (truckRamp.currentFrame == truckRamp.totalFrames){
truckRamp.gotoAndStop(truckRamp.totalFrames);
mainFunc = nop;
};
}
private function truckLeftButton_rollOutEvent(_arg1:MouseEvent):void{
truckLeftButton_rollOver.visible = false;
}
private function mainloop_handleCountdown():void{
if (countDown.currentFrame == countDown.totalFrames){
countDown.gotoAndStop(countDown.currentFrame);
mainFunc = nop;
speedSelected();
} else {
if (countDown.currentFrame < 105){
handleSpeed();
} else {
if (countDown.currentFrame == 20){
soundHandler.play_go321();
};
};
};
}
private function removeSpeedo():void{
if (speedo.parent != null){
playField_hud.removeChild(speedo);
};
}
private function truckLeftButton_pressed(_arg1:MouseEvent):void{
if (currentCarNumber > 1){
currentCarNumber--;
wireFrame.gotoAndStop(currentCarNumber);
soundHandler.play_buttonClick();
};
padLock.visible = gameController.getCarData().getLockedCars((currentCarNumber - 1));
if (padLock.visible == true){
killButton(truckSelectButton, truckSelectButton_pressed);
} else {
initButton(truckSelectButton, truckSelectButton_pressed);
};
if (helpText3.parent != null){
stage.removeChild(helpText3);
};
}
public function getCarDataComplete(_arg1:int):Object{
var _local2:Object = new Object();
switch (_arg1){
case 1:
_local2.carBody = new car1MC();
_local2.carBody.name = ("mc" + Math.round((Math.random() * 9999999)));
_local2.wheel_front = new car1WheelMC();
_local2.wheel_front.name = ("fw" + Math.round((Math.random() * 9999999)));
_local2.wheel_rear = new car1WheelMC();
_local2.wheel_rear.name = ("rw" + Math.round((Math.random() * 9999999)));
_local2.weight = 40;
break;
case 2:
_local2.carBody = new car2MC();
_local2.carBody.name = ("mc" + Math.round((Math.random() * 9999999)));
_local2.wheel_front = new car2WheelMC();
_local2.wheel_front.name = ("fw" + Math.round((Math.random() * 9999999)));
_local2.wheel_rear = new car2WheelMC();
_local2.wheel_rear.name = ("rw" + Math.round((Math.random() * 9999999)));
_local2.weight = 38;
break;
case 3:
_local2.carBody = new car3MC();
_local2.carBody.name = ("mc" + Math.round((Math.random() * 9999999)));
_local2.wheel_front = new car3WheelMC();
_local2.wheel_front.name = ("fw" + Math.round((Math.random() * 9999999)));
_local2.wheel_rear = new car3WheelMC();
_local2.wheel_rear.name = ("rw" + Math.round((Math.random() * 9999999)));
_local2.weight = 28;
break;
case 4:
_local2.carBody = new car4MC();
_local2.carBody.name = ("mc" + Math.round((Math.random() * 9999999)));
_local2.wheel_front = new car4WheelMC();
_local2.wheel_front.name = ("fw" + Math.round((Math.random() * 9999999)));
_local2.wheel_rear = new car4WheelMC();
_local2.wheel_rear.name = ("rw" + Math.round((Math.random() * 9999999)));
_local2.weight = 35;
break;
case 5:
_local2.carBody = new car5MC();
_local2.carBody.name = ("mc" + Math.round((Math.random() * 9999999)));
_local2.wheel_front = new car5WheelMC();
_local2.wheel_front.name = ("fw" + Math.round((Math.random() * 9999999)));
_local2.wheel_rear = new car5WheelMC();
_local2.wheel_rear.name = ("rw" + Math.round((Math.random() * 9999999)));
_local2.weight = 45;
break;
case 6:
_local2.carBody = new car6MC();
_local2.carBody.name = ("mc" + Math.round((Math.random() * 9999999)));
_local2.wheel_front = new car6WheelMC();
_local2.wheel_front.name = ("fw" + Math.round((Math.random() * 9999999)));
_local2.wheel_rear = new car6WheelMC();
_local2.wheel_rear.name = ("rw" + Math.round((Math.random() * 9999999)));
_local2.weight = 44;
break;
case 7:
_local2.carBody = new car7MC();
_local2.carBody.name = ("mc" + Math.round((Math.random() * 9999999)));
_local2.wheel_front = new car7WheelMC();
_local2.wheel_front.name = ("fw" + Math.round((Math.random() * 9999999)));
_local2.wheel_rear = new car7WheelMC();
_local2.wheel_rear.name = ("rw" + Math.round((Math.random() * 9999999)));
_local2.weight = 44;
break;
case 8:
_local2.carBody = new car8MC();
_local2.carBody.name = ("mc" + Math.round((Math.random() * 9999999)));
_local2.wheel_front = new car8WheelMC();
_local2.wheel_front.name = ("fw" + Math.round((Math.random() * 9999999)));
_local2.wheel_rear = new car8WheelMC();
_local2.wheel_rear.name = ("rw" + Math.round((Math.random() * 9999999)));
_local2.weight = 40;
break;
case 9:
_local2.carBody = new car9MC();
_local2.carBody.name = ("mc" + Math.round((Math.random() * 9999999)));
_local2.wheel_front = new car9WheelMC();
_local2.wheel_front.name = ("fw" + Math.round((Math.random() * 9999999)));
_local2.wheel_rear = new car9WheelMC();
_local2.wheel_rear.name = ("rw" + Math.round((Math.random() * 9999999)));
_local2.weight = 38;
break;
case 10:
_local2.carBody = new car10MC();
_local2.carBody.name = ("mc" + Math.round((Math.random() * 9999999)));
_local2.wheel_front = new car10WheelMC();
_local2.wheel_front.name = ("fw" + Math.round((Math.random() * 9999999)));
_local2.wheel_rear = new car10WheelMC();
_local2.wheel_rear.name = ("rw" + Math.round((Math.random() * 9999999)));
_local2.weight = 40;
break;
case 11:
_local2.carBody = new car11MC();
_local2.carBody.name = ("mc" + Math.round((Math.random() * 9999999)));
_local2.wheel_front = new car11WheelMC();
_local2.wheel_front.name = ("fw" + Math.round((Math.random() * 9999999)));
_local2.wheel_rear = new car11WheelMC();
_local2.wheel_rear.name = ("rw" + Math.round((Math.random() * 9999999)));
_local2.weight = 48;
break;
case 12:
_local2.carBody = new car12MC();
_local2.carBody.name = ("mc" + Math.round((Math.random() * 9999999)));
_local2.wheel_front = new car12WheelMC();
_local2.wheel_front.name = ("fw" + Math.round((Math.random() * 9999999)));
_local2.wheel_rear = new car12WheelMC();
_local2.wheel_rear.name = ("rw" + Math.round((Math.random() * 9999999)));
_local2.weight = 54;
break;
case 13:
_local2.carBody = new car13MC();
_local2.carBody.name = ("mc" + Math.round((Math.random() * 9999999)));
_local2.wheel_front = null;
_local2.wheel_rear = null;
_local2.weight = 38;
break;
case 14:
_local2.carBody = new car14MC();
_local2.carBody.name = ("mc" + Math.round((Math.random() * 9999999)));
_local2.wheel_front = null;
_local2.wheel_rear = null;
_local2.weight = 37;
break;
};
return (_local2);
}
private function nop():void{
}
public function getCurrentShock_rear():Sprite{
return (new car1ShockMC());
}
public function rampSelected():void{
truckInit();
mainFunc = mainloop_panningTowardsStart;
}
public function houseKeeping():void{
if (helpText3.parent != null){
stage.removeChild(helpText3);
};
if (helpText4.parent != null){
stage.removeChild(helpText4);
};
if (truck.parent != null){
stage.removeChild(truck);
};
if (speedo.parent != null){
playField_hud.removeChild(speedo);
};
if (dust.parent != null){
playField.removeChild(dust);
};
if (dustRear.parent != null){
playField.removeChild(dustRear);
};
reduceEngineVolume(0);
}
private function handleSpeed():void{
if (mousePressedFlag == true){
speed = (speed + 2);
needle.rotation = (needle.rotation + 2);
if (speed > 190){
speed = (speed - 5);
needle.rotation = (needle.rotation - 5);
};
} else {
if (speed <= 0){
speed = (speed + 5);
needle.rotation = (needle.rotation + 5);
} else {
speed = (speed - 2);
needle.rotation = (needle.rotation - 2);
};
};
if (currentCarSound == 1){
soundHandler.handle_engine1(speed);
} else {
if (currentCarSound == 2){
soundHandler.handle_engine2(speed);
} else {
if (currentCarSound == 3){
soundHandler.handle_engine3(speed);
} else {
soundHandler.handle_engine4(speed);
};
};
};
}
public function getCurrentShock_front():Sprite{
return (new car1ShockMC());
}
private function truckbuttons_Init():void{
initButton(truckSelectButton, truckSelectButton_pressed);
initButton((truckLeftButton as MovieClip), truckLeftButton_pressed, truckLeftButton_rollOverEvent, truckLeftButton_rollOutEvent);
initButton((truckRightButton as MovieClip), truckRightButton_pressed, truckRightButton_rollOverEvent, truckRightButton_rollOutEvent);
}
public function init():void{
if (particleHandler == null){
particleHandler = gameController.getParticleHandler();
};
scrollPos = 2000;
playField.x = -2000;
mainFunc = mainloop_panningTowardsCars;
}
public function ensureTruckOnTopDepth():void{
var _local1:int = (playField.numChildren - 1);
if (playField.getChildIndex(truck) < _local1){
playField.setChildIndex(truck, _local1);
};
}
private function mainloop_panningTowardsCars():void{
var _local1:int;
if (playField.x <= (-((gameController.getLevelPlotter().endMostCarXpos - 300)) + 8)){
mainFunc = nop;
gameController.rampSelectStart();
} else {
_local1 = 12;
scroller.scrollRight(_local1);
playField.x = (playField.x - _local1);
scrollPos = (scrollPos + _local1);
};
}
private function truckSelectButton_pressed(_arg1:MouseEvent):void{
soundHandler.play_buttonClick();
killButton(truckSelectButton, truckSelectButton_pressed);
killButton((truckLeftButton as MovieClip), truckLeftButton_pressed, truckLeftButton_rollOverEvent, truckLeftButton_rollOutEvent);
killButton((truckRightButton as MovieClip), truckRightButton_pressed, truckRightButton_rollOverEvent, truckRightButton_rollOutEvent);
if (helpText3.parent != null){
stage.removeChild(helpText3);
};
currentCarSound = carSoundStorage[(currentCarNumber - 1)];
setupCarData();
gameController.carSelected();
truckRamp.gotoAndPlay(1);
soundHandler.play_dooropen();
mainFunc = mainloop_waitingForTruckRampAnim;
}
private function increaseSpeed(_arg1:MouseEvent):void{
mousePressedFlag = true;
}
public function updateSpeedo(_arg1:Number):void{
var _local2:Number = Math.round(_arg1);
_local2 = (_local2 * 4);
speedText.text = _local2.toString();
if (currentCarSound == 1){
soundHandler.handle_engine1(_local2);
} else {
if (currentCarSound == 2){
soundHandler.handle_engine2(_local2);
} else {
if (currentCarSound == 3){
soundHandler.handle_engine3(_local2);
} else {
soundHandler.handle_engine4(_local2);
};
};
};
var _local3:Number = (needle.rotation + 98);
if (_local3 < (_local2 * 2)){
if (needle.rotation < (190 - 98)){
needle.rotation++;
} else {
needle.rotation = (needle.rotation - 2);
};
} else {
if (_local3 > _local2){
if (needle.rotation > -98){
needle.rotation = (needle.rotation - 5);
};
};
};
}
private function mainloop_dustParticles():void{
var _local1:Point = gameController.getPhysics().getRearWheelPos();
if (_local1.y < (wheelOnGroundYPos - 5)){
mainFunc = nop;
return;
};
_local1.y = (_local1.y + 5);
particleHandler.createDustParticle(_local1);
_local1 = gameController.getPhysics().getFrontWheelPos();
_local1.y = (_local1.y + 5);
particleHandler.createDustParticle(_local1);
}
private function mainloop_removeDust():void{
var _local1:Point;
if (dust.alpha <= 0){
if (dust.parent != null){
playField.removeChild(dust);
};
dust.alpha = 1;
dust.gotoAndStop(1);
if (dustRear.parent != null){
playField.removeChild(dustRear);
};
dustRear.alpha = 1;
dustRear.gotoAndStop(1);
_local1 = gameController.getPhysics().getRearWheelPos();
wheelOnGroundYPos = _local1.y;
mainFunc = mainloop_dustParticles;
} else {
dust.alpha = (dust.alpha - 0.1);
dustRear.alpha = (dustRear.alpha - 0.1);
};
}
private function truckRightButton_rollOutEvent(_arg1:MouseEvent):void{
truckRightButton_rollOver.visible = false;
}
public function scrollRight(_arg1:Number):void{
scroller.scrollRight(_arg1);
}
public function getCurrentChassis():Sprite{
return (currentChassis);
}
public function getCurrentCar():MovieClip{
currentCar.gotoAndStop(gameController.getCarData().getCurrentLivery((currentCarNumber - 1)));
return (currentCar);
}
private function killTruck():void{
playField.removeChild(truck);
}
public function mainloop():void{
mainFunc();
}
public function getCurrentCarWheel_front():Sprite{
return (currentWheel_front);
}
}
}//package Classes
Section 137
//Player_car10ChassisMC (Classes.Player_car10ChassisMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car10ChassisMC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var button15:DisplayObject;
public var button25:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var glassCenter:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var weightStat:DisplayObject;
public var padlock15:DisplayObject;
public var truckRamp:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var padlock23:DisplayObject;
public var leftRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var star21:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var rightRollOver:DisplayObject;
public var linkButton:DisplayObject;
public var startButton:DisplayObject;
public var description:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var selectButton:DisplayObject;
public var cardHolder:DisplayObject;
public var wheel3:DisplayObject;
public var padlock22:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var hitAreaMC:DisplayObject;
public var padLock:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var flag:DisplayObject;
public var rightButton:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var location:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var padlock2:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var wireFrame:DisplayObject;
public var best:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var star15:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 138
//Player_car10MC (Classes.Player_car10MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car10MC extends MovieClipAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var glassCenter:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var padlock15:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var linkButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var padlock22:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var hitAreaMC:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var padlock2:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 139
//Player_car10WheelMC (Classes.Player_car10WheelMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car10WheelMC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var glassCenter:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var padlock15:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var linkButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var padlock22:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var hitAreaMC:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var padlock2:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 140
//Player_car11ChassisMC (Classes.Player_car11ChassisMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car11ChassisMC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var padlock20:DisplayObject;
public var button25:DisplayObject;
public var backButton:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock14:DisplayObject;
public var truckRamp:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var button23:DisplayObject;
public var leftRollOver:DisplayObject;
public var weightStat:DisplayObject;
public var colourButtons:DisplayObject;
public var star21:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var rightRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var startButton:DisplayObject;
public var description:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var button15:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var selectButton:DisplayObject;
public var cardHolder:DisplayObject;
public var wheel3:DisplayObject;
public var padlock13:DisplayObject;
public var doneButton:DisplayObject;
public var hitAreaMC:DisplayObject;
public var lockedText:DisplayObject;
public var padLock:DisplayObject;
public var button4:DisplayObject;
public var button22:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var flag:DisplayObject;
public var rightButton:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var location:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var linkButton:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var padlock2:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button12:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var button19:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var wireFrame:DisplayObject;
public var padlock15:DisplayObject;
public var best:DisplayObject;
public var padlock19:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var button24:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var glassCenter:DisplayObject;
public var star18:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock21:DisplayObject;
public var padlock22:DisplayObject;
public var padlock23:DisplayObject;
}
}//package Classes
Section 141
//Player_car11MC (Classes.Player_car11MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car11MC extends MovieClipAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var button15:DisplayObject;
public var button25:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var glassCenter:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var weightStat:DisplayObject;
public var padlock15:DisplayObject;
public var truckRamp:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var padlock23:DisplayObject;
public var leftRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var star21:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var rightRollOver:DisplayObject;
public var linkButton:DisplayObject;
public var startButton:DisplayObject;
public var description:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var selectButton:DisplayObject;
public var cardHolder:DisplayObject;
public var wheel3:DisplayObject;
public var padlock22:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var hitAreaMC:DisplayObject;
public var padLock:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var flag:DisplayObject;
public var rightButton:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var location:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var padlock2:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var wireFrame:DisplayObject;
public var best:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var star15:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 142
//Player_car11WheelMC (Classes.Player_car11WheelMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car11WheelMC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var glassCenter:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var padlock15:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var linkButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var padlock22:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var hitAreaMC:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var padlock2:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 143
//Player_car12ChassisMC (Classes.Player_car12ChassisMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car12ChassisMC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var glassCenter:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var padlock15:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var linkButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var padlock22:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var hitAreaMC:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var padlock2:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 144
//Player_car12MC (Classes.Player_car12MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car12MC extends MovieClipAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var padlock20:DisplayObject;
public var button25:DisplayObject;
public var backButton:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock14:DisplayObject;
public var truckRamp:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var button23:DisplayObject;
public var leftRollOver:DisplayObject;
public var weightStat:DisplayObject;
public var colourButtons:DisplayObject;
public var star21:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var rightRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var startButton:DisplayObject;
public var description:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var button15:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var selectButton:DisplayObject;
public var cardHolder:DisplayObject;
public var wheel3:DisplayObject;
public var padlock13:DisplayObject;
public var doneButton:DisplayObject;
public var hitAreaMC:DisplayObject;
public var lockedText:DisplayObject;
public var padLock:DisplayObject;
public var button4:DisplayObject;
public var button22:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var flag:DisplayObject;
public var rightButton:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var location:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var linkButton:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var padlock2:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button12:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var button19:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var wireFrame:DisplayObject;
public var padlock15:DisplayObject;
public var best:DisplayObject;
public var padlock19:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var button24:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var glassCenter:DisplayObject;
public var star18:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock21:DisplayObject;
public var padlock22:DisplayObject;
public var padlock23:DisplayObject;
}
}//package Classes
Section 145
//Player_car12WheelMC (Classes.Player_car12WheelMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car12WheelMC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var glassCenter:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var padlock15:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var linkButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var padlock22:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var hitAreaMC:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var padlock2:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 146
//Player_car13MC (Classes.Player_car13MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car13MC extends MovieClipAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var glassCenter:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var padlock15:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var linkButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var padlock22:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var hitAreaMC:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var padlock2:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 147
//Player_car14MC (Classes.Player_car14MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car14MC extends MovieClipAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var button15:DisplayObject;
public var button25:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var glassCenter:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var weightStat:DisplayObject;
public var padlock15:DisplayObject;
public var truckRamp:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var padlock23:DisplayObject;
public var leftRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var star21:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var rightRollOver:DisplayObject;
public var linkButton:DisplayObject;
public var startButton:DisplayObject;
public var description:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var selectButton:DisplayObject;
public var cardHolder:DisplayObject;
public var wheel3:DisplayObject;
public var padlock22:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var hitAreaMC:DisplayObject;
public var padLock:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var flag:DisplayObject;
public var rightButton:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var location:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var padlock2:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var wireFrame:DisplayObject;
public var best:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var star15:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 148
//Player_car1ChassisMC (Classes.Player_car1ChassisMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car1ChassisMC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var glassCenter:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var padlock15:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var linkButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var padlock22:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var hitAreaMC:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var padlock2:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 149
//Player_car1MC (Classes.Player_car1MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car1MC extends MovieClipAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var glassCenter:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var padlock15:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var linkButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var padlock22:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var hitAreaMC:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var padlock2:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 150
//Player_car1ShockMC (Classes.Player_car1ShockMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car1ShockMC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var padlock20:DisplayObject;
public var button25:DisplayObject;
public var backButton:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock14:DisplayObject;
public var truckRamp:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var button23:DisplayObject;
public var leftRollOver:DisplayObject;
public var weightStat:DisplayObject;
public var colourButtons:DisplayObject;
public var star21:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var rightRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var startButton:DisplayObject;
public var description:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var button15:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var selectButton:DisplayObject;
public var cardHolder:DisplayObject;
public var wheel3:DisplayObject;
public var padlock13:DisplayObject;
public var doneButton:DisplayObject;
public var hitAreaMC:DisplayObject;
public var lockedText:DisplayObject;
public var padLock:DisplayObject;
public var button4:DisplayObject;
public var button22:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var flag:DisplayObject;
public var rightButton:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var location:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var linkButton:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var padlock2:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button12:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var button19:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var wireFrame:DisplayObject;
public var padlock15:DisplayObject;
public var best:DisplayObject;
public var padlock19:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var button24:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var glassCenter:DisplayObject;
public var star18:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock21:DisplayObject;
public var padlock22:DisplayObject;
public var padlock23:DisplayObject;
}
}//package Classes
Section 151
//Player_car1WheelMC (Classes.Player_car1WheelMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car1WheelMC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var button15:DisplayObject;
public var button25:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var glassCenter:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var weightStat:DisplayObject;
public var padlock15:DisplayObject;
public var truckRamp:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var padlock23:DisplayObject;
public var leftRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var star21:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var rightRollOver:DisplayObject;
public var linkButton:DisplayObject;
public var startButton:DisplayObject;
public var description:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var selectButton:DisplayObject;
public var cardHolder:DisplayObject;
public var wheel3:DisplayObject;
public var padlock22:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var hitAreaMC:DisplayObject;
public var padLock:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var flag:DisplayObject;
public var rightButton:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var location:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var padlock2:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var wireFrame:DisplayObject;
public var best:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var star15:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 152
//Player_car2ChassisMC (Classes.Player_car2ChassisMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car2ChassisMC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var glassCenter:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var padlock15:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var linkButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var padlock22:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var hitAreaMC:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var padlock2:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 153
//Player_car2MC (Classes.Player_car2MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car2MC extends MovieClipAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var glassCenter:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var padlock15:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var linkButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var padlock22:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var hitAreaMC:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var padlock2:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 154
//Player_car2WheelMC (Classes.Player_car2WheelMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car2WheelMC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var button15:DisplayObject;
public var button25:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var glassCenter:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var weightStat:DisplayObject;
public var padlock15:DisplayObject;
public var truckRamp:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var padlock23:DisplayObject;
public var leftRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var star21:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var rightRollOver:DisplayObject;
public var linkButton:DisplayObject;
public var startButton:DisplayObject;
public var description:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var selectButton:DisplayObject;
public var cardHolder:DisplayObject;
public var wheel3:DisplayObject;
public var padlock22:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var hitAreaMC:DisplayObject;
public var padLock:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var flag:DisplayObject;
public var rightButton:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var location:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var padlock2:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var wireFrame:DisplayObject;
public var best:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var star15:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 155
//Player_car3ChassisMC (Classes.Player_car3ChassisMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car3ChassisMC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var glassCenter:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var padlock15:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var linkButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var padlock22:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var hitAreaMC:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var padlock2:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 156
//Player_car3MC (Classes.Player_car3MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car3MC extends MovieClipAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var button15:DisplayObject;
public var button25:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var glassCenter:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var weightStat:DisplayObject;
public var padlock15:DisplayObject;
public var truckRamp:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var padlock23:DisplayObject;
public var leftRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var star21:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var rightRollOver:DisplayObject;
public var linkButton:DisplayObject;
public var startButton:DisplayObject;
public var description:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var selectButton:DisplayObject;
public var cardHolder:DisplayObject;
public var wheel3:DisplayObject;
public var padlock22:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var hitAreaMC:DisplayObject;
public var padLock:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var flag:DisplayObject;
public var rightButton:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var location:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var padlock2:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var wireFrame:DisplayObject;
public var best:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var star15:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 157
//Player_car3WheelMC (Classes.Player_car3WheelMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car3WheelMC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var padlock20:DisplayObject;
public var button25:DisplayObject;
public var backButton:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock14:DisplayObject;
public var truckRamp:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var button23:DisplayObject;
public var leftRollOver:DisplayObject;
public var weightStat:DisplayObject;
public var colourButtons:DisplayObject;
public var star21:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var rightRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var startButton:DisplayObject;
public var description:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var button15:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var selectButton:DisplayObject;
public var cardHolder:DisplayObject;
public var wheel3:DisplayObject;
public var padlock13:DisplayObject;
public var doneButton:DisplayObject;
public var hitAreaMC:DisplayObject;
public var lockedText:DisplayObject;
public var padLock:DisplayObject;
public var button4:DisplayObject;
public var button22:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var flag:DisplayObject;
public var rightButton:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var location:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var linkButton:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var padlock2:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button12:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var button19:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var wireFrame:DisplayObject;
public var padlock15:DisplayObject;
public var best:DisplayObject;
public var padlock19:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var button24:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var glassCenter:DisplayObject;
public var star18:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock21:DisplayObject;
public var padlock22:DisplayObject;
public var padlock23:DisplayObject;
}
}//package Classes
Section 158
//Player_car4ChassisMC (Classes.Player_car4ChassisMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car4ChassisMC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var padlock20:DisplayObject;
public var button25:DisplayObject;
public var backButton:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock14:DisplayObject;
public var truckRamp:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var button23:DisplayObject;
public var leftRollOver:DisplayObject;
public var weightStat:DisplayObject;
public var colourButtons:DisplayObject;
public var star21:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var rightRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var startButton:DisplayObject;
public var description:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var button15:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var selectButton:DisplayObject;
public var cardHolder:DisplayObject;
public var wheel3:DisplayObject;
public var padlock13:DisplayObject;
public var doneButton:DisplayObject;
public var hitAreaMC:DisplayObject;
public var lockedText:DisplayObject;
public var padLock:DisplayObject;
public var button4:DisplayObject;
public var button22:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var flag:DisplayObject;
public var rightButton:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var location:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var linkButton:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var padlock2:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button12:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var button19:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var wireFrame:DisplayObject;
public var padlock15:DisplayObject;
public var best:DisplayObject;
public var padlock19:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var button24:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var glassCenter:DisplayObject;
public var star18:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock21:DisplayObject;
public var padlock22:DisplayObject;
public var padlock23:DisplayObject;
}
}//package Classes
Section 159
//Player_car4MC (Classes.Player_car4MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car4MC extends MovieClipAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var glassCenter:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var padlock15:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var linkButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var padlock22:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var hitAreaMC:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var padlock2:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 160
//Player_car4WheelMC (Classes.Player_car4WheelMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car4WheelMC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var glassCenter:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var padlock15:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var linkButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var padlock22:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var hitAreaMC:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var padlock2:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 161
//Player_car5ChassisMC (Classes.Player_car5ChassisMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car5ChassisMC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var padlock20:DisplayObject;
public var button25:DisplayObject;
public var backButton:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock14:DisplayObject;
public var truckRamp:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var button23:DisplayObject;
public var leftRollOver:DisplayObject;
public var weightStat:DisplayObject;
public var colourButtons:DisplayObject;
public var star21:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var rightRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var startButton:DisplayObject;
public var description:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var button15:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var selectButton:DisplayObject;
public var cardHolder:DisplayObject;
public var wheel3:DisplayObject;
public var padlock13:DisplayObject;
public var doneButton:DisplayObject;
public var hitAreaMC:DisplayObject;
public var lockedText:DisplayObject;
public var padLock:DisplayObject;
public var button4:DisplayObject;
public var button22:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var flag:DisplayObject;
public var rightButton:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var location:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var linkButton:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var padlock2:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button12:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var button19:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var wireFrame:DisplayObject;
public var padlock15:DisplayObject;
public var best:DisplayObject;
public var padlock19:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var button24:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var glassCenter:DisplayObject;
public var star18:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock21:DisplayObject;
public var padlock22:DisplayObject;
public var padlock23:DisplayObject;
}
}//package Classes
Section 162
//Player_car5MC (Classes.Player_car5MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car5MC extends MovieClipAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var glassCenter:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var padlock15:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var linkButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var padlock22:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var hitAreaMC:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var padlock2:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 163
//Player_car5WheelMC (Classes.Player_car5WheelMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car5WheelMC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var padlock20:DisplayObject;
public var button25:DisplayObject;
public var backButton:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock14:DisplayObject;
public var truckRamp:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var button23:DisplayObject;
public var leftRollOver:DisplayObject;
public var weightStat:DisplayObject;
public var colourButtons:DisplayObject;
public var star21:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var rightRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var startButton:DisplayObject;
public var description:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var button15:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var selectButton:DisplayObject;
public var cardHolder:DisplayObject;
public var wheel3:DisplayObject;
public var padlock13:DisplayObject;
public var doneButton:DisplayObject;
public var hitAreaMC:DisplayObject;
public var lockedText:DisplayObject;
public var padLock:DisplayObject;
public var button4:DisplayObject;
public var button22:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var flag:DisplayObject;
public var rightButton:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var location:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var linkButton:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var padlock2:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button12:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var button19:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var wireFrame:DisplayObject;
public var padlock15:DisplayObject;
public var best:DisplayObject;
public var padlock19:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var button24:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var glassCenter:DisplayObject;
public var star18:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock21:DisplayObject;
public var padlock22:DisplayObject;
public var padlock23:DisplayObject;
}
}//package Classes
Section 164
//Player_car6ChassisMC (Classes.Player_car6ChassisMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car6ChassisMC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var glassCenter:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var padlock15:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var linkButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var padlock22:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var hitAreaMC:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var padlock2:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 165
//Player_car6MC (Classes.Player_car6MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car6MC extends MovieClipAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var glassCenter:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var padlock15:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var linkButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var padlock22:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var hitAreaMC:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var padlock2:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 166
//Player_car6WheelMC (Classes.Player_car6WheelMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car6WheelMC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var glassCenter:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var padlock15:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var linkButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var padlock22:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var hitAreaMC:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var padlock2:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 167
//Player_car7ChassisMC (Classes.Player_car7ChassisMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car7ChassisMC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var padlock20:DisplayObject;
public var button25:DisplayObject;
public var backButton:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock14:DisplayObject;
public var truckRamp:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var button23:DisplayObject;
public var leftRollOver:DisplayObject;
public var weightStat:DisplayObject;
public var colourButtons:DisplayObject;
public var star21:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var rightRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var startButton:DisplayObject;
public var description:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var button15:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var selectButton:DisplayObject;
public var cardHolder:DisplayObject;
public var wheel3:DisplayObject;
public var padlock13:DisplayObject;
public var doneButton:DisplayObject;
public var hitAreaMC:DisplayObject;
public var lockedText:DisplayObject;
public var padLock:DisplayObject;
public var button4:DisplayObject;
public var button22:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var flag:DisplayObject;
public var rightButton:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var location:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var linkButton:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var padlock2:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button12:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var button19:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var wireFrame:DisplayObject;
public var padlock15:DisplayObject;
public var best:DisplayObject;
public var padlock19:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var button24:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var glassCenter:DisplayObject;
public var star18:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock21:DisplayObject;
public var padlock22:DisplayObject;
public var padlock23:DisplayObject;
}
}//package Classes
Section 168
//Player_car7MC (Classes.Player_car7MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car7MC extends MovieClipAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var glassCenter:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var padlock15:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var linkButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var padlock22:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var hitAreaMC:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var padlock2:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 169
//Player_car7WheelMC (Classes.Player_car7WheelMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car7WheelMC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var padlock20:DisplayObject;
public var button25:DisplayObject;
public var backButton:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock14:DisplayObject;
public var truckRamp:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var button23:DisplayObject;
public var leftRollOver:DisplayObject;
public var weightStat:DisplayObject;
public var colourButtons:DisplayObject;
public var star21:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var rightRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var startButton:DisplayObject;
public var description:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var button15:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var selectButton:DisplayObject;
public var cardHolder:DisplayObject;
public var wheel3:DisplayObject;
public var padlock13:DisplayObject;
public var doneButton:DisplayObject;
public var hitAreaMC:DisplayObject;
public var lockedText:DisplayObject;
public var padLock:DisplayObject;
public var button4:DisplayObject;
public var button22:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var flag:DisplayObject;
public var rightButton:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var location:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var linkButton:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var padlock2:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button12:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var button19:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var wireFrame:DisplayObject;
public var padlock15:DisplayObject;
public var best:DisplayObject;
public var padlock19:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var button24:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var glassCenter:DisplayObject;
public var star18:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock21:DisplayObject;
public var padlock22:DisplayObject;
public var padlock23:DisplayObject;
}
}//package Classes
Section 170
//Player_car8ChassisMC (Classes.Player_car8ChassisMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car8ChassisMC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var button15:DisplayObject;
public var button25:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var glassCenter:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var weightStat:DisplayObject;
public var padlock15:DisplayObject;
public var truckRamp:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var padlock23:DisplayObject;
public var leftRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var star21:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var rightRollOver:DisplayObject;
public var linkButton:DisplayObject;
public var startButton:DisplayObject;
public var description:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var selectButton:DisplayObject;
public var cardHolder:DisplayObject;
public var wheel3:DisplayObject;
public var padlock22:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var hitAreaMC:DisplayObject;
public var padLock:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var flag:DisplayObject;
public var rightButton:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var location:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var padlock2:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var wireFrame:DisplayObject;
public var best:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var star15:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 171
//Player_car8MC (Classes.Player_car8MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car8MC extends MovieClipAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var padlock20:DisplayObject;
public var button25:DisplayObject;
public var backButton:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock14:DisplayObject;
public var truckRamp:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var button23:DisplayObject;
public var leftRollOver:DisplayObject;
public var weightStat:DisplayObject;
public var colourButtons:DisplayObject;
public var star21:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var rightRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var startButton:DisplayObject;
public var description:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var button15:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var selectButton:DisplayObject;
public var cardHolder:DisplayObject;
public var wheel3:DisplayObject;
public var padlock13:DisplayObject;
public var doneButton:DisplayObject;
public var hitAreaMC:DisplayObject;
public var lockedText:DisplayObject;
public var padLock:DisplayObject;
public var button4:DisplayObject;
public var button22:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var flag:DisplayObject;
public var rightButton:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var location:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var linkButton:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var padlock2:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button12:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var button19:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var wireFrame:DisplayObject;
public var padlock15:DisplayObject;
public var best:DisplayObject;
public var padlock19:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var button24:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var glassCenter:DisplayObject;
public var star18:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock21:DisplayObject;
public var padlock22:DisplayObject;
public var padlock23:DisplayObject;
}
}//package Classes
Section 172
//Player_car8WheelMC (Classes.Player_car8WheelMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car8WheelMC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var padlock20:DisplayObject;
public var button25:DisplayObject;
public var backButton:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock14:DisplayObject;
public var truckRamp:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var button23:DisplayObject;
public var leftRollOver:DisplayObject;
public var weightStat:DisplayObject;
public var colourButtons:DisplayObject;
public var star21:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var rightRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var startButton:DisplayObject;
public var description:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var button15:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var selectButton:DisplayObject;
public var cardHolder:DisplayObject;
public var wheel3:DisplayObject;
public var padlock13:DisplayObject;
public var doneButton:DisplayObject;
public var hitAreaMC:DisplayObject;
public var lockedText:DisplayObject;
public var padLock:DisplayObject;
public var button4:DisplayObject;
public var button22:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var flag:DisplayObject;
public var rightButton:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var location:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var linkButton:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var padlock2:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button12:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var button19:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var wireFrame:DisplayObject;
public var padlock15:DisplayObject;
public var best:DisplayObject;
public var padlock19:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var button24:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var glassCenter:DisplayObject;
public var star18:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock21:DisplayObject;
public var padlock22:DisplayObject;
public var padlock23:DisplayObject;
}
}//package Classes
Section 173
//Player_car9ChassisMC (Classes.Player_car9ChassisMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car9ChassisMC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var glassCenter:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var padlock15:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var linkButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var padlock22:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var hitAreaMC:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var padlock2:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 174
//Player_car9MC (Classes.Player_car9MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car9MC extends MovieClipAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var button15:DisplayObject;
public var button25:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var glassCenter:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var weightStat:DisplayObject;
public var padlock15:DisplayObject;
public var truckRamp:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var padlock23:DisplayObject;
public var leftRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var star21:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var rightRollOver:DisplayObject;
public var linkButton:DisplayObject;
public var startButton:DisplayObject;
public var description:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var selectButton:DisplayObject;
public var cardHolder:DisplayObject;
public var wheel3:DisplayObject;
public var padlock22:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var hitAreaMC:DisplayObject;
public var padLock:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var flag:DisplayObject;
public var rightButton:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var location:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var padlock2:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var wireFrame:DisplayObject;
public var best:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var star15:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 175
//Player_car9WheelMC (Classes.Player_car9WheelMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_car9WheelMC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var padlock20:DisplayObject;
public var button25:DisplayObject;
public var backButton:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock14:DisplayObject;
public var truckRamp:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var button23:DisplayObject;
public var leftRollOver:DisplayObject;
public var weightStat:DisplayObject;
public var colourButtons:DisplayObject;
public var star21:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var rightRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var startButton:DisplayObject;
public var description:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var button15:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var selectButton:DisplayObject;
public var cardHolder:DisplayObject;
public var wheel3:DisplayObject;
public var padlock13:DisplayObject;
public var doneButton:DisplayObject;
public var hitAreaMC:DisplayObject;
public var lockedText:DisplayObject;
public var padLock:DisplayObject;
public var button4:DisplayObject;
public var button22:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var flag:DisplayObject;
public var rightButton:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var location:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var linkButton:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var padlock2:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button12:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var button19:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var wireFrame:DisplayObject;
public var padlock15:DisplayObject;
public var best:DisplayObject;
public var padlock19:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var button24:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var glassCenter:DisplayObject;
public var star18:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock21:DisplayObject;
public var padlock22:DisplayObject;
public var padlock23:DisplayObject;
}
}//package Classes
Section 176
//Player_countDownMC (Classes.Player_countDownMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_countDownMC extends MovieClipAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var glassCenter:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var padlock15:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var linkButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var padlock22:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var hitAreaMC:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var padlock2:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 177
//Player_dustMC (Classes.Player_dustMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_dustMC extends MovieClipAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var glassCenter:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var padlock15:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var linkButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var padlock22:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var hitAreaMC:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var padlock2:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 178
//Player_helpText3MC (Classes.Player_helpText3MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_helpText3MC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var glassCenter:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var padlock15:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var linkButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var padlock22:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var hitAreaMC:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var padlock2:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 179
//Player_helpText4MC (Classes.Player_helpText4MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_helpText4MC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var padlock20:DisplayObject;
public var button25:DisplayObject;
public var backButton:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock14:DisplayObject;
public var truckRamp:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var button23:DisplayObject;
public var leftRollOver:DisplayObject;
public var weightStat:DisplayObject;
public var colourButtons:DisplayObject;
public var star21:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var rightRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var startButton:DisplayObject;
public var description:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var button15:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var selectButton:DisplayObject;
public var cardHolder:DisplayObject;
public var wheel3:DisplayObject;
public var padlock13:DisplayObject;
public var doneButton:DisplayObject;
public var hitAreaMC:DisplayObject;
public var lockedText:DisplayObject;
public var padLock:DisplayObject;
public var button4:DisplayObject;
public var button22:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var flag:DisplayObject;
public var rightButton:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var location:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var linkButton:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var padlock2:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button12:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var button19:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var wireFrame:DisplayObject;
public var padlock15:DisplayObject;
public var best:DisplayObject;
public var padlock19:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var button24:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var glassCenter:DisplayObject;
public var star18:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock21:DisplayObject;
public var padlock22:DisplayObject;
public var padlock23:DisplayObject;
}
}//package Classes
Section 180
//Player_speedoMC (Classes.Player_speedoMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_speedoMC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var padlock20:DisplayObject;
public var button25:DisplayObject;
public var backButton:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock14:DisplayObject;
public var truckRamp:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var button23:DisplayObject;
public var leftRollOver:DisplayObject;
public var weightStat:DisplayObject;
public var colourButtons:DisplayObject;
public var star21:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var rightRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var startButton:DisplayObject;
public var description:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var button15:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var selectButton:DisplayObject;
public var cardHolder:DisplayObject;
public var wheel3:DisplayObject;
public var padlock13:DisplayObject;
public var doneButton:DisplayObject;
public var hitAreaMC:DisplayObject;
public var lockedText:DisplayObject;
public var padLock:DisplayObject;
public var button4:DisplayObject;
public var button22:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var flag:DisplayObject;
public var rightButton:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var location:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var linkButton:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var padlock2:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button12:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var button19:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var wireFrame:DisplayObject;
public var padlock15:DisplayObject;
public var best:DisplayObject;
public var padlock19:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var button24:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var glassCenter:DisplayObject;
public var star18:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock21:DisplayObject;
public var padlock22:DisplayObject;
public var padlock23:DisplayObject;
}
}//package Classes
Section 181
//Player_truckMC (Classes.Player_truckMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Player_truckMC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var button15:DisplayObject;
public var button25:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var glassCenter:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var weightStat:DisplayObject;
public var padlock15:DisplayObject;
public var truckRamp:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var padlock23:DisplayObject;
public var leftRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var star21:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var rightRollOver:DisplayObject;
public var linkButton:DisplayObject;
public var startButton:DisplayObject;
public var description:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var selectButton:DisplayObject;
public var cardHolder:DisplayObject;
public var wheel3:DisplayObject;
public var padlock22:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var hitAreaMC:DisplayObject;
public var padLock:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var flag:DisplayObject;
public var rightButton:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var location:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock6:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var padlock2:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var wireFrame:DisplayObject;
public var best:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var star15:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 182
//PlayField (Classes.PlayField)
package Classes {
import flash.display.*;
public class PlayField {
private var main:Main;
public var attract:Sprite;
public var pauseScreen:Sprite;
private var stage:Stage;
private var mainMovie:DisplayObject;
public var sprites:Sprite;
public var scroller_level1:Sprite;
public var scroller_level2:Sprite;
public var scroller_level3:Sprite;
public var transition:Sprite;
private var pauseScreenMC:Class;
public var scroller_level4:Sprite;
public var background:Sprite;
public var scroller_stadium:Sprite;
public var scroller_billboards:Sprite;
public var hud:Sprite;
public function PlayField(){
pauseScreenMC = PlayField_pauseScreenMC;
super();
main = Main.getInstance();
mainMovie = main.getMainMovie();
stage = main.getStage();
background = new Sprite();
scroller_stadium = new Sprite();
scroller_billboards = new Sprite();
scroller_level1 = new Sprite();
scroller_level2 = new Sprite();
scroller_level3 = new Sprite();
scroller_level4 = new Sprite();
sprites = new Sprite();
pauseScreen = new pauseScreenMC();
pauseScreen.visible = false;
hud = new Sprite();
attract = new Sprite();
transition = new Sprite();
stage.addChild(background);
stage.addChild(scroller_stadium);
stage.addChild(scroller_billboards);
stage.addChild(scroller_level1);
stage.addChild(scroller_level2);
stage.addChild(scroller_level3);
stage.addChild(scroller_level4);
stage.addChild(sprites);
stage.addChild(hud);
stage.addChild(attract);
stage.addChild(transition);
stage.addChild(pauseScreen);
}
public function toString():String{
return ("PlayField");
}
public function resume():void{
pauseScreen.visible = false;
}
public function pause():void{
pauseScreen.visible = true;
}
}
}//package Classes
Section 183
//PlayField_pauseScreenMC (Classes.PlayField_pauseScreenMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class PlayField_pauseScreenMC extends SpriteAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 184
//RampCoords (Classes.RampCoords)
package Classes {
public class RampCoords {
private var ramp1Coords:Array;
private var ramp3Coords:Array;
private var ramp4Coords:Array;
private var ramp5Coords:Array;
private var ramp6Coords:Array;
private var ramp7Coords:Array;
private var ramp8Coords:Array;
private var ramp9Coords:Array;
private var ramp2Coords:Array;
private var ramp10Coords:Array;
private var ramp11Coords:Array;
private var ramp12Coords:Array;
private var ramp13Coords:Array;
private var ramp14Coords:Array;
private var coordsStorage:Array;
public function RampCoords(){
ramp1Coords = [[7, 267, 267, 242, 267, 267]];
ramp2Coords = [[0, 267, 269, 212, 269, 267]];
ramp3Coords = [[0, 267, 214, 223, 214, 267], [215, 223, 268, 202, 268, 267]];
ramp4Coords = [[0, 267, 150, 236, 150, 267], [151, 267, 268, 190, 268, 267]];
ramp5Coords = [[0, 267, 94, 248, 94, 267], [95, 248, 268, 180, 268, 267]];
ramp6Coords = [[0, 267, 94, 248, 94, 267], [95, 248, 196, 208, 196, 267], [197, 208, 267, 163, 267, 267]];
ramp7Coords = [[2, 267, 93, 250, 93, 267], [94, 249, 137, 232, 137, 267], [137, 231, 267, 150, 267, 267]];
ramp8Coords = [[0, 267, 94, 248, 94, 267], [95, 248, 134, 232, 134, 267], [135, 232, 206, 187, 206, 267], [207, 187, 264, 136, 246, 267]];
ramp9Coords = [[0, 267, 94, 248, 94, 267], [95, 248, 137, 231, 137, 267], [138, 231, 170, 211, 170, 267], [171, 211, 266, 123, 266, 267]];
ramp10Coords = [[0, 267, 92, 248, 92, 267], [93, 248, 132, 232, 132, 267], [133, 232, 166, 212, 166, 267], [167, 212, 233, 150, 233, 267], [234, 150, 264, 108, 264, 267]];
ramp11Coords = [[0, 267, 92, 248, 92, 267], [93, 248, 132, 232, 132, 267], [133, 232, 166, 212, 166, 267], [167, 212, 202, 180, 202, 267], [203, 180, 264, 94, 264, 267]];
ramp12Coords = [[0, 267, 92, 248, 92, 267], [93, 248, 136, 232, 136, 267], [137, 232, 167, 212, 167, 267], [168, 212, 202, 180, 202, 267], [203, 180, 248, 116, 248, 267], [249, 116, 266, 73, 266, 267]];
ramp13Coords = [[0, 267, 94, 248, 94, 267], [95, 248, 135, 232, 135, 267], [136, 232, 168, 212, 168, 267], [169, 212, 202, 181, 202, 267], [203, 181, 232, 149, 232, 267], [233, 149, 266, 41, 266, 267]];
ramp14Coords = [[0, 267, 94, 248, 94, 267], [95, 248, 135, 232, 135, 267], [136, 232, 168, 212, 168, 267], [169, 212, 203, 181, 203, 267], [204, 181, 232, 141, 232, 267], [233, 141, 251, 85, 251, 267], [252, 85, 263, 4, 263, 267]];
super();
coordsStorage = new Array();
coordsStorage.push(ramp1Coords, ramp2Coords, ramp3Coords, ramp4Coords, ramp5Coords, ramp6Coords, ramp7Coords, ramp8Coords, ramp9Coords, ramp10Coords, ramp11Coords, ramp12Coords, ramp13Coords, ramp14Coords);
}
public function getPolyData(_arg1:int):Array{
return (coordsStorage[(_arg1 - 1)]);
}
}
}//package Classes
Section 185
//RampHandler (Classes.RampHandler)
package Classes {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
public class RampHandler {
private var stage:Stage;
private var scrollBar:Sprite;
private var mainMovie:DisplayObject;
private var scrollBarMC:Class;
private var mainFunc:Function;
private var playField:Sprite;
private var ramp_selectButtonMC:Class;
private var rampUpButtonMC:Class;
private var helpText1MC:Class;
private var ramp_upButton:MovieClip;
private var soundHandler:SoundHandler;
private var rampDownButtonMC:Class;
private var playFieldScrollArea:Rectangle;
private var ramp_downButton:MovieClip;
private var helpText5_flag:Boolean;// = false
private var sprite:MovieClip;
private var helpText1_flag:Boolean;// = false
private var scroller:Scroller;
private var previousPlayFieldXPos:Number;
private var main:Main;
private var currentRampNumber:int;
private var helpText5MC:Class;
private var hitAreaMC:Sprite;
private var ramp_selectButton:MovieClip;
private var scrollBarRunner:Sprite;
private var helpText1:Sprite;
private var helpText2:Sprite;
private var helpText2_flag:Boolean;// = false
private var scrollBarHeld:Boolean;
private var helpText5:Sprite;
private var rampsMC:Class;
private var helpText2MC:Class;
private var dragBoundary:Rectangle;
private var gameControler:GameController;
public function RampHandler(){
rampsMC = RampHandler_rampsMC;
ramp_selectButtonMC = RampHandler_ramp_selectButtonMC;
rampUpButtonMC = RampHandler_rampUpButtonMC;
rampDownButtonMC = RampHandler_rampDownButtonMC;
helpText1MC = RampHandler_helpText1MC;
helpText2MC = RampHandler_helpText2MC;
helpText5MC = RampHandler_helpText5MC;
scrollBarMC = RampHandler_scrollBarMC;
dragBoundary = new Rectangle(0, -4, (300 - 27), 0);
super();
main = Main.getInstance();
mainMovie = main.getMainMovie();
stage = main.getStage();
playField = main.getInitObj().getPlayField().sprites;
gameControler = main.getInitObj().getGameController();
scroller = gameControler.getScroller();
soundHandler = main.getInitObj().getSoundHandler();
sprite = new rampsMC();
sprite.y = 158;
ramp_selectButton = new ramp_selectButtonMC();
ramp_selectButton.x = 2800;
ramp_selectButton.y = 344;
ramp_selectButton.gotoAndStop(1);
ramp_upButton = new rampUpButtonMC();
ramp_upButton.x = (ramp_selectButton.x + 28);
ramp_upButton.y = (ramp_selectButton.y - 36);
ramp_upButton.gotoAndStop(1);
ramp_downButton = new rampDownButtonMC();
ramp_downButton.x = ramp_upButton.x;
ramp_downButton.y = ((ramp_selectButton.y + ramp_selectButton.height) + 4);
ramp_downButton.gotoAndStop(1);
helpText1 = new helpText1MC();
helpText1.x = 8;
helpText1.y = 45;
helpText2 = new helpText2MC();
helpText2.x = 55;
helpText2.y = 45;
helpText5 = new helpText5MC();
helpText5.x = 31;
helpText5.y = 45;
scrollBarRunner = new scrollBarMC();
scrollBarRunner.x = 170;
scrollBarRunner.y = 422;
currentRampNumber = 7;
}
public function houseKeeping():void{
if (sprite.parent != null){
playField.removeChild(sprite);
};
}
private function mouseReleased(_arg1:MouseEvent):void{
scrollBarHeld = false;
scrollBar.stopDrag();
}
public function rampSelectStart():void{
ramp_upButton.alpha = 1;
ramp_downButton.alpha = 1;
playField.addChild(ramp_selectButton);
playField.addChild(ramp_upButton);
playField.addChild(ramp_downButton);
initButton(ramp_selectButton, ramp_selectButton_pressed);
initButton(ramp_upButton, ramp_upButton_pressed);
initButton(ramp_downButton, ramp_downButton_pressed);
if (helpText1_flag == false){
helpText1_flag = true;
stage.addChild(helpText1);
} else {
if (helpText5_flag == false){
if (gameControler.getCarData().getlockedCarLevelFlag(gameControler.level) == true){
helpText5_flag = true;
stage.addChild(helpText5);
};
};
};
playField.x = -(((main.getInitObj().getGameController().getLevelPlotter().endMostCarXpos - 300) + 8));
previousPlayFieldXPos = playField.x;
scrollBar_init();
}
public function init():void{
sprite.x = 2600;
sprite.gotoAndStop(currentRampNumber);
hitAreaMC = sprite["hitAreaMC"];
var _local1:int = gameControler.getLevelPlotter().endMostCarXpos;
playFieldScrollArea = new Rectangle((sprite.x - 200), 0, (_local1 - (sprite.x + 100)), 0);
playField.addChild(sprite);
}
private function scrollBar_kill():void{
scrollBar.removeEventListener(MouseEvent.MOUSE_DOWN, mousePressed);
stage.removeEventListener(MouseEvent.MOUSE_UP, mouseReleased);
stage.removeEventListener(MouseEvent.MOUSE_MOVE, mouseMove);
stage.removeChild(scrollBarRunner);
}
public function getHitAreaMC():Sprite{
return (hitAreaMC);
}
private function ramp_upButton_pressed(_arg1:MouseEvent):void{
soundHandler.play_buttonClick();
if (++currentRampNumber == 14){
killButton(ramp_upButton, ramp_upButton_pressed);
ramp_upButton.alpha = 0.4;
};
initButton(ramp_downButton, ramp_downButton_pressed);
ramp_downButton.alpha = 1;
sprite.gotoAndStop(currentRampNumber);
if (helpText2.parent != null){
stage.removeChild(helpText2);
};
}
private function mouseMove(_arg1:MouseEvent):void{
if (scrollBarHeld == false){
return;
};
if (scrollBar.x > dragBoundary.width){
scrollBar.x = dragBoundary.width;
};
var _local2:int = (((scrollBar.x - dragBoundary.x) / (dragBoundary.width - dragBoundary.x)) * 100);
var _local3:int = ((-(playFieldScrollArea.width) / 100) * _local2);
previousPlayFieldXPos = playField.x;
playField.x = -((playFieldScrollArea.x + (dragBoundary.x - _local3)));
if (playField.x > previousPlayFieldXPos){
gameControler.getPlayer().scrollLeft((playField.x - previousPlayFieldXPos));
} else {
gameControler.getPlayer().scrollRight((previousPlayFieldXPos - playField.x));
};
if (_local2 < 40){
if (helpText2_flag == false){
helpText2_flag = true;
stage.addChild(helpText2);
};
};
}
private function scrollBar_init():void{
scrollBar = scrollBarRunner["dragger"];
scrollBar.x = dragBoundary.width;
scrollBar.useHandCursor = true;
scrollBar.buttonMode = true;
scrollBarHeld = false;
scrollBar.addEventListener(MouseEvent.MOUSE_DOWN, mousePressed);
stage.addEventListener(MouseEvent.MOUSE_UP, mouseReleased);
stage.addEventListener(MouseEvent.MOUSE_MOVE, mouseMove);
stage.addChild(scrollBarRunner);
}
private function ramp_downButton_pressed(_arg1:MouseEvent):void{
soundHandler.play_buttonClick();
if (--currentRampNumber == 1){
killButton(ramp_downButton, ramp_downButton_pressed);
ramp_downButton.alpha = 0.4;
};
initButton(ramp_upButton, ramp_upButton_pressed);
ramp_upButton.alpha = 1;
sprite.gotoAndStop(currentRampNumber);
if (helpText2.parent != null){
stage.removeChild(helpText2);
};
}
private function killButton(_arg1:MovieClip, _arg2:Function):void{
_arg1.useHandCursor = false;
_arg1.buttonMode = false;
_arg1.gotoAndStop(1);
_arg1.removeEventListener(MouseEvent.CLICK, _arg2);
}
private function ramp_selectButton_pressed(_arg1:MouseEvent):void{
soundHandler.play_buttonClick();
killButton(ramp_selectButton, ramp_selectButton_pressed);
playField.removeChild(ramp_selectButton);
playField.removeChild(ramp_upButton);
playField.removeChild(ramp_downButton);
if (helpText2.parent != null){
stage.removeChild(helpText2);
};
scrollBar_kill();
gameControler.rampSelected(sprite.currentFrame);
}
public function getRampPosition():Point{
var _local1:Point = new Point(sprite.x, sprite.y);
return (_local1);
}
private function mousePressed(_arg1:MouseEvent):void{
scrollBar.startDrag(false, dragBoundary);
scrollBarHeld = true;
if (helpText1.parent != null){
stage.removeChild(helpText1);
};
if (helpText5.parent != null){
stage.removeChild(helpText5);
};
}
private function initButton(_arg1:MovieClip, _arg2:Function):void{
_arg1.useHandCursor = true;
_arg1.buttonMode = true;
_arg1.enabled = true;
_arg1.mouseChildren = true;
_arg1.gotoAndStop(1);
_arg1.addEventListener(MouseEvent.CLICK, _arg2);
}
public function toString():String{
return ("Scroller");
}
}
}//package Classes
Section 186
//RampHandler_helpText1MC (Classes.RampHandler_helpText1MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class RampHandler_helpText1MC extends SpriteAsset {
public var description:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var retryButton:DisplayObject;
public var spilLogo:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var colourButtons:DisplayObject;
public var leftRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var muteRollOver:DisplayObject;
public var reflection:DisplayObject;
public var photo:DisplayObject;
public var startButton:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var scroller:DisplayObject;
public var wheel3:DisplayObject;
public var hitAreaMC:DisplayObject;
public var padLock:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var liveryPhotoAnim:DisplayObject;
public var photoHolder:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var score:DisplayObject;
public var pauseGhosted:DisplayObject;
public var par:DisplayObject;
public var muteButton:DisplayObject;
public var pauseButton:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock15:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var cardHolder:DisplayObject;
public var weightStat:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var levelSelectButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var tryAndGetTween:DisplayObject;
public var backButton:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock23:DisplayObject;
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var omgTextTween:DisplayObject;
public var padlock22:DisplayObject;
public var pauseRollOver:DisplayObject;
public var glassCenter:DisplayObject;
public var button22:DisplayObject;
public var fireworks:DisplayObject;
public var truckRamp:DisplayObject;
public var resetGhosted:DisplayObject;
public var rightRollOver:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var liveryButton:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var button7:DisplayObject;
public var selectButton:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var resetRollOver:DisplayObject;
public var resetButton:DisplayObject;
public var photoAnim:DisplayObject;
public var topSpeedStat:DisplayObject;
public var flag:DisplayObject;
public var target:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock6:DisplayObject;
public var linkButton:DisplayObject;
public var padlock2:DisplayObject;
public var best:DisplayObject;
public var wireFrame:DisplayObject;
public var star12:DisplayObject;
public var star15:DisplayObject;
public var dateText:DisplayObject;
}
}//package Classes
Section 187
//RampHandler_helpText2MC (Classes.RampHandler_helpText2MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class RampHandler_helpText2MC extends SpriteAsset {
public var description:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var retryButton:DisplayObject;
public var spilLogo:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var colourButtons:DisplayObject;
public var leftRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var muteRollOver:DisplayObject;
public var reflection:DisplayObject;
public var photo:DisplayObject;
public var startButton:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var scroller:DisplayObject;
public var wheel3:DisplayObject;
public var hitAreaMC:DisplayObject;
public var padLock:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var liveryPhotoAnim:DisplayObject;
public var photoHolder:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var score:DisplayObject;
public var pauseGhosted:DisplayObject;
public var par:DisplayObject;
public var muteButton:DisplayObject;
public var pauseButton:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock15:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var cardHolder:DisplayObject;
public var weightStat:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var levelSelectButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var tryAndGetTween:DisplayObject;
public var backButton:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock23:DisplayObject;
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var omgTextTween:DisplayObject;
public var padlock22:DisplayObject;
public var pauseRollOver:DisplayObject;
public var glassCenter:DisplayObject;
public var button22:DisplayObject;
public var fireworks:DisplayObject;
public var truckRamp:DisplayObject;
public var resetGhosted:DisplayObject;
public var rightRollOver:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var liveryButton:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var button7:DisplayObject;
public var selectButton:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var resetRollOver:DisplayObject;
public var resetButton:DisplayObject;
public var photoAnim:DisplayObject;
public var topSpeedStat:DisplayObject;
public var flag:DisplayObject;
public var target:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var dragger:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock6:DisplayObject;
public var linkButton:DisplayObject;
public var padlock2:DisplayObject;
public var best:DisplayObject;
public var wireFrame:DisplayObject;
public var star12:DisplayObject;
public var star15:DisplayObject;
public var dateText:DisplayObject;
}
}//package Classes
Section 188
//RampHandler_helpText5MC (Classes.RampHandler_helpText5MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class RampHandler_helpText5MC extends SpriteAsset {
public var description:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var retryButton:DisplayObject;
public var spilLogo:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var colourButtons:DisplayObject;
public var leftRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var muteRollOver:DisplayObject;
public var reflection:DisplayObject;
public var photo:DisplayObject;
public var startButton:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var scroller:DisplayObject;
public var wheel3:DisplayObject;
public var hitAreaMC:DisplayObject;
public var padLock:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var liveryPhotoAnim:DisplayObject;
public var photoHolder:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var score:DisplayObject;
public var pauseGhosted:DisplayObject;
public var par:DisplayObject;
public var muteButton:DisplayObject;
public var pauseButton:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock15:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var cardHolder:DisplayObject;
public var weightStat:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var levelSelectButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var tryAndGetTween:DisplayObject;
public var backButton:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock23:DisplayObject;
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var omgTextTween:DisplayObject;
public var padlock22:DisplayObject;
public var pauseRollOver:DisplayObject;
public var glassCenter:DisplayObject;
public var button22:DisplayObject;
public var fireworks:DisplayObject;
public var truckRamp:DisplayObject;
public var resetGhosted:DisplayObject;
public var rightRollOver:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var liveryButton:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var button7:DisplayObject;
public var selectButton:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var resetRollOver:DisplayObject;
public var resetButton:DisplayObject;
public var photoAnim:DisplayObject;
public var topSpeedStat:DisplayObject;
public var flag:DisplayObject;
public var target:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock6:DisplayObject;
public var linkButton:DisplayObject;
public var padlock2:DisplayObject;
public var best:DisplayObject;
public var wireFrame:DisplayObject;
public var star12:DisplayObject;
public var star15:DisplayObject;
public var dateText:DisplayObject;
}
}//package Classes
Section 189
//RampHandler_ramp_selectButtonMC (Classes.RampHandler_ramp_selectButtonMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class RampHandler_ramp_selectButtonMC extends MovieClipAsset {
public var description:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var retryButton:DisplayObject;
public var spilLogo:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var colourButtons:DisplayObject;
public var leftRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var muteRollOver:DisplayObject;
public var reflection:DisplayObject;
public var photo:DisplayObject;
public var startButton:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var scroller:DisplayObject;
public var wheel3:DisplayObject;
public var hitAreaMC:DisplayObject;
public var padLock:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var liveryPhotoAnim:DisplayObject;
public var photoHolder:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var score:DisplayObject;
public var pauseGhosted:DisplayObject;
public var par:DisplayObject;
public var muteButton:DisplayObject;
public var pauseButton:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock15:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var cardHolder:DisplayObject;
public var weightStat:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var levelSelectButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var tryAndGetTween:DisplayObject;
public var backButton:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock23:DisplayObject;
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var omgTextTween:DisplayObject;
public var padlock22:DisplayObject;
public var pauseRollOver:DisplayObject;
public var glassCenter:DisplayObject;
public var button22:DisplayObject;
public var fireworks:DisplayObject;
public var truckRamp:DisplayObject;
public var resetGhosted:DisplayObject;
public var rightRollOver:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var liveryButton:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var button7:DisplayObject;
public var selectButton:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var resetRollOver:DisplayObject;
public var resetButton:DisplayObject;
public var photoAnim:DisplayObject;
public var topSpeedStat:DisplayObject;
public var flag:DisplayObject;
public var target:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock6:DisplayObject;
public var linkButton:DisplayObject;
public var padlock2:DisplayObject;
public var best:DisplayObject;
public var wireFrame:DisplayObject;
public var star12:DisplayObject;
public var star15:DisplayObject;
public var dateText:DisplayObject;
}
}//package Classes
Section 190
//RampHandler_rampDownButtonMC (Classes.RampHandler_rampDownButtonMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class RampHandler_rampDownButtonMC extends MovieClipAsset {
public var description:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var retryButton:DisplayObject;
public var spilLogo:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var colourButtons:DisplayObject;
public var leftRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var muteRollOver:DisplayObject;
public var reflection:DisplayObject;
public var photo:DisplayObject;
public var startButton:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var scroller:DisplayObject;
public var wheel3:DisplayObject;
public var hitAreaMC:DisplayObject;
public var padLock:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var liveryPhotoAnim:DisplayObject;
public var photoHolder:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var score:DisplayObject;
public var pauseGhosted:DisplayObject;
public var par:DisplayObject;
public var muteButton:DisplayObject;
public var pauseButton:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock15:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var cardHolder:DisplayObject;
public var weightStat:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var levelSelectButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var tryAndGetTween:DisplayObject;
public var backButton:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock23:DisplayObject;
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var omgTextTween:DisplayObject;
public var padlock22:DisplayObject;
public var pauseRollOver:DisplayObject;
public var glassCenter:DisplayObject;
public var button22:DisplayObject;
public var fireworks:DisplayObject;
public var truckRamp:DisplayObject;
public var resetGhosted:DisplayObject;
public var rightRollOver:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var liveryButton:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var button7:DisplayObject;
public var selectButton:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var resetRollOver:DisplayObject;
public var resetButton:DisplayObject;
public var photoAnim:DisplayObject;
public var topSpeedStat:DisplayObject;
public var flag:DisplayObject;
public var target:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var dragger:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock6:DisplayObject;
public var linkButton:DisplayObject;
public var padlock2:DisplayObject;
public var best:DisplayObject;
public var wireFrame:DisplayObject;
public var star12:DisplayObject;
public var star15:DisplayObject;
public var dateText:DisplayObject;
}
}//package Classes
Section 191
//RampHandler_rampsMC (Classes.RampHandler_rampsMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class RampHandler_rampsMC extends MovieClipAsset {
public var description:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var retryButton:DisplayObject;
public var spilLogo:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var colourButtons:DisplayObject;
public var leftRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var muteRollOver:DisplayObject;
public var reflection:DisplayObject;
public var photo:DisplayObject;
public var startButton:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var scroller:DisplayObject;
public var wheel3:DisplayObject;
public var hitAreaMC:DisplayObject;
public var padLock:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var liveryPhotoAnim:DisplayObject;
public var photoHolder:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var score:DisplayObject;
public var pauseGhosted:DisplayObject;
public var par:DisplayObject;
public var muteButton:DisplayObject;
public var pauseButton:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock15:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var cardHolder:DisplayObject;
public var weightStat:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var levelSelectButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var tryAndGetTween:DisplayObject;
public var backButton:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock23:DisplayObject;
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var omgTextTween:DisplayObject;
public var padlock22:DisplayObject;
public var pauseRollOver:DisplayObject;
public var glassCenter:DisplayObject;
public var button22:DisplayObject;
public var fireworks:DisplayObject;
public var truckRamp:DisplayObject;
public var resetGhosted:DisplayObject;
public var rightRollOver:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var liveryButton:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var button7:DisplayObject;
public var selectButton:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var resetRollOver:DisplayObject;
public var resetButton:DisplayObject;
public var photoAnim:DisplayObject;
public var topSpeedStat:DisplayObject;
public var flag:DisplayObject;
public var target:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock6:DisplayObject;
public var linkButton:DisplayObject;
public var padlock2:DisplayObject;
public var best:DisplayObject;
public var wireFrame:DisplayObject;
public var star12:DisplayObject;
public var star15:DisplayObject;
public var dateText:DisplayObject;
}
}//package Classes
Section 192
//RampHandler_rampUpButtonMC (Classes.RampHandler_rampUpButtonMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class RampHandler_rampUpButtonMC extends MovieClipAsset {
public var description:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var retryButton:DisplayObject;
public var spilLogo:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var colourButtons:DisplayObject;
public var leftRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var muteRollOver:DisplayObject;
public var reflection:DisplayObject;
public var photo:DisplayObject;
public var startButton:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var scroller:DisplayObject;
public var wheel3:DisplayObject;
public var hitAreaMC:DisplayObject;
public var padLock:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var liveryPhotoAnim:DisplayObject;
public var photoHolder:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var score:DisplayObject;
public var pauseGhosted:DisplayObject;
public var par:DisplayObject;
public var muteButton:DisplayObject;
public var pauseButton:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock15:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var cardHolder:DisplayObject;
public var weightStat:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var levelSelectButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var tryAndGetTween:DisplayObject;
public var backButton:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock23:DisplayObject;
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var omgTextTween:DisplayObject;
public var padlock22:DisplayObject;
public var pauseRollOver:DisplayObject;
public var glassCenter:DisplayObject;
public var button22:DisplayObject;
public var fireworks:DisplayObject;
public var truckRamp:DisplayObject;
public var resetGhosted:DisplayObject;
public var rightRollOver:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var liveryButton:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var button7:DisplayObject;
public var selectButton:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var resetRollOver:DisplayObject;
public var resetButton:DisplayObject;
public var photoAnim:DisplayObject;
public var topSpeedStat:DisplayObject;
public var flag:DisplayObject;
public var target:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock6:DisplayObject;
public var linkButton:DisplayObject;
public var padlock2:DisplayObject;
public var best:DisplayObject;
public var wireFrame:DisplayObject;
public var star12:DisplayObject;
public var star15:DisplayObject;
public var dateText:DisplayObject;
}
}//package Classes
Section 193
//RampHandler_scrollBarMC (Classes.RampHandler_scrollBarMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class RampHandler_scrollBarMC extends SpriteAsset {
public var description:DisplayObject;
public var star16:DisplayObject;
public var star18:DisplayObject;
public var retryButton:DisplayObject;
public var spilLogo:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var speedText:DisplayObject;
public var colourButtons:DisplayObject;
public var leftRollOver:DisplayObject;
public var leftButton:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var muteRollOver:DisplayObject;
public var reflection:DisplayObject;
public var photo:DisplayObject;
public var startButton:DisplayObject;
public var wheel1:DisplayObject;
public var wheel2:DisplayObject;
public var flagHolder:DisplayObject;
public var scroller:DisplayObject;
public var wheel3:DisplayObject;
public var hitAreaMC:DisplayObject;
public var padLock:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var liveryPhotoAnim:DisplayObject;
public var photoHolder:DisplayObject;
public var carName:DisplayObject;
public var needle:DisplayObject;
public var score:DisplayObject;
public var pauseGhosted:DisplayObject;
public var par:DisplayObject;
public var muteButton:DisplayObject;
public var pauseButton:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock15:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var cardHolder:DisplayObject;
public var weightStat:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var levelSelectButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var tryAndGetTween:DisplayObject;
public var backButton:DisplayObject;
public var accelerationStat:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock23:DisplayObject;
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var omgTextTween:DisplayObject;
public var padlock22:DisplayObject;
public var pauseRollOver:DisplayObject;
public var glassCenter:DisplayObject;
public var button22:DisplayObject;
public var fireworks:DisplayObject;
public var truckRamp:DisplayObject;
public var resetGhosted:DisplayObject;
public var rightRollOver:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var liveryButton:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var button7:DisplayObject;
public var selectButton:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var resetRollOver:DisplayObject;
public var resetButton:DisplayObject;
public var photoAnim:DisplayObject;
public var topSpeedStat:DisplayObject;
public var flag:DisplayObject;
public var target:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var dragger:DisplayObject;
public var styleStat:DisplayObject;
public var padlock3:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock6:DisplayObject;
public var linkButton:DisplayObject;
public var padlock2:DisplayObject;
public var best:DisplayObject;
public var wireFrame:DisplayObject;
public var star12:DisplayObject;
public var star15:DisplayObject;
public var dateText:DisplayObject;
}
}//package Classes
Section 194
//Scroller (Classes.Scroller)
package Classes {
import flash.display.*;
public class Scroller {
private var stadium:MovieClip;
private var stage:Stage;
private var mainMovie:DisplayObject;
private var playField_billboards:Sprite;
private var stadiumMC:Class;
private var levelPlotter:LevelPlotter;
private var billboards:MovieClip;
private var playField_stadium:Sprite;
private var floor1:Sprite;
private var playField_level2:Sprite;
private var playField_level3:Sprite;
private var playField_level4:Sprite;
private var billboardsMC:Class;
private var playField_level1:Sprite;
private var floor3:Sprite;
private var floor4:Sprite;
private var floor2:Sprite;
private var main:Main;
private var floor1MC:Class;
private var floor2MC:Class;
private var floor3MC:Class;
private var floor4MC:Class;
public function Scroller(){
floor4MC = Scroller_floor4MC;
floor3MC = Scroller_floor3MC;
floor2MC = Scroller_floor2MC;
floor1MC = Scroller_floor1MC;
stadiumMC = Scroller_stadiumMC;
billboardsMC = Scroller_billboardsMC;
super();
main = Main.getInstance();
mainMovie = main.getMainMovie();
stage = main.getStage();
playField_stadium = main.getInitObj().getPlayField().scroller_stadium;
stadium = new stadiumMC();
stadium.x = 0;
stadium.y = 71;
playField_stadium.addChild(stadium);
playField_billboards = main.getInitObj().getPlayField().scroller_billboards;
billboards = new billboardsMC();
billboards.x = 0;
billboards.y = 315;
playField_billboards.addChild(billboards);
var _local1:String = stage.loaderInfo.url;
if (_local1.lastIndexOf("_agame") != -1){
billboards.gotoAndStop(1);
} else {
if (_local1.lastIndexOf("_spielen") != -1){
billboards.gotoAndStop(5);
} else {
if (_local1.lastIndexOf("_jeu") != -1){
billboards.gotoAndStop(4);
} else {
if (_local1.lastIndexOf("_spelNL") != -1){
billboards.gotoAndStop(3);
} else {
if (_local1.lastIndexOf("_gamesCOID") != -1){
billboards.gotoAndStop(11);
} else {
if (_local1.lastIndexOf("_spelaSE") != -1){
billboards.gotoAndStop(7);
} else {
if (_local1.lastIndexOf("_egames") != -1){
billboards.gotoAndStop(6);
} else {
if (_local1.lastIndexOf("_zapjuegos") != -1){
billboards.gotoAndStop(9);
} else {
if (_local1.lastIndexOf("_clickjogos") != -1){
billboards.gotoAndStop(10);
} else {
if (_local1.lastIndexOf("_gameCN") != -1){
billboards.gotoAndStop(2);
} else {
if (_local1.lastIndexOf("_flashgames") != -1){
billboards.gotoAndStop(12);
} else {
if (_local1.lastIndexOf("_gioco") != -1){
billboards.gotoAndStop(1);
} else {
if (_local1.lastIndexOf("_gry") != -1){
billboards.gotoAndStop(13);
} else {
if (_local1.lastIndexOf("_ojogos") != -1){
billboards.gotoAndStop(14);
} else {
billboards.gotoAndStop(1);
};
};
};
};
};
};
};
};
};
};
};
};
};
};
playField_level4 = main.getInitObj().getPlayField().scroller_level4;
floor4 = new floor4MC();
floor4.x = 0;
floor4.y = 357;
playField_level4.addChild(floor4);
playField_level3 = main.getInitObj().getPlayField().scroller_level3;
floor3 = new floor3MC();
floor3.x = 0;
floor3.y = 357;
playField_level3.addChild(floor3);
playField_level2 = main.getInitObj().getPlayField().scroller_level2;
floor2 = new floor2MC();
floor2.x = 0;
floor2.y = 357;
playField_level2.addChild(floor2);
playField_level1 = main.getInitObj().getPlayField().scroller_level1;
floor1 = new floor1MC();
floor1.x = 0;
floor1.y = 357;
playField_level1.addChild(floor1);
}
public function setCountry(_arg1:int):void{
stadium.gotoAndStop((_arg1 + 1));
}
public function scrollRight(_arg1:Number):void{
playField_level4.x = (playField_level4.x - (_arg1 + (_arg1 * 0.5)));
if (playField_level4.x <= -1280){
playField_level4.x = (playField_level4.x + 0x0500);
};
playField_level3.x = (playField_level3.x - _arg1);
if (playField_level3.x <= -1280){
playField_level3.x = (playField_level3.x + 0x0500);
};
playField_level2.x = (playField_level2.x - (_arg1 - (_arg1 / 3)));
if (playField_level2.x <= -1280){
playField_level2.x = (playField_level2.x + 0x0500);
};
playField_level1.x = (playField_level1.x - (_arg1 - (_arg1 / 4)));
if (playField_level1.x <= -1280){
playField_level1.x = (playField_level1.x + 0x0500);
};
playField_billboards.x = (playField_billboards.x - (_arg1 * 0.5));
if (playField_billboards.x <= -1026){
playField_billboards.x = (playField_billboards.x + 1026);
};
var _local2:Number = ((_arg1 * 0.5) - 0.2);
if (_local2 > 0){
playField_stadium.x = (playField_stadium.x - _local2);
if (playField_stadium.x <= -1280){
playField_stadium.x = (playField_stadium.x + 0x0500);
};
};
levelPlotter.scrollRight();
}
public function scrollLeft(_arg1:Number):void{
playField_level4.x = (playField_level4.x + (_arg1 + (_arg1 * 0.5)));
if (playField_level4.x >= 0x0500){
playField_level4.x = (playField_level4.x - 0x0500);
};
playField_level3.x = (playField_level3.x + _arg1);
if (playField_level3.x >= 0x0500){
playField_level3.x = (playField_level3.x - 0x0500);
};
playField_level2.x = (playField_level2.x + (_arg1 - (_arg1 / 3)));
if (playField_level2.x >= 0x0500){
playField_level2.x = (playField_level2.x - 0x0500);
};
playField_level1.x = (playField_level1.x + (_arg1 - (_arg1 / 4)));
if (playField_level1.x >= 0x0500){
playField_level1.x = (playField_level1.x - 0x0500);
};
playField_billboards.x = (playField_billboards.x + (_arg1 * 0.5));
if (playField_billboards.x >= 1026){
playField_billboards.x = (playField_billboards.x - 1026);
};
playField_stadium.x = (playField_stadium.x + ((_arg1 * 0.5) - 0.2));
if (playField_stadium.x >= 0x0500){
playField_stadium.x = (playField_stadium.x - 0x0500);
};
levelPlotter.scrollLeft();
}
public function init():void{
if (levelPlotter == null){
levelPlotter = main.getInitObj().getGameController().getLevelPlotter();
};
playField_stadium.x = 0;
playField_billboards.x = 0;
playField_level4.x = 0;
playField_level3.x = 0;
playField_level2.x = 0;
playField_level1.x = 0;
}
public function toString():String{
return ("Scroller");
}
}
}//package Classes
Section 195
//Scroller_billboardsMC (Classes.Scroller_billboardsMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Scroller_billboardsMC extends MovieClipAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var padlock22:DisplayObject;
public var star18:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var startButton:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var creditsButton:DisplayObject;
public var loadedButton:DisplayObject;
public var par:DisplayObject;
public var location:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock6:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock2:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var linkButton:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock13:DisplayObject;
public var padlock15:DisplayObject;
public var best:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock19:DisplayObject;
public var padlock23:DisplayObject;
}
}//package Classes
Section 196
//Scroller_floor1MC (Classes.Scroller_floor1MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Scroller_floor1MC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var padlock22:DisplayObject;
public var star18:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var startButton:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var creditsButton:DisplayObject;
public var loadedButton:DisplayObject;
public var par:DisplayObject;
public var location:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock6:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock2:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var linkButton:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock13:DisplayObject;
public var padlock15:DisplayObject;
public var best:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock19:DisplayObject;
public var padlock23:DisplayObject;
}
}//package Classes
Section 197
//Scroller_floor2MC (Classes.Scroller_floor2MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Scroller_floor2MC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var padlock22:DisplayObject;
public var star18:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var startButton:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var creditsButton:DisplayObject;
public var loadedButton:DisplayObject;
public var par:DisplayObject;
public var location:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock6:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock2:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var linkButton:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock13:DisplayObject;
public var padlock15:DisplayObject;
public var best:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock19:DisplayObject;
public var padlock23:DisplayObject;
}
}//package Classes
Section 198
//Scroller_floor3MC (Classes.Scroller_floor3MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Scroller_floor3MC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var padlock22:DisplayObject;
public var star18:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var startButton:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var creditsButton:DisplayObject;
public var loadedButton:DisplayObject;
public var par:DisplayObject;
public var location:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock6:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock2:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var linkButton:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock13:DisplayObject;
public var padlock15:DisplayObject;
public var best:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock19:DisplayObject;
public var padlock23:DisplayObject;
}
}//package Classes
Section 199
//Scroller_floor4MC (Classes.Scroller_floor4MC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Scroller_floor4MC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var padlock22:DisplayObject;
public var star18:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var startButton:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var creditsButton:DisplayObject;
public var loadedButton:DisplayObject;
public var par:DisplayObject;
public var location:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock6:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock2:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var linkButton:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock13:DisplayObject;
public var padlock15:DisplayObject;
public var best:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock19:DisplayObject;
public var padlock23:DisplayObject;
}
}//package Classes
Section 200
//Scroller_stadiumMC (Classes.Scroller_stadiumMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Scroller_stadiumMC extends MovieClipAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var padlock22:DisplayObject;
public var star18:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var star21:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var startButton:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var button3:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button4:DisplayObject;
public var creditsButton:DisplayObject;
public var loadedButton:DisplayObject;
public var par:DisplayObject;
public var location:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock6:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock9:DisplayObject;
public var padlock2:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var linkButton:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var padlock17:DisplayObject;
public var padlock18:DisplayObject;
public var padlock13:DisplayObject;
public var padlock15:DisplayObject;
public var best:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var button24:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
public var padlock19:DisplayObject;
public var padlock23:DisplayObject;
}
}//package Classes
Section 201
//SoundHandler (Classes.SoundHandler)
package Classes {
import flash.display.*;
import flash.events.*;
import flash.media.*;
public class SoundHandler {
private var engine2_3SFX:Class;
private var engine4_5SFX:Class;
private var masterVolume:Number;// = 1
private var engine1_5SFX:Class;
private var engine1_1:Sound;
private var engine1_2:Sound;
private var engine1_3:Sound;
private var engine1_4:Sound;
private var engine1_5:Sound;
private var engine1_6:Sound;
private var crashSoundsStorage:Array;
private var mod1_channel:SoundChannel;
private var crash5SFX:Class;
private var engine3_6Channel:SoundChannel;
private var wheelSpin:Sound;
private var crowdcheerairhornSFX:Class;
private var engine3_2SFX:Class;
private var engine2_5Channel:SoundChannel;
private var crowdcheersmall:Sound;
private var engine1_4Channel:SoundChannel;
private var go321SFX:Class;
private var engine4_6SFX:Class;
private var engine2_4SFX:Class;
private var dooropenSFX:Class;
private var engine4_5Channel:SoundChannel;
private var engine3_4Channel:SoundChannel;
private var engine1_6SFX:Class;
private var engine4_1SFX:Class;
private var engine1_2Channel:SoundChannel;
private var tune1SFX:Class;
private var crash6SFX:Class;
private var engine2_3Channel:SoundChannel;
private var mod1_transform:SoundTransform;
private var engine3_3SFX:Class;
private var engine1_1SFX:Class;
private var crash1SFX:Class;
private var engine4_3Channel:SoundChannel;
private var crowdcheersmallSFX:Class;
private var engine2_5SFX:Class;
private var engine2_1Channel:SoundChannel;
private var engine3_2Channel:SoundChannel;
private var fireworks_channel:SoundChannel;
private var engine4_2SFX:Class;
private var spinSFX:Class;
private var tune2SFX:Class;
private var crash7SFX:Class;
private var dooropen:Sound;
private var engine4_1Channel:SoundChannel;
private var engine1_2SFX:Class;
private var engine3_4SFX:Class;
private var fireworks:Sound;
private var crowdcheerairhorn:Sound;
private var crash2SFX:Class;
private var engine2_6Channel:SoundChannel;
private var engine2_6SFX:Class;
private var engine1_5Channel:SoundChannel;
private var buttonClickSFX:Class;
private var mod2_channel:SoundChannel;
private var engine4_3SFX:Class;
private var engine2_1SFX:Class;
private var crash8SFX:Class;
private var engine3_5Channel:SoundChannel;
private var mod2_transform:SoundTransform;
private var engine3_5SFX:Class;
private var engine1_3Channel:SoundChannel;
private var engine4_6Channel:SoundChannel;
private var engine1_3SFX:Class;
private var engine4_1:Sound;
private var engine4_2:Sound;
private var engine4_3:Sound;
private var engine4_4:Sound;
private var engine4_5:Sound;
private var crash1:Sound;
private var crash2:Sound;
private var crash3:Sound;
private var engine2_4Channel:SoundChannel;
private var mod1:Sound;
private var mod2:Sound;
private var crash8:Sound;
private var crash4:Sound;
private var crash5:Sound;
private var crash7:Sound;
private var engine4_6:Sound;
private var crash3SFX:Class;
private var buttonClick:Sound;
private var controllerSprite:Sprite;
private var crash6:Sound;
private var fadeDelayCnt:int;
private var engine4_4Channel:SoundChannel;
private var engine4_4SFX:Class;
private var engine2_2SFX:Class;
private var engine3_1:Sound;
private var engine3_2:Sound;
private var engine3_3:Sound;
private var engine3_4:Sound;
private var engine3_5:Sound;
private var engine3_6:Sound;
private var engine1_1Channel:SoundChannel;
private var engine3_3Channel:SoundChannel;
private var engine2_2Channel:SoundChannel;
private var liverySelectedSFX:Class;
private var engine3_6SFX:Class;
private var engine1_4SFX:Class;
private var go321:Sound;
private var crash4SFX:Class;
private var fireworksSFX:Class;
private var engine4_2Channel:SoundChannel;
private var engine3_1Channel:SoundChannel;
private var engine3_1SFX:Class;
private var engine2_2:Sound;
private var engine2_3:Sound;
private var engine2_4:Sound;
private var engine2_5:Sound;
private var engine2_6:Sound;
private var engine2_1:Sound;
private var liverySelected:Sound;
private var engine1_6Channel:SoundChannel;
public function SoundHandler(){
tune1SFX = SoundHandler_tune1SFX;
tune2SFX = SoundHandler_tune2SFX;
buttonClickSFX = SoundHandler_buttonClickSFX;
liverySelectedSFX = SoundHandler_liverySelectedSFX;
fireworksSFX = SoundHandler_fireworksSFX;
dooropenSFX = SoundHandler_dooropenSFX;
crowdcheersmallSFX = SoundHandler_crowdcheersmallSFX;
crowdcheerairhornSFX = SoundHandler_crowdcheerairhornSFX;
go321SFX = SoundHandler_go321SFX;
spinSFX = SoundHandler_spinSFX;
engine1_1SFX = SoundHandler_engine1_1SFX;
engine1_2SFX = SoundHandler_engine1_2SFX;
engine1_3SFX = SoundHandler_engine1_3SFX;
engine1_4SFX = SoundHandler_engine1_4SFX;
engine1_5SFX = SoundHandler_engine1_5SFX;
engine1_6SFX = SoundHandler_engine1_6SFX;
engine2_1SFX = SoundHandler_engine2_1SFX;
engine2_2SFX = SoundHandler_engine2_2SFX;
engine2_3SFX = SoundHandler_engine2_3SFX;
engine2_4SFX = SoundHandler_engine2_4SFX;
engine2_5SFX = SoundHandler_engine2_5SFX;
engine2_6SFX = SoundHandler_engine2_6SFX;
engine3_1SFX = SoundHandler_engine3_1SFX;
engine3_2SFX = SoundHandler_engine3_2SFX;
engine3_3SFX = SoundHandler_engine3_3SFX;
engine3_4SFX = SoundHandler_engine3_4SFX;
engine3_5SFX = SoundHandler_engine3_5SFX;
engine3_6SFX = SoundHandler_engine3_6SFX;
engine4_1SFX = SoundHandler_engine4_1SFX;
engine4_2SFX = SoundHandler_engine4_2SFX;
engine4_3SFX = SoundHandler_engine4_3SFX;
engine4_4SFX = SoundHandler_engine4_4SFX;
engine4_5SFX = SoundHandler_engine4_5SFX;
engine4_6SFX = SoundHandler_engine4_6SFX;
crash1SFX = SoundHandler_crash1SFX;
crash2SFX = SoundHandler_crash2SFX;
crash3SFX = SoundHandler_crash3SFX;
crash4SFX = SoundHandler_crash4SFX;
crash5SFX = SoundHandler_crash5SFX;
crash6SFX = SoundHandler_crash6SFX;
crash7SFX = SoundHandler_crash7SFX;
crash8SFX = SoundHandler_crash8SFX;
super();
controllerSprite = new Sprite();
SoundMixer.soundTransform = new SoundTransform(masterVolume);
mod1 = new tune1SFX();
mod2 = new tune2SFX();
buttonClick = new buttonClickSFX();
liverySelected = new liverySelectedSFX();
fireworks = new fireworksSFX();
dooropen = new dooropenSFX();
crowdcheersmall = new crowdcheersmallSFX();
crowdcheerairhorn = new crowdcheerairhornSFX();
go321 = new go321SFX();
wheelSpin = new spinSFX();
engine1_1 = new engine1_1SFX();
engine1_2 = new engine1_2SFX();
engine1_3 = new engine1_3SFX();
engine1_4 = new engine1_4SFX();
engine1_5 = new engine1_5SFX();
engine1_6 = new engine1_6SFX();
engine2_1 = new engine2_1SFX();
engine2_2 = new engine2_2SFX();
engine2_3 = new engine2_3SFX();
engine2_4 = new engine2_4SFX();
engine2_5 = new engine2_5SFX();
engine2_6 = new engine2_6SFX();
engine3_1 = new engine3_1SFX();
engine3_2 = new engine3_2SFX();
engine3_3 = new engine3_3SFX();
engine3_4 = new engine3_4SFX();
engine3_5 = new engine3_5SFX();
engine3_6 = new engine3_6SFX();
engine4_1 = new engine4_1SFX();
engine4_2 = new engine4_2SFX();
engine4_3 = new engine4_3SFX();
engine4_4 = new engine4_4SFX();
engine4_5 = new engine4_5SFX();
engine4_6 = new engine4_6SFX();
crash1 = new crash1SFX();
crash2 = new crash2SFX();
crash3 = new crash3SFX();
crash4 = new crash4SFX();
crash5 = new crash5SFX();
crash6 = new crash6SFX();
crash7 = new crash7SFX();
crash8 = new crash8SFX();
crashSoundsStorage = new Array();
crashSoundsStorage.push(crash1, crash2, crash3, crash4, crash5, crash6, crash7, crash8);
}
public function fadeOut_engine1(_arg1:int):void{
var _local2:Number = ((100 / 200) * _arg1);
_local2 = (_local2 / 100);
if (_local2 <= 0){
stop_engine1();
return;
};
var _local3:SoundTransform = engine1_1Channel.soundTransform;
var _local4:SoundTransform = engine1_2Channel.soundTransform;
var _local5:SoundTransform = engine1_3Channel.soundTransform;
var _local6:SoundTransform = engine1_4Channel.soundTransform;
var _local7:SoundTransform = engine1_5Channel.soundTransform;
var _local8:SoundTransform = engine1_6Channel.soundTransform;
_local3.volume = _local2;
_local4.volume = _local2;
_local5.volume = _local2;
_local6.volume = _local2;
_local7.volume = _local2;
_local8.volume = _local2;
engine1_1Channel.soundTransform = _local3;
engine1_2Channel.soundTransform = _local4;
engine1_3Channel.soundTransform = _local5;
engine1_4Channel.soundTransform = _local6;
engine1_5Channel.soundTransform = _local7;
engine1_6Channel.soundTransform = _local8;
}
public function fadeOut_engine2(_arg1:int):void{
var _local2:Number = ((100 / 200) * _arg1);
_local2 = (_local2 / 100);
if (_local2 <= 0){
stop_engine1();
return;
};
var _local3:SoundTransform = engine2_1Channel.soundTransform;
var _local4:SoundTransform = engine2_2Channel.soundTransform;
var _local5:SoundTransform = engine2_3Channel.soundTransform;
var _local6:SoundTransform = engine2_4Channel.soundTransform;
var _local7:SoundTransform = engine2_5Channel.soundTransform;
var _local8:SoundTransform = engine2_6Channel.soundTransform;
_local3.volume = _local2;
_local4.volume = _local2;
_local5.volume = _local2;
_local6.volume = _local2;
_local7.volume = _local2;
_local8.volume = _local2;
engine2_1Channel.soundTransform = _local3;
engine2_2Channel.soundTransform = _local4;
engine2_3Channel.soundTransform = _local5;
engine2_4Channel.soundTransform = _local6;
engine2_5Channel.soundTransform = _local7;
engine2_6Channel.soundTransform = _local8;
}
public function setVolume(_arg1:int):void{
masterVolume = _arg1;
SoundMixer.soundTransform = new SoundTransform(masterVolume);
}
public function fadeOut_engine4(_arg1:int):void{
var _local2:Number = ((100 / 200) * _arg1);
_local2 = (_local2 / 100);
if (_local2 <= 0){
stop_engine1();
return;
};
var _local3:SoundTransform = engine4_1Channel.soundTransform;
var _local4:SoundTransform = engine4_2Channel.soundTransform;
var _local5:SoundTransform = engine4_3Channel.soundTransform;
var _local6:SoundTransform = engine4_4Channel.soundTransform;
var _local7:SoundTransform = engine4_5Channel.soundTransform;
var _local8:SoundTransform = engine4_6Channel.soundTransform;
_local3.volume = _local2;
_local4.volume = _local2;
_local5.volume = _local2;
_local6.volume = _local2;
_local7.volume = _local2;
_local8.volume = _local2;
engine4_1Channel.soundTransform = _local3;
engine4_2Channel.soundTransform = _local4;
engine4_3Channel.soundTransform = _local5;
engine4_4Channel.soundTransform = _local6;
engine4_5Channel.soundTransform = _local7;
engine4_6Channel.soundTransform = _local8;
}
public function fadeIn_mod2(_arg1:Event):void{
mod2_transform = mod2_channel.soundTransform;
var _local2:Number = mod2_transform.volume;
if (_local2 >= 1){
mod2_transform.volume = 1;
mod2_channel.soundTransform = mod2_transform;
controllerSprite.removeEventListener(Event.ENTER_FRAME, fadeIn_mod2);
} else {
if (++fadeDelayCnt >= 5){
fadeDelayCnt = 0;
mod2_transform.volume = (mod2_transform.volume + 0.02);
mod2_channel.soundTransform = mod2_transform;
};
};
}
public function fadeOut_engine3(_arg1:int):void{
var _local2:Number = ((100 / 200) * _arg1);
_local2 = (_local2 / 100);
if (_local2 <= 0){
stop_engine1();
return;
};
var _local3:SoundTransform = engine3_1Channel.soundTransform;
var _local4:SoundTransform = engine3_2Channel.soundTransform;
var _local5:SoundTransform = engine3_3Channel.soundTransform;
var _local6:SoundTransform = engine3_4Channel.soundTransform;
var _local7:SoundTransform = engine3_5Channel.soundTransform;
var _local8:SoundTransform = engine3_6Channel.soundTransform;
_local3.volume = _local2;
_local4.volume = _local2;
_local5.volume = _local2;
_local6.volume = _local2;
_local7.volume = _local2;
_local8.volume = _local2;
engine3_1Channel.soundTransform = _local3;
engine3_2Channel.soundTransform = _local4;
engine3_3Channel.soundTransform = _local5;
engine3_4Channel.soundTransform = _local6;
engine3_5Channel.soundTransform = _local7;
engine3_6Channel.soundTransform = _local8;
}
public function play_liverySelected():void{
liverySelected.play();
}
public function fadeOut_mod2(_arg1:Event):void{
mod2_transform = mod2_channel.soundTransform;
var _local2:Number = mod2_transform.volume;
if (_local2 == 0){
controllerSprite.removeEventListener(Event.ENTER_FRAME, fadeOut_mod2);
return;
};
if (++fadeDelayCnt >= 5){
fadeDelayCnt = 0;
mod2_transform.volume = (mod2_transform.volume - 0.1);
mod2_channel.soundTransform = mod2_transform;
};
}
public function play_crowdcheerairhornSFX():void{
crowdcheerairhorn.play();
}
public function fadeIn_mod2Init():void{
fadeDelayCnt = 0;
controllerSprite.removeEventListener(Event.ENTER_FRAME, fadeOut_mod2);
controllerSprite.addEventListener(Event.ENTER_FRAME, fadeIn_mod2);
}
public function toString():String{
return ("SoundHandler");
}
public function stop_engine2():void{
engine2_1Channel.stop();
engine2_2Channel.stop();
engine2_3Channel.stop();
engine2_4Channel.stop();
engine2_5Channel.stop();
engine2_6Channel.stop();
}
public function stop_engine3():void{
engine3_1Channel.stop();
engine3_2Channel.stop();
engine3_3Channel.stop();
engine3_4Channel.stop();
engine3_5Channel.stop();
engine3_6Channel.stop();
}
public function stop_engine1():void{
engine1_1Channel.stop();
engine1_2Channel.stop();
engine1_3Channel.stop();
engine1_4Channel.stop();
engine1_5Channel.stop();
engine1_6Channel.stop();
}
public function stop_engine4():void{
engine4_1Channel.stop();
engine4_2Channel.stop();
engine4_3Channel.stop();
engine4_4Channel.stop();
engine4_5Channel.stop();
engine4_6Channel.stop();
}
public function play_wheelSpin():void{
wheelSpin.play();
}
public function play_go321():void{
go321.play();
}
public function stop_fireworks():void{
if (fireworks_channel != null){
fireworks_channel.stop();
};
}
public function fadeOut_mod2Init():void{
fadeDelayCnt = 0;
controllerSprite.removeEventListener(Event.ENTER_FRAME, fadeIn_mod2);
controllerSprite.addEventListener(Event.ENTER_FRAME, fadeOut_mod2);
}
public function handle_engine2(_arg1:int):void{
var _local2:Number = ((100 / 186) * _arg1);
_local2 = (_local2 / 100);
var _local3:SoundTransform = engine2_1Channel.soundTransform;
var _local4:SoundTransform = engine2_2Channel.soundTransform;
var _local5:SoundTransform = engine2_3Channel.soundTransform;
var _local6:SoundTransform = engine2_4Channel.soundTransform;
var _local7:SoundTransform = engine2_5Channel.soundTransform;
var _local8:SoundTransform = engine2_6Channel.soundTransform;
_local3.volume = (0.9 - _local2);
_local4.volume = (0.8 - _local2);
_local5.volume = (0.6 - _local2);
_local6.volume = (0.4 - _local2);
_local7.volume = (0.2 - _local2);
_local8.volume = (0.1 - _local2);
engine2_1Channel.soundTransform = _local3;
engine2_2Channel.soundTransform = _local4;
engine2_3Channel.soundTransform = _local5;
engine2_4Channel.soundTransform = _local6;
engine2_5Channel.soundTransform = _local7;
engine2_6Channel.soundTransform = _local8;
}
public function handle_engine4(_arg1:int):void{
var _local2:Number = ((100 / 186) * _arg1);
_local2 = (_local2 / 100);
var _local3:SoundTransform = engine4_1Channel.soundTransform;
var _local4:SoundTransform = engine4_2Channel.soundTransform;
var _local5:SoundTransform = engine4_3Channel.soundTransform;
var _local6:SoundTransform = engine4_4Channel.soundTransform;
var _local7:SoundTransform = engine4_5Channel.soundTransform;
var _local8:SoundTransform = engine4_6Channel.soundTransform;
_local3.volume = (0.9 - _local2);
_local4.volume = (0.8 - _local2);
_local5.volume = (0.6 - _local2);
_local6.volume = (0.4 - _local2);
_local7.volume = (0.2 - _local2);
_local8.volume = (0.1 - _local2);
engine4_1Channel.soundTransform = _local3;
engine4_2Channel.soundTransform = _local4;
engine4_3Channel.soundTransform = _local5;
engine4_4Channel.soundTransform = _local6;
engine4_5Channel.soundTransform = _local7;
engine4_6Channel.soundTransform = _local8;
}
public function handle_engine1(_arg1:int):void{
var _local2:Number = ((100 / 186) * _arg1);
_local2 = (_local2 / 100);
var _local3:SoundTransform = engine1_1Channel.soundTransform;
var _local4:SoundTransform = engine1_2Channel.soundTransform;
var _local5:SoundTransform = engine1_3Channel.soundTransform;
var _local6:SoundTransform = engine1_4Channel.soundTransform;
var _local7:SoundTransform = engine1_5Channel.soundTransform;
var _local8:SoundTransform = engine1_6Channel.soundTransform;
_local3.volume = (0.9 - _local2);
_local4.volume = (0.8 - _local2);
_local5.volume = (0.6 - _local2);
_local6.volume = (0.4 - _local2);
_local7.volume = (0.2 - _local2);
_local8.volume = (0.1 - _local2);
engine1_1Channel.soundTransform = _local3;
engine1_2Channel.soundTransform = _local4;
engine1_3Channel.soundTransform = _local5;
engine1_4Channel.soundTransform = _local6;
engine1_5Channel.soundTransform = _local7;
engine1_6Channel.soundTransform = _local8;
}
public function handle_engine3(_arg1:int):void{
var _local2:Number = ((100 / 186) * _arg1);
_local2 = (_local2 / 100);
var _local3:SoundTransform = engine3_1Channel.soundTransform;
var _local4:SoundTransform = engine3_2Channel.soundTransform;
var _local5:SoundTransform = engine3_3Channel.soundTransform;
var _local6:SoundTransform = engine3_4Channel.soundTransform;
var _local7:SoundTransform = engine3_5Channel.soundTransform;
var _local8:SoundTransform = engine3_6Channel.soundTransform;
_local3.volume = (0.9 - _local2);
_local4.volume = (0.8 - _local2);
_local5.volume = (0.6 - _local2);
_local6.volume = (0.4 - _local2);
_local7.volume = (0.2 - _local2);
_local8.volume = (0.1 - _local2);
engine3_1Channel.soundTransform = _local3;
engine3_2Channel.soundTransform = _local4;
engine3_3Channel.soundTransform = _local5;
engine3_4Channel.soundTransform = _local6;
engine3_5Channel.soundTransform = _local7;
engine3_6Channel.soundTransform = _local8;
}
public function play_buttonClick():void{
buttonClick.play();
}
public function start_engine1():void{
engine1_1Channel = engine1_1.play(0, 99999999);
var _local1:SoundTransform = engine1_1Channel.soundTransform;
_local1.volume = 0;
engine1_1Channel.soundTransform = _local1;
engine1_2Channel = engine1_2.play(0, 99999999);
_local1 = engine1_2Channel.soundTransform;
_local1.volume = 0;
engine1_2Channel.soundTransform = _local1;
engine1_3Channel = engine1_3.play(0, 99999999);
_local1 = engine1_3Channel.soundTransform;
_local1.volume = 0;
engine1_3Channel.soundTransform = _local1;
engine1_4Channel = engine1_4.play(0, 99999999);
_local1 = engine1_4Channel.soundTransform;
_local1.volume = 0;
engine1_4Channel.soundTransform = _local1;
engine1_5Channel = engine1_5.play(0, 99999999);
_local1 = engine1_5Channel.soundTransform;
_local1.volume = 0;
engine1_5Channel.soundTransform = _local1;
engine1_6Channel = engine1_6.play(0, 99999999);
_local1 = engine1_6Channel.soundTransform;
_local1.volume = 0;
engine1_6Channel.soundTransform = _local1;
}
public function start_engine2():void{
engine2_1Channel = engine2_1.play(0, 99999999);
var _local1:SoundTransform = engine2_1Channel.soundTransform;
_local1.volume = 0;
engine2_1Channel.soundTransform = _local1;
engine2_2Channel = engine2_2.play(0, 99999999);
_local1 = engine2_2Channel.soundTransform;
_local1.volume = 0;
engine2_2Channel.soundTransform = _local1;
engine2_3Channel = engine2_3.play(0, 99999999);
_local1 = engine2_3Channel.soundTransform;
_local1.volume = 0;
engine2_3Channel.soundTransform = _local1;
engine2_4Channel = engine2_4.play(0, 99999999);
_local1 = engine2_4Channel.soundTransform;
_local1.volume = 0;
engine2_4Channel.soundTransform = _local1;
engine2_5Channel = engine2_5.play(0, 99999999);
_local1 = engine2_5Channel.soundTransform;
_local1.volume = 0;
engine2_5Channel.soundTransform = _local1;
engine2_6Channel = engine2_6.play(0, 99999999);
_local1 = engine2_6Channel.soundTransform;
_local1.volume = 0;
engine2_6Channel.soundTransform = _local1;
}
public function start_engine4():void{
engine4_1Channel = engine4_1.play(0, 99999999);
var _local1:SoundTransform = engine4_1Channel.soundTransform;
_local1.volume = 0;
engine4_1Channel.soundTransform = _local1;
engine4_2Channel = engine4_2.play(0, 99999999);
_local1 = engine4_2Channel.soundTransform;
_local1.volume = 0;
engine4_2Channel.soundTransform = _local1;
engine4_3Channel = engine4_3.play(0, 99999999);
_local1 = engine4_3Channel.soundTransform;
_local1.volume = 0;
engine4_3Channel.soundTransform = _local1;
engine4_4Channel = engine4_4.play(0, 99999999);
_local1 = engine4_4Channel.soundTransform;
_local1.volume = 0;
engine4_4Channel.soundTransform = _local1;
engine4_5Channel = engine4_5.play(0, 99999999);
_local1 = engine4_5Channel.soundTransform;
_local1.volume = 0;
engine4_5Channel.soundTransform = _local1;
engine4_6Channel = engine4_6.play(0, 99999999);
_local1 = engine4_6Channel.soundTransform;
_local1.volume = 0;
engine4_6Channel.soundTransform = _local1;
}
public function startMod():void{
mod1 = new tune1SFX();
mod2 = new tune2SFX();
mod1_channel = mod1.play(0, 99999999);
mod1_transform = mod1_channel.soundTransform;
mod2_channel = mod2.play(0, 99999999);
mod2_transform = mod2_channel.soundTransform;
mod2_transform.volume = 0;
mod2_channel.soundTransform = mod2_transform;
}
public function start_engine3():void{
engine3_1Channel = engine3_1.play(0, 99999999);
var _local1:SoundTransform = engine3_1Channel.soundTransform;
_local1.volume = 0;
engine3_1Channel.soundTransform = _local1;
engine3_2Channel = engine3_2.play(0, 99999999);
_local1 = engine3_2Channel.soundTransform;
_local1.volume = 0;
engine3_2Channel.soundTransform = _local1;
engine3_3Channel = engine3_3.play(0, 99999999);
_local1 = engine3_3Channel.soundTransform;
_local1.volume = 0;
engine3_3Channel.soundTransform = _local1;
engine3_4Channel = engine3_4.play(0, 99999999);
_local1 = engine3_4Channel.soundTransform;
_local1.volume = 0;
engine3_4Channel.soundTransform = _local1;
engine3_5Channel = engine3_5.play(0, 99999999);
_local1 = engine3_5Channel.soundTransform;
_local1.volume = 0;
engine3_5Channel.soundTransform = _local1;
engine3_6Channel = engine3_6.play(0, 99999999);
_local1 = engine3_6Channel.soundTransform;
_local1.volume = 0;
engine3_6Channel.soundTransform = _local1;
}
public function play_crowdcheersmall():void{
crowdcheersmall.play();
}
public function play_crashSound():void{
var _local1:int = Math.floor((Math.random() * crashSoundsStorage.length));
var _local2:Sound = crashSoundsStorage[_local1];
_local2.play();
}
public function play_dooropen():void{
dooropen.play();
}
public function toggleSounds():int{
if (masterVolume == 1){
masterVolume = 0;
} else {
masterVolume = 1;
};
SoundMixer.soundTransform = new SoundTransform(masterVolume);
return (masterVolume);
}
private function loopMod(_arg1:Event):void{
}
public function play_fireworks():void{
fireworks_channel = fireworks.play(0, 9999999);
}
}
}//package Classes
Section 202
//SoundHandler_buttonClickSFX (Classes.SoundHandler_buttonClickSFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_buttonClickSFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 203
//SoundHandler_crash1SFX (Classes.SoundHandler_crash1SFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_crash1SFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 204
//SoundHandler_crash2SFX (Classes.SoundHandler_crash2SFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_crash2SFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 205
//SoundHandler_crash3SFX (Classes.SoundHandler_crash3SFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_crash3SFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 206
//SoundHandler_crash4SFX (Classes.SoundHandler_crash4SFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_crash4SFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 207
//SoundHandler_crash5SFX (Classes.SoundHandler_crash5SFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_crash5SFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 208
//SoundHandler_crash6SFX (Classes.SoundHandler_crash6SFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_crash6SFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 209
//SoundHandler_crash7SFX (Classes.SoundHandler_crash7SFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_crash7SFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 210
//SoundHandler_crash8SFX (Classes.SoundHandler_crash8SFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_crash8SFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 211
//SoundHandler_crowdcheerairhornSFX (Classes.SoundHandler_crowdcheerairhornSFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_crowdcheerairhornSFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 212
//SoundHandler_crowdcheersmallSFX (Classes.SoundHandler_crowdcheersmallSFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_crowdcheersmallSFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 213
//SoundHandler_dooropenSFX (Classes.SoundHandler_dooropenSFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_dooropenSFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 214
//SoundHandler_engine1_1SFX (Classes.SoundHandler_engine1_1SFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_engine1_1SFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 215
//SoundHandler_engine1_2SFX (Classes.SoundHandler_engine1_2SFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_engine1_2SFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 216
//SoundHandler_engine1_3SFX (Classes.SoundHandler_engine1_3SFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_engine1_3SFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 217
//SoundHandler_engine1_4SFX (Classes.SoundHandler_engine1_4SFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_engine1_4SFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 218
//SoundHandler_engine1_5SFX (Classes.SoundHandler_engine1_5SFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_engine1_5SFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 219
//SoundHandler_engine1_6SFX (Classes.SoundHandler_engine1_6SFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_engine1_6SFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 220
//SoundHandler_engine2_1SFX (Classes.SoundHandler_engine2_1SFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_engine2_1SFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 221
//SoundHandler_engine2_2SFX (Classes.SoundHandler_engine2_2SFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_engine2_2SFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 222
//SoundHandler_engine2_3SFX (Classes.SoundHandler_engine2_3SFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_engine2_3SFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 223
//SoundHandler_engine2_4SFX (Classes.SoundHandler_engine2_4SFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_engine2_4SFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 224
//SoundHandler_engine2_5SFX (Classes.SoundHandler_engine2_5SFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_engine2_5SFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 225
//SoundHandler_engine2_6SFX (Classes.SoundHandler_engine2_6SFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_engine2_6SFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 226
//SoundHandler_engine3_1SFX (Classes.SoundHandler_engine3_1SFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_engine3_1SFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 227
//SoundHandler_engine3_2SFX (Classes.SoundHandler_engine3_2SFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_engine3_2SFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 228
//SoundHandler_engine3_3SFX (Classes.SoundHandler_engine3_3SFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_engine3_3SFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 229
//SoundHandler_engine3_4SFX (Classes.SoundHandler_engine3_4SFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_engine3_4SFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 230
//SoundHandler_engine3_5SFX (Classes.SoundHandler_engine3_5SFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_engine3_5SFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 231
//SoundHandler_engine3_6SFX (Classes.SoundHandler_engine3_6SFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_engine3_6SFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 232
//SoundHandler_engine4_1SFX (Classes.SoundHandler_engine4_1SFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_engine4_1SFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 233
//SoundHandler_engine4_2SFX (Classes.SoundHandler_engine4_2SFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_engine4_2SFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 234
//SoundHandler_engine4_3SFX (Classes.SoundHandler_engine4_3SFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_engine4_3SFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 235
//SoundHandler_engine4_4SFX (Classes.SoundHandler_engine4_4SFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_engine4_4SFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 236
//SoundHandler_engine4_5SFX (Classes.SoundHandler_engine4_5SFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_engine4_5SFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 237
//SoundHandler_engine4_6SFX (Classes.SoundHandler_engine4_6SFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_engine4_6SFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 238
//SoundHandler_fireworksSFX (Classes.SoundHandler_fireworksSFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_fireworksSFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 239
//SoundHandler_go321SFX (Classes.SoundHandler_go321SFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_go321SFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 240
//SoundHandler_liverySelectedSFX (Classes.SoundHandler_liverySelectedSFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_liverySelectedSFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 241
//SoundHandler_spinSFX (Classes.SoundHandler_spinSFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_spinSFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 242
//SoundHandler_tune1SFX (Classes.SoundHandler_tune1SFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_tune1SFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 243
//SoundHandler_tune2SFX (Classes.SoundHandler_tune2SFX)
package Classes {
import flash.display.*;
import mx.core.*;
public class SoundHandler_tune2SFX extends SoundAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package Classes
Section 244
//StackData (Classes.StackData)
package Classes {
public class StackData {
private var level25Stack:Array;
private var level13Stack:Array;
private var level21Stack:Array;
private var level7Stack:Array;
private var level3Stack:Array;
private var level18Stack:Array;
private var level14Stack:Array;
private var level22Stack:Array;
private var level10Stack:Array;
private var level8Stack:Array;
private var level4Stack:Array;
private var level19Stack:Array;
private var level15Stack:Array;
private var level23Stack:Array;
private var level11Stack:Array;
private var cameraPositions:Array;
private var level9Stack:Array;
private var level5Stack:Array;
private var level1Stack:Array;
private var levelStorage:Array;
private var level16Stack:Array;
private var level24Stack:Array;
private var level12Stack:Array;
private var level20Stack:Array;
private var level6Stack:Array;
private var level2Stack:Array;
private var level17Stack:Array;
public function StackData(){
level1Stack = [[13, 3200, 398, -90, 1], [13, 3384, 398, -90, 3], [14, 3238, 164, 0, 1], [14, 3237, 169, -67, 3], [14, 3384, -15, 73, 5]];
level2Stack = [[14, 3200, 400, -75, 7], [14, 3330, 208, 75, 9], [2, 3200, 168, 0, 9], [1, 3270, 166, -68.5, 11], [14, 3380, 400, -75, 1], [14, 3510, 208, 75, 3], [2, 3380, 168, 0, 11], [1, 3410, -18, 66.5, 9]];
level3Stack = [[14, 3200, 400, -90, 5], [14, 3291, 400, -90, 7], [14, 3382, 400, -90, 9], [14, 3473, 400, -90, 3], [1, 3219, 164, 0, 11], [1, 3409, 172, -5, 9], [4, 3610, 226, 90, 13]];
level4Stack = [[4, 3214, 400, -90, 11], [4, 3279, 400, -90, 9], [14, 3420, 414, -120, 1], [14, 3220, 186, 0, 9], [2, 3400, 188, -180, 9]];
level5Stack = [[14, 3257, (400 - 196), 90, 3], [14, 3255, 400, -90, 5], [13, 3140, 146, 0, 5], [13, 3250, -16, 105, 3], [6, 3286, 182, -110, 13]];
level6Stack = [[6, 3200, 390, -90, 9], [14, 3300, 400, -90, 9], [14, 3400, 400, -90, 7], [14, 3550, (400 - 196), 90, 5], [1, 3465, 220, -180, 9], [6, 3345, 174, -90, 11]];
level7Stack = [[2, 3200, 400, -90, 11], [13, 3300, 394, -90, 5], [14, 3400, 400, -90, 1], [3, 3520, 335, 0, 13], [14, 3284, 146, 3, 9], [14, 3206, 206, -52, 3], [6, 3512, 190, -155, 9]];
level8Stack = [[1, 3200, 395, -79, 11], [14, 3314, 400, -89, 5], [13, 3390, 402, -105, 1], [13, 3590, 222, 114, 5], [14, 3564, 400, -89, 7], [1, 3705, 204, 80, 11], [3, 3258, 148, 0, 11], [3, 3562, 152, 0, 11]];
level9Stack = [[6, 3220, 390, -90, 11], [14, 3388, (400 - 196), 90, 9], [3, 3400, 335, 0, 11], [14, 3512, 400, -90, 5], [1, 3352, 172, 0, 11], [2, 3410, 6, 90, 11], [5, 3470, 174, -90, 13]];
level10Stack = [[13, 3200, 320, 0, 5], [3, 3430, 394, -97, 11], [13, 3380, 326, -180, 3], [1, 3230, 86, 90, 11], [1, 3320, 90, 90, 9], [1, 3410, 90, 90, 11], [14, 3200, 50, 0, 5]];
level11Stack = [[14, 3200, 382, -60, 1], [4, 3325, 400, -90, 9], [14, 3398, 212, 60, 7], [2, 3260, 174, 0, 9], [2, (3260 + 184), 177, -180, 11]];
level12Stack = [[14, 3200, 400, -90, 9], [14, 3260, 400, -90, 7], [5, 3380, 390, -101, 9], [3, 3560, 335, 0, 11], [2, 3770, 400, -90, 11], [3, 3362, 186, 159, 9], [6, 3335, 115, 0, 9], [9, 3580, 306, -23, 13]];
level13Stack = [[1, 3218, 292, 139, 11], [14, 3200, 400, -90, 3], [2, 3453, 392, -180, 13], [14, 3440, 400, -90, 5], [1, 3500, 238, 44, 11], [6, 3264, 0x0100, 0, 11], [4, 3384, 135, 117, 11], [4, 3409, 303, -115, 11], [2, 3210, 176, -45, 11], [2, 3398, 48, 45, 11]];
level14Stack = [[5, 3200, 290, 0, 9], [2, 3330, 318, -180, 11], [3, 3370, 122, 90, 9], [4, (3500 + 20), 400, -90, 9], [4, (3560 + 20), 400, -90, 11], [14, (3444 + 20), 186, 0, 5], [4, (3458 + 20), 198, -75, 11], [4, (3570 + 20), 212, -105, 9]];
level15Stack = [[8, 3200, 306, 0, 13], [14, 3410, (400 - 196), 90, 3], [14, 3480, 400, -90, 1], [6, 3570, 320, 0, 11], [13, 3530, 224, -180, 3], [4, 3450, 8, 90, 11], [4, 3490, 184, -90, 9]];
level16Stack = [[14, 3200, (400 - 196), 90, 5], [14, 3260, 400, -90, 9], [14, 3360, 400, -90, 7], [10, 3090, 136, 0, 13], [3, 3340, 154, 0, 9], [4, 3318, 20, 120, 11], [4, 3330, -10, 68, 9]];
level17Stack = [[3, 3200, 335, 0, 11], [10, 3360, 318, 0, 9], [3, 3570, 335, 0, 9], [8, 3476, 160, 90, 11], [10, 3490, 358, -105, 11], [5, 3530, 170, -180, 11], [3, 3500, 114, -180, 11]];
level18Stack = [[10, 3200, 318, 0, 11], [1, 3420, 400, -90, 11], [1, 3550, (400 - 194), 90, 9], [1, 3620, (400 - 194), 90, 11], [8, 3700, 306, 0, 9], [10, 3350, 322, -180, 9], [5, 3430, 116, 0, 9], [11, 3550, 0, 120, 13], [3, 3542, 150, -90, 11], [4, 3610, 198, -105, 11]];
level19Stack = [[13, 3200, 398, -90, 5], [13, 3267, 398, -90, 3], [6, 3380, 398, -90, 11], [13, 3467, 398, -90, 1], [13, 3531, 398, -90, 5], [14, 3310, 166, 0, 7], [14, 3300, 126, 0, 9], [4, 3213, 187, -46, 9], [4, 3474, 68, 39, 11]];
level20Stack = [[14, 3200, 400, -90, 3], [13, 3300, 396, -90, 1], [10, 3450, 398, -98, 9], [5, 3580, 390, -101, 11], [14, 3700, 400, -90, 5], [14, 3780, 400, -90, 7], [4, 3430, 206, -180, 9], [8, 3874, 180, 159, 9], [1, 3794, -4, 104, 11], [3, 3807, 142, -96, 9]];
level21Stack = [[3, 3200, 335, 0, 11], [6, 3340, 390, -90, 9], [2, 3410, 400, -90, 11], [6, 3480, 390, -90, 11], [5, 3560, 386, -99, 9], [11, 3520, 204, -180, 11], [12, 3390, 140, -90, 13]];
level22Stack = [[12, 3200, 306, 0, 9], [12, 3400, 306, 0, 11], [12, 3700, 306, 0, 11], [12, 3900, 306, 0, 9], [5, 3206, 274, -69, 11], [12, 3500, 310, -180, 9], [8, 3516, 320, -90, 9], [3, 3376, 260, -97, 11], [9, 3445, 112, 0, 11], [4, 3494, 39, 105, 9], [3, 3573, 130, -90, 9]];
level23Stack = [[14, 3200, 220, 105, 3], [14, 3220, 410, -105, 9], [6, 3320, 398, -90, 11], [6, 3390, 398, -90, 9], [7, 3550, 250, 0, 13], [9, 3270, 216, -180, 9], [9, 3286, 160, 2, 11], [8, 3370, 166, -88, 11]];
level24Stack = [[3, 3200, 394, -90, 11], [8, 3280, 398, -90, 11], [7, 3380, 376, -95, 11], [5, 3550, 390, -101, 9], [11, (3700 - 20), 290, 0, 9], [3, (3950 - 30), 335, 0, 9], [13, 3332, 196, 153, 1], [4, 3468, 218, 163, 9], [9, 3635, 136, 150, 9], [11, (3770 - 30), 300, -90, 11]];
level25Stack = [[14, 3200, 400, -90, 5], [14, 3260, 400, -90, 3], [5, 3320, 390, -101, 9], [3, 3560, 392, -90, 9], [7, 3620, 250, 0, 13], [5, 3980, 186, 110, 11], [12, 3916, 306, 0, 9], [9, 4120, 338, 0, 9], [7, 3370, 146, 0, 11], [3, 3250, 170, -21, 11], [10, 4100, 130, 90, 9]];
super();
levelStorage = new Array();
levelStorage.push(level1Stack, level2Stack, level3Stack, level4Stack, level5Stack, level6Stack, level7Stack, level8Stack, level9Stack, level10Stack, level11Stack, level12Stack, level13Stack, level14Stack, level15Stack, level16Stack, level17Stack, level18Stack, level19Stack, level20Stack, level21Stack, level22Stack, level23Stack, level24Stack, level25Stack);
cameraPositions = new Array();
cameraPositions.push(3100, 3100, 3200, 3100, 3200, 3250, 3250, 3300, 3400, 3200, 3100, 3300, 3300, 3250, 3250, 3150, 3200, 3400, 3200, 3400, 3200, 3460, 3300, 3500, 3700);
}
public function getStackData(_arg1:int):Array{
return (levelStorage[(_arg1 - 1)]);
}
public function getCameraPosition(_arg1:int):int{
return (cameraPositions[(_arg1 - 1)]);
}
}
}//package Classes
Section 245
//Transition (Classes.Transition)
package Classes {
import flash.display.*;
import flash.geom.*;
import Box2D.Common.Math.*;
import gs.*;
import flash.filters.*;
public class Transition {
private var photoBitmap:Bitmap;
private var photoBitmapData:BitmapData;
private var stage:Stage;
private var physScale:int;
private var carCenterPos:Point;
private var grabBitmap:Bitmap;
private var snapShotGrabBitmap:Bitmap;
private var transitionMask:Sprite;
private var grabBitmapData:BitmapData;
private var playField:Sprite;
private var snapShotGrabBitmapData:BitmapData;
private var callBack:Function;
private var mainMovie:DisplayObject;
private var main:Main;
private var transitionMaskMC:Class;
public function Transition(){
transitionMaskMC = Transition_transitionMaskMC;
super();
main = Main.getInstance();
mainMovie = main.getMainMovie();
stage = main.getStage();
grabBitmapData = new BitmapData(640, 480, false, 0);
grabBitmap = new Bitmap(grabBitmapData);
grabBitmap.cacheAsBitmap = true;
snapShotGrabBitmapData = new BitmapData(640, 480, false, 0);
snapShotGrabBitmap = new Bitmap(snapShotGrabBitmapData);
snapShotGrabBitmap.cacheAsBitmap = true;
photoBitmapData = new BitmapData((160 * 2), (170 * 2), false, 0);
photoBitmap = new Bitmap(photoBitmapData);
photoBitmap.cacheAsBitmap = true;
var _local1:Array = [1.62226, -0.54846, -0.0738, 0, 15, -0.27774, 1.35154, -0.0738, 0, 15, -0.27774, -0.54846, 1.8262, 0, 15, 0, 0, 0, 1, 0];
var _local2:ColorMatrixFilter = new ColorMatrixFilter(_local1);
photoBitmap.filters = [_local2];
transitionMask = new transitionMaskMC();
transitionMask.cacheAsBitmap = true;
carCenterPos = new Point();
}
public function houseKeeping():void{
playField.removeChild(transitionMask);
playField.removeChild(grabBitmap);
}
public function photoHouseKeeping(_arg1:Sprite):void{
_arg1.removeChild(photoBitmap);
}
public function takeSnapShot(_arg1:b2Vec2, _arg2:int):void{
physScale = _arg2;
carCenterPos.x = (_arg1.x * physScale);
carCenterPos.y = (_arg1.y * physScale);
var _local3:Sprite = main.getInitObj().getPlayField().sprites;
carCenterPos.x = (carCenterPos.x + _local3.x);
carCenterPos.x = (carCenterPos.x + 100);
carCenterPos.y = (carCenterPos.y + 50);
snapShotGrabBitmapData.draw(stage, null, null);
}
public function cropPhoto(_arg1:Sprite):void{
var _local2:Rectangle = new Rectangle((carCenterPos.x - (photoBitmap.width / 2)), (carCenterPos.y - (photoBitmap.height / 2)), photoBitmap.width, photoBitmap.height);
if (_local2.y < 0){
_local2.y = 0;
} else {
if (_local2.bottom > 428){
_local2.y = (_local2.y - (_local2.bottom - 428));
};
};
photoBitmapData.copyPixels(snapShotGrabBitmapData, _local2, new Point(0, 0));
_arg1.addChild(photoBitmap);
}
public function grabScreen(_arg1:Function):void{
callBack = _arg1;
if (playField == null){
playField = main.getInitObj().getPlayField().transition;
};
grabBitmapData.draw(stage, null, null);
transitionMask.x = -160;
grabBitmap.mask = transitionMask;
playField.addChild(grabBitmap);
playField.addChild(transitionMask);
_arg1();
TweenLite.to(transitionMask, 1.5, {x:640, delay:0.2, onComplete:houseKeeping});
}
public function toString():String{
return ("Transition");
}
public function pauseGrabScreen():void{
grabBitmapData.draw(stage, null, null);
grabBitmap.mask = null;
playField.addChild(grabBitmap);
}
public function releasePauseGrabScreen():void{
playField.removeChild(grabBitmap);
}
}
}//package Classes
Section 246
//Transition_transitionMaskMC (Classes.Transition_transitionMaskMC)
package Classes {
import flash.display.*;
import mx.core.*;
public class Transition_transitionMaskMC extends SpriteAsset {
public var padlock24:DisplayObject;
public var padlock25:DisplayObject;
public var weightStat:DisplayObject;
public var spilLogo:DisplayObject;
public var padlock12:DisplayObject;
public var padlock13:DisplayObject;
public var padlock23:DisplayObject;
public var star21:DisplayObject;
public var linkButton:DisplayObject;
public var star23:DisplayObject;
public var button22:DisplayObject;
public var colourButtons:DisplayObject;
public var leftButton:DisplayObject;
public var star18:DisplayObject;
public var description:DisplayObject;
public var padlock22:DisplayObject;
public var star3:DisplayObject;
public var star5:DisplayObject;
public var star7:DisplayObject;
public var star9:DisplayObject;
public var reflection:DisplayObject;
public var cardHolder:DisplayObject;
public var startButton:DisplayObject;
public var flagHolder:DisplayObject;
public var button1:DisplayObject;
public var button2:DisplayObject;
public var scroller:DisplayObject;
public var button5:DisplayObject;
public var button6:DisplayObject;
public var button7:DisplayObject;
public var button8:DisplayObject;
public var button9:DisplayObject;
public var button3:DisplayObject;
public var button4:DisplayObject;
public var doneButton:DisplayObject;
public var lockedText:DisplayObject;
public var topSpeedStat:DisplayObject;
public var creditsButton:DisplayObject;
public var rightButton:DisplayObject;
public var flag:DisplayObject;
public var carName:DisplayObject;
public var loadedButton:DisplayObject;
public var tick:DisplayObject;
public var par:DisplayObject;
public var styleStat:DisplayObject;
public var padlock4:DisplayObject;
public var padlock5:DisplayObject;
public var padlock7:DisplayObject;
public var padlock8:DisplayObject;
public var padlock2:DisplayObject;
public var padlock6:DisplayObject;
public var padlock9:DisplayObject;
public var location:DisplayObject;
public var padlock3:DisplayObject;
public var button10:DisplayObject;
public var button11:DisplayObject;
public var button12:DisplayObject;
public var button13:DisplayObject;
public var button14:DisplayObject;
public var button15:DisplayObject;
public var button16:DisplayObject;
public var button18:DisplayObject;
public var button19:DisplayObject;
public var padlock10:DisplayObject;
public var padlock11:DisplayObject;
public var button17:DisplayObject;
public var padlock14:DisplayObject;
public var padlock16:DisplayObject;
public var best:DisplayObject;
public var padlock18:DisplayObject;
public var padlock19:DisplayObject;
public var padlock15:DisplayObject;
public var padlock17:DisplayObject;
public var button20:DisplayObject;
public var button21:DisplayObject;
public var star12:DisplayObject;
public var accelerationStat:DisplayObject;
public var button25:DisplayObject;
public var star15:DisplayObject;
public var star16:DisplayObject;
public var backButton:DisplayObject;
public var button23:DisplayObject;
public var button24:DisplayObject;
public var padlock20:DisplayObject;
public var padlock21:DisplayObject;
}
}//package Classes
Section 247
//B2Dwrapper (com.gamingyourway.Physics.B2Dwrapper)
package com.gamingyourway.Physics {
import flash.display.*;
import flash.geom.*;
import Box2D.Dynamics.*;
import Box2D.Dynamics.Joints.*;
import Box2D.Common.Math.*;
import Box2D.Collision.*;
import Box2D.Collision.Shapes.*;
import Box2D.Common.*;
public class B2Dwrapper {
private var groundBody:b2Body;
private var dbgDraw:b2DebugDraw;
private var world:b2World;
private var debugFlag:Boolean;// = false
private var physScale:Number;// = 6
private var iterations:int;
private var timeStep:Number;
public function B2Dwrapper(){
dbgDraw = new b2DebugDraw();
timeStep = (1 / 60);
iterations = 10;
}
public function createDistanceJoint(_arg1:b2DistanceJointDef):b2DistanceJoint{
return ((world.CreateJoint(_arg1) as b2DistanceJoint));
}
public function destroyBody(_arg1:b2Body):void{
world.DestroyBody(_arg1);
}
public function houseKeeping():void{
var _local1:b2Body = world.m_bodyList;
while (_local1) {
if ((_local1.m_userData is DisplayObject)){
_local1.m_userData.parent.removeChild(_local1.m_userData);
world.DestroyBody(_local1);
} else {
if (_local1 != groundBody){
world.DestroyBody(_local1);
};
};
_local1 = _local1.m_next;
};
var _local2:b2Joint = world.m_jointList;
while (_local2) {
world.DestroyJoint(_local2);
_local2 = _local2.m_next;
};
}
public function addToWorld(_arg1:b2BodyDef):b2Body{
return (world.CreateBody(_arg1));
}
public function set physicsScale(_arg1:Number):void{
physScale = _arg1;
}
public function set timeStepValue(_arg1:Number):void{
timeStep = _arg1;
}
public function set iterationsValue(_arg1:Number):void{
iterations = _arg1;
}
public function createRectangle(_arg1:Number, _arg2:Number, _arg3:Point, _arg4:Number=0):b2PolygonDef{
var _local5:b2PolygonDef = new b2PolygonDef();
_local5.SetAsOrientedBox(((_arg1 * 0.5) / physScale), ((_arg2 * 0.5) / physScale), new b2Vec2((_arg3.x / physScale), (_arg3.x / physScale)), (_arg4 * b2Settings.b2_pi));
return (_local5);
}
public function createContactListener(_arg1:b2ContactListener):void{
world.SetContactListener(_arg1);
}
public function mainloop():void{
world.Step(timeStep, iterations);
var _local1:b2Body = world.m_bodyList;
while (_local1) {
if ((_local1.m_userData is DisplayObject)){
_local1.m_userData.x = (_local1.GetPosition().x * physScale);
_local1.m_userData.y = (_local1.GetPosition().y * physScale);
_local1.m_userData.rotation = (_local1.GetAngle() * (180 / Math.PI));
};
_local1 = _local1.m_next;
};
}
public function createPolygon(_arg1:Rectangle):b2PolygonDef{
var _local2:b2PolygonDef = new b2PolygonDef();
_local2.vertexCount = 4;
_local2.vertices[0].Set((_arg1.x / physScale), (_arg1.y / physScale));
_local2.vertices[1].Set((_arg1.right / physScale), (_arg1.y / physScale));
_local2.vertices[2].Set((_arg1.right / physScale), (_arg1.bottom / physScale));
_local2.vertices[3].Set((_arg1.x / physScale), (_arg1.bottom / physScale));
return (_local2);
}
public function toggleDebug(_arg1:Sprite):void{
if (debugFlag == false){
debugFlag = true;
_arg1.visible = true;
dbgDraw.m_sprite = _arg1;
dbgDraw.m_drawScale = physScale;
dbgDraw.m_fillAlpha = 0.2;
dbgDraw.m_lineThickness = 1;
dbgDraw.m_drawFlags = ((b2DebugDraw.e_centerOfMassBit | b2DebugDraw.e_shapeBit) | b2DebugDraw.e_jointBit);
world.SetDebugDraw(dbgDraw);
} else {
debugFlag = false;
dbgDraw.m_drawFlags = 0;
_arg1.visible = false;
};
}
public function createGround(_arg1:Point, _arg2:Number, _arg3:Number, _arg4:Number):void{
var _local5:b2BodyDef = new b2BodyDef();
_local5.position.Set((_arg1.x / physScale), (_arg1.y / physScale));
var _local6:b2PolygonDef = new b2PolygonDef();
_local6.SetAsBox((_arg2 / physScale), (_arg3 / physScale));
_local6.friction = _arg4;
groundBody = world.CreateBody(_local5);
groundBody.CreateShape(_local6);
groundBody.SetMassFromShapes();
groundBody.PutToSleep();
}
public function createRevoluteJoint(_arg1:b2RevoluteJointDef):b2RevoluteJoint{
return ((world.CreateJoint(_arg1) as b2RevoluteJoint));
}
public function position(_arg1:b2BodyDef, _arg2:Point):void{
_arg1.position.Set((_arg2.x / physScale), (_arg2.y / physScale));
}
public function createTriangle(_arg1:Point, _arg2:Point, _arg3:Point):b2PolygonDef{
var _local4:b2PolygonDef = new b2PolygonDef();
_local4.vertexCount = 3;
_local4.vertices[0].Set((_arg1.x / physScale), (_arg1.y / physScale));
_local4.vertices[1].Set((_arg2.x / physScale), (_arg2.y / physScale));
_local4.vertices[2].Set((_arg3.x / physScale), (_arg3.y / physScale));
return (_local4);
}
public function areOverHalfSleeping():Boolean{
var _local1:int;
var _local2:int;
var _local3:b2Body = world.m_bodyList;
while (_local3) {
if ((_local3.m_userData is DisplayObject)){
_local2++;
if (_local3.IsSleeping() == true){
_local1++;
};
};
_local3 = _local3.m_next;
};
var _local4:Number = ((_local2 / 100) * 75);
if (_local1 > _local4){
return (true);
};
return (false);
}
public function mainloop_noGraphicUpdate():void{
world.Step(timeStep, iterations);
}
public function refilter(_arg1:b2Shape):void{
world.Refilter(_arg1);
}
public function destroyJoint(_arg1:b2Joint):void{
world.DestroyJoint(_arg1);
}
public function createPrismaticJoint(_arg1:b2PrismaticJointDef):b2PrismaticJoint{
return ((world.CreateJoint(_arg1) as b2PrismaticJoint));
}
public function createCircle(_arg1:Point, _arg2:Number):b2CircleDef{
var _local3:b2CircleDef = new b2CircleDef();
_local3.radius = ((_arg2 * 0.5) / physScale);
_local3.density = 10;
_local3.friction = 1;
_local3.restitution = 0.3;
return (_local3);
}
public function showAll():void{
var _local1:b2Body = world.m_bodyList;
while (_local1) {
if ((_local1.m_userData is DisplayObject)){
_local1.m_userData.visible = true;
};
_local1 = _local1.m_next;
};
}
public function createWorld(_arg1:Rectangle, _arg2:Point, _arg3:Boolean):b2World{
var _local4:b2AABB = new b2AABB();
_local4.lowerBound.Set((-(_arg1.x) / physScale), (-(_arg1.height) / physScale));
_local4.upperBound.Set((_arg1.width / physScale), (_arg1.height / physScale));
var _local5:b2Vec2 = new b2Vec2(_arg2.x, _arg2.y);
world = new b2World(_local4, _local5, _arg3);
return (world);
}
public function hideAll():void{
var _local1:b2Body = world.m_bodyList;
while (_local1) {
if ((_local1.m_userData is DisplayObject)){
_local1.m_userData.visible = false;
};
_local1 = _local1.m_next;
};
}
}
}//package com.gamingyourway.Physics
Section 248
//Key (com.gamingyourway.Utils.Key)
package com.gamingyourway.Utils {
import flash.display.*;
import flash.events.*;
public class Key {
private static var initialized:Boolean = false;
private static var keysDown:Object = new Object();
public static function initialize(_arg1:Stage):void{
if (!initialized){
_arg1.addEventListener(KeyboardEvent.KEY_DOWN, keyPressed);
_arg1.addEventListener(KeyboardEvent.KEY_UP, keyReleased);
_arg1.addEventListener(Event.DEACTIVATE, clearKeys);
initialized = true;
};
}
private static function clearKeys(_arg1:Event):void{
keysDown = new Object();
}
public static function isDown(_arg1:uint):Boolean{
if (!initialized){
throw (new Error("Key class has yet been initialized."));
};
return (Boolean((_arg1 in keysDown)));
}
private static function keyPressed(_arg1:KeyboardEvent):void{
keysDown[_arg1.keyCode] = true;
}
private static function keyReleased(_arg1:KeyboardEvent):void{
if ((_arg1.keyCode in keysDown)){
delete keysDown[_arg1.keyCode];
};
}
}
}//package com.gamingyourway.Utils
Section 249
//Web (com.gamingyourway.Utils.Web)
package com.gamingyourway.Utils {
import com.hexagonstar.util.debug.*;
import flash.net.*;
public class Web {
public static function getURL(_arg1:String, _arg2:String=null):void{
var url = _arg1;
var window = _arg2;
var req:URLRequest = new URLRequest(url);
try {
navigateToURL(req, window);
} catch(e:Error) {
Debug.trace("Navigate to URL failed", e.message);
};
}
}
}//package com.gamingyourway.Utils
Section 250
//Debug (com.hexagonstar.util.debug.Debug)
package com.hexagonstar.util.debug {
import flash.events.*;
import flash.display.*;
import flash.utils.*;
import flash.net.*;
import flash.system.*;
public final class Debug {
private static var _isConnected:Boolean = false;
private static var _fpsMeter:FPSMeter;
private static var _isPollingFPS:Boolean = false;
private static var _isDisabled:Boolean = false;
private static var _filterLevel:uint = 0;
private static var _fpsPollInterval:uint = 1000;
private static var _stopWatch:StopWatch;
private static var _isLargeData:Boolean = false;
private static var _connection:LocalConnection;
private static var _stage:Stage;
public static function timerSeconds():void{
if (_stopWatch != null){
Debug.trace((_stopWatch.getTimeInSeconds() + "s"));
};
}
private static function onFPSUpdate(_arg1:Event):void{
send("onFPS", ((((_fpsMeter.getFPS() + "/") + _stage.frameRate) + "|") + System.totalMemory));
}
public static function trace(_arg1=undefined, _arg2=null, _arg3:int=-1):void{
var _local4:* = _arg1;
var _local5:Boolean;
var _local6 = 1;
if (typeof(_arg2) == "boolean"){
_local5 = _arg2;
} else {
if (typeof(_arg2) == "number"){
_local6 = _arg2;
};
};
if (_arg3 > -1){
_local6 = _arg3;
};
if ((((_local6 >= _filterLevel)) && ((_local6 < 7)))){
send("onData", _local4, _local6, (_local5) ? 1 : 0);
};
}
private static function send(_arg1:String, _arg2, _arg3:int=1, _arg4:uint=0):void{
var _local5:uint;
var _local6:ByteArray;
if (!_isDisabled){
if (!_isConnected){
_isConnected = true;
_connection = new LocalConnection();
_connection.addEventListener(StatusEvent.STATUS, onStatus);
};
_local5 = 0;
if (typeof(_arg2) == "string"){
_local5 = String(_arg2).length;
} else {
if (typeof(_arg2) == "object"){
_local6 = new ByteArray();
_local6.writeObject(_arg2);
_local5 = _local6.length;
_local6 = null;
};
};
if (_local5 > 39000){
storeDataLSO(_arg1, _arg2);
_arg1 = "onLargeData";
_arg2 = null;
};
_connection.send("_alcon_lc", _arg1, _arg2, _arg3, _arg4, "");
};
}
public static function fpsStop():void{
if (_fpsMeter != null){
_isPollingFPS = false;
_fpsMeter.stop();
_fpsMeter.removeEventListener(FPSMeter.FPS_UPDATE, onFPSUpdate);
_fpsMeter = null;
};
}
public static function clear():void{
Debug.trace("[%CLR%]", 5);
}
public static function delimiter():void{
Debug.trace("[%DLT%]", 5);
}
public static function timerReset():void{
if (_stopWatch != null){
_stopWatch.reset();
};
}
public static function time():void{
Debug.trace("[%TME%]", 5);
}
public static function inspect(_arg1:Object=null, _arg2:int=-1):void{
send("onInspect", _arg1, 1, _arg2);
}
public static function timerMilliSeconds():void{
if (_stopWatch != null){
Debug.trace((_stopWatch.getTimeInMilliSeconds() + "ms"));
};
}
public static function getFilterLevel():int{
return (_filterLevel);
}
public static function timerStart():void{
if (!_isDisabled){
if (_stopWatch == null){
_stopWatch = new StopWatch();
};
_stopWatch.start();
};
}
public static function timerToString():void{
if (_stopWatch != null){
Debug.trace(_stopWatch.toString());
};
}
private static function storeDataLSO(_arg1:String, _arg2):void{
var flushResult:String;
var method = _arg1;
var data = _arg2;
var sharedObject:SharedObject = SharedObject.getLocal("alcon", "/");
sharedObject.data.alconMethod = method;
sharedObject.data.alconData = data;
try {
flushResult = sharedObject.flush();
if (flushResult == SharedObjectFlushStatus.FLUSHED){
return;
};
} catch(e:Error) {
Security.showSettings(SecurityPanel.LOCAL_STORAGE);
};
}
public static function timerStop():void{
if (_stopWatch != null){
_stopWatch.stop();
};
}
public static function disable():void{
_isDisabled = true;
}
public static function setFilterLevel(_arg1:uint=0):void{
if ((((_arg1 >= 0)) && ((_arg1 < 5)))){
_filterLevel = _arg1;
};
}
public static function hexDump(_arg1):void{
send("onHexDump", _arg1, 0, 0);
}
private static function onStatus(_arg1:StatusEvent):void{
}
public static function timerStopToString():void{
if (_stopWatch != null){
_stopWatch.stop();
Debug.trace(_stopWatch.toString());
};
}
public static function pause():void{
Debug.trace("[%PSE%]", 5);
}
public static function fpsStart(_arg1:Stage):void{
if (((!(_isDisabled)) && ((_fpsMeter == null)))){
_isPollingFPS = true;
_stage = _arg1;
_fpsMeter = new FPSMeter(_arg1);
_fpsMeter.addEventListener(FPSMeter.FPS_UPDATE, onFPSUpdate);
_fpsMeter.start();
};
}
}
}//package com.hexagonstar.util.debug
Section 251
//FPSMeter (com.hexagonstar.util.debug.FPSMeter)
package com.hexagonstar.util.debug {
import flash.events.*;
import flash.display.*;
import flash.utils.*;
public class FPSMeter extends EventDispatcher {
private var _timer:Timer;
private var _fps:int;
private var _isRunning:Boolean;
private var _stage:Stage;
public static const FPS_UPDATE:String = "fpsUpdate";
public function FPSMeter(_arg1:Stage){
_stage = _arg1;
_fps = 0;
_isRunning = false;
}
public function stop():void{
if (_isRunning){
_isRunning = false;
_timer.stop();
_timer.removeEventListener(TimerEvent.TIMER, onTimer);
_stage.removeEventListener(Event.ENTER_FRAME, onEnterFrame);
_timer = null;
};
}
private function onEnterFrame(_arg1:Event):void{
_fps++;
}
public function start(_arg1:uint=1000):void{
if (!_isRunning){
_isRunning = true;
_timer = new Timer(_arg1, 0);
_timer.addEventListener(TimerEvent.TIMER, onTimer);
_stage.addEventListener(Event.ENTER_FRAME, onEnterFrame);
_timer.start();
};
}
private function onTimer(_arg1:TimerEvent):void{
dispatchEvent(new Event(FPSMeter.FPS_UPDATE));
_fps = 0;
}
public function getFPS():int{
return (_fps);
}
}
}//package com.hexagonstar.util.debug
Section 252
//StopWatch (com.hexagonstar.util.debug.StopWatch)
package com.hexagonstar.util.debug {
import flash.utils.*;
public class StopWatch {
private var started:Boolean;// = false
private var startTimeKeys:Array;
private var stopTimeKeys:Array;
public function StopWatch(){
reset();
}
public function hasStarted():Boolean{
return (started);
}
public function stop():void{
var _local1:uint;
if (hasStarted()){
_local1 = getTimer();
stopTimeKeys[(startTimeKeys.length - 1)] = _local1;
started = false;
};
}
public function toString():String{
var _local2:uint;
var _local1 = "\n ********** [STOPWATCH] **********";
_local2 = 0;
while (_local2 < startTimeKeys.length) {
_local1 = (_local1 + (((("\n started [" + startTimeKeys[_local2]) + "ms] stopped [") + stopTimeKeys[_local2]) + "ms]"));
_local2++;
};
if (_local2 == 0){
_local1 = (_local1 + "\n never started.");
} else {
_local1 = (_local1 + (("\n total runnning time: " + getTimeInMilliSeconds()) + "ms"));
};
_local1 = (_local1 + "\n *********************************");
return (_local1);
}
public function reset():void{
startTimeKeys = new Array();
stopTimeKeys = new Array();
started = false;
}
public function start():void{
if (!hasStarted()){
started = true;
startTimeKeys.push(getTimer());
};
}
public function getTimeInSeconds():Number{
return ((getTimeInMilliSeconds() / 1000));
}
public function getTimeInMilliSeconds():uint{
if (hasStarted()){
stopTimeKeys[(startTimeKeys.length - 1)] = getTimer();
};
var _local1:uint;
var _local2:uint = startTimeKeys.length;
var _local3:uint;
while (_local3 < _local2) {
_local1 = (_local1 + (stopTimeKeys[_local3] - startTimeKeys[_local3]));
_local3++;
};
return (_local1);
}
}
}//package com.hexagonstar.util.debug
Section 253
//compareStringCaseInSensitive (de.polygonal.ds.sort.compare.compareStringCaseInSensitive)
package de.polygonal.ds.sort.compare {
public function compareStringCaseInSensitive(_arg1:String, _arg2:String):int{
var _local3:int;
var _local4:int;
var _local5:int;
_arg1 = _arg1.toLowerCase();
_arg2 = _arg2.toLowerCase();
if ((_arg1.length + _arg2.length) > 2){
_local3 = 0;
_local4 = ((_arg1.length > _arg2.length)) ? _arg1.length : _arg2.length;
_local5 = 0;
while (_local5 < _local4) {
_local3 = (_arg1.charCodeAt(_local5) - _arg2.charCodeAt(_local5));
if (_local3 != 0){
break;
};
_local5++;
};
return (_local3);
//unresolved jump
};
return ((_arg1.charCodeAt(0) - _arg2.charCodeAt(0)));
}
}//package de.polygonal.ds.sort.compare
Section 254
//compareStringCaseInSensitiveDesc (de.polygonal.ds.sort.compare.compareStringCaseInSensitiveDesc)
package de.polygonal.ds.sort.compare {
public function compareStringCaseInSensitiveDesc(_arg1:String, _arg2:String):int{
var _local3:int;
var _local4:int;
var _local5:int;
_arg1 = _arg1.toLowerCase();
_arg2 = _arg2.toLowerCase();
if ((_arg1.length + _arg2.length) > 2){
_local3 = 0;
_local4 = ((_arg1.length > _arg2.length)) ? _arg1.length : _arg2.length;
_local5 = 0;
while (_local5 < _local4) {
_local3 = (_arg2.charCodeAt(_local5) - _arg1.charCodeAt(_local5));
if (_local3 != 0){
break;
};
_local5++;
};
return (_local3);
//unresolved jump
};
return ((_arg2.charCodeAt(0) - _arg1.charCodeAt(0)));
}
}//package de.polygonal.ds.sort.compare
Section 255
//compareStringCaseSensitive (de.polygonal.ds.sort.compare.compareStringCaseSensitive)
package de.polygonal.ds.sort.compare {
public function compareStringCaseSensitive(_arg1:String, _arg2:String):int{
var _local3:int;
var _local4:int;
var _local5:int;
if ((_arg1.length + _arg2.length) > 2){
_local3 = 0;
_local4 = ((_arg1.length > _arg2.length)) ? _arg1.length : _arg2.length;
_local5 = 0;
while (_local5 < _local4) {
_local3 = (_arg1.charCodeAt(_local5) - _arg2.charCodeAt(_local5));
if (_local3 != 0){
break;
};
_local5++;
};
return (_local3);
//unresolved jump
};
return ((_arg1.charCodeAt(0) - _arg2.charCodeAt(0)));
}
}//package de.polygonal.ds.sort.compare
Section 256
//compareStringCaseSensitiveDesc (de.polygonal.ds.sort.compare.compareStringCaseSensitiveDesc)
package de.polygonal.ds.sort.compare {
public function compareStringCaseSensitiveDesc(_arg1:String, _arg2:String):int{
var _local3:int;
var _local4:int;
var _local5:int;
if ((_arg1.length + _arg2.length) > 2){
_local3 = 0;
_local4 = ((_arg1.length > _arg2.length)) ? _arg1.length : _arg2.length;
_local5 = 0;
while (_local5 < _local4) {
_local3 = (_arg2.charCodeAt(_local5) - _arg1.charCodeAt(_local5));
if (_local3 != 0){
break;
};
_local5++;
};
return (_local3);
//unresolved jump
};
return ((_arg2.charCodeAt(0) - _arg1.charCodeAt(0)));
}
}//package de.polygonal.ds.sort.compare
Section 257
//dLinkedInsertionSort (de.polygonal.ds.sort.dLinkedInsertionSort)
package de.polygonal.ds.sort {
import de.polygonal.ds.*;
public function dLinkedInsertionSort(_arg1:DListNode, _arg2:Boolean=false):DListNode{
var _local4:DListNode;
var _local5:DListNode;
var _local6:DListNode;
var _local7:DListNode;
var _local8:*;
if (!_arg1){
return (null);
};
var _local3:DListNode = _arg1;
if (_arg2){
_local5 = _local3.next;
while (_local5) {
_local6 = _local5.next;
_local4 = _local5.prev;
if (_local4.data < _local5.data){
_local7 = _local4;
while (_local7.prev) {
if (_local7.prev.data < _local5.data){
_local7 = _local7.prev;
} else {
break;
};
};
if (_local6){
_local4.next = _local6;
_local6.prev = _local4;
} else {
_local4.next = null;
};
if (_local7 == _local3){
_local5.prev = null;
_local5.next = _local7;
_local7.prev = _local5;
_local3 = _local5;
} else {
_local5.prev = _local7.prev;
_local7.prev.next = _local5;
_local5.next = _local7;
_local7.prev = _local5;
};
};
_local5 = _local6;
};
return (_local3);
//unresolved jump
};
_local5 = _local3.next;
while (_local5) {
_local6 = _local5.next;
_local4 = _local5.prev;
if (_local4.data > _local5.data){
_local7 = _local4;
while (_local7.prev) {
if (_local7.prev.data > _local5.data){
_local7 = _local7.prev;
} else {
break;
};
};
if (_local6){
_local4.next = _local6;
_local6.prev = _local4;
} else {
_local4.next = null;
};
if (_local7 == _local3){
_local5.prev = null;
_local5.next = _local7;
_local7.prev = _local5;
_local3 = _local5;
} else {
_local5.prev = _local7.prev;
_local7.prev.next = _local5;
_local5.next = _local7;
_local7.prev = _local5;
};
};
_local5 = _local6;
};
return (_local3);
}
}//package de.polygonal.ds.sort
Section 258
//dLinkedInsertionSortCmp (de.polygonal.ds.sort.dLinkedInsertionSortCmp)
package de.polygonal.ds.sort {
import de.polygonal.ds.*;
public function dLinkedInsertionSortCmp(_arg1:DListNode, _arg2:Function, _arg3:Boolean=false):DListNode{
var _local5:DListNode;
var _local6:DListNode;
var _local7:DListNode;
var _local8:DListNode;
var _local9:*;
if (((!(_arg1)) || ((_arg2 == null)))){
return (null);
};
var _local4:DListNode = _arg1;
if (_arg3){
_local6 = _local4.next;
while (_local6) {
_local7 = _local6.next;
_local5 = _local6.prev;
if (_arg2(_local5.data, _local6.data) < 0){
_local8 = _local5;
while (_local8.prev) {
if (_arg2(_local8.prev.data, _local6.data) < 0){
_local8 = _local8.prev;
} else {
break;
};
};
if (_local7){
_local5.next = _local7;
_local7.prev = _local5;
} else {
_local5.next = null;
};
if (_local8 == _local4){
_local6.prev = null;
_local6.next = _local8;
_local8.prev = _local6;
_local4 = _local6;
} else {
_local6.prev = _local8.prev;
_local8.prev.next = _local6;
_local6.next = _local8;
_local8.prev = _local6;
};
};
_local6 = _local7;
};
} else {
_local6 = _local4.next;
while (_local6) {
_local7 = _local6.next;
_local5 = _local6.prev;
if (_arg2(_local5.data, _local6.data) > 0){
_local8 = _local5;
while (_local8.prev) {
if (_arg2(_local8.prev.data, _local6.data) > 0){
_local8 = _local8.prev;
} else {
break;
};
};
if (_local7){
_local5.next = _local7;
_local7.prev = _local5;
} else {
_local5.next = null;
};
if (_local8 == _local4){
_local6.prev = null;
_local6.next = _local8;
_local8.prev = _local6;
_local4 = _local6;
} else {
_local6.prev = _local8.prev;
_local8.prev.next = _local6;
_local6.next = _local8;
_local8.prev = _local6;
};
};
_local6 = _local7;
};
};
return (_local4);
}
}//package de.polygonal.ds.sort
Section 259
//dLinkedMergeSort (de.polygonal.ds.sort.dLinkedMergeSort)
package de.polygonal.ds.sort {
import de.polygonal.ds.*;
public function dLinkedMergeSort(_arg1:DListNode, _arg2:Boolean=false):DListNode{
var _local4:DListNode;
var _local5:DListNode;
var _local6:DListNode;
var _local7:DListNode;
var _local9:int;
var _local10:int;
var _local11:int;
var _local12:int;
if (!_arg1){
return (null);
};
var _local3:DListNode = _arg1;
var _local8 = 1;
if (_arg2){
while (true) {
_local4 = _local3;
_local7 = null;
_local3 = _local7;
_local9 = 0;
while (_local4) {
_local9++;
_local12 = 0;
_local10 = 0;
_local5 = _local4;
while (_local12 < _local8) {
_local10++;
_local5 = _local5.next;
if (!_local5){
break;
};
_local12++;
};
_local11 = _local8;
while ((((_local10 > 0)) || ((((_local11 > 0)) && (_local5))))) {
if (_local10 == 0){
_local6 = _local5;
_local5 = _local5.next;
_local11--;
} else {
if ((((_local11 == 0)) || (!(_local5)))){
_local6 = _local4;
_local4 = _local4.next;
_local10--;
} else {
if ((_local4.data - _local5.data) >= 0){
_local6 = _local4;
_local4 = _local4.next;
_local10--;
} else {
_local6 = _local5;
_local5 = _local5.next;
_local11--;
};
};
};
if (_local7){
_local7.next = _local6;
} else {
_local3 = _local6;
};
_local6.prev = _local7;
_local7 = _local6;
};
_local4 = _local5;
};
_local7.next = null;
if (_local9 <= 1){
return (_local3);
};
_local8 = (_local8 << 1);
};
} else {
while (true) {
_local4 = _local3;
_local7 = null;
_local3 = _local7;
_local9 = 0;
while (_local4) {
_local9++;
_local12 = 0;
_local10 = 0;
_local5 = _local4;
while (_local12 < _local8) {
_local10++;
_local5 = _local5.next;
if (!_local5){
break;
};
_local12++;
};
_local11 = _local8;
while ((((_local10 > 0)) || ((((_local11 > 0)) && (_local5))))) {
if (_local10 == 0){
_local6 = _local5;
_local5 = _local5.next;
_local11--;
} else {
if ((((_local11 == 0)) || (!(_local5)))){
_local6 = _local4;
_local4 = _local4.next;
_local10--;
} else {
if ((_local4.data - _local5.data) <= 0){
_local6 = _local4;
_local4 = _local4.next;
_local10--;
} else {
_local6 = _local5;
_local5 = _local5.next;
_local11--;
};
};
};
if (_local7){
_local7.next = _local6;
} else {
_local3 = _local6;
};
_local6.prev = _local7;
_local7 = _local6;
};
_local4 = _local5;
};
_local7.next = null;
if (_local9 <= 1){
return (_local3);
};
_local8 = (_local8 << 1);
};
};
return (null);
}
}//package de.polygonal.ds.sort
Section 260
//dLinkedMergeSortCmp (de.polygonal.ds.sort.dLinkedMergeSortCmp)
package de.polygonal.ds.sort {
import de.polygonal.ds.*;
public function dLinkedMergeSortCmp(_arg1:DListNode, _arg2:Function, _arg3:Boolean=false):DListNode{
var _local5:DListNode;
var _local6:DListNode;
var _local7:DListNode;
var _local8:DListNode;
var _local10:int;
var _local11:int;
var _local12:int;
var _local13:int;
if (((!(_arg1)) || ((_arg2 == null)))){
return (null);
};
var _local4:DListNode = _arg1;
var _local9 = 1;
if (_arg3){
while (true) {
_local5 = _local4;
_local8 = null;
_local4 = _local8;
_local10 = 0;
while (_local5) {
_local10++;
_local13 = 0;
_local11 = 0;
_local6 = _local5;
while (_local13 < _local9) {
_local11++;
_local6 = _local6.next;
if (!_local6){
break;
};
_local13++;
};
_local12 = _local9;
while ((((_local11 > 0)) || ((((_local12 > 0)) && (_local6))))) {
if (_local11 == 0){
_local7 = _local6;
_local6 = _local6.next;
_local12--;
} else {
if ((((_local12 == 0)) || (!(_local6)))){
_local7 = _local5;
_local5 = _local5.next;
_local11--;
} else {
if (_arg2(_local5.data, _local6.data) >= 0){
_local7 = _local5;
_local5 = _local5.next;
_local11--;
} else {
_local7 = _local6;
_local6 = _local6.next;
_local12--;
};
};
};
if (_local8){
_local8.next = _local7;
} else {
_local4 = _local7;
};
_local7.prev = _local8;
_local8 = _local7;
};
_local5 = _local6;
};
_arg1.prev = _local8;
_local8.next = null;
if (_local10 <= 1){
return (_local4);
};
_local9 = (_local9 << 1);
};
} else {
while (true) {
_local5 = _local4;
_local8 = null;
_local4 = _local8;
_local10 = 0;
while (_local5) {
_local10++;
_local13 = 0;
_local11 = 0;
_local6 = _local5;
while (_local13 < _local9) {
_local11++;
_local6 = _local6.next;
if (!_local6){
break;
};
_local13++;
};
_local12 = _local9;
while ((((_local11 > 0)) || ((((_local12 > 0)) && (_local6))))) {
if (_local11 == 0){
_local7 = _local6;
_local6 = _local6.next;
_local12--;
} else {
if ((((_local12 == 0)) || (!(_local6)))){
_local7 = _local5;
_local5 = _local5.next;
_local11--;
} else {
if (_arg2(_local5.data, _local6.data) <= 0){
_local7 = _local5;
_local5 = _local5.next;
_local11--;
} else {
_local7 = _local6;
_local6 = _local6.next;
_local12--;
};
};
};
if (_local8){
_local8.next = _local7;
} else {
_local4 = _local7;
};
_local7.prev = _local8;
_local8 = _local7;
};
_local5 = _local6;
};
_arg1.prev = _local8;
_local8.next = null;
if (_local10 <= 1){
return (_local4);
};
_local9 = (_local9 << 1);
};
};
return (null);
}
}//package de.polygonal.ds.sort
Section 261
//Collection (de.polygonal.ds.Collection)
package de.polygonal.ds {
public interface Collection {
function get size():int;
function isEmpty():Boolean;
function getIterator():Iterator;
function clear():void;
function toArray():Array;
function contains(_arg1):Boolean;
}
}//package de.polygonal.ds
Section 262
//DLinkedList (de.polygonal.ds.DLinkedList)
package de.polygonal.ds {
import de.polygonal.ds.sort.compare.*;
import de.polygonal.ds.sort.*;
public class DLinkedList implements Collection {
private var _count:int;
public var tail:DListNode;
public var head:DListNode;
public function DLinkedList(... _args){
head = (tail = null);
_count = 0;
if (_args.length > 0){
append.apply(this, _args);
};
}
public function get size():int{
return (_count);
}
public function isEmpty():Boolean{
return ((_count == 0));
}
public function remove(_arg1:DListIterator):Boolean{
if (((!((_arg1.list == this))) || (!(_arg1.node)))){
return (false);
};
var _local2:DListNode = _arg1.node;
if (_local2 == head){
head = head.next;
} else {
if (_local2 == tail){
tail = tail.prev;
};
};
if (_arg1.node){
_arg1.node = _arg1.node.next;
};
if (_local2.prev){
_local2.prev.next = _local2.next;
};
if (_local2.next){
_local2.next.prev = _local2.prev;
};
_local2.next = (_local2.prev = null);
if (head == null){
tail = null;
};
_count--;
return (true);
}
public function removeHead(){
var _local1:*;
if (head){
_local1 = head.data;
head = head.next;
if (head){
head.prev = null;
} else {
tail = null;
};
_count--;
return (_local1);
};
return (null);
}
public function clear():void{
var _local2:DListNode;
var _local1:DListNode = head;
head = null;
while (_local1) {
_local2 = _local1.next;
_local1.next = (_local1.prev = null);
_local1 = _local2;
};
_count = 0;
}
public function prepend(... _args):DListNode{
var _local4:DListNode;
var _local5:int;
var _local2:int = _args.length;
var _local3:DListNode = new DListNode(_args[int((_local2 - 1))]);
if (head){
head.insertBefore(_local3);
head = head.prev;
} else {
head = (tail = _local3);
};
if (_local2 > 1){
_local4 = _local3;
_local5 = (_local2 - 2);
while (_local5 >= 0) {
_local3 = new DListNode(_args[_local5]);
head.insertBefore(_local3);
head = head.prev;
_local5--;
};
_count = (_count + _local2);
return (_local4);
};
_count++;
return (_local3);
}
public function popDown():void{
var _local1:DListNode = tail;
if (tail.prev == head){
tail = head;
tail.next = null;
head = _local1;
head.prev = null;
head.next = tail;
tail.prev = head;
} else {
tail = tail.prev;
tail.next = null;
head.prev = _local1;
_local1.prev = null;
_local1.next = head;
head = _local1;
};
}
public function concat(... _args):DLinkedList{
var _local3:DLinkedList;
var _local4:DListNode;
var _local2:DLinkedList = new DLinkedList();
_local4 = head;
while (_local4) {
_local2.append(_local4.data);
_local4 = _local4.next;
};
var _local5:int = _args.length;
var _local6:int;
while (_local6 < _local5) {
_local3 = _args[_local6];
_local4 = _local3.head;
while (_local4) {
_local2.append(_local4.data);
_local4 = _local4.next;
};
_local6++;
};
return (_local2);
}
public function insertBefore(_arg1:DListIterator, _arg2):DListNode{
var _local3:DListNode;
if (_arg1.list != this){
return (null);
};
if (_arg1.node){
_local3 = new DListNode(_arg2);
_arg1.node.insertBefore(_local3);
if (_arg1.node == head){
head = head.prev;
};
_count++;
return (_local3);
//unresolved jump
};
return (prepend(_arg2));
}
public function append(... _args):DListNode{
var _local4:DListNode;
var _local5:int;
var _local2:int = _args.length;
var _local3:DListNode = new DListNode(_args[0]);
if (head){
tail.insertAfter(_local3);
tail = tail.next;
} else {
head = (tail = _local3);
};
if (_local2 > 1){
_local4 = _local3;
_local5 = 1;
while (_local5 < _local2) {
_local3 = new DListNode(_args[_local5]);
tail.insertAfter(_local3);
tail = tail.next;
_local5++;
};
_count = (_count + _local2);
return (_local4);
};
_count++;
return (_local3);
}
public function sort(... _args):void{
var _local2:int;
var _local3:Function;
var _local4:*;
if (_count <= 1){
return;
};
if (_args.length > 0){
_local2 = 0;
_local3 = null;
_local4 = _args[0];
if ((_local4 is Function)){
_local3 = _local4;
if (_args.length > 1){
_local4 = _args[1];
if ((_local4 is int)){
_local2 = _local4;
};
};
} else {
if ((_local4 is int)){
_local2 = _local4;
};
};
if (Boolean(_local3)){
if ((_local2 & 2)){
head = dLinkedInsertionSortCmp(head, _local3, (_local2 == 18));
} else {
head = dLinkedMergeSortCmp(head, _local3, (_local2 == 16));
};
} else {
if ((_local2 & 2)){
if ((_local2 & 4)){
if (_local2 == 22){
head = dLinkedInsertionSortCmp(head, compareStringCaseSensitiveDesc);
} else {
if (_local2 == 14){
head = dLinkedInsertionSortCmp(head, compareStringCaseInSensitive);
} else {
if (_local2 == 30){
head = dLinkedInsertionSortCmp(head, compareStringCaseInSensitiveDesc);
} else {
head = dLinkedInsertionSortCmp(head, compareStringCaseSensitive);
};
};
};
} else {
head = dLinkedInsertionSort(head, (_local2 == 18));
};
} else {
if ((_local2 & 4)){
if (_local2 == 20){
head = dLinkedMergeSortCmp(head, compareStringCaseSensitiveDesc);
} else {
if (_local2 == 12){
head = dLinkedMergeSortCmp(head, compareStringCaseInSensitive);
} else {
if (_local2 == 28){
head = dLinkedMergeSortCmp(head, compareStringCaseInSensitiveDesc);
} else {
head = dLinkedMergeSortCmp(head, compareStringCaseSensitive);
};
};
};
} else {
if ((_local2 & 16)){
head = dLinkedMergeSort(head, true);
};
};
};
};
} else {
head = dLinkedMergeSort(head);
};
}
public function contains(_arg1):Boolean{
var _local2:DListNode = head;
while (_local2) {
if (_local2.data == _arg1){
return (true);
};
_local2 = _local2.next;
};
return (false);
}
public function reverse():void{
var _local1:DListNode;
var _local3:DListNode;
if (_count == 0){
return;
};
var _local2:DListNode = tail;
while (_local2) {
_local1 = _local2.prev;
if (!_local2.next){
_local2.next = _local2.prev;
_local2.prev = null;
head = _local2;
} else {
if (!_local2.prev){
_local2.prev = _local2.next;
_local2.next = null;
tail = _local2;
} else {
_local3 = _local2.next;
_local2.next = _local2.prev;
_local2.prev = _local3;
};
};
_local2 = _local1;
};
}
public function insertAfter(_arg1:DListIterator, _arg2):DListNode{
var _local3:DListNode;
if (_arg1.list != this){
return (null);
};
if (_arg1.node){
_local3 = new DListNode(_arg2);
_arg1.node.insertAfter(_local3);
if (_arg1.node == tail){
tail = _arg1.node.next;
};
_count++;
return (_local3);
//unresolved jump
};
return (append(_arg2));
}
public function getIterator():Iterator{
return (new DListIterator(this, head));
}
public function toArray():Array{
var _local1:Array = [];
var _local2:DListNode = head;
while (_local2) {
_local1.push(_local2.data);
_local2 = _local2.next;
};
return (_local1);
}
public function getListIterator():DListIterator{
return (new DListIterator(this, head));
}
public function join(_arg1):String{
if (_count == 0){
return ("");
};
var _local2 = "";
var _local3:DListNode = head;
while (_local3.next) {
_local2 = (_local2 + (_local3.data + _arg1));
_local3 = _local3.next;
};
_local2 = (_local2 + _local3.data);
return (_local2);
}
public function toString():String{
return ((("[DLinkedList > has " + size) + " nodes]"));
}
public function removeTail(){
var _local1:*;
if (tail){
_local1 = tail.data;
tail = tail.prev;
if (tail){
tail.next = null;
} else {
head = null;
};
_count--;
return (_local1);
};
return (null);
}
public function lastNodeOf(_arg1, _arg2:DListIterator=null):DListIterator{
if (_arg2 != null){
if (_arg2.list != this){
return (null);
};
};
var _local3:DListNode = ((_arg2)==null) ? tail : _arg2.node;
while (_local3) {
if (_local3.data === _arg1){
return (new DListIterator(this, _local3));
};
_local3 = _local3.prev;
};
return (null);
}
public function merge(... _args):void{
var _local2:DLinkedList;
_local2 = _args[0];
if (_local2.head){
if (head){
tail.next = _local2.head;
_local2.head.prev = tail;
tail = _local2.tail;
} else {
head = _local2.head;
tail = _local2.tail;
};
_count = (_count + _local2.size);
};
var _local3:int = _args.length;
var _local4 = 1;
while (_local4 < _local3) {
_local2 = _args[_local4];
if (_local2.head){
tail.next = _local2.head;
_local2.head.prev = tail;
tail = _local2.tail;
_count = (_count + _local2.size);
};
_local4++;
};
}
public function nodeOf(_arg1, _arg2:DListIterator=null):DListIterator{
if (_arg2 != null){
if (_arg2.list != this){
return (null);
};
};
var _local3:DListNode = ((_arg2)==null) ? head : _arg2.node;
while (_local3) {
if (_local3.data === _arg1){
return (new DListIterator(this, _local3));
};
_local3 = _local3.next;
};
return (null);
}
public function dump():String{
if (head == null){
return ("DLinkedList, empty");
};
var _local1 = (((("DLinkedList, has " + _count) + " node") + ((_count == 1)) ? "" : "s") + "\n|< Head\n");
var _local2:DListIterator = getListIterator();
while (_local2.valid()) {
_local1 = (_local1 + (("\t" + _local2.data) + "\n"));
_local2.forth();
};
_local1 = (_local1 + "Tail >|");
return (_local1);
}
public function splice(_arg1:DListIterator, _arg2:uint=4294967295, ... _args):DLinkedList{
var _local4:DListNode;
var _local5:DListNode;
var _local6:DLinkedList;
var _local7:int;
var _local8:int;
var _local9:DListNode;
if (_arg1){
if (_arg1.list != this){
return (null);
};
};
if (_arg1.node){
_local4 = _arg1.node;
_local5 = _arg1.node.prev;
_local6 = new DLinkedList();
if (_arg2 == 4294967295){
if (_arg1.node == tail){
return (_local6);
};
while (_arg1.node) {
_local6.append(_arg1.node.data);
_arg1.remove();
};
_arg1.list = _local6;
_arg1.node = _local4;
return (_local6);
} else {
_local7 = 0;
while (_local7 < _arg2) {
if (_arg1.node){
_local6.append(_arg1.node.data);
_arg1.remove();
} else {
break;
};
_local7++;
};
};
_local8 = _args.length;
if (_local8 > 0){
if (_count == 0){
_local7 = 0;
while (_local7 < _local8) {
append(_args[_local7]);
_local7++;
};
} else {
if (_local5 == null){
_local9 = prepend(_args[0]);
_local7 = 1;
while (_local7 < _local8) {
_local9.insertAfter(new DListNode(_args[_local7]));
if (_local9 == tail){
tail = _local9.next;
};
_local9 = _local9.next;
_count++;
_local7++;
};
} else {
_local9 = _local5;
_local7 = 0;
while (_local7 < _local8) {
_local9.insertAfter(new DListNode(_args[_local7]));
if (_local9 == tail){
tail = _local9.next;
};
_local9 = _local9.next;
_count++;
_local7++;
};
};
};
_arg1.node = _local9;
} else {
_arg1.node = _local4;
};
_arg1.list = _local6;
return (_local6);
};
return (null);
}
public function shiftUp():void{
var _local1:DListNode = head;
if (head.next == tail){
head = tail;
head.prev = null;
tail = _local1;
tail.next = null;
head.next = tail;
tail.prev = head;
} else {
head = head.next;
head.prev = null;
tail.next = _local1;
_local1.next = null;
_local1.prev = tail;
tail = _local1;
};
}
}
}//package de.polygonal.ds
Section 263
//DListIterator (de.polygonal.ds.DListIterator)
package de.polygonal.ds {
public class DListIterator implements Iterator {
public var node:DListNode;
public var list:DLinkedList;
public function DListIterator(_arg1:DLinkedList, _arg2:DListNode=null){
this.list = _arg1;
this.node = _arg2;
}
public function remove():Boolean{
return (list.remove(this));
}
public function back():void{
if (node){
node = node.prev;
};
}
public function start():void{
node = list.head;
}
public function get data(){
if (node){
return (node.data);
};
return (null);
}
public function forth():void{
if (node){
node = node.next;
};
}
public function toString():String{
return ((("{DListIterator, data=" + (node) ? node.data : "null") + "}"));
}
public function hasNext():Boolean{
return (Boolean(node));
}
public function valid():Boolean{
return (Boolean(node));
}
public function next(){
var _local1:*;
if (hasNext()){
_local1 = node.data;
node = node.next;
return (_local1);
};
return (null);
}
public function set data(_arg1):void{
node.data = _arg1;
}
public function end():void{
node = list.tail;
}
}
}//package de.polygonal.ds
Section 264
//DListNode (de.polygonal.ds.DListNode)
package de.polygonal.ds {
public class DListNode implements LinkedListNode {
public var prev:DListNode;
public var next:DListNode;
public var data;
public function DListNode(_arg1){
next = (prev = null);
data = _arg1;
}
public function unlink():void{
if (prev){
prev.next = next;
};
if (next){
next.prev = prev;
};
next = (prev = null);
}
public function insertAfter(_arg1:DListNode):void{
_arg1.next = next;
_arg1.prev = this;
if (next){
next.prev = _arg1;
};
next = _arg1;
}
public function insertBefore(_arg1:DListNode):void{
_arg1.next = this;
_arg1.prev = prev;
if (prev){
prev.next = _arg1;
};
prev = _arg1;
}
public function toString():String{
return ((("[DListNode, data=" + data) + "]"));
}
}
}//package de.polygonal.ds
Section 265
//Iterator (de.polygonal.ds.Iterator)
package de.polygonal.ds {
public interface Iterator {
function start():void;
function set data(_arg1):void;
function get data();
function next();
function hasNext():Boolean;
}
}//package de.polygonal.ds
Section 266
//LinkedListNode (de.polygonal.ds.LinkedListNode)
package de.polygonal.ds {
public interface LinkedListNode {
}
}//package de.polygonal.ds
Section 267
//TweenLite (gs.TweenLite)
package gs {
import flash.display.*;
import flash.events.*;
import flash.geom.*;
import flash.utils.*;
public class TweenLite {
public var delay:Number;
protected var _hasUpdate:Boolean;
protected var _subTweens:Array;
protected var _initted:Boolean;
public var startTime:int;
public var target:Object;
public var duration:Number;
protected var _hst:Boolean;
protected var _isDisplayObject:Boolean;
protected var _active:Boolean;
public var tweens:Array;
public var vars:Object;
public var initTime:int;
private static var _timer:Timer = new Timer(2000);
private static var _classInitted:Boolean;
public static var defaultEase:Function = TweenLite.easeOut;
public static var version:Number = 7.04;
private static var _sprite:Sprite = new Sprite();
protected static var _all:Dictionary = new Dictionary();
public static var killDelayedCallsTo:Function = TweenLite.killTweensOf;
protected static var _curTime:uint;
private static var _listening:Boolean;
public function TweenLite(_arg1:Object, _arg2:Number, _arg3:Object){
var _local4:*;
super();
if (_arg1 == null){
return;
};
if (((((!((_arg3.overwrite == false))) && (!((_arg1 == null))))) || ((_all[_arg1] == undefined)))){
delete _all[_arg1];
_all[_arg1] = new Dictionary();
};
_all[_arg1][this] = this;
this.vars = _arg3;
this.duration = ((_arg2) || (0.001));
this.delay = ((_arg3.delay) || (0));
_active = (((_arg2 == 0)) && ((this.delay == 0)));
this.target = _arg1;
_isDisplayObject = (_arg1 is DisplayObject);
if (!(this.vars.ease is Function)){
this.vars.ease = defaultEase;
};
if (this.vars.easeParams != null){
this.vars.proxiedEase = this.vars.ease;
this.vars.ease = easeProxy;
};
if (!isNaN(Number(this.vars.autoAlpha))){
this.vars.alpha = Number(this.vars.autoAlpha);
this.vars.visible = (this.vars.alpha > 0);
};
this.tweens = [];
_subTweens = [];
_hst = (_initted = false);
if (!_classInitted){
_curTime = getTimer();
_sprite.addEventListener(Event.ENTER_FRAME, executeAll);
_classInitted = true;
};
this.initTime = _curTime;
if ((((((this.vars.runBackwards == true)) && (!((this.vars.renderOnStart == true))))) || (_active))){
initTweenVals();
this.startTime = _curTime;
if (_active){
render((this.startTime + 1));
} else {
render(this.startTime);
};
_local4 = this.vars.visible;
if (this.vars.isTV == true){
_local4 = this.vars.exposedProps.visible;
};
if (((((!((_local4 == null))) && ((this.vars.runBackwards == true)))) && (_isDisplayObject))){
this.target.visible = Boolean(_local4);
};
};
if (((!(_listening)) && (!(_active)))){
_timer.addEventListener("timer", killGarbage);
_timer.start();
_listening = true;
};
}
protected function addSubTween(_arg1:Function, _arg2:Object, _arg3:Object, _arg4:Object=null):void{
var _local6:String;
var _local5:Object = {proxy:_arg1, target:_arg2, info:_arg4};
_subTweens[_subTweens.length] = _local5;
for (_local6 in _arg3) {
if (typeof(_arg3[_local6]) == "number"){
this.tweens[this.tweens.length] = {o:_arg2, p:_local6, s:_arg2[_local6], c:(_arg3[_local6] - _arg2[_local6]), sub:_local5};
} else {
this.tweens[this.tweens.length] = {o:_arg2, p:_local6, s:_arg2[_local6], c:Number(_arg3[_local6]), sub:_local5};
};
};
_hst = true;
}
public function initTweenVals(_arg1:Boolean=false, _arg2:String=""):void{
var _local3:String;
var _local4:int;
var _local6:Array;
var _local7:ColorTransform;
var _local8:ColorTransform;
var _local9:Object;
var _local5:Object = this.vars;
if (_local5.isTV == true){
_local5 = _local5.exposedProps;
};
if ((this.target is Array)){
_local6 = ((this.vars.endArray) || ([]));
_local4 = 0;
while (_local4 < _local6.length) {
if (((!((this.target[_local4] == _local6[_local4]))) && (!((this.target[_local4] == undefined))))){
this.tweens[this.tweens.length] = {o:this.target, p:_local4.toString(), s:this.target[_local4], c:(_local6[_local4] - this.target[_local4])};
};
_local4++;
};
} else {
if (((((!((typeof(_local5.tint) == "undefined"))) || ((this.vars.removeTint == true)))) && (_isDisplayObject))){
_local7 = this.target.transform.colorTransform;
_local8 = new ColorTransform();
if (_local5.alpha != undefined){
_local8.alphaMultiplier = _local5.alpha;
delete _local5.alpha;
} else {
_local8.alphaMultiplier = this.target.alpha;
};
if (((!((this.vars.removeTint == true))) && (((((!((_local5.tint == null))) && (!((_local5.tint == ""))))) || ((_local5.tint == 0)))))){
_local8.color = _local5.tint;
};
addSubTween(tintProxy, {progress:0}, {progress:1}, {target:this.target, color:_local7, endColor:_local8});
};
if (((!((_local5.frame == null))) && (_isDisplayObject))){
addSubTween(frameProxy, {frame:this.target.currentFrame}, {frame:_local5.frame}, {target:this.target});
};
if (((!(isNaN(this.vars.volume))) && (this.target.hasOwnProperty("soundTransform")))){
addSubTween(volumeProxy, this.target.soundTransform, {volume:this.vars.volume}, {target:this.target});
};
for (_local3 in _local5) {
if ((((((((((((((((((((((((((((((((((_local3 == "ease")) || ((_local3 == "delay")))) || ((_local3 == "overwrite")))) || ((_local3 == "onComplete")))) || ((_local3 == "onCompleteParams")))) || ((_local3 == "runBackwards")))) || ((_local3 == "visible")))) || ((_local3 == "persist")))) || ((_local3 == "onUpdate")))) || ((_local3 == "onUpdateParams")))) || ((_local3 == "autoAlpha")))) || ((_local3 == "onStart")))) || ((_local3 == "onStartParams")))) || ((_local3 == "renderOnStart")))) || ((_local3 == "proxiedEase")))) || ((_local3 == "easeParams")))) || (((_arg1) && (!((_arg2.indexOf(((" " + _local3) + " ")) == -1))))))){
} else {
if (((!(((_isDisplayObject) && ((((((_local3 == "tint")) || ((_local3 == "removeTint")))) || ((_local3 == "frame"))))))) && (!((((_local3 == "volume")) && (this.target.hasOwnProperty("soundTransform"))))))){
if (typeof(_local5[_local3]) == "number"){
this.tweens[this.tweens.length] = {o:this.target, p:_local3, s:this.target[_local3], c:(_local5[_local3] - this.target[_local3])};
} else {
this.tweens[this.tweens.length] = {o:this.target, p:_local3, s:this.target[_local3], c:Number(_local5[_local3])};
};
};
};
};
};
if (this.vars.runBackwards == true){
_local4 = (this.tweens.length - 1);
while (_local4 > -1) {
_local9 = this.tweens[_local4];
this.tweens[_local4].s = (_local9.s + _local9.c);
_local9.c = (_local9.c * -1);
_local4--;
};
};
if ((((_local5.visible == true)) && (_isDisplayObject))){
this.target.visible = true;
};
if (this.vars.onUpdate != null){
_hasUpdate = true;
};
_initted = true;
}
public function get active():Boolean{
if (_active){
return (true);
};
if (((_curTime - this.initTime) / 1000) > this.delay){
_active = true;
this.startTime = (this.initTime + (this.delay * 1000));
if (!_initted){
initTweenVals();
} else {
if (((!((this.vars.visible == undefined))) && (_isDisplayObject))){
this.target.visible = true;
};
};
if (this.vars.onStart != null){
this.vars.onStart.apply(null, this.vars.onStartParams);
};
if (this.duration == 0.001){
this.startTime = (this.startTime - 1);
};
return (true);
//unresolved jump
};
return (false);
}
public function render(_arg1:uint):void{
var _local3:Number;
var _local4:Object;
var _local5:int;
var _local2:Number = ((_arg1 - this.startTime) / 1000);
if (_local2 >= this.duration){
_local2 = this.duration;
_local3 = 1;
} else {
_local3 = this.vars.ease(_local2, 0, 1, this.duration);
};
_local5 = (this.tweens.length - 1);
while (_local5 > -1) {
_local4 = this.tweens[_local5];
_local4.o[_local4.p] = (_local4.s + (_local3 * _local4.c));
_local5--;
};
if (_hst){
_local5 = (_subTweens.length - 1);
while (_local5 > -1) {
_subTweens[_local5].proxy(_subTweens[_local5]);
_local5--;
};
};
if (_hasUpdate){
this.vars.onUpdate.apply(null, this.vars.onUpdateParams);
};
if (_local2 == this.duration){
complete(true);
};
}
protected function easeProxy(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
return (this.vars.proxiedEase.apply(null, arguments.concat(this.vars.easeParams)));
}
public function complete(_arg1:Boolean=false):void{
if (!_arg1){
if (!_initted){
initTweenVals();
};
this.startTime = (_curTime - (this.duration * 1000));
render(_curTime);
return;
};
if (((!((this.vars.visible == undefined))) && (_isDisplayObject))){
if (((!(isNaN(this.vars.autoAlpha))) && ((this.target.alpha == 0)))){
this.target.visible = false;
} else {
if (this.vars.runBackwards != true){
this.target.visible = this.vars.visible;
};
};
};
if (this.vars.persist != true){
removeTween(this);
};
if (this.vars.onComplete != null){
this.vars.onComplete.apply(null, this.vars.onCompleteParams);
};
}
public static function easeOut(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{
_arg1 = (_arg1 / _arg4);
return ((((-(_arg3) * _arg1) * (_arg1 - 2)) + _arg2));
}
public static function frameProxy(_arg1:Object):void{
_arg1.info.target.gotoAndStop(Math.round(_arg1.target.frame));
}
public static function removeTween(_arg1:TweenLite=null):void{
if (((!((_arg1 == null))) && (!((_all[_arg1.target] == undefined))))){
delete _all[_arg1.target][_arg1];
};
}
public static function killTweensOf(_arg1:Object=null, _arg2:Boolean=false):void{
var _local3:Object;
var _local4:*;
if (((!((_arg1 == null))) && (!((_all[_arg1] == undefined))))){
if (_arg2){
_local3 = _all[_arg1];
for (_local4 in _local3) {
_local3[_local4].complete(false);
};
};
delete _all[_arg1];
};
}
public static function delayedCall(_arg1:Number, _arg2:Function, _arg3:Array=null):TweenLite{
return (new TweenLite(_arg2, 0, {delay:_arg1, onComplete:_arg2, onCompleteParams:_arg3, overwrite:false}));
}
public static function from(_arg1:Object, _arg2:Number, _arg3:Object):TweenLite{
_arg3.runBackwards = true;
return (new TweenLite(_arg1, _arg2, _arg3));
}
public static function executeAll(_arg1:Event=null):void{
var _local3:Dictionary;
var _local4:Object;
var _local5:Object;
var _local2:uint = (_curTime = getTimer());
if (_listening){
_local3 = _all;
for each (_local4 in _local3) {
for (_local5 in _local4) {
if (((!((_local4[_local5] == undefined))) && (_local4[_local5].active))){
_local4[_local5].render(_local2);
};
};
};
};
}
public static function volumeProxy(_arg1:Object):void{
_arg1.info.target.soundTransform = _arg1.target;
}
public static function killGarbage(_arg1:TimerEvent):void{
var _local3:Boolean;
var _local4:Object;
var _local5:Object;
var _local6:Object;
var _local2:uint;
for (_local4 in _all) {
_local3 = false;
for (_local5 in _all[_local4]) {
_local3 = true;
break;
};
if (!_local3){
delete _all[_local4];
} else {
_local2++;
};
};
if (_local2 == 0){
_timer.removeEventListener("timer", killGarbage);
_timer.stop();
_listening = false;
};
}
public static function tintProxy(_arg1:Object):void{
var _local2:Number = _arg1.target.progress;
var _local3:Number = (1 - _local2);
var _local4:Object = _arg1.info.color;
var _local5:Object = _arg1.info.endColor;
_arg1.info.target.transform.colorTransform = new ColorTransform(((_local4.redMultiplier * _local3) + (_local5.redMultiplier * _local2)), ((_local4.greenMultiplier * _local3) + (_local5.greenMultiplier * _local2)), ((_local4.blueMultiplier * _local3) + (_local5.blueMultiplier * _local2)), ((_local4.alphaMultiplier * _local3) + (_local5.alphaMultiplier * _local2)), ((_local4.redOffset * _local3) + (_local5.redOffset * _local2)), ((_local4.greenOffset * _local3) + (_local5.greenOffset * _local2)), ((_local4.blueOffset * _local3) + (_local5.blueOffset * _local2)), ((_local4.alphaOffset * _local3) + (_local5.alphaOffset * _local2)));
}
public static function to(_arg1:Object, _arg2:Number, _arg3:Object):TweenLite{
return (new TweenLite(_arg1, _arg2, _arg3));
}
}
}//package gs
Section 268
//BitmapAsset (mx.core.BitmapAsset)
package mx.core {
import flash.display.*;
public class BitmapAsset extends FlexBitmap implements IFlexAsset, IFlexDisplayObject {
mx_internal static const VERSION:String = "3.2.0.3958";
public function BitmapAsset(_arg1:BitmapData=null, _arg2:String="auto", _arg3:Boolean=false){
super(_arg1, _arg2, _arg3);
}
public function get measuredWidth():Number{
if (bitmapData){
return (bitmapData.width);
};
return (0);
}
public function get measuredHeight():Number{
if (bitmapData){
return (bitmapData.height);
};
return (0);
}
public function setActualSize(_arg1:Number, _arg2:Number):void{
width = _arg1;
height = _arg2;
}
public function move(_arg1:Number, _arg2:Number):void{
this.x = _arg1;
this.y = _arg2;
}
}
}//package mx.core
Section 269
//EdgeMetrics (mx.core.EdgeMetrics)
package mx.core {
public class EdgeMetrics {
public var top:Number;
public var left:Number;
public var bottom:Number;
public var right:Number;
mx_internal static const VERSION:String = "3.2.0.3958";
public static const EMPTY:EdgeMetrics = new EdgeMetrics(0, 0, 0, 0);
;
public function EdgeMetrics(_arg1:Number=0, _arg2:Number=0, _arg3:Number=0, _arg4:Number=0){
this.left = _arg1;
this.top = _arg2;
this.right = _arg3;
this.bottom = _arg4;
}
public function clone():EdgeMetrics{
return (new EdgeMetrics(left, top, right, bottom));
}
}
}//package mx.core
Section 270
//FlexBitmap (mx.core.FlexBitmap)
package mx.core {
import flash.display.*;
import mx.utils.*;
public class FlexBitmap extends Bitmap {
mx_internal static const VERSION:String = "3.2.0.3958";
public function FlexBitmap(_arg1:BitmapData=null, _arg2:String="auto", _arg3:Boolean=false){
var bitmapData = _arg1;
var pixelSnapping = _arg2;
var smoothing = _arg3;
super(bitmapData, pixelSnapping, smoothing);
try {
name = NameUtil.createUniqueName(this);
} catch(e:Error) {
};
}
override public function toString():String{
return (NameUtil.displayObjectToString(this));
}
}
}//package mx.core
Section 271
//FlexMovieClip (mx.core.FlexMovieClip)
package mx.core {
import flash.display.*;
import mx.utils.*;
public class FlexMovieClip extends MovieClip {
mx_internal static const VERSION:String = "3.2.0.3958";
public function FlexMovieClip(){
super();
try {
name = NameUtil.createUniqueName(this);
} catch(e:Error) {
};
}
override public function toString():String{
return (NameUtil.displayObjectToString(this));
}
}
}//package mx.core
Section 272
//FlexSprite (mx.core.FlexSprite)
package mx.core {
import flash.display.*;
import mx.utils.*;
public class FlexSprite extends Sprite {
mx_internal static const VERSION:String = "3.2.0.3958";
public function FlexSprite(){
super();
try {
name = NameUtil.createUniqueName(this);
} catch(e:Error) {
};
}
override public function toString():String{
return (NameUtil.displayObjectToString(this));
}
}
}//package mx.core
Section 273
//IBorder (mx.core.IBorder)
package mx.core {
public interface IBorder {
function get borderMetrics():EdgeMetrics;
}
}//package mx.core
Section 274
//IFlexAsset (mx.core.IFlexAsset)
package mx.core {
public interface IFlexAsset {
}
}//package mx.core
Section 275
//IFlexDisplayObject (mx.core.IFlexDisplayObject)
package mx.core {
import flash.events.*;
import flash.display.*;
import flash.geom.*;
import flash.accessibility.*;
public interface IFlexDisplayObject extends IBitmapDrawable, IEventDispatcher {
function get visible():Boolean;
function get rotation():Number;
function localToGlobal(_arg1:Point):Point;
function get name():String;
function set width(_arg1:Number):void;
function get measuredHeight():Number;
function get blendMode():String;
function get scale9Grid():Rectangle;
function set name(_arg1:String):void;
function set scaleX(_arg1:Number):void;
function set scaleY(_arg1:Number):void;
function get measuredWidth():Number;
function get accessibilityProperties():AccessibilityProperties;
function set scrollRect(_arg1:Rectangle):void;
function get cacheAsBitmap():Boolean;
function globalToLocal(_arg1:Point):Point;
function get height():Number;
function set blendMode(_arg1:String):void;
function get parent():DisplayObjectContainer;
function getBounds(_arg1:DisplayObject):Rectangle;
function get opaqueBackground():Object;
function set scale9Grid(_arg1:Rectangle):void;
function setActualSize(_arg1:Number, _arg2:Number):void;
function set alpha(_arg1:Number):void;
function set accessibilityProperties(_arg1:AccessibilityProperties):void;
function get width():Number;
function hitTestPoint(_arg1:Number, _arg2:Number, _arg3:Boolean=false):Boolean;
function set cacheAsBitmap(_arg1:Boolean):void;
function get scaleX():Number;
function get scaleY():Number;
function get scrollRect():Rectangle;
function get mouseX():Number;
function get mouseY():Number;
function set height(_arg1:Number):void;
function set mask(_arg1:DisplayObject):void;
function getRect(_arg1:DisplayObject):Rectangle;
function get alpha():Number;
function set transform(_arg1:Transform):void;
function move(_arg1:Number, _arg2:Number):void;
function get loaderInfo():LoaderInfo;
function get root():DisplayObject;
function hitTestObject(_arg1:DisplayObject):Boolean;
function set opaqueBackground(_arg1:Object):void;
function set visible(_arg1:Boolean):void;
function get mask():DisplayObject;
function set x(_arg1:Number):void;
function set y(_arg1:Number):void;
function get transform():Transform;
function set filters(_arg1:Array):void;
function get x():Number;
function get y():Number;
function get filters():Array;
function set rotation(_arg1:Number):void;
function get stage():Stage;
}
}//package mx.core
Section 276
//IRepeaterClient (mx.core.IRepeaterClient)
package mx.core {
public interface IRepeaterClient {
function get instanceIndices():Array;
function set instanceIndices(_arg1:Array):void;
function get isDocument():Boolean;
function set repeaters(_arg1:Array):void;
function initializeRepeaterArrays(_arg1:IRepeaterClient):void;
function get repeaters():Array;
function set repeaterIndices(_arg1:Array):void;
function get repeaterIndices():Array;
}
}//package mx.core
Section 277
//MovieClipAsset (mx.core.MovieClipAsset)
package mx.core {
public class MovieClipAsset extends FlexMovieClip implements IFlexAsset, IFlexDisplayObject, IBorder {
private var _measuredHeight:Number;
private var _measuredWidth:Number;
mx_internal static const VERSION:String = "3.2.0.3958";
public function MovieClipAsset(){
_measuredWidth = width;
_measuredHeight = height;
}
public function get measuredWidth():Number{
return (_measuredWidth);
}
public function get measuredHeight():Number{
return (_measuredHeight);
}
public function setActualSize(_arg1:Number, _arg2:Number):void{
width = _arg1;
height = _arg2;
}
public function move(_arg1:Number, _arg2:Number):void{
this.x = _arg1;
this.y = _arg2;
}
public function get borderMetrics():EdgeMetrics{
if (scale9Grid == null){
return (EdgeMetrics.EMPTY);
};
return (new EdgeMetrics(scale9Grid.left, scale9Grid.top, Math.ceil((measuredWidth - scale9Grid.right)), Math.ceil((measuredHeight - scale9Grid.bottom))));
}
}
}//package mx.core
Section 278
//mx_internal (mx.core.mx_internal)
package mx.core {
public namespace mx_internal = "http://www.adobe.com/2006/flex/mx/internal";
}//package mx.core
Section 279
//SoundAsset (mx.core.SoundAsset)
package mx.core {
import flash.media.*;
public class SoundAsset extends Sound implements IFlexAsset {
mx_internal static const VERSION:String = "3.2.0.3958";
}
}//package mx.core
Section 280
//SpriteAsset (mx.core.SpriteAsset)
package mx.core {
public class SpriteAsset extends FlexSprite implements IFlexAsset, IFlexDisplayObject, IBorder {
private var _measuredHeight:Number;
private var _measuredWidth:Number;
mx_internal static const VERSION:String = "3.2.0.3958";
public function SpriteAsset(){
_measuredWidth = width;
_measuredHeight = height;
}
public function get measuredWidth():Number{
return (_measuredWidth);
}
public function get measuredHeight():Number{
return (_measuredHeight);
}
public function setActualSize(_arg1:Number, _arg2:Number):void{
width = _arg1;
height = _arg2;
}
public function move(_arg1:Number, _arg2:Number):void{
this.x = _arg1;
this.y = _arg2;
}
public function get borderMetrics():EdgeMetrics{
if (scale9Grid == null){
return (EdgeMetrics.EMPTY);
};
return (new EdgeMetrics(scale9Grid.left, scale9Grid.top, Math.ceil((measuredWidth - scale9Grid.right)), Math.ceil((measuredHeight - scale9Grid.bottom))));
}
}
}//package mx.core
Section 281
//NameUtil (mx.utils.NameUtil)
package mx.utils {
import mx.core.*;
import flash.display.*;
import flash.utils.*;
public class NameUtil {
mx_internal static const VERSION:String = "3.2.0.3958";
private static var counter:int = 0;
public static function displayObjectToString(_arg1:DisplayObject):String{
var result:String;
var o:DisplayObject;
var s:String;
var indices:Array;
var displayObject = _arg1;
try {
o = displayObject;
while (o != null) {
if (((((o.parent) && (o.stage))) && ((o.parent == o.stage)))){
break;
};
s = o.name;
if ((o is IRepeaterClient)){
indices = IRepeaterClient(o).instanceIndices;
if (indices){
s = (s + (("[" + indices.join("][")) + "]"));
};
};
result = ((result == null)) ? s : ((s + ".") + result);
o = o.parent;
};
} catch(e:SecurityError) {
};
return (result);
}
public static function createUniqueName(_arg1:Object):String{
if (!_arg1){
return (null);
};
var _local2:String = getQualifiedClassName(_arg1);
var _local3:int = _local2.indexOf("::");
if (_local3 != -1){
_local2 = _local2.substr((_local3 + 2));
};
var _local4:int = _local2.charCodeAt((_local2.length - 1));
if ((((_local4 >= 48)) && ((_local4 <= 57)))){
_local2 = (_local2 + "_");
};
return ((_local2 + counter++));
}
}
}//package mx.utils
Section 282
//Main (Main)
package {
import flash.display.*;
import Classes.*;
import flash.events.*;
import flash.ui.*;
public class Main extends Sprite {
private static var __parent:DisplayObject;
private static var instance:Main;
private static var initObj:Init;
private static var stage:Stage;
public function Main(){
if (instance){
throw (new Error("Singleton and can only be accessed through Singleton.getInstance()"));
};
instance = this;
waiting();
}
public function getInitObj():Init{
return (initObj);
}
public function getMainMovie():DisplayObject{
return (__parent);
}
public function getStage():Stage{
return (stage);
}
private function mainAddedToStage(_arg1:Event):void{
stage = this.stage;
var _local2:ContextMenu = new ContextMenu();
_local2.builtInItems.forwardAndBack = false;
_local2.builtInItems.loop = false;
_local2.builtInItems.play = false;
_local2.builtInItems.print = false;
_local2.builtInItems.rewind = false;
_local2.builtInItems.zoom = false;
_local2.builtInItems.save = false;
contextMenu = _local2;
stage.quality = StageQuality.MEDIUM;
stage.scaleMode = StageScaleMode.NO_SCALE;
__parent = this.root;
initObj = new Init();
}
override public function toString():String{
return ("Main");
}
public function waiting():void{
addEventListener(Event.ADDED_TO_STAGE, mainAddedToStage);
}
public static function getInstance():Main{
return (instance);
}
}
}//package
Section 283
//Preloader (Preloader)
package {
import flash.events.*;
import flash.display.*;
import flash.ui.*;
import flash.utils.*;
public class Preloader extends MovieClip {
private var logoClassInstance:Object;
private var logoClass:Class;
public function Preloader(){
addEventListener(Event.ADDED_TO_STAGE, preloaderAddedToStage);
}
private function triggerGame():void{
var _local2:Object;
var _local1:Class = (getDefinitionByName("Main") as Class);
if (_local1){
_local2 = new (_local1);
addChild((_local2 as DisplayObject));
};
}
private function mainloop2(_arg1:Event):void{
if (framesLoaded == totalFrames){
if (logoClassInstance.animTweenInFlag == true){
removeEventListener(Event.ENTER_FRAME, mainloop2);
logoClassInstance.fullyLoaded();
addEventListener(Event.ENTER_FRAME, mainloop3);
};
};
}
private function mainloop3(_arg1:Event):void{
if (logoClassInstance.animCompletedFlag == true){
removeEventListener(Event.ENTER_FRAME, mainloop3);
nextFrame();
triggerGame();
};
}
private function preloaderAddedToStage(_arg1:Event):void{
removeEventListener(Event.ADDED_TO_STAGE, preloaderAddedToStage);
var _local2:ContextMenu = new ContextMenu();
_local2.builtInItems.forwardAndBack = false;
_local2.builtInItems.loop = false;
_local2.builtInItems.play = false;
_local2.builtInItems.print = false;
_local2.builtInItems.rewind = false;
_local2.builtInItems.zoom = false;
_local2.builtInItems.save = false;
contextMenu = _local2;
stage.scaleMode = StageScaleMode.NO_SCALE;
addEventListener(Event.ENTER_FRAME, mainloop);
}
private function triggerLogo():void{
logoClass = (getDefinitionByName("PreloaderLogo") as Class);
if (logoClass){
logoClassInstance = new logoClass(stage.loaderInfo.url);
addChild((logoClassInstance as DisplayObject));
};
}
private function mainloop(_arg1:Event):void{
if (framesLoaded >= 2){
nextFrame();
triggerLogo();
removeEventListener(Event.ENTER_FRAME, mainloop);
addEventListener(Event.ENTER_FRAME, mainloop2);
};
}
}
}//package
Section 284
//PreloaderLogo (PreloaderLogo)
package {
import flash.events.*;
import flash.display.*;
import com.gamingyourway.Utils.*;
public class PreloaderLogo extends Sprite {
private var logoAnim:MovieClip;
public var animCompletedFlag:Boolean;// = false
private var spilLogo:MovieClip;
public var animTweenInFlag:Boolean;// = false
private var logoAnimMC:Class;
private var loadedButton:MovieClip;
private var link:String;// = "http://www.agame.com"
private var hostingdomain:String;
public function PreloaderLogo(_arg1:String){
var _local4:String;
var _local5:Number;
logoAnimMC = PreloaderLogo_logoAnimMC;
super();
logoAnim = new logoAnimMC();
spilLogo = logoAnim["spilLogo"];
if (_arg1.lastIndexOf("_agame") != -1){
spilLogo.gotoAndStop(1);
link = "http://www.agame.com";
} else {
if (_arg1.lastIndexOf("_spielen") != -1){
spilLogo.gotoAndStop(6);
link = "http://www.Spielen.com";
} else {
if (_arg1.lastIndexOf("_jeu") != -1){
spilLogo.gotoAndStop(5);
link = "http://www.Jeu.fr";
} else {
if (_arg1.lastIndexOf("_spelNL") != -1){
spilLogo.gotoAndStop(4);
link = "http://www.Spel.nl";
} else {
if (_arg1.lastIndexOf("_gamesCOID") != -1){
spilLogo.gotoAndStop(13);
link = "http://www.Games.co.id";
} else {
if (_arg1.lastIndexOf("_spelaSE") != -1){
spilLogo.gotoAndStop(22);
link = "http://www.Spela.se";
} else {
if (_arg1.lastIndexOf("_egames") != -1){
spilLogo.gotoAndStop(44);
link = "http://www.Egames.jp";
} else {
if (_arg1.lastIndexOf("_zapjuegos") != -1){
spilLogo.gotoAndStop(3);
link = "http://www.Zapjuegos.com";
} else {
if (_arg1.lastIndexOf("_clickjogos") != -1){
spilLogo.gotoAndStop(7);
link = "http://www.Clickjogos.com";
} else {
if (_arg1.lastIndexOf("_gameCN") != -1){
spilLogo.gotoAndStop(2);
link = "http://www.game.com.cn";
} else {
if (_arg1.lastIndexOf("_flashgames") != -1){
spilLogo.gotoAndStop(11);
link = "http://www.Flashgames.ru";
} else {
if (_arg1.lastIndexOf("_gioco") != -1){
spilLogo.gotoAndStop(23);
link = "http://www.Gioco.it";
} else {
if (_arg1.lastIndexOf("_gry") != -1){
spilLogo.gotoAndStop(21);
link = "http://www.Gry.pl";
} else {
if (_arg1.lastIndexOf("_ojogos") != -1){
spilLogo.gotoAndStop(25);
link = "http://www.ojogos.com.br";
} else {
spilLogo.gotoAndStop(1);
};
};
};
};
};
};
};
};
};
};
};
};
};
};
var _local2:String = _arg1;
var _local3:Number = _local2.indexOf("http://");
if (_local3 == -1){
hostingdomain = "offline_play";
} else {
_local4 = _local2.slice((_local3 + 6));
_local5 = _local4.indexOf("/");
hostingdomain = _local4.slice(0, _local5);
};
loadedButton = logoAnim["loadedButton"];
loadedButton.gotoAndStop(1);
waiting();
}
private function waitingToEnd(_arg1:Event):void{
if (logoAnim.currentFrame == logoAnim.totalFrames){
logoAnim.gotoAndStop(logoAnim.totalFrames);
logoAnim.removeEventListener(Event.ENTER_FRAME, waitingToEnd);
animCompletedFlag = true;
dispose();
};
}
public function waiting():void{
addEventListener(Event.ADDED_TO_STAGE, logoAddedToStage);
}
private function logoClicked(_arg1:MouseEvent):void{
logoAnim.useHandCursor = false;
logoAnim.buttonMode = false;
logoAnim.enabled = false;
logoAnim.removeEventListener(MouseEvent.CLICK, logoClicked);
var _local2 = (((link + "/?utm_medium=brandedgames_external&utm_campaign=DestroyAllCars&utm_source=") + hostingdomain) + "&utm_content=logo_intro");
Web.getURL(_local2, "_blank");
}
public function fullyLoaded():void{
loadedButton.gotoAndStop(2);
loadedButton.buttonMode = true;
loadedButton.addEventListener(MouseEvent.MOUSE_DOWN, buttonPressed);
logoAnim.useHandCursor = false;
logoAnim.buttonMode = false;
logoAnim.enabled = false;
logoAnim.removeEventListener(MouseEvent.CLICK, logoClicked);
logoAnim.gotoAndPlay("killButton");
logoAnim.addEventListener(Event.ENTER_FRAME, waitingToEnd);
}
private function buttonPressed(_arg1:MouseEvent):void{
loadedButton.removeEventListener(MouseEvent.MOUSE_DOWN, buttonPressed);
loadedButton.visible = false;
logoAnim.gotoAndPlay("out");
logoAnim.addEventListener(Event.ENTER_FRAME, waitingToEnd);
}
private function logoAddedToStage(_arg1:Event):void{
stage.addChild(logoAnim);
logoAnim.useHandCursor = true;
logoAnim.buttonMode = true;
logoAnim.enabled = true;
logoAnim.mouseChildren = true;
logoAnim.addEventListener(MouseEvent.CLICK, logoClicked);
logoAnim.gotoAndPlay(1);
logoAnim.addEventListener(Event.ENTER_FRAME, waitingToFinish);
}
private function waitingToFinish(_arg1:Event):void{
if (logoAnim.currentLabel == "stop"){
logoAnim.gotoAndStop("stop");
logoAnim.removeEventListener(Event.ENTER_FRAME, waitingToFinish);
animTweenInFlag = true;
};
}
public function dispose():void{
stage.removeChild(logoAnim);
}
}
}//package
Section 285
//PreloaderLogo_logoAnimMC (PreloaderLogo_logoAnimMC)
package {
import mx.core.*;
import flash.display.*;
public class PreloaderLogo_logoAnimMC extends MovieClipAsset {
public var spilLogo:DisplayObject;
public var loadedButton:DisplayObject;
}
}//package