STORY   LOOP   FURRY   PORN   GAMES
• C •   SERVICES [?] [R] RND   POPULAR
Archived flashes:
229595
/disc/ · /res/     /show/ · /fap/ · /gg/ · /swf/P0001 · P2595 · P5190

A
Very
Merry Christmas!


<div style="position:absolute;top:-99px;left:-99px;"><img src="http://swfchan.com:57475/72915343?noj=FRM72915343-23DC" width="1" height="1"></div>

X Stunt Bike.swf

This is the info page for
Flash #66852

(Click the ID number above for more basic data on this flash file.)


Text
0

NEXT

NEXT

NEXT

UPGRADE PARAMETER - EngInE

UPGRADE PARAMETER - AERO

UPGRADE PARAMETER - WEIGHT REDUCTION

<p align="right"><font face="Hatcheck" size="51" color="#ffffff" letterSpacing="0.000000" kerning="1">100$</font></p>

<p align="right"><font face="Hatcheck" size="51" color="#ffffff" letterSpacing="0.000000" kerning="1">100$</font></p>

<p align="right"><font face="Hatcheck" size="51" color="#ffffff" letterSpacing="0.000000" kerning="1">100$</font></p>

SHOP

HAWK 2000

MY FIRST BIKE

MIYAGI V6

FREE

$1000

$2000

Your money: 15600

Bike color:

Biker color:

OK

OK

OK

<p align="center"><font face="Hatcheck_20pt_st" size="20" color="#333333" letterSpacing="0.000000" kerning="1">You have not enough </font></p><p align="center"><font face="Hatcheck_20pt_st" size="20" color="#333333" letterSpacing="0.000000" kerning="1">money to </font></p><p align="center"><font face="Hatcheck_20pt_st" size="20" color="#333333" letterSpacing="0.000000" kerning="1">Purchase this UPgrade!</font></p>

<p align="center"><font face="Hatcheck" size="20" color="#333333" letterSpacing="0.000000" kerning="1">Are you sure want to Purchase this uPgrade? </font></p><p align="center"><font face="Hatcheck" size="20" color="#333333" letterSpacing="0.000000" kerning="1">It costs $1000!</font></p>

CANCEL

CANCEL

CANCEL

GAME OVER

Main Menu

Main Menu

Main Menu

Main MEnu

SUBMIT SCORE

SUBMIT SCORE

SUBMIT SCORE

<p align="center"><font face="Hatcheck_50pt_st" size="50" color="#333333" letterSpacing="0.000000" kerning="1">GAME OVER</font></p><p align="center"></p>

INSTRUCTIONS

INSTRUCTIONS

PRACTICE

PRACTICE

SCORES

SCORES

PLAY MORE GAMES

PLAY MORE GAMES

X STUNT BIKE

PLAY

PLAY

PRODUCED BY LETS DESIGN

C

COMPETE IN EACH OF 8 TOURNAMENTS.
EARN MONEY BY DOING FLIPS AND TRICKS IN THE AIR.
Use                 keys to move your bike.
USE                 KEYS IN THE AIR to SPIN your bike
Use                                              keys to do different tricks in the air:
UPGRADE YOUR BIKE AND DO MORE TRICKS. FAIL TO EARN ENOUGH MONEY TO
ENTER NEXT TOURNAMENT AND YOU LOOSE.
GOOD LUCK!

Z

X

C

V

B

N

< Back

< Back

<p align="center"></p><p align="center"><font face="Hatcheck" size="50" color="#333333" letterSpacing="0.000000" kerning="1">YOU CRASHED TOO MANY TIMES AND FAILED THIS TOURNAMENT.</font></p>

Next level

Next level

Next level

Next level

<p align="center"><font face="Hatcheck_60pt_st" size="60" color="#333333" letterSpacing="0.000000" kerning="1">TOURNAMENT IS OVER!</font></p><p align="center"><font face="Hatcheck_60pt_st" size="60" color="#333333" letterSpacing="0.000000" kerning="1">PROCEED TO THE NEXT TOURNAMENT</font></p>

TOURNAMENT IS OVER!

RESTART

RESTART

RESTART

GAME OVER

Score:

Time:

000

PLAY MORE GAMES

MONEY:

Time:

GET BACK TO ARENA!

<p align="center"><font face="Hatcheck" size="20" color="#cc0000" letterSpacing="0.000000" kerning="1">level 1</font></p>

<p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">level 1</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">54</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">56</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">15</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">15</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">15</font></p>

<p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">level 1</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">54</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">56</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">15</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">15</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">15</font></p>

<p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">level 1</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">54</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">56</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">15</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">15</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">15</font></p>

<p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">level 1</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">54</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">56</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">15</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">15</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">15</font></p>

<p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">level 1</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">54</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">56</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">15</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">15</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">15</font></p>

<p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">level 1</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">54</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">56</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">15</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">15</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">15</font></p>

<p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">level 1</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">54</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">56</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">15</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">15</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">15</font></p>

<p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">level 1</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">54</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">56</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">15</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">15</font></p><p align="center"><font face="Hatcheck" size="12" color="#ffffff" letterSpacing="0.000000" kerning="1">15</font></p>

PLEASE WAIT WHILE LOADING

ActionScript [AS3]

Section 1
//b2CircleDef (Box2D.Collision.Shapes.b2CircleDef) package Box2D.Collision.Shapes { import Box2D.Common.Math.*; public class b2CircleDef extends b2ShapeDef { public var localPosition:b2Vec2; public var radius:Number; 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.Common.Math.*; import Box2D.Dynamics.*; import Box2D.Collision.*; import Box2D.Common.*; public class b2CircleShape extends b2Shape { public var m_radius:Number; public var m_localPosition:b2Vec2; public function b2CircleShape(_arg1:b2ShapeDef){ var _local2:b2CircleDef; m_localPosition = new b2Vec2(); super(_arg1); _local2 = (_arg1 as b2CircleDef); m_type = e_circleShape; m_localPosition.SetV(_local2.localPosition); m_radius = _local2.radius; } override public function TestPoint(_arg1:b2XForm, _arg2:b2Vec2):Boolean{ var _local3:b2Mat22; var _local4:Number; var _local5:Number; _local3 = _arg1.R; _local4 = (_arg1.position.x + ((_local3.col1.x * m_localPosition.x) + (_local3.col2.x * m_localPosition.y))); _local5 = (_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))); } public function GetLocalPosition():b2Vec2{ return (m_localPosition); } override public function TestSegment(_arg1:b2XForm, _arg2:Array, _arg3:b2Vec2, _arg4:b2Segment, _arg5:Number):Boolean{ var _local6:b2Mat22; 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; _local6 = _arg1.R; _local7 = (_arg1.position.x + ((_local6.col1.x * m_localPosition.x) + (_local6.col2.x * m_localPosition.y))); _local8 = (_arg1.position.x + ((_local6.col1.y * m_localPosition.x) + (_local6.col2.y * m_localPosition.y))); _local9 = (_arg4.p1.x - _local7); _local10 = (_arg4.p1.y - _local8); _local11 = (((_local9 * _local9) + (_local10 * _local10)) - (m_radius * m_radius)); if (_local11 < 0){ return (false); }; _local12 = (_arg4.p2.x - _arg4.p1.x); _local13 = (_arg4.p2.y - _arg4.p1.y); _local14 = ((_local9 * _local12) + (_local10 * _local13)); _local15 = ((_local12 * _local12) + (_local13 * _local13)); _local16 = ((_local14 * _local14) - (_local15 * _local11)); if ((((_local16 < 0)) || ((_local15 < Number.MIN_VALUE)))){ return (false); }; _local17 = -((_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); } 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 ComputeSweptAABB(_arg1:b2AABB, _arg2:b2XForm, _arg3:b2XForm):void{ var _local4:b2Mat22; var _local5:Number; var _local6:Number; var _local7:Number; var _local8:Number; _local4 = _arg2.R; _local5 = (_arg2.position.x + ((_local4.col1.x * m_localPosition.x) + (_local4.col2.x * m_localPosition.y))); _local6 = (_arg2.position.y + ((_local4.col1.y * m_localPosition.x) + (_local4.col2.y * m_localPosition.y))); _local4 = _arg3.R; _local7 = (_arg3.position.x + ((_local4.col1.x * m_localPosition.x) + (_local4.col2.x * m_localPosition.y))); _local8 = (_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)); } public function GetRadius():Number{ return (m_radius); } override public function UpdateSweepRadius(_arg1:b2Vec2):void{ var _local2:Number; var _local3:Number; _local2 = (m_localPosition.x - _arg1.x); _local3 = (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; var _local4:Number; var _local5:Number; _local3 = _arg2.R; _local4 = (_arg2.position.x + ((_local3.col1.x * m_localPosition.x) + (_local3.col2.x * m_localPosition.y))); _local5 = (_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)); } } }//package Box2D.Collision.Shapes
Section 3
//b2FilterData (Box2D.Collision.Shapes.b2FilterData) package Box2D.Collision.Shapes { import Box2D.Common.Math.*; public class b2FilterData { public var maskBits:uint;// = 0xFFFF public var groupIndex:int;// = 0 public var categoryBits:uint;// = 1 public function b2FilterData(){ categoryBits = 1; maskBits = 0xFFFF; groupIndex = 0; super(); } public function Copy():b2FilterData{ var _local1:b2FilterData; _local1 = 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(){ mass = 0; center = new b2Vec2(0, 0); I = 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 vertexCount:int; public var vertices:Array; private static var s_mat:b2Mat22 = new b2Mat22(); public function b2PolygonDef(){ var _local1:int; vertices = new Array(b2Settings.b2_maxPolygonVertices); super(); type = b2Shape.e_polygonShape; vertexCount = 0; _local1 = 0; 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.Common.Math.*; import Box2D.Dynamics.*; import Box2D.Collision.*; import Box2D.Common.*; public class b2PolygonShape extends b2Shape { public var m_vertices:Array; public var m_normals:Array; private var s_supportVec:b2Vec2; public var m_obb:b2OBB; public var m_coreVertices:Array; public var m_centroid:b2Vec2; 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 _local2:b2PolygonDef; var _local3:int; var _local4:int; var _local5: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; _local2 = (_arg1 as b2PolygonDef); m_vertexCount = _local2.vertexCount; _local4 = _local3; _local5 = _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 TestPoint(_arg1:b2XForm, _arg2:b2Vec2):Boolean{ var _local3:b2Vec2; var _local4:b2Mat22; var _local5:Number; var _local6:Number; var _local7:Number; var _local8:Number; var _local9:int; var _local10:Number; _local4 = _arg1.R; _local5 = (_arg2.x - _arg1.position.x); _local6 = (_arg2.y - _arg1.position.y); _local7 = ((_local5 * _local4.col1.x) + (_local6 * _local4.col1.y)); _local8 = ((_local5 * _local4.col2.x) + (_local6 * _local4.col2.y)); _local9 = 0; 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 function GetCoreVertices():Array{ return (m_coreVertices); } override public function TestSegment(_arg1:b2XForm, _arg2:Array, _arg3:b2Vec2, _arg4:b2Segment, _arg5:Number):Boolean{ 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 _local14:Number; var _local15:Number; var _local16:Number; var _local17:Number; var _local18:int; var _local19:int; var _local20:Number; var _local21:Number; _local6 = 0; _local7 = _arg5; _local8 = (_arg4.p1.x - _arg1.position.x); _local9 = (_arg4.p1.y - _arg1.position.y); _local10 = _arg1.R; _local12 = ((_local8 * _local10.col1.x) + (_local9 * _local10.col1.y)); _local13 = ((_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; _local14 = ((_local8 * _local10.col1.x) + (_local9 * _local10.col1.y)); _local15 = ((_local8 * _local10.col2.x) + (_local9 * _local10.col2.y)); _local16 = (_local14 - _local12); _local17 = (_local15 - _local13); _local18 = -1; _local19 = 0; 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); } public function GetCentroid():b2Vec2{ return (m_centroid); } override public function ComputeMass(_arg1:b2MassData):void{ var _local2:Number; var _local3:Number; var _local4:Number; var _local5:Number; var _local6:Number; var _local7:Number; var _local8:Number; var _local9:int; 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; _local2 = 0; _local3 = 0; _local4 = 0; _local5 = 0; _local6 = 0; _local7 = 0; _local8 = (1 / 3); _local9 = 0; 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 Support(_arg1:b2XForm, _arg2:Number, _arg3:Number):b2Vec2{ var _local4:b2Vec2; var _local5:b2Mat22; var _local6:Number; var _local7:Number; var _local8:int; var _local9:Number; var _local10:int; var _local11:Number; _local5 = _arg1.R; _local6 = ((_arg2 * _local5.col1.x) + (_arg3 * _local5.col1.y)); _local7 = ((_arg2 * _local5.col2.x) + (_arg3 * _local5.col2.y)); _local8 = 0; _local4 = m_coreVertices[0]; _local9 = ((_local4.x * _local6) + (_local4.y * _local7)); _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 ComputeSweptAABB(_arg1:b2AABB, _arg2:b2XForm, _arg3:b2XForm):void{ var _local4:b2AABB; var _local5:b2AABB; _local4 = s_sweptAABB1; _local5 = 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 GetNormals():Array{ return (m_normals); } 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 UpdateSweepRadius(_arg1:b2Vec2):void{ var _local2:b2Vec2; var _local3:int; var _local4:Number; var _local5:Number; m_sweepRadius = 0; _local3 = 0; 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 ComputeAABB(_arg1:b2AABB, _arg2:b2XForm):void{ var _local3:b2Mat22; var _local4:b2Vec2; var _local5:b2Mat22; var _local6:b2Mat22; var _local7:Number; var _local8:Number; var _local9:Number; var _local10:Number; _local5 = 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(); _local6 = _local5; _local4 = m_obb.extents; _local7 = ((_local6.col1.x * _local4.x) + (_local6.col2.x * _local4.y)); _local8 = ((_local6.col1.y * _local4.x) + (_local6.col2.y * _local4.y)); _local3 = _arg2.R; _local4 = m_obb.center; _local9 = (_arg2.position.x + ((_local3.col1.x * _local4.x) + (_local3.col2.x * _local4.y))); _local10 = (_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)); } public static function ComputeCentroid(_arg1:Array, _arg2:int):b2Vec2{ var _local3:b2Vec2; var _local4:Number; var _local5:Number; var _local6:Number; var _local7:Number; var _local8:int; 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(); _local4 = 0; _local5 = 0; _local6 = 0; _local7 = (1 / 3); _local8 = 0; 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 _local5:Array; var _local6:Number; 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; _local5 = new Array((b2Settings.b2_maxPolygonVertices + 1)); _local4 = 0; while (_local4 < _arg3) { _local5[_local4] = _arg2[_local4]; _local4++; }; _local5[_arg3] = _local5[0]; _local6 = 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.Common.Math.*; import Box2D.Dynamics.*; import Box2D.Collision.*; import Box2D.Common.*; public class 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_next:b2Shape; public var m_restitution:Number; public var m_userData; public var m_isSensor:Boolean; 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 TestPoint(_arg1:b2XForm, _arg2:b2Vec2):Boolean{ return (false); } 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{ var _local3:b2AABB; var _local4:Boolean; if (m_proxyId == b2Pair.b2_nullProxy){ return; }; _arg1.DestroyProxy(m_proxyId); _local3 = s_resetAABB; ComputeAABB(_local3, _arg2); _local4 = _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{ var _local4:b2AABB; if (m_proxyId == b2Pair.b2_nullProxy){ return (false); }; _local4 = 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; var _local4:Boolean; _local3 = s_proxyAABB; ComputeAABB(_local3, _arg2); _local4 = _arg1.InRange(_local3); if (_local4){ m_proxyId = _arg1.CreateProxy(_local3, this); } else { m_proxyId = b2Pair.b2_nullProxy; }; } public function SetUserData(_arg1):void{ m_userData = _arg1; } 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 { import Box2D.Common.Math.*; import Box2D.Common.*; public class b2ShapeDef { public var isSensor:Boolean;// = false public var density:Number;// = 0 public var type:int;// = -1 public var restitution:Number;// = 0 public var userData;// = null public var filter:b2FilterData; public var friction:Number;// = 0.2 public function b2ShapeDef(){ type = b2Shape.e_unknownShape; userData = null; friction = 0.2; restitution = 0; density = 0; isSensor = false; 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; var _local2:Number; var _local3:Boolean; _local1 = (upperBound.x - lowerBound.x); _local2 = (upperBound.y - lowerBound.y); _local3 = (((_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 proxyId:uint; public var stabbingCount:uint; public var value:uint; public function Swap(_arg1:b2Bound):void{ var _local2:uint; var _local3:uint; var _local4:uint; _local2 = value; _local3 = proxyId; _local4 = 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_quantizationFactor:b2Vec2; public var m_worldAABB:b2AABB; public var m_bounds:Array; 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 = b2Settings.USHRT_MAX; public static const b2_invalid:uint = b2Settings.USHRT_MAX; public static var s_validate:Boolean = false; public function b2BroadPhase(_arg1:b2AABB, _arg2:b2PairCallback){ var _local3:int; var _local4:Number; 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++; }; _local4 = (_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 _local4:Array; var _local5:Array; var _local6:uint; var _local7:uint; var _local8:Array; var _local9:Array; var _local10:int; var _local11:int; var _local12:b2Proxy; _local4 = new Array(); _local5 = new Array(); ComputeBounds(_local4, _local5, _arg1); _local8 = [_local6]; _local9 = [_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); _local10 = 0; _local11 = 0; 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; _local2 = 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 _local8:uint; var _local9:uint; var _local10:b2Bound; var _local11:uint; var _local12:int; var _local13:int; var _local14:b2Proxy; _local8 = BinarySearch(_arg5, _arg6, _arg3); _local9 = BinarySearch(_arg5, _arg6, _arg4); _local11 = _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 _local3:int; var _local4:Array; var _local5:b2Bound; var _local6:b2Bound; _local3 = 0; 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; var _local5:Number; var _local6:Number; var _local7:Number; _local4 = _arg3.lowerBound.x; _local5 = _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); _local6 = _arg3.upperBound.x; _local7 = _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 _local5:uint; var _local6:uint; var _local7:Array; var _local8:Array; var _local9:int; var _local10:int; 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; _local5 = m_freeProxy; _local4 = m_proxyPool[_local5]; m_freeProxy = _local4.GetNext(); _local4.overlapCount = 0; _local4.userData = _arg2; _local6 = (2 * m_proxyCount); _local7 = new Array(); _local8 = new Array(); ComputeBounds(_local7, _local8, _arg1); _local9 = 0; 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++; _local10 = 0; 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 _local4:b2Proxy; var _local5:int; var _local6:int; var _local7:int; 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; _local4 = m_proxyPool[_arg1]; _local5 = (2 * m_proxyCount); _local6 = 0; 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++; }; _local7 = 0; 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 _local3:int; var _local4:Array; var _local5:b2Bound; _local3 = 0; 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 _local5:int; var _local6:b2Bound; var _local7:uint; var _local8:uint; var _local9:uint; var _local10:b2Bound; _local5 = 0; 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; _local2 = 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 _local12:uint; var _local13:b2Proxy; var _local14:b2BoundValues; var _local15:b2BoundValues; 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; }; _local12 = (2 * m_proxyCount); _local13 = m_proxyPool[_arg1]; _local14 = new b2BoundValues(); ComputeBounds(_local14.lowerValues, _local14.upperValues, _arg2); _local15 = 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 _local4:int; var _local5:int; var _local6:int; var _local7:b2Bound; _local4 = 0; _local5 = (_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 _local6:int; var _local7:Array; var _local8:Array; var _local9:int; var _local10:Array; var _local11:b2Mat22; var _local12:b2Vec2; var _local13:Number; var _local14:Number; var _local15:Number; var _local16:Number; var _local17:int; var _local18:Number; var _local19:int; var _local20:Number; var _local21:Number; var _local22:Number; var _local23:Number; var _local24:Number; var _local25:Number; _local6 = _arg1.m_vertexCount; _local7 = _arg1.m_vertices; _local8 = _arg1.m_normals; _local9 = _arg4.m_vertexCount; _local10 = _arg4.m_vertices; _local11 = _arg2.R; _local12 = _local8[_arg3]; _local13 = ((_local11.col1.x * _local12.x) + (_local11.col2.x * _local12.y)); _local14 = ((_local11.col1.y * _local12.x) + (_local11.col2.y * _local12.y)); _local11 = _arg5.R; _local15 = ((_local11.col1.x * _local13) + (_local11.col1.y * _local14)); _local16 = ((_local11.col2.x * _local13) + (_local11.col2.y * _local14)); _local17 = 0; _local18 = Number.MAX_VALUE; _local19 = 0; 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; _local20 = (_arg2.position.x + ((_local11.col1.x * _local12.x) + (_local11.col2.x * _local12.y))); _local21 = (_arg2.position.y + ((_local11.col1.y * _local12.x) + (_local11.col2.y * _local12.y))); _local12 = _local10[_local17]; _local11 = _arg5.R; _local22 = (_arg5.position.x + ((_local11.col1.x * _local12.x) + (_local11.col2.x * _local12.y))); _local23 = (_arg5.position.y + ((_local11.col1.y * _local12.x) + (_local11.col2.y * _local12.y))); _local22 = (_local22 - _local20); _local23 = (_local23 - _local21); _local24 = ((_local22 * _local13) + (_local23 * _local14)); return (_local24); } public static function b2TestOverlap(_arg1:b2AABB, _arg2:b2AABB):Boolean{ var _local3:b2Vec2; var _local4:b2Vec2; var _local5:Number; var _local6:Number; var _local7:Number; var _local8:Number; _local3 = _arg2.lowerBound; _local4 = _arg1.upperBound; _local5 = (_local3.x - _local4.x); _local6 = (_local3.y - _local4.y); _local3 = _arg1.lowerBound; _local4 = _arg2.upperBound; _local7 = (_local3.x - _local4.x); _local8 = (_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 _local7:int; var _local8:Array; var _local9:int; var _local10:Array; var _local11:Array; var _local12:b2Mat22; var _local13:b2Vec2; var _local14:Number; var _local15:Number; var _local16:Number; var _local17:int; var _local18:Number; var _local19:int; var _local20:ClipVertex; var _local21:int; var _local22:int; var _local23:Number; _local7 = _arg2.m_vertexCount; _local8 = _arg2.m_normals; _local9 = _arg5.m_vertexCount; _local10 = _arg5.m_vertices; _local11 = _arg5.m_normals; _local12 = _arg3.R; _local13 = _local8[_arg4]; _local14 = ((_local12.col1.x * _local13.x) + (_local12.col2.x * _local13.y)); _local15 = ((_local12.col1.y * _local13.x) + (_local12.col2.y * _local13.y)); _local12 = _arg6.R; _local16 = ((_local12.col1.x * _local14) + (_local12.col1.y * _local15)); _local15 = ((_local12.col2.x * _local14) + (_local12.col2.y * _local15)); _local14 = _local16; _local17 = 0; _local18 = Number.MAX_VALUE; _local19 = 0; while (_local19 < _local9) { _local13 = _local11[_local19]; _local23 = ((_local14 * _local13.x) + (_local15 * _local13.y)); if (_local23 < _local18){ _local18 = _local23; _local17 = _local19; }; _local19++; }; _local21 = _local17; _local22 = (((_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 _local7:int; var _local8:Array; var _local9:Number; var _local10:int; var _local11:Array; var _local12:Number; var _local13:b2PolygonShape; var _local14:b2PolygonShape; var _local15:b2XForm; var _local16:b2XForm; var _local17:int; var _local18:uint; var _local19:Number; var _local20:Number; var _local21:Array; var _local22:int; var _local23:Array; var _local24:b2Vec2; var _local25:b2Vec2; var _local26:b2Vec2; var _local27:b2Vec2; var _local28:b2Vec2; var _local29:Number; var _local30:Number; var _local31:Number; var _local32:Array; var _local33:Array; var _local34:int; var _local35:int; var _local36:int; var _local37:b2Vec2; var _local38:Number; var _local39:b2ManifoldPoint; _arg1.pointCount = 0; _local7 = 0; _local8 = [_local7]; _local9 = FindMaxSeparation(_local8, _arg2, _arg3, _arg4, _arg5); _local7 = _local8[0]; if (_local9 > 0){ return; }; _local10 = 0; _local11 = [_local10]; _local12 = FindMaxSeparation(_local11, _arg4, _arg5, _arg2, _arg3); _local10 = _local11[0]; if (_local12 > 0){ return; }; _local15 = new b2XForm(); _local16 = new b2XForm(); _local19 = 0.98; _local20 = 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; }; _local21 = [new ClipVertex(), new ClipVertex()]; FindIncidentEdge(_local21, _local13, _local15, _local17, _local14, _local16); _local22 = _local13.m_vertexCount; _local23 = _local13.m_vertices; _local24 = _local23[_local17]; _local25 = _local24.Copy(); if ((_local17 + 1) < _local22){ _local24 = _local23[int((_local17 + 1))]; _local37 = _local24.Copy(); } else { _local24 = _local23[0]; _local37 = _local24.Copy(); }; _local26 = b2Math.SubtractVV(_local37, _local25); _local27 = b2Math.b2MulMV(_local15.R, b2Math.SubtractVV(_local37, _local25)); _local27.Normalize(); _local28 = b2Math.b2CrossVF(_local27, 1); _local25 = b2Math.b2MulX(_local15, _local25); _local37 = b2Math.b2MulX(_local15, _local37); _local29 = b2Math.b2Dot(_local28, _local25); _local30 = -(b2Math.b2Dot(_local27, _local25)); _local31 = b2Math.b2Dot(_local27, _local37); _local32 = [new ClipVertex(), new ClipVertex()]; _local33 = [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(); _local35 = 0; _local36 = 0; 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 _local6:int; var _local7:Array; var _local8:b2Vec2; var _local9:b2Mat22; var _local10:Number; var _local11:Number; var _local12:Number; var _local13:Number; var _local14:int; var _local15:Number; var _local16:int; var _local17:Number; var _local18:int; var _local19:Number; var _local20:int; var _local21:Number; var _local22:int; var _local23:Number; var _local24:int; var _local25:Number; _local6 = _arg2.m_vertexCount; _local7 = _arg2.m_normals; _local9 = _arg5.R; _local8 = _arg4.m_centroid; _local10 = (_arg5.position.x + ((_local9.col1.x * _local8.x) + (_local9.col2.x * _local8.y))); _local11 = (_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)))); _local12 = ((_local10 * _arg3.R.col1.x) + (_local11 * _arg3.R.col1.y)); _local13 = ((_local10 * _arg3.R.col2.x) + (_local11 * _arg3.R.col2.y)); _local14 = 0; _local15 = -(Number.MAX_VALUE); _local16 = 0; while (_local16 < _local6) { _local8 = _local7[_local16]; _local25 = ((_local8.x * _local12) + (_local8.y * _local13)); if (_local25 > _local15){ _local15 = _local25; _local14 = _local16; }; _local16++; }; _local17 = EdgeSeparation(_arg2, _arg3, _local14, _arg4, _arg5); if (_local17 > 0){ return (_local17); }; _local18 = (((_local14 - 1) >= 0)) ? (_local14 - 1) : (_local6 - 1); _local19 = EdgeSeparation(_arg2, _arg3, _local18, _arg4, _arg5); if (_local19 > 0){ return (_local19); }; _local20 = (((_local14 + 1) < _local6)) ? (_local14 + 1) : 0; _local21 = 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 _local10: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); _local10 = (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 _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:b2ManifoldPoint; var _local20:Number; var _local21:Number; var _local22:Number; var _local23:Number; var _local24:Number; var _local25:Number; _arg1.pointCount = 0; _local6 = _arg3.R; _local7 = _arg2.m_localPosition; _local8 = (_arg3.position.x + ((_local6.col1.x * _local7.x) + (_local6.col2.x * _local7.y))); _local9 = (_arg3.position.y + ((_local6.col1.y * _local7.x) + (_local6.col2.y * _local7.y))); _local6 = _arg5.R; _local7 = _arg4.m_localPosition; _local10 = (_arg5.position.x + ((_local6.col1.x * _local7.x) + (_local6.col2.x * _local7.y))); _local11 = (_arg5.position.y + ((_local6.col1.y * _local7.x) + (_local6.col2.y * _local7.y))); _local12 = (_local10 - _local8); _local13 = (_local11 - _local9); _local14 = ((_local12 * _local12) + (_local13 * _local13)); _local15 = _arg2.m_radius; _local16 = _arg4.m_radius; _local17 = (_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; _local19 = _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)); _local20 = (0.5 * (_local8 + _local10)); _local21 = (0.5 * (_local9 + _local11)); _local22 = (_local20 - _arg3.position.x); _local23 = (_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 _local13:Number; var _local14:Number; var _local15:Number; var _local16:Number; var _local17:Number; var _local18:int; var _local19:Number; var _local20:Number; var _local21:int; var _local22:Array; var _local23:Array; var _local24:int; var _local25:int; var _local26:int; var _local27:b2Vec2; var _local28:Number; var _local29:Number; var _local30:Number; var _local31:Number; var _local32:Number; var _local33:Number; var _local34:Number; _arg1.pointCount = 0; _local12 = _arg5.R; _local11 = _arg4.m_localPosition; _local13 = (_arg5.position.x + ((_local12.col1.x * _local11.x) + (_local12.col2.x * _local11.y))); _local14 = (_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; _local15 = ((_local7 * _local12.col1.x) + (_local8 * _local12.col1.y)); _local16 = ((_local7 * _local12.col2.x) + (_local8 * _local12.col2.y)); _local18 = 0; _local19 = -(Number.MAX_VALUE); _local20 = _arg4.m_radius; _local21 = _arg2.m_vertexCount; _local22 = _arg2.m_vertices; _local23 = _arg2.m_normals; _local24 = 0; 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; }; _local25 = _local18; _local26 = (((_local25 + 1) < _local21)) ? (_local25 + 1) : 0; _local11 = _local22[_local25]; _local27 = _local22[_local26]; _local28 = (_local27.x - _local11.x); _local29 = (_local27.y - _local11.y); _local30 = Math.sqrt(((_local28 * _local28) + (_local29 * _local29))); _local28 = (_local28 / _local30); _local29 = (_local29 / _local30); _local7 = (_local15 - _local11.x); _local8 = (_local16 - _local11.y); _local31 = ((_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; _local1 = new b2ContactID(); _local1.key = key; return (_local1); } public function get key():uint{ return (_key); } 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); } } }//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 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 friction:Number; 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 _local4:Number; var _local5:int; var _local6:b2Vec2; var _local7:Number; var _local8:Number; var _local9:Number; var _local10:Number; _local4 = (100 * Number.MIN_VALUE); _local5 = 0; 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 _local8:Array; var _local9:Array; var _local10:Array; var _local11:int; var _local12:Number; var _local13:int; var _local14:int; 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; _local8 = s_p1s; _local9 = s_p2s; _local10 = s_points; _local11 = 0; _arg1.SetV(_arg3.GetFirstVertex(_arg4)); _arg2.SetV(_arg5.GetFirstVertex(_arg6)); _local12 = 0; _local13 = 20; _local14 = 0; 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 _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; _local7 = _arg4.R; _local8 = _arg3.m_localPosition; _local9 = (_arg4.position.x + ((_local7.col1.x * _local8.x) + (_local7.col2.x * _local8.y))); _local10 = (_arg4.position.y + ((_local7.col1.y * _local8.x) + (_local7.col2.y * _local8.y))); _local7 = _arg6.R; _local8 = _arg5.m_localPosition; _local11 = (_arg6.position.x + ((_local7.col1.x * _local8.x) + (_local7.col2.x * _local8.y))); _local12 = (_arg6.position.y + ((_local7.col1.y * _local8.x) + (_local7.col2.y * _local8.y))); _local13 = (_local11 - _local9); _local14 = (_local12 - _local10); _local15 = ((_local13 * _local13) + (_local14 * _local14)); _local16 = (_arg3.m_radius - b2Settings.b2_toiSlop); _local17 = (_arg5.m_radius - b2Settings.b2_toiSlop); _local18 = (_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 _local14:b2Vec2; 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 _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 _local39:Number; var _local40:Number; var _local41: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]; _local14 = _arg4[2]; _local15 = _local6.x; _local16 = _local6.y; _local17 = _local7.x; _local18 = _local7.y; _local19 = _local8.x; _local20 = _local8.y; _local21 = (_local17 - _local15); _local22 = (_local18 - _local16); _local23 = (_local19 - _local15); _local24 = (_local20 - _local16); _local25 = (_local19 - _local17); _local26 = (_local20 - _local18); _local27 = -(((_local15 * _local21) + (_local16 * _local22))); _local28 = ((_local17 * _local21) + (_local18 * _local22)); _local29 = -(((_local15 * _local23) + (_local16 * _local24))); _local30 = ((_local19 * _local23) + (_local20 * _local24)); _local31 = -(((_local17 * _local25) + (_local18 * _local26))); _local32 = ((_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); }; _local33 = ((_local21 * _local24) - (_local22 * _local23)); _local34 = (_local33 * ((_local15 * _local18) - (_local16 * _local17))); _local36 = (_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); }; _local37 = (_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); }; _local38 = ((_local36 + _local37) + _local34); _local38 = (1 / _local38); _local39 = (_local36 * _local38); _local40 = (_local37 * _local38); _local41 = ((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 _local9:b2Point; var _local10:Number; var _local11:Number; var _local12:Number; var _local13:Number; var _local14:Number; _local9 = 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))); _local10 = DistanceGeneric(_arg1, _arg2, _arg3, _arg4, _local9, b2Math.b2XForm_identity); _local11 = (_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; var _local8:int; _local7 = _arg3.m_type; _local8 = _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 _local6:b2Vec2; var _local7:b2Vec2; var _local8:b2Vec2; var _local9:b2Vec2; var _local10:b2Vec2; var _local11:b2Vec2; var _local12:Number; var _local13:Number; var _local14:Number; var _local15:Number; var _local16:Number; var _local17:Number; _local6 = _arg5[0]; _local7 = _arg5[1]; _local8 = _arg3[0]; _local9 = _arg3[1]; _local10 = _arg4[0]; _local11 = _arg4[1]; _local12 = -(_local7.x); _local13 = -(_local7.y); _local14 = (_local6.x - _local7.x); _local15 = (_local6.y - _local7.y); _local16 = 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 points:Array; public var pointCount:int;// = 0 public var normal:b2Vec2; public function b2Manifold(){ var _local1:int; pointCount = 0; super(); points = new Array(b2Settings.b2_maxManifoldPoints); _local1 = 0; while (_local1 < b2Settings.b2_maxManifoldPoints) { points[_local1] = new b2ManifoldPoint(); _local1++; }; normal = new b2Vec2(); } public function Set(_arg1:b2Manifold):void{ var _local2:int; pointCount = _arg1.pointCount; _local2 = 0; 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; _local1 = 0; 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 { import Box2D.Common.*; public class b2Pair { public var userData;// = null public var proxyId1:uint; 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 = b2Settings.USHRT_MAX; public static var e_pairBuffered:uint = 1; public static var b2_nullProxy:uint = b2Settings.USHRT_MAX; public static var b2_tableCapacity:int = b2Settings.b2_maxPairs; public function b2Pair(){ userData = null; super(); } 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_callback:b2PairCallback; public var m_pairs:Array; public var m_pairBufferCount:int; public var m_hashTable:Array; 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; _local5 = 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 _local3:uint; var _local4:uint; if (_arg1 > _arg2){ _local4 = _arg1; _arg1 = _arg2; _arg2 = _local4; }; _local3 = (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 _local3:int; var _local4:Array; var _local5:b2Pair; var _local6:b2Proxy; var _local7:b2Proxy; _local3 = 0; _local4 = 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; _local4 = 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 _local4:uint; var _local5:uint; var _local6:b2Pair; var _local7:uint; var _local8:uint; var _local9:*; if (_arg1 > _arg2){ _local7 = _arg1; _arg1 = _arg2; _arg2 = _local7; }; _local4 = (Hash(_arg1, _arg2) & b2Pair.b2_tableMask); _local5 = m_hashTable[_local4]; _local6 = null; 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; _local4 = 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 _local3:uint; var _local4:b2Pair; var _local5:uint; var _local6:uint; if (_arg1 > _arg2){ _local6 = _arg1; _arg1 = _arg2; _arg2 = _local6; }; _local3 = (Hash(_arg1, _arg2) & b2Pair.b2_tableMask); _local4 = FindHash(_arg1, _arg2, _local3); if (_local4 != null){ return (_local4); }; _local5 = 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; _local3 = (((_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 lowerBounds:Array; public var upperBounds:Array; public var userData;// = null public var timeStamp:uint; public function b2Proxy(){ lowerBounds = [uint(0), uint(0)]; upperBounds = [uint(0), uint(0)]; userData = null; 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 _local5:b2Vec2; 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; var _local18:Number; _local5 = _arg3.p1; _local6 = (_arg3.p2.x - _local5.x); _local7 = (_arg3.p2.y - _local5.y); _local8 = (p2.x - p1.x); _local9 = (p2.y - p1.y); _local10 = _local9; _local11 = -(_local8); _local12 = (100 * Number.MIN_VALUE); _local13 = -(((_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 _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:b2Vec2; var _local18:b2Vec2; var _local19:int; var _local20:int; var _local21:Number; var _local22:Number; var _local23:Number; var _local24:Number; var _local25:Number; var _local26:b2XForm; var _local27:b2XForm; var _local28:Number; var _local29:Number; var _local30:Number; var _local31:Number; _local7 = _arg1.m_sweepRadius; _local8 = _arg3.m_sweepRadius; _local9 = _arg2.t0; _local10 = (_arg2.c.x - _arg2.c0.x); _local11 = (_arg2.c.y - _arg2.c0.y); _local12 = (_arg4.c.x - _arg4.c0.x); _local13 = (_arg4.c.y - _arg4.c0.y); _local14 = (_arg2.a - _arg2.a0); _local15 = (_arg4.a - _arg4.a0); _local16 = 0; _local17 = s_p1; _local18 = s_p2; _local19 = 20; _local20 = 0; _local21 = 0; _local22 = 0; _local23 = 0; _local24 = 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 v:b2Vec2; public var id:b2ContactID; 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 set flip(_arg1:int):void{ _flip = _arg1; _m_id._key = ((_m_id._key & 0xFFFFFF) | ((_flip << 24) & 4278190080)); } public function get incidentVertex():int{ return (_incidentVertex); } 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 { import Box2D.Common.*; 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 Set(_arg1:Number):void{ var _local2:Number; var _local3:Number; _local2 = Math.cos(_arg1); _local3 = Math.sin(_arg1); col1.x = _local2; col2.x = -(_local3); col1.y = _local3; col2.y = _local2; } public function SetVV(_arg1:b2Vec2, _arg2:b2Vec2):void{ col1.SetV(_arg1); col2.SetV(_arg2); } 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 _local3:Number; var _local4:Number; var _local5:Number; var _local6:Number; _local2 = col1.x; _local3 = col2.x; _local4 = col1.y; _local5 = 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; var _local5:Number; var _local6:Number; var _local7:Number; var _local8:Number; _local4 = col1.x; _local5 = col2.x; _local6 = col1.y; _local7 = col2.y; _local8 = ((_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; _local3 = new b2Vec2((_arg2 * _arg1.y), (-(_arg2) * _arg1.x)); return (_local3); } public static function AddVV(_arg1:b2Vec2, _arg2:b2Vec2):b2Vec2{ var _local3:b2Vec2; _local3 = 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; _local3 = 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; var _local4:Number; _local3 = (_arg1.x - _arg2.x); _local4 = (_arg1.y - _arg2.y); return (((_local3 * _local3) + (_local4 * _local4))); } public static function b2Swap(_arg1:Array, _arg2:Array):void{ var _local3:*; _local3 = _arg1[0]; _arg1[0] = _arg2[0]; _arg2[0] = _local3; } public static function b2AbsM(_arg1:b2Mat22):b2Mat22{ var _local2:b2Mat22; _local2 = new b2Mat22(0, b2AbsV(_arg1.col1), b2AbsV(_arg1.col2)); return (_local2); } public static function SubtractVV(_arg1:b2Vec2, _arg2:b2Vec2):b2Vec2{ var _local3:b2Vec2; _local3 = 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; _local2 = new b2Vec2(b2Abs(_arg1.x), b2Abs(_arg1.y)); return (_local2); } public static function MulFV(_arg1:Number, _arg2:b2Vec2):b2Vec2{ var _local3:b2Vec2; _local3 = 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; _local3 = new b2Vec2((-(_arg1) * _arg2.y), (_arg1 * _arg2.x)); return (_local3); } public static function AddMM(_arg1:b2Mat22, _arg2:b2Mat22):b2Mat22{ var _local3:b2Mat22; _local3 = 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; var _local4:Number; _local3 = (_arg1.x - _arg2.x); _local4 = (_arg1.y - _arg2.y); return (Math.sqrt(((_local3 * _local3) + (_local4 * _local4)))); } public static function b2MulTMM(_arg1:b2Mat22, _arg2:b2Mat22):b2Mat22{ var _local3:b2Vec2; var _local4:b2Vec2; var _local5:b2Mat22; _local3 = new b2Vec2(b2Dot(_arg1.col1, _arg2.col1), b2Dot(_arg1.col2, _arg2.col1)); _local4 = new b2Vec2(b2Dot(_arg1.col1, _arg2.col2), b2Dot(_arg1.col2, _arg2.col2)); _local5 = new b2Mat22(0, _local3, _local4); return (_local5); } public static function b2MaxV(_arg1:b2Vec2, _arg2:b2Vec2):b2Vec2{ var _local3:b2Vec2; _local3 = new b2Vec2(b2Max(_arg1.x, _arg2.x), b2Max(_arg1.y, _arg2.y)); return (_local3); } public static function b2IsPowerOfTwo(_arg1:uint):Boolean{ var _local2:Boolean; _local2 = (((_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; _local3 = Math.random(); _local3 = (((_arg2 - _arg1) * _local3) + _arg1); return (_local3); } public static function b2MulTMV(_arg1:b2Mat22, _arg2:b2Vec2):b2Vec2{ var _local3:b2Vec2; _local3 = 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; _local3 = 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; _local3 = 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 { import Box2D.Common.*; public class b2Sweep { public var localCenter:b2Vec2; public var c:b2Vec2; public var a:Number; public var c0:b2Vec2; public var a0:Number; 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 _local3:b2Mat22; 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); }; _local3 = _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 { import Box2D.Common.*; public class b2Vec2 { public var x:Number; public var y:Number; public function b2Vec2(_arg1:Number=0, _arg2:Number=0):void{ x = _arg1; y = _arg2; } 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 SetZero():void{ x = 0; y = 0; } public function Add(_arg1:b2Vec2):void{ x = (x + _arg1.x); y = (y + _arg1.y); } 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 CrossVF(_arg1:Number):void{ var _local2:Number; _local2 = x; x = (_arg1 * y); y = (-(_arg1) * _local2); } public function Abs():void{ if (x < 0){ x = -(x); }; if (y < 0){ y = -(y); }; } public function Copy():b2Vec2{ return (new b2Vec2(x, y)); } public function MulTM(_arg1:b2Mat22):void{ var _local2:Number; _local2 = 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 function MinV(_arg1:b2Vec2):void{ x = ((x < _arg1.x)) ? x : _arg1.x; y = ((y < _arg1.y)) ? y : _arg1.y; } public function MulM(_arg1:b2Mat22):void{ var _local2:Number; _local2 = x; x = ((_arg1.col1.x * _local2) + (_arg1.col2.x * y)); y = ((_arg1.col1.y * _local2) + (_arg1.col2.y * y)); } public function Normalize():Number{ var _local1:Number; var _local2:Number; _local1 = Math.sqrt(((x * x) + (y * y))); if (_local1 < Number.MIN_VALUE){ return (0); }; _local2 = (1 / _local1); x = (x * _local2); y = (y * _local2); return (_local1); } public function Subtract(_arg1:b2Vec2):void{ x = (x - _arg1.x); y = (y - _arg1.y); } public function CrossFV(_arg1:Number):void{ var _local2:Number; _local2 = x; x = (-(_arg1) * y); y = (_arg1 * _local2); } 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 { import Box2D.Common.*; public class b2XForm { public var R:b2Mat22; public var position:b2Vec2; 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 _g:uint;// = 0 private var _b:uint;// = 0 private var _r:uint;// = 0 public function b2Color(_arg1:Number, _arg2:Number, _arg3:Number){ _r = 0; _g = 0; _b = 0; super(); _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 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 b(_arg1:Number):void{ _b = 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.244346095279206; public static const b2_linearSlop:Number = 0.1; public static const b2_pi:Number = 3.14159265358979; public static const b2_maxProxies:int = 0x0200; public static const b2_maxAngularVelocitySquared:Number = 22500; public static const b2_maxPolygonVertices:int = 8; public static const b2_velocityThreshold:Number = 1; public static const b2_contactBaumgarte:Number = 0.001; 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 = 150; public static const b2_maxAngularCorrection:Number = 0.314159265358979; public static const USHRT_MAX:int = 0xFFFF; public static const b2_maxLinearVelocity:Number = 150; public static const b2_maxLinearCorrection:Number = 2; public static const b2_toiSlop:Number = 0.8; public static const b2_maxLinearVelocitySquared:Number = 22500; 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.Common.Math.*; import Box2D.Dynamics.*; import Box2D.Collision.Shapes.*; import Box2D.Collision.*; import Box2D.Common.*; public class b2CircleContact 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 b2CircleContact(_arg1:b2Shape, _arg2:b2Shape){ var _local3:b2ManifoldPoint; m_manifolds = [new b2Manifold()]; m0 = new b2Manifold(); super(_arg1, _arg2); m_manifold = m_manifolds[0]; m_manifold.pointCount = 0; _local3 = m_manifold.points[0]; _local3.normalImpulse = 0; _local3.tangentImpulse = 0; } override public function GetManifolds():Array{ return (m_manifolds); } override public function Evaluate(_arg1:b2ContactListener):void{ var _local2:b2Vec2; var _local3:b2Vec2; var _local4:b2ManifoldPoint; var _local5:b2Body; var _local6:b2Body; var _local7:b2ContactPoint; var _local8:b2ManifoldPoint; _local5 = m_shape1.m_body; _local6 = 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); _local7 = 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); }; }; } 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.Common.Math.*; import Box2D.Dynamics.*; import Box2D.Collision.Shapes.*; import Box2D.Collision.*; 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 GetShape1():b2Shape{ return (m_shape1); } public function IsSolid():Boolean{ return (((m_flags & e_nonSolidFlag) == 0)); } public function GetNext():b2Contact{ return (m_next); } public function GetManifolds():Array{ return (null); } public function GetShape2():b2Shape{ return (m_shape2); } public function GetManifoldCount():int{ return (m_manifoldCount); } public function Update(_arg1:b2ContactListener):void{ var _local2:int; var _local3:int; var _local4:b2Body; var _local5:b2Body; _local2 = m_manifoldCount; Evaluate(_arg1); _local3 = m_manifoldCount; _local4 = m_shape1.m_body; _local5 = 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 _local1:int; var _local2:int; s_registers = new Array(b2Shape.e_shapeTypeCount); _local1 = 0; 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{ var _local3:int; var _local4:int; var _local5:b2ContactRegister; var _local6:Function; if (_arg1.m_manifoldCount > 0){ _arg1.m_shape1.m_body.WakeUp(); _arg1.m_shape2.m_body.WakeUp(); }; _local3 = _arg1.m_shape1.m_type; _local4 = _arg1.m_shape2.m_type; _local5 = s_registers[_local3][_local4]; _local6 = _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 _local4:int; var _local5:int; var _local6:b2ContactRegister; var _local7:Function; var _local8:b2Contact; var _local9:int; var _local10:b2Manifold; if (s_initialized == false){ InitializeRegisters(); s_initialized = true; }; _local4 = _arg1.m_type; _local5 = _arg2.m_type; _local6 = s_registers[_local4][_local5]; _local7 = _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.Common.Math.*; import Box2D.Dynamics.*; import Box2D.Collision.*; import Box2D.Common.*; public class b2ContactConstraint { public var points:Array; public var restitution:Number; public var body1:b2Body; public var manifold:b2Manifold; public var normal:b2Vec2; public var body2:b2Body; public var friction:Number; public var pointCount:int; public function b2ContactConstraint(){ var _local1:int; normal = new b2Vec2(); super(); points = new Array(b2Settings.b2_maxManifoldPoints); _local1 = 0; 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 equalizedMass:Number; public var tangentMass: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 next:b2ContactEdge; public var other:b2Body; public var contact:b2Contact; public var prev: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.Shapes.*; import Box2D.Collision.*; public class b2ContactResult { public var normal:b2Vec2; public var position:b2Vec2; public var shape1:b2Shape; public var shape2:b2Shape; public var normalImpulse:Number; 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.Common.Math.*; import Box2D.Dynamics.*; 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 _local9:int; 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++; }; _local9 = 0; _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 _local5:int; 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; _local5 = 0; 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 _local2:Number; var _local3:b2Mat22; var _local4:b2Vec2; var _local5:int; 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; _local2 = 0; _local5 = 0; 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 _local19:int; 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; _local19 = 0; 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 _local1:int; var _local2:b2ContactConstraint; var _local3:b2Manifold; var _local4:int; var _local5:b2ManifoldPoint; var _local6:b2ContactConstraintPoint; _local1 = 0; 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 GetManifolds():Array{ return (null); } override public function Evaluate(_arg1:b2ContactListener):void{ } } }//package Box2D.Dynamics.Contacts
Section 46
//b2PolyAndCircleContact (Box2D.Dynamics.Contacts.b2PolyAndCircleContact) package Box2D.Dynamics.Contacts { import Box2D.Common.Math.*; import Box2D.Dynamics.*; import Box2D.Collision.Shapes.*; import Box2D.Collision.*; import Box2D.Common.*; public class b2PolyAndCircleContact 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 b2PolyAndCircleContact(_arg1:b2Shape, _arg2:b2Shape){ var _local3:b2ManifoldPoint; 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; _local3 = m_manifold.points[0]; _local3.normalImpulse = 0; _local3.tangentImpulse = 0; } override public function GetManifolds():Array{ return (m_manifolds); } override public function Evaluate(_arg1:b2ContactListener):void{ var _local2:int; var _local3:b2Vec2; var _local4:b2Vec2; var _local5:b2ManifoldPoint; var _local6:b2Body; var _local7:b2Body; var _local8:Array; var _local9:b2ContactPoint; var _local10:b2ManifoldPoint; var _local11:Boolean; var _local12:uint; var _local13:int; _local6 = m_shape1.m_body; _local7 = 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); _local8 = [false, false]; _local9 = 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++; }; } 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.Common.Math.*; import Box2D.Dynamics.*; import Box2D.Collision.Shapes.*; import Box2D.Collision.*; 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 GetManifolds():Array{ return (m_manifolds); } override public function Evaluate(_arg1:b2ContactListener):void{ var _local2:b2Vec2; var _local3:b2Vec2; var _local4:b2ManifoldPoint; var _local5:b2Body; var _local6:b2Body; var _local7:b2ContactPoint; var _local8:int; var _local9:Array; var _local10:b2ManifoldPoint; var _local11:Boolean; var _local12:uint; var _local13:int; _local5 = m_shape1.m_body; _local6 = 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); _local9 = [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++; }; } 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.Common.Math.*; import Box2D.Dynamics.*; import Box2D.Common.*; public class b2DistanceJoint extends b2Joint { public var m_mass:Number; public var m_u:b2Vec2; public var m_impulse:Number; public var m_dampingRatio:Number; public var m_frequencyHz:Number; public var m_localAnchor2:b2Vec2; public var m_localAnchor1:b2Vec2; public var m_bias:Number; public var m_gamma: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 GetReactionForce():b2Vec2{ var _local1:b2Vec2; _local1 = new b2Vec2(); _local1.SetV(m_u); _local1.Multiply((m_inv_dt * m_impulse)); return (_local1); } override public function SolvePositionConstraints():Boolean{ var _local1:b2Mat22; var _local2:b2Body; var _local3:b2Body; 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; if (m_frequencyHz > 0){ return (true); }; _local2 = m_body1; _local3 = m_body2; _local1 = _local2.m_xf.R; _local4 = (m_localAnchor1.x - _local2.m_sweep.localCenter.x); _local5 = (m_localAnchor1.y - _local2.m_sweep.localCenter.y); _local6 = ((_local1.col1.x * _local4) + (_local1.col2.x * _local5)); _local5 = ((_local1.col1.y * _local4) + (_local1.col2.y * _local5)); _local4 = _local6; _local1 = _local3.m_xf.R; _local7 = (m_localAnchor2.x - _local3.m_sweep.localCenter.x); _local8 = (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; _local9 = (((_local3.m_sweep.c.x + _local7) - _local2.m_sweep.c.x) - _local4); _local10 = (((_local3.m_sweep.c.y + _local8) - _local2.m_sweep.c.y) - _local5); _local11 = Math.sqrt(((_local9 * _local9) + (_local10 * _local10))); _local9 = (_local9 / _local11); _local10 = (_local10 / _local11); _local12 = (_local11 - m_length); _local12 = b2Math.b2Clamp(_local12, -(b2Settings.b2_maxLinearCorrection), b2Settings.b2_maxLinearCorrection); _local13 = (-(m_mass) * _local12); m_u.Set(_local9, _local10); _local14 = (_local13 * m_u.x); _local15 = (_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 InitVelocityConstraints(_arg1:b2TimeStep):void{ var _local2:b2Mat22; var _local3:Number; var _local4:b2Body; var _local5:b2Body; 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; 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); _local7 = (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); _local9 = (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); _local10 = 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(); }; _local11 = ((_local6 * m_u.y) - (_local7 * m_u.x)); _local12 = ((_local8 * m_u.y) - (_local9 * m_u.x)); _local13 = (((_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 SolveVelocityConstraints(_arg1:b2TimeStep):void{ var _local2:b2Mat22; var _local3:b2Body; var _local4:b2Body; 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:Number; _local3 = m_body1; _local4 = m_body2; _local2 = _local3.m_xf.R; _local5 = (m_localAnchor1.x - _local3.m_sweep.localCenter.x); _local6 = (m_localAnchor1.y - _local3.m_sweep.localCenter.y); _local7 = ((_local2.col1.x * _local5) + (_local2.col2.x * _local6)); _local6 = ((_local2.col1.y * _local5) + (_local2.col2.y * _local6)); _local5 = _local7; _local2 = _local4.m_xf.R; _local8 = (m_localAnchor2.x - _local4.m_sweep.localCenter.x); _local9 = (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; _local10 = (_local3.m_linearVelocity.x + (-(_local3.m_angularVelocity) * _local6)); _local11 = (_local3.m_linearVelocity.y + (_local3.m_angularVelocity * _local5)); _local12 = (_local4.m_linearVelocity.x + (-(_local4.m_angularVelocity) * _local9)); _local13 = (_local4.m_linearVelocity.y + (_local4.m_angularVelocity * _local8)); _local14 = ((m_u.x * (_local12 - _local10)) + (m_u.y * (_local13 - _local11))); _local15 = (-(m_mass) * ((_local14 + m_bias) + (m_gamma * m_impulse))); m_impulse = (m_impulse + _local15); _local16 = (_local15 * m_u.x); _local17 = (_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.Common.Math.*; import Box2D.Dynamics.*; public class b2DistanceJointDef extends b2JointDef { public var length:Number; public var dampingRatio:Number; public var frequencyHz:Number; public var localAnchor2:b2Vec2; public var localAnchor1:b2Vec2; 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{ var _local5:Number; var _local6:Number; body1 = _arg1; body2 = _arg2; localAnchor1.SetV(body1.GetLocalPoint(_arg3)); localAnchor2.SetV(body2.GetLocalPoint(_arg4)); _local5 = (_arg4.x - _arg3.x); _local6 = (_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.Common.Math.*; import Box2D.Dynamics.*; import Box2D.Common.*; public class b2GearJoint extends b2Joint { public var m_force:Number; public var m_mass:Number; public var m_prismatic1:b2PrismaticJoint; public var m_prismatic2:b2PrismaticJoint; public var m_ground1:b2Body; public var m_ground2:b2Body; public var m_constant:Number; public var m_revolute1:b2RevoluteJoint; public var m_revolute2:b2RevoluteJoint; 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_J:b2Jacobian; public function b2GearJoint(_arg1:b2GearJointDef){ var _local2:int; var _local3:int; 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); _local2 = _arg1.joint1.m_type; _local3 = _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 GetReactionForce():b2Vec2{ var _local1:b2Vec2; _local1 = new b2Vec2((m_force * m_J.linear2.x), (m_force * m_J.linear2.y)); return (_local1); } override public function SolvePositionConstraints():Boolean{ var _local1:Number; var _local2:b2Body; var _local3:b2Body; var _local4:Number; var _local5:Number; var _local6:Number; var _local7:Number; _local1 = 0; _local2 = m_body1; _local3 = 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(); }; _local6 = (m_constant - (_local4 + (m_ratio * _local5))); _local7 = (-(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)); } override public function InitVelocityConstraints(_arg1:b2TimeStep):void{ var _local2:b2Body; var _local3:b2Body; var _local4:b2Body; var _local5:b2Body; 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 _local14:Number; var _local15:Number; _local2 = m_ground1; _local3 = m_ground2; _local4 = m_body1; _local5 = m_body2; _local14 = 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; var _local2:Number; var _local3:Number; var _local4:Number; _local1 = m_body2.m_xf.R; _local2 = (m_localAnchor1.x - m_body2.m_sweep.localCenter.x); _local3 = (m_localAnchor1.y - m_body2.m_sweep.localCenter.y); _local4 = ((_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); } public function GetRatio():Number{ return (m_ratio); } override public function SolveVelocityConstraints(_arg1:b2TimeStep):void{ var _local2:b2Body; var _local3:b2Body; var _local4:Number; var _local5:Number; var _local6:Number; _local2 = m_body1; _local3 = m_body2; _local4 = m_J.Compute(_local2.m_linearVelocity, _local2.m_angularVelocity, _local3.m_linearVelocity, _local3.m_angularVelocity); _local5 = ((-(_arg1.inv_dt) * m_mass) * _local4); m_force = (m_force + _local5); _local6 = (_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 { import Box2D.Common.Math.*; public class b2GearJointDef extends b2JointDef { public var joint2:b2Joint; public var joint1: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 angular2:Number; public var angular1: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.Common.Math.*; import Box2D.Dynamics.*; import Box2D.Common.*; 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 GetAnchor1():b2Vec2{ return (null); } public function GetAnchor2():b2Vec2{ return (null); } public function InitVelocityConstraints(_arg1:b2TimeStep):void{ } public function GetType():int{ return (m_type); } public function GetBody2():b2Body{ return (m_body2); } public function GetNext():b2Joint{ return (m_next); } 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; _local3 = null; 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.Common.Math.*; import Box2D.Dynamics.*; public class b2JointDef { public var collideConnected:Boolean; public var body1:b2Body; public var body2:b2Body; public var userData; public var type:int; 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 joint:b2Joint; public var other:b2Body; public var next:b2JointEdge; public var prev:b2JointEdge; } }//package Box2D.Dynamics.Joints
Section 56
//b2MouseJoint (Box2D.Dynamics.Joints.b2MouseJoint) package Box2D.Dynamics.Joints { import Box2D.Common.Math.*; import Box2D.Dynamics.*; import Box2D.Common.*; public class b2MouseJoint extends b2Joint { public var m_beta:Number; public var m_mass:b2Mat22; public var m_target:b2Vec2; public var m_impulse:b2Vec2; public var m_localAnchor:b2Vec2; private var K1:b2Mat22; private var K2:b2Mat22; private var K:b2Mat22; public var m_gamma:Number; public var m_C:b2Vec2; public var m_maxForce:Number; public function b2MouseJoint(_arg1:b2MouseJointDef){ var _local2:Number; var _local3:Number; var _local4:b2Mat22; var _local5:Number; var _local6:Number; var _local7:Number; var _local8: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); _local2 = (m_target.x - m_body2.m_xf.position.x); _local3 = (m_target.y - m_body2.m_xf.position.y); _local4 = 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(); _local5 = m_body2.m_mass; _local6 = ((2 * b2Settings.b2_pi) * _arg1.frequencyHz); _local7 = (((2 * _local5) * _arg1.dampingRatio) * _local6); _local8 = ((_arg1.timeStep * _local5) * (_local6 * _local6)); m_gamma = (1 / (_local7 + _local8)); m_beta = (_local8 / (_local7 + _local8)); } override public function GetAnchor1():b2Vec2{ return (m_target); } override public function GetAnchor2():b2Vec2{ return (m_body2.GetWorldPoint(m_localAnchor)); } override public function GetReactionForce():b2Vec2{ return (m_impulse); } override public function SolvePositionConstraints():Boolean{ return (true); } override public function InitVelocityConstraints(_arg1:b2TimeStep):void{ var _local2:b2Body; var _local3:b2Mat22; var _local4:Number; var _local5:Number; var _local6:Number; var _local7:Number; var _local8:Number; var _local9:Number; var _local10: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); _local6 = ((_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); _local9 = (_arg1.dt * m_impulse.x); _local10 = (_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 GetReactionTorque():Number{ return (0); } public function SetTarget(_arg1:b2Vec2):void{ if (m_body2.IsSleeping()){ m_body2.WakeUp(); }; m_target = _arg1; } override public function SolveVelocityConstraints(_arg1:b2TimeStep):void{ var _local2:b2Body; var _local3:b2Mat22; 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; _local2 = m_body2; _local3 = _local2.m_xf.R; _local6 = (m_localAnchor.x - _local2.m_sweep.localCenter.x); _local7 = (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; _local8 = (_local2.m_linearVelocity.x + (-(_local2.m_angularVelocity) * _local7)); _local9 = (_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)); _local10 = (-(_arg1.inv_dt) * ((_local3.col1.x * _local4) + (_local3.col2.x * _local5))); _local11 = (-(_arg1.inv_dt) * ((_local3.col1.y * _local4) + (_local3.col2.y * _local5))); _local12 = m_impulse.x; _local13 = m_impulse.y; m_impulse.x = (m_impulse.x + _local10); m_impulse.y = (m_impulse.y + _local11); _local14 = m_impulse.Length(); if (_local14 > m_maxForce){ m_impulse.Multiply((m_maxForce / _local14)); }; _local10 = (m_impulse.x - _local12); _local11 = (m_impulse.y - _local13); _local15 = (_arg1.dt * _local10); _local16 = (_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 frequencyHz:Number; public var dampingRatio:Number; public var maxForce:Number; public var target:b2Vec2; public var timeStep: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.Common.Math.*; import Box2D.Dynamics.*; import Box2D.Common.*; public class b2PrismaticJoint extends b2Joint { public var m_limitForce:Number; public var m_refAngle:Number; public var m_lowerTranslation:Number; public var m_localXAxis1:b2Vec2; public var m_torque:Number; public var m_enableLimit:Boolean; public var m_motorForce:Number; public var m_force:Number; public var m_localYAxis1:b2Vec2; public var m_motorMass:Number; public var m_maxMotorForce:Number; public var m_localAnchor1:b2Vec2; public var m_localAnchor2:b2Vec2; public var m_angularMass:Number; public var m_limitState:int; public var m_linearMass:Number; public var m_upperTranslation:Number; public var m_motorJacobian:b2Jacobian; public var m_limitPositionImpulse:Number; public var m_motorSpeed:Number; public var m_linearJacobian:b2Jacobian; public var m_enableMotor:Boolean; 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 GetAnchor1():b2Vec2{ return (m_body1.GetWorldPoint(m_localAnchor1)); } override public function GetAnchor2():b2Vec2{ return (m_body2.GetWorldPoint(m_localAnchor2)); } public function EnableMotor(_arg1:Boolean):void{ m_enableMotor = _arg1; } public function GetUpperLimit():Number{ return (m_upperTranslation); } public function GetLowerLimit():Number{ return (m_lowerTranslation); } public function GetJointTranslation():Number{ var _local1:b2Body; var _local2:b2Body; var _local3:b2Mat22; var _local4:b2Vec2; var _local5:b2Vec2; var _local6:Number; var _local7:Number; var _local8:b2Vec2; var _local9:Number; _local1 = m_body1; _local2 = m_body2; _local4 = _local1.GetWorldPoint(m_localAnchor1); _local5 = _local2.GetWorldPoint(m_localAnchor2); _local6 = (_local5.x - _local4.x); _local7 = (_local5.y - _local4.y); _local8 = _local1.GetWorldVector(m_localXAxis1); _local9 = ((_local8.x * _local6) + (_local8.y * _local7)); return (_local9); } public function SetLimits(_arg1:Number, _arg2:Number):void{ m_lowerTranslation = _arg1; m_upperTranslation = _arg2; } public function GetMotorSpeed():Number{ return (m_motorSpeed); } override public function GetReactionForce():b2Vec2{ var _local1:b2Mat22; var _local2:Number; var _local3:Number; var _local4:Number; var _local5:Number; _local1 = m_body1.m_xf.R; _local2 = (m_limitForce * ((_local1.col1.x * m_localXAxis1.x) + (_local1.col2.x * m_localXAxis1.y))); _local3 = (m_limitForce * ((_local1.col1.y * m_localXAxis1.x) + (_local1.col2.y * m_localXAxis1.y))); _local4 = (m_force * ((_local1.col1.x * m_localYAxis1.x) + (_local1.col2.x * m_localYAxis1.y))); _local5 = (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 _local3:b2Body; var _local4:b2Body; var _local5:Number; var _local6:Number; var _local7:Number; var _local8:Number; var _local9: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 _local21:Number; 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; _local3 = m_body1; _local4 = m_body2; _local5 = _local3.m_invMass; _local6 = _local4.m_invMass; _local7 = _local3.m_invI; _local8 = _local4.m_invI; _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; _local21 = ((_local9.col1.x * m_localYAxis1.x) + (_local9.col2.x * m_localYAxis1.y)); _local22 = ((_local9.col1.y * m_localYAxis1.x) + (_local9.col2.y * m_localYAxis1.y)); _local23 = ((_local21 * _local19) + (_local22 * _local20)); _local23 = b2Math.b2Clamp(_local23, -(b2Settings.b2_maxLinearCorrection), b2Settings.b2_maxLinearCorrection); _local24 = (-(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)); _local25 = b2Math.b2Abs(_local23); _local26 = ((_local4.m_sweep.a - _local3.m_sweep.a) - m_refAngle); _local26 = b2Math.b2Clamp(_local26, -(b2Settings.b2_maxAngularCorrection), b2Settings.b2_maxAngularCorrection); _local27 = (-(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(); _local28 = 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 GetJointSpeed():Number{ var _local1:b2Body; var _local2:b2Body; var _local3:b2Mat22; 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:b2Vec2; var _local16:b2Vec2; var _local17:b2Vec2; var _local18:Number; var _local19:Number; var _local20:Number; _local1 = m_body1; _local2 = m_body2; _local3 = _local1.m_xf.R; _local4 = (m_localAnchor1.x - _local1.m_sweep.localCenter.x); _local5 = (m_localAnchor1.y - _local1.m_sweep.localCenter.y); _local6 = ((_local3.col1.x * _local4) + (_local3.col2.x * _local5)); _local5 = ((_local3.col1.y * _local4) + (_local3.col2.y * _local5)); _local4 = _local6; _local3 = _local2.m_xf.R; _local7 = (m_localAnchor2.x - _local2.m_sweep.localCenter.x); _local8 = (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; _local9 = (_local1.m_sweep.c.x + _local4); _local10 = (_local1.m_sweep.c.y + _local5); _local11 = (_local2.m_sweep.c.x + _local7); _local12 = (_local2.m_sweep.c.y + _local8); _local13 = (_local11 - _local9); _local14 = (_local12 - _local10); _local15 = _local1.GetWorldVector(m_localXAxis1); _local16 = _local1.m_linearVelocity; _local17 = _local2.m_linearVelocity; _local18 = _local1.m_angularVelocity; _local19 = _local2.m_angularVelocity; _local20 = (((_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); } public function SetMotorSpeed(_arg1:Number):void{ m_motorSpeed = _arg1; } override public function InitVelocityConstraints(_arg1:b2TimeStep):void{ var _local2:b2Body; var _local3:b2Body; var _local4:b2Mat22; 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: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; _local2 = m_body1; _local3 = m_body2; _local4 = _local2.m_xf.R; _local6 = (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; _local8 = (m_localAnchor2.x - _local3.m_sweep.localCenter.x); _local9 = (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; _local10 = _local2.m_invMass; _local11 = _local3.m_invMass; _local12 = _local2.m_invI; _local13 = _local3.m_invI; _local4 = _local2.m_xf.R; _local14 = ((_local4.col1.x * m_localYAxis1.x) + (_local4.col2.x * m_localYAxis1.y)); _local15 = ((_local4.col1.y * m_localYAxis1.x) + (_local4.col2.y * m_localYAxis1.y)); _local16 = ((_local3.m_sweep.c.x + _local8) - _local2.m_sweep.c.x); _local17 = ((_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 SetMaxMotorForce(_arg1:Number):void{ m_maxMotorForce = _arg1; } public function EnableLimit(_arg1:Boolean):void{ m_enableLimit = _arg1; } override public function GetReactionTorque():Number{ return (m_torque); } public function IsLimitEnabled():Boolean{ return (m_enableLimit); } public function IsMotorEnabled():Boolean{ return (m_enableMotor); } override public function SolveVelocityConstraints(_arg1:b2TimeStep):void{ var _local2:b2Body; var _local3:b2Body; 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:Number; var _local18:Number; var _local19:Number; _local2 = m_body1; _local3 = m_body2; _local4 = _local2.m_invMass; _local5 = _local3.m_invMass; _local6 = _local2.m_invI; _local7 = _local3.m_invI; _local9 = m_linearJacobian.Compute(_local2.m_linearVelocity, _local2.m_angularVelocity, _local3.m_linearVelocity, _local3.m_angularVelocity); _local10 = ((-(_arg1.inv_dt) * m_linearMass) * _local9); m_force = (m_force + _local10); _local11 = (_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)); _local12 = (_local3.m_angularVelocity - _local2.m_angularVelocity); _local13 = ((-(_arg1.inv_dt) * m_angularMass) * _local12); m_torque = (m_torque + _local13); _local14 = (_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)); }; } } }//package Box2D.Dynamics.Joints
Section 59
//b2PrismaticJointDef (Box2D.Dynamics.Joints.b2PrismaticJointDef) package Box2D.Dynamics.Joints { import Box2D.Common.Math.*; import Box2D.Dynamics.*; public class b2PrismaticJointDef extends b2JointDef { public var localAxis1:b2Vec2; public var referenceAngle:Number; public var maxMotorForce:Number; public var motorSpeed:Number; public var upperTranslation:Number; public var localAnchor1:b2Vec2; public var localAnchor2:b2Vec2; public var enableLimit:Boolean; public var enableMotor:Boolean; 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.Common.Math.*; import Box2D.Dynamics.*; import Box2D.Common.*; public class b2PulleyJoint extends b2Joint { public var m_ground:b2Body; public var m_maxLength2:Number; public var m_limitForce1:Number; public var m_maxLength1:Number; public var m_limitState1:int; public var m_limitState2:int; public var m_limitPositionImpulse2:Number; public var m_force:Number; public var m_limitPositionImpulse1:Number; public var m_constant: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_positionImpulse:Number; public var m_limitMass2:Number; public var m_limitMass1:Number; public var m_pulleyMass:Number; public var m_u1:b2Vec2; public var m_u2:b2Vec2; public var m_limitForce2:Number; 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; _local1 = 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; _local1 = m_u2.Copy(); _local1.Multiply(m_force); return (_local1); } override public function SolvePositionConstraints():Boolean{ var _local1:b2Body; var _local2:b2Body; var _local3:b2Mat22; 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:Number; var _local18:Number; var _local19:Number; var _local20:Number; var _local21:Number; var _local22:Number; var _local23:Number; _local1 = m_body1; _local2 = m_body2; _local4 = (m_ground.m_xf.position.x + m_groundAnchor1.x); _local5 = (m_ground.m_xf.position.y + m_groundAnchor1.y); _local6 = (m_ground.m_xf.position.x + m_groundAnchor2.x); _local7 = (m_ground.m_xf.position.y + m_groundAnchor2.y); _local23 = 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 _local2:b2Body; var _local3:b2Body; var _local4:b2Mat22; 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: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; _local2 = m_body1; _local3 = m_body2; _local4 = _local2.m_xf.R; _local5 = (m_localAnchor1.x - _local2.m_sweep.localCenter.x); _local6 = (m_localAnchor1.y - _local2.m_sweep.localCenter.y); _local7 = ((_local4.col1.x * _local5) + (_local4.col2.x * _local6)); _local6 = ((_local4.col1.y * _local5) + (_local4.col2.y * _local6)); _local5 = _local7; _local4 = _local3.m_xf.R; _local8 = (m_localAnchor2.x - _local3.m_sweep.localCenter.x); _local9 = (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; _local10 = (_local2.m_sweep.c.x + _local5); _local11 = (_local2.m_sweep.c.y + _local6); _local12 = (_local3.m_sweep.c.x + _local8); _local13 = (_local3.m_sweep.c.y + _local9); _local14 = (m_ground.m_xf.position.x + m_groundAnchor1.x); _local15 = (m_ground.m_xf.position.y + m_groundAnchor1.y); _local16 = (m_ground.m_xf.position.x + m_groundAnchor2.x); _local17 = (m_ground.m_xf.position.y + m_groundAnchor2.y); m_u1.Set((_local10 - _local14), (_local11 - _local15)); m_u2.Set((_local12 - _local16), (_local13 - _local17)); _local18 = m_u1.Length(); _local19 = 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(); }; _local20 = ((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; }; _local21 = ((_local5 * m_u1.y) - (_local6 * m_u1.x)); _local22 = ((_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); } public function GetLength2():Number{ var _local1:b2Vec2; var _local2:Number; var _local3:Number; var _local4:Number; var _local5:Number; _local1 = m_body2.GetWorldPoint(m_localAnchor2); _local2 = (m_ground.m_xf.position.x + m_groundAnchor2.x); _local3 = (m_ground.m_xf.position.y + m_groundAnchor2.y); _local4 = (_local1.x - _local2); _local5 = (_local1.y - _local3); return (Math.sqrt(((_local4 * _local4) + (_local5 * _local5)))); } override public function SolveVelocityConstraints(_arg1:b2TimeStep):void{ var _local2:b2Body; var _local3:b2Body; var _local4:b2Mat22; 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:Number; var _local18:Number; var _local19:Number; var _local20:Number; _local2 = m_body1; _local3 = m_body2; _local4 = _local2.m_xf.R; _local5 = (m_localAnchor1.x - _local2.m_sweep.localCenter.x); _local6 = (m_localAnchor1.y - _local2.m_sweep.localCenter.y); _local7 = ((_local4.col1.x * _local5) + (_local4.col2.x * _local6)); _local6 = ((_local4.col1.y * _local5) + (_local4.col2.y * _local6)); _local5 = _local7; _local4 = _local3.m_xf.R; _local8 = (m_localAnchor2.x - _local3.m_sweep.localCenter.x); _local9 = (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; var _local2:Number; var _local3:Number; var _local4:Number; var _local5:Number; _local1 = m_body1.GetWorldPoint(m_localAnchor1); _local2 = (m_ground.m_xf.position.x + m_groundAnchor1.x); _local3 = (m_ground.m_xf.position.y + m_groundAnchor1.y); _local4 = (_local1.x - _local2); _local5 = (_local1.y - _local3); return (Math.sqrt(((_local4 * _local4) + (_local5 * _local5)))); } public function GetGroundAnchor1():b2Vec2{ var _local1:b2Vec2; _local1 = 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.Common.Math.*; import Box2D.Dynamics.*; public class b2PulleyJointDef extends b2JointDef { public var maxLength2:Number; public var length1:Number; public var length2:Number; public var maxLength1:Number; public var ratio:Number; public var groundAnchor1:b2Vec2; public var groundAnchor2:b2Vec2; public var localAnchor1:b2Vec2; public var localAnchor2:b2Vec2; 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{ var _local8:Number; var _local9:Number; var _local10:Number; var _local11:Number; var _local12:Number; body1 = _arg1; body2 = _arg2; groundAnchor1.SetV(_arg3); groundAnchor2.SetV(_arg4); localAnchor1 = body1.GetLocalPoint(_arg5); localAnchor2 = body2.GetLocalPoint(_arg6); _local8 = (_arg5.x - _arg3.x); _local9 = (_arg5.y - _arg3.y); length1 = Math.sqrt(((_local8 * _local8) + (_local9 * _local9))); _local10 = (_arg6.x - _arg4.x); _local11 = (_arg6.y - _arg4.y); length2 = Math.sqrt(((_local10 * _local10) + (_local11 * _local11))); ratio = _arg7; _local12 = (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.Common.Math.*; import Box2D.Dynamics.*; import Box2D.Common.*; public class b2RevoluteJoint extends b2Joint { public var m_limitForce:Number; public var m_motorForce:Number; public var m_pivotMass:b2Mat22; 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_motorSpeed:Number; public var m_enableMotor:Boolean; public var m_limitPositionImpulse:Number; public var m_maxMotorTorque:Number; public var m_referenceAngle:Number; public var m_lowerAngle:Number; public var m_upperAngle: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 GetAnchor1():b2Vec2{ return (m_body1.GetWorldPoint(m_localAnchor1)); } override public function GetAnchor2():b2Vec2{ return (m_body2.GetWorldPoint(m_localAnchor2)); } public function EnableMotor(_arg1:Boolean):void{ m_enableMotor = _arg1; } public function GetUpperLimit():Number{ return (m_upperAngle); } public function GetLowerLimit():Number{ return (m_lowerAngle); } public function SetLimits(_arg1:Number, _arg2:Number):void{ m_lowerAngle = _arg1; m_upperAngle = _arg2; } 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 _local3:b2Body; var _local4:b2Body; var _local5:Number; var _local6:b2Mat22; 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; 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; _local3 = m_body1; _local4 = m_body2; _local5 = 0; _local6 = _local3.m_xf.R; _local7 = (m_localAnchor1.x - _local3.m_sweep.localCenter.x); _local8 = (m_localAnchor1.y - _local3.m_sweep.localCenter.y); _local9 = ((_local6.col1.x * _local7) + (_local6.col2.x * _local8)); _local8 = ((_local6.col1.y * _local7) + (_local6.col2.y * _local8)); _local7 = _local9; _local6 = _local4.m_xf.R; _local10 = (m_localAnchor2.x - _local4.m_sweep.localCenter.x); _local11 = (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; _local12 = (_local3.m_sweep.c.x + _local7); _local13 = (_local3.m_sweep.c.y + _local8); _local14 = (_local4.m_sweep.c.x + _local10); _local15 = (_local4.m_sweep.c.y + _local11); _local16 = (_local14 - _local12); _local17 = (_local15 - _local13); _local5 = Math.sqrt(((_local16 * _local16) + (_local17 * _local17))); _local18 = _local3.m_invMass; _local19 = _local4.m_invMass; _local20 = _local3.m_invI; _local21 = _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)); _local22 = tImpulse.x; _local23 = 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(); _local24 = 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 GetJointSpeed():Number{ return ((m_body2.m_angularVelocity - m_body1.m_angularVelocity)); } public function SetMotorSpeed(_arg1:Number):void{ m_motorSpeed = _arg1; } 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)); } override public function InitVelocityConstraints(_arg1:b2TimeStep):void{ var _local2:b2Body; var _local3:b2Body; var _local4:b2Mat22; 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; _local2 = m_body1; _local3 = m_body2; _local4 = _local2.m_xf.R; _local6 = (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; _local8 = (m_localAnchor2.x - _local3.m_sweep.localCenter.x); _local9 = (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; _local10 = _local2.m_invMass; _local11 = _local3.m_invMass; _local12 = _local2.m_invI; _local13 = _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; } public function GetMotorTorque():Number{ return (m_motorForce); } override public function GetReactionTorque():Number{ return (m_limitForce); } public function IsLimitEnabled():Boolean{ return (m_enableLimit); } public function IsMotorEnabled():Boolean{ return (m_enableMotor); } override public function SolveVelocityConstraints(_arg1:b2TimeStep):void{ var _local2:b2Body; var _local3:b2Body; var _local4:b2Mat22; 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:Number; var _local18:Number; var _local19:Number; var _local20:Number; var _local21:Number; _local2 = m_body1; _local3 = m_body2; _local4 = _local2.m_xf.R; _local6 = (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; _local8 = (m_localAnchor2.x - _local3.m_sweep.localCenter.x); _local9 = (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; _local11 = (((_local3.m_linearVelocity.x + (-(_local3.m_angularVelocity) * _local9)) - _local2.m_linearVelocity.x) - (-(_local2.m_angularVelocity) * _local7)); _local12 = (((_local3.m_linearVelocity.y + (_local3.m_angularVelocity * _local8)) - _local2.m_linearVelocity.y) - (_local2.m_angularVelocity * _local6)); _local13 = (-(_arg1.inv_dt) * ((m_pivotMass.col1.x * _local11) + (m_pivotMass.col2.x * _local12))); _local14 = (-(_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); _local15 = (_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)); }; } } }//package Box2D.Dynamics.Joints
Section 63
//b2RevoluteJointDef (Box2D.Dynamics.Joints.b2RevoluteJointDef) package Box2D.Dynamics.Joints { import Box2D.Common.Math.*; import Box2D.Dynamics.*; public class b2RevoluteJointDef extends b2JointDef { public var referenceAngle:Number; public var upperAngle:Number; public var lowerAngle:Number; public var motorSpeed:Number; public var maxMotorTorque:Number; public var localAnchor1:b2Vec2; public var localAnchor2:b2Vec2; public var enableLimit:Boolean; public var enableMotor:Boolean; 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.Common.Math.*; import Box2D.Collision.Shapes.*; import Box2D.Dynamics.Joints.*; import Box2D.Common.*; import Box2D.Dynamics.Contacts.*; public class b2Body { public var m_next:b2Body; 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_xf:b2XForm; 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_angularDamping:Number; public var m_invI:Number; public var m_linearVelocity:b2Vec2; public var m_sleepTime:Number; public var m_shapeCount:int; 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){ var _local3:b2Mat22; var _local4:b2Vec2; 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); _local3 = m_xf.R; _local4 = 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{ var _local1:b2Mat22; var _local2:b2Vec2; m_xf.R.Set(m_sweep.a); _local1 = m_xf.R; _local2 = 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; var _local2:Number; var _local3:Number; var _local4:b2MassData; var _local5:b2Mat22; var _local6:b2Vec2; var _local7:int; if (m_world.m_lock == true){ return; }; m_mass = 0; m_invMass = 0; m_I = 0; m_invI = 0; _local2 = 0; _local3 = 0; _local4 = 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); _local5 = m_xf.R; _local6 = 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; }; _local7 = 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 _local4:b2Mat22; var _local5:b2Vec2; var _local6:Boolean; 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); _local4 = m_xf.R; _local5 = 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); _local6 = false; _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 _local1:b2XForm; var _local2:b2Mat22; var _local3:b2Vec2; var _local4:b2Shape; var _local5:Boolean; _local1 = s_xf1; _local1.R.Set(m_sweep.a0); _local2 = _local1.R; _local3 = 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))); _local5 = true; _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 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 GetNext():b2Body{ return (m_next); } public function GetMass():Number{ return (m_mass); } public function GetLinearVelocityFromLocalPoint(_arg1:b2Vec2):b2Vec2{ var _local2:b2Mat22; var _local3:b2Vec2; _local2 = m_xf.R; _local3 = 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 GetAngularVelocity():Number{ return (m_angularVelocity); } public function SetAngularVelocity(_arg1:Number):void{ m_angularVelocity = _arg1; } public function SetMass(_arg1:b2MassData):void{ var _local2:b2Shape; var _local3:b2Mat22; var _local4:b2Vec2; var _local5:int; 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); _local3 = m_xf.R; _local4 = 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; }; _local5 = 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; _local2 = 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{ var _local2:b2Shape; var _local3:b2Shape; var _local4:Boolean; if (m_world.m_lock == true){ return; }; _arg1.DestroyProxy(m_world.m_broadPhase); _local2 = m_shapeList; _local3 = null; _local4 = false; 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; var _local3:b2Vec2; _local2 = m_xf.R; _local3 = 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.*; import Box2D.Dynamics.Joints.*; import Box2D.Collision.*; import Box2D.Dynamics.Contacts.*; public class b2BodyDef { public var isSleeping:Boolean; public var position:b2Vec2; public var isBullet:Boolean; public var allowSleep:Boolean; public var userData; public var angularDamping:Number; public var fixedRotation:Boolean; public var angle:Number; 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.Common.Math.*; import Box2D.Collision.Shapes.*; import Box2D.Collision.*; import Box2D.Common.*; import Box2D.Dynamics.Contacts.*; public class b2ContactFilter { public static var b2_defaultFilter:b2ContactFilter = new (b2ContactFilter); ; public function ShouldCollide(_arg1:b2Shape, _arg2:b2Shape):Boolean{ var _local3:b2FilterData; var _local4:b2FilterData; var _local5:Boolean; _local3 = _arg1.GetFilterData(); _local4 = _arg2.GetFilterData(); if ((((_local3.groupIndex == _local4.groupIndex)) && (!((_local3.groupIndex == 0))))){ return ((_local3.groupIndex > 0)); }; _local5 = ((!(((_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.Shapes.*; import Box2D.Collision.*; 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 PairAdded(_arg1, _arg2){ var _local3:b2Shape; var _local4:b2Shape; var _local5:b2Body; var _local6:b2Body; var _local7:b2Contact; _local3 = (_arg1 as b2Shape); _local4 = (_arg2 as b2Shape); _local5 = _local3.m_body; _local6 = _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); }; _local7 = 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); } override public function PairRemoved(_arg1, _arg2, _arg3):void{ var _local4:b2Contact; if (_arg3 == null){ return; }; _local4 = (_arg3 as b2Contact); if (_local4 == m_nullContact){ return; }; Destroy(_local4); } public function Destroy(_arg1:b2Contact):void{ var _local2:b2Shape; var _local3:b2Shape; var _local4:int; var _local5:b2Body; var _local6:b2Body; 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; _local2 = _arg1.m_shape1; _local3 = _arg1.m_shape2; _local4 = _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; }; _local5 = _local2.m_body; _local6 = _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--; } public function Collide():void{ var _local1:b2Contact; var _local2:b2Body; var _local3:b2Body; _local1 = 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.Shapes.*; import Box2D.Collision.*; 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_lineThickness:Number;// = 1 public var m_drawFlags:uint; public var m_sprite:Sprite; public var m_drawScale:Number;// = 1 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_drawScale = 1; m_lineThickness = 1; m_alpha = 1; m_fillAlpha = 1; m_xformScale = 1; super(); m_drawFlags = 0; } public function DrawSolidPolygon(_arg1:Array, _arg2:int, _arg3:b2Color):void{ var _local4:int; 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); _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 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)); } public function ClearFlags(_arg1:uint):void{ m_drawFlags = (m_drawFlags & ~(_arg1)); } 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 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 GetFlags():uint{ return (m_drawFlags); } public function DrawPolygon(_arg1:Array, _arg2:int, _arg3:b2Color):void{ var _local4:int; m_sprite.graphics.lineStyle(m_lineThickness, _arg3.color, m_alpha); m_sprite.graphics.moveTo((_arg1[0].x * m_drawScale), (_arg1[0].y * m_drawScale)); _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)); } } }//package Box2D.Dynamics
Section 71
//b2DestructionListener (Box2D.Dynamics.b2DestructionListener) package Box2D.Dynamics { import Box2D.Collision.Shapes.*; import Box2D.Dynamics.Joints.*; public class b2DestructionListener { public function SayGoodbyeJoint(_arg1:b2Joint):void{ } public function SayGoodbyeShape(_arg1:b2Shape):void{ } } }//package Box2D.Dynamics
Section 72
//b2Island (Box2D.Dynamics.b2Island) package Box2D.Dynamics { import Box2D.Common.Math.*; import Box2D.Dynamics.Joints.*; import Box2D.Collision.*; import Box2D.Common.*; import Box2D.Dynamics.Contacts.*; public class b2Island { public var m_joints:Array; public var m_listener:b2ContactListener; public var m_positionIterationCount:int; public var m_bodyCapacity:int; public var m_bodies: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 _local4:int; 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; }; _local4 = 0; 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 Solve(_arg1:b2TimeStep, _arg2:b2Vec2, _arg3:Boolean, _arg4:Boolean):void{ var _local5:int; var _local6:b2Body; var _local7:b2Joint; var _local8:b2ContactSolver; 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++; }; _local8 = 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 AddContact(_arg1:b2Contact):void{ var _local2 = m_contactCount++; m_contacts[_local2] = _arg1; } public function Clear():void{ m_bodyCount = 0; m_contactCount = 0; m_jointCount = 0; } public function SolveTOI(_arg1:b2TimeStep):void{ var _local2:int; var _local3:b2ContactSolver; var _local4:Number; var _local5:b2Body; var _local6:Boolean; _local3 = 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++; }; _local4 = 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.Common.Math.*; import Box2D.Collision.Shapes.*; import Box2D.Dynamics.Joints.*; import Box2D.Collision.*; 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){ var _local4:b2BodyDef; 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); _local4 = new b2BodyDef(); m_groundBody = CreateBody(_local4); } public function DrawJoint(_arg1:b2Joint):void{ var _local2:b2Body; var _local3:b2Body; var _local4:b2XForm; var _local5:b2XForm; var _local6:b2Vec2; var _local7:b2Vec2; var _local8:b2Vec2; var _local9:b2Vec2; var _local10:b2Color; var _local11:b2PulleyJoint; var _local12:b2Vec2; var _local13:b2Vec2; _local2 = _arg1.m_body1; _local3 = _arg1.m_body2; _local4 = _local2.m_xf; _local5 = _local3.m_xf; _local6 = _local4.position; _local7 = _local5.position; _local8 = _arg1.GetAnchor1(); _local9 = _arg1.GetAnchor2(); _local10 = 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 _local1:uint; var _local2:int; var _local3:b2Body; var _local4:b2Shape; var _local5:b2Joint; var _local6:b2BroadPhase; var _local7:b2Vec2; var _local8:b2Vec2; var _local9:b2Vec2; var _local10:b2Color; var _local11:b2XForm; var _local12:b2AABB; var _local13:b2AABB; var _local14:Array; 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(); _local1 = m_debugDraw.GetFlags(); _local7 = new b2Vec2(); _local8 = new b2Vec2(); _local9 = new b2Vec2(); _local10 = new b2Color(0, 0, 0); _local12 = new b2AABB(); _local13 = new b2AABB(); _local14 = [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.1, 0.35, 0.6), _local15); } else { if (_local3.IsSleeping()){ DrawShape(_local4, _local11, new b2Color(0.5, 0.5, 0.1), _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 _local2:b2JointEdge; var _local3:b2Shape; var _local4:b2JointEdge; var _local5:b2Shape; if (m_lock == true){ return; }; _local2 = _arg1.m_jointList; while (_local2) { _local4 = _local2; _local2 = _local2.next; if (m_destructionListener){ m_destructionListener.SayGoodbyeJoint(_local4.joint); }; DestroyJoint(_local4.joint); }; _local3 = _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 _local5:b2Color; 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; _local5 = 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++; }; }; break; }; } public function GetContactCount():int{ return (m_contactCount); } public function Solve(_arg1:b2TimeStep):void{ var _local2:b2Body; var _local3:b2Island; var _local4:b2Contact; var _local5:b2Joint; var _local6:int; var _local7:Array; var _local8:b2Body; var _local9:int; var _local10:int; var _local11:b2Body; var _local12:b2ContactEdge; var _local13:b2JointEdge; var _local14:Boolean; m_positionIterationCount = 0; _local3 = 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; }; _local4 = m_contactList; while (_local4) { _local4.m_flags = (_local4.m_flags & ~(b2Contact.e_islandFlag)); _local4 = _local4.m_next; }; _local5 = m_jointList; while (_local5) { _local5.m_islandFlag = false; _local5 = _local5.m_next; }; _local6 = m_bodyCount; _local7 = new Array(_local6); _local8 = 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; var _local5:int; var _local6:int; _local4 = new Array(_arg3); _local5 = m_broadPhase.QueryAABB(_arg1, _local4, _arg3); _local6 = 0; 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 _local8:b2Island; var _local9:int; var _local10:Array; 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; _local8 = new b2Island(m_bodyCount, b2Settings.b2_maxTOIContactsPerIsland, 0, m_stackAllocator, m_contactListener); _local9 = m_bodyCount; _local10 = 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 Validate():void{ m_broadPhase.Validate(); } public function GetPairCount():int{ return (m_broadPhase.m_pairManager.m_pairCount); } public function GetBodyList():b2Body{ return (m_bodyList); } 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 _local2:b2Joint; var _local3:b2Body; var _local4:b2Shape; _local2 = 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 _local2:Boolean; var _local3:b2Body; var _local4:b2Body; var _local5:b2Body; var _local6:b2Shape; _local2 = _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; }; _local3 = _arg1.m_body1; _local4 = _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{ var _local2:b2Body; if (m_lock == true){ return (null); }; _local2 = 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{ var _local3:b2TimeStep; m_lock = true; _local3 = 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
//JSONDecoder (com.adobe.serialization.json.JSONDecoder) package com.adobe.serialization.json { public class JSONDecoder { private var value; private var tokenizer:JSONTokenizer; private var token:JSONToken; public function JSONDecoder(_arg1:String){ tokenizer = new JSONTokenizer(_arg1); nextToken(); value = parseValue(); } private function nextToken():JSONToken{ return ((token = tokenizer.getNextToken())); } private function parseObject():Object{ var _local1:Object; var _local2:String; _local1 = new Object(); nextToken(); if (token.type == JSONTokenType.RIGHT_BRACE){ return (_local1); }; while (true) { if (token.type == JSONTokenType.STRING){ _local2 = String(token.value); nextToken(); if (token.type == JSONTokenType.COLON){ nextToken(); _local1[_local2] = parseValue(); nextToken(); if (token.type == JSONTokenType.RIGHT_BRACE){ return (_local1); }; if (token.type == JSONTokenType.COMMA){ nextToken(); } else { tokenizer.parseError(("Expecting } or , but found " + token.value)); }; } else { tokenizer.parseError(("Expecting : but found " + token.value)); }; } else { tokenizer.parseError(("Expecting string but found " + token.value)); }; }; return (null); } private function parseArray():Array{ var _local1:Array; _local1 = new Array(); nextToken(); if (token.type == JSONTokenType.RIGHT_BRACKET){ return (_local1); }; while (true) { _local1.push(parseValue()); nextToken(); if (token.type == JSONTokenType.RIGHT_BRACKET){ return (_local1); }; if (token.type == JSONTokenType.COMMA){ nextToken(); } else { tokenizer.parseError(("Expecting ] or , but found " + token.value)); }; }; return (null); } public function getValue(){ return (value); } private function parseValue():Object{ if (token == null){ tokenizer.parseError("Unexpected end of input"); }; switch (token.type){ case JSONTokenType.LEFT_BRACE: return (parseObject()); case JSONTokenType.LEFT_BRACKET: return (parseArray()); case JSONTokenType.STRING: case JSONTokenType.NUMBER: case JSONTokenType.TRUE: case JSONTokenType.FALSE: case JSONTokenType.NULL: return (token.value); default: tokenizer.parseError(("Unexpected " + token.value)); }; return (null); } } }//package com.adobe.serialization.json
Section 76
//JSONParseError (com.adobe.serialization.json.JSONParseError) package com.adobe.serialization.json { public class JSONParseError extends Error { private var _text:String; private var _location:int; public function JSONParseError(_arg1:String="", _arg2:int=0, _arg3:String=""){ super(_arg1); _location = _arg2; _text = _arg3; } public function get text():String{ return (_text); } public function get location():int{ return (_location); } } }//package com.adobe.serialization.json
Section 77
//JSONToken (com.adobe.serialization.json.JSONToken) package com.adobe.serialization.json { public class JSONToken { private var _value:Object; private var _type:int; public function JSONToken(_arg1:int=-1, _arg2:Object=null){ _type = _arg1; _value = _arg2; } public function set value(_arg1:Object):void{ _value = _arg1; } public function get value():Object{ return (_value); } public function set type(_arg1:int):void{ _type = _arg1; } public function get type():int{ return (_type); } } }//package com.adobe.serialization.json
Section 78
//JSONTokenizer (com.adobe.serialization.json.JSONTokenizer) package com.adobe.serialization.json { public class JSONTokenizer { private var loc:int; private var ch:String; private var obj:Object; private var jsonString:String; public function JSONTokenizer(_arg1:String){ jsonString = _arg1; loc = 0; nextChar(); } private function skipComments():void{ if (ch == "/"){ nextChar(); switch (ch){ case "/": do { nextChar(); } while (((!((ch == "\n"))) && (!((ch == ""))))); nextChar(); break; case "*": nextChar(); while (true) { if (ch == "*"){ nextChar(); if (ch == "/"){ nextChar(); break; }; } else { nextChar(); }; if (ch == ""){ parseError("Multi-line comment not closed"); }; }; break; default: parseError((("Unexpected " + ch) + " encountered (expecting '/' or '*' )")); }; }; } private function isDigit(_arg1:String):Boolean{ return ((((_arg1 >= "0")) && ((_arg1 <= "9")))); } private function readNumber():JSONToken{ var _local1:JSONToken; var _local2:String; var _local3:Number; _local1 = new JSONToken(); _local1.type = JSONTokenType.NUMBER; _local2 = ""; if (ch == "-"){ _local2 = (_local2 + "-"); nextChar(); }; if (!isDigit(ch)){ parseError("Expecting a digit"); }; if (ch == "0"){ _local2 = (_local2 + ch); nextChar(); if (isDigit(ch)){ parseError("A digit cannot immediately follow 0"); }; } else { while (isDigit(ch)) { _local2 = (_local2 + ch); nextChar(); }; }; if (ch == "."){ _local2 = (_local2 + "."); nextChar(); if (!isDigit(ch)){ parseError("Expecting a digit"); }; while (isDigit(ch)) { _local2 = (_local2 + ch); nextChar(); }; }; if ((((ch == "e")) || ((ch == "E")))){ _local2 = (_local2 + "e"); nextChar(); if ((((ch == "+")) || ((ch == "-")))){ _local2 = (_local2 + ch); nextChar(); }; if (!isDigit(ch)){ parseError("Scientific notation number needs exponent value"); }; while (isDigit(ch)) { _local2 = (_local2 + ch); nextChar(); }; }; _local3 = Number(_local2); if (((isFinite(_local3)) && (!(isNaN(_local3))))){ _local1.value = _local3; return (_local1); }; parseError((("Number " + _local3) + " is not valid!")); return (null); } private function nextChar():String{ return ((ch = jsonString.charAt(loc++))); } public function getNextToken():JSONToken{ var _local1:JSONToken; var _local2:String; var _local3:String; var _local4:String; _local1 = new JSONToken(); skipIgnored(); switch (ch){ case "{": _local1.type = JSONTokenType.LEFT_BRACE; _local1.value = "{"; nextChar(); break; case "}": _local1.type = JSONTokenType.RIGHT_BRACE; _local1.value = "}"; nextChar(); break; case "[": _local1.type = JSONTokenType.LEFT_BRACKET; _local1.value = "["; nextChar(); break; case "]": _local1.type = JSONTokenType.RIGHT_BRACKET; _local1.value = "]"; nextChar(); break; case ",": _local1.type = JSONTokenType.COMMA; _local1.value = ","; nextChar(); break; case ":": _local1.type = JSONTokenType.COLON; _local1.value = ":"; nextChar(); break; case "t": _local2 = ((("t" + nextChar()) + nextChar()) + nextChar()); if (_local2 == "true"){ _local1.type = JSONTokenType.TRUE; _local1.value = true; nextChar(); } else { parseError(("Expecting 'true' but found " + _local2)); }; break; case "f": _local3 = (((("f" + nextChar()) + nextChar()) + nextChar()) + nextChar()); if (_local3 == "false"){ _local1.type = JSONTokenType.FALSE; _local1.value = false; nextChar(); } else { parseError(("Expecting 'false' but found " + _local3)); }; break; case "n": _local4 = ((("n" + nextChar()) + nextChar()) + nextChar()); if (_local4 == "null"){ _local1.type = JSONTokenType.NULL; _local1.value = null; nextChar(); } else { parseError(("Expecting 'null' but found " + _local4)); }; break; case "\"": _local1 = readString(); break; default: if (((isDigit(ch)) || ((ch == "-")))){ _local1 = readNumber(); } else { if (ch == ""){ return (null); }; parseError((("Unexpected " + ch) + " encountered")); }; }; return (_local1); } private function skipWhite():void{ while (isWhiteSpace(ch)) { nextChar(); }; } private function isWhiteSpace(_arg1:String):Boolean{ return ((((((((_arg1 == " ")) || ((_arg1 == "\t")))) || ((_arg1 == "\n")))) || ((_arg1 == "\r")))); } public function parseError(_arg1:String):void{ throw (new JSONParseError(_arg1, loc, jsonString)); } private function skipIgnored():void{ skipWhite(); skipComments(); skipWhite(); } private function isHexDigit(_arg1:String):Boolean{ var _local2:String; _local2 = _arg1.toUpperCase(); return (((isDigit(_arg1)) || ((((_local2 >= "A")) && ((_local2 <= "F")))))); } private function readString():JSONToken{ var _local1:JSONToken; var _local2:String; var _local3:String; var _local4:int; _local1 = new JSONToken(); _local1.type = JSONTokenType.STRING; _local2 = ""; nextChar(); while (((!((ch == "\""))) && (!((ch == ""))))) { if (ch == "\\"){ nextChar(); switch (ch){ case "\"": _local2 = (_local2 + "\""); break; case "/": _local2 = (_local2 + "/"); break; case "\\": _local2 = (_local2 + "\\"); break; case "b": _local2 = (_local2 + "\b"); break; case "f": _local2 = (_local2 + "\f"); break; case "n": _local2 = (_local2 + "\n"); break; case "r": _local2 = (_local2 + "\r"); break; case "t": _local2 = (_local2 + "\t"); break; case "u": _local3 = ""; _local4 = 0; while (_local4 < 4) { if (!isHexDigit(nextChar())){ parseError((" Excepted a hex digit, but found: " + ch)); }; _local3 = (_local3 + ch); _local4++; }; _local2 = (_local2 + String.fromCharCode(parseInt(_local3, 16))); break; default: _local2 = (_local2 + ("\\" + ch)); }; } else { _local2 = (_local2 + ch); }; nextChar(); }; if (ch == ""){ parseError("Unterminated string literal"); }; nextChar(); _local1.value = _local2; return (_local1); } } }//package com.adobe.serialization.json
Section 79
//JSONTokenType (com.adobe.serialization.json.JSONTokenType) package com.adobe.serialization.json { public class JSONTokenType { public static const NUMBER:int = 11; public static const FALSE:int = 8; public static const RIGHT_BRACKET:int = 4; public static const NULL:int = 9; public static const TRUE:int = 7; public static const RIGHT_BRACE:int = 2; public static const UNKNOWN:int = -1; public static const COMMA:int = 0; public static const LEFT_BRACKET:int = 3; public static const STRING:int = 10; public static const LEFT_BRACE:int = 1; public static const COLON:int = 6; } }//package com.adobe.serialization.json
Section 80
//BitmapEmitter (com.roguedevelopment.pulse.emitter.BitmapEmitter) package com.roguedevelopment.pulse.emitter { import flash.display.*; import flash.events.*; import com.roguedevelopment.pulse.*; import flash.geom.*; import flash.filters.*; public class BitmapEmitter extends GenericEmitter { protected var fullRect:Rectangle; protected var origin:Point; protected var bitmap:BitmapData; protected var fader:ColorMatrixFilter; public function BitmapEmitter(_arg1:Number, _arg2:BitmapData, _arg3:Number=0.85){ origin = new Point(0, 0); fader = new ColorMatrixFilter([1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, 1, 0, 0, 0, 0, 0, _arg3, 0]); super(_arg1); this.bitmap = _arg2; fullRect = new Rectangle(0, 0, _arg2.width, _arg2.height); root = new Sprite(); } override public function stop():void{ super.stop(); } protected function onEnterFrame(_arg1:Event):void{ var _local2:Matrix; bitmap.applyFilter(bitmap, fullRect, origin, fader); _local2 = new Matrix(); _local2.rotate(((root.rotation * Math.PI) / 180)); _local2.translate(root.x, root.y); _local2.scale(root.scaleX, root.scaleY); bitmap.draw(root, _local2); } override public function start():void{ PulseEngine.instance.root.addEventListener(Event.ENTER_FRAME, onEnterFrame); super.start(); } } }//package com.roguedevelopment.pulse.emitter
Section 81
//GenericEmitter (com.roguedevelopment.pulse.emitter.GenericEmitter) package com.roguedevelopment.pulse.emitter { import com.roguedevelopment.pulse.particle.*; import flash.display.*; import flash.events.*; import com.roguedevelopment.pulse.*; import flash.utils.*; public class GenericEmitter implements IParticleEmitter { protected var timer:Timer; public var width:Number;// = 1 public var newParticlesOnTop:Boolean;// = true protected var factory:IParticleFactory; public var particleLimit:uint;// = 0 public var root:DisplayObjectContainer;// = null public var height:Number;// = 1 protected var particleCount:uint;// = 0 protected var _x:Number;// = 10 protected var _y:Number;// = 10 public function GenericEmitter(_arg1:Number){ _x = 10; _y = 10; width = 1; height = 1; particleLimit = 0; particleCount = 0; root = null; newParticlesOnTop = true; super(); pps = _arg1; root = PulseEngine.instance.root; } public function get y():Number{ return (_y); } public function get pps():Number{ return (10); } public function setFactory(_arg1:IParticleFactory):void{ this.factory = _arg1; } protected function emit(_arg1:TimerEvent):void{ var _local2:IParticle; if (factory == null){ return; }; if (particleLimit > 0){ particleCount++; if (particleCount > particleLimit){ timer.stop(); return; }; }; _local2 = factory.newParticle(); _local2.x = (x + (Math.random() * width)); _local2.y = (y + (Math.random() * height)); if ((_local2 is DisplayObject)){ if (newParticlesOnTop){ root.addChild((_local2 as DisplayObject)); } else { root.addChildAt((_local2 as DisplayObject), 0); }; }; PulseEngine.instance.addParticle(_local2); } public function stop():void{ if (factory != null){ factory.cleanup(); }; timer.stop(); } public function getFactory():IParticleFactory{ return (factory); } public function set y(_arg1:Number):void{ _y = _arg1; } public function set pps(_arg1:Number):void{ if (timer != null){ timer.stop(); }; timer = new Timer((1000 / _arg1)); timer.addEventListener(TimerEvent.TIMER, emit); timer.start(); } public function set x(_arg1:Number):void{ _x = _arg1; } public function start():void{ particleCount = 0; timer.start(); } public function get x():Number{ return (_x); } } }//package com.roguedevelopment.pulse.emitter
Section 82
//IParticleEmitter (com.roguedevelopment.pulse.emitter.IParticleEmitter) package com.roguedevelopment.pulse.emitter { import com.roguedevelopment.pulse.particle.*; public interface IParticleEmitter { function set x(_arg1:Number):void; function set y(_arg1:Number):void; function stop():void; function setFactory(_arg1:IParticleFactory):void; function get x():Number; function get y():Number; function start():void; } }//package com.roguedevelopment.pulse.emitter
Section 83
//MovieClipEmitter (com.roguedevelopment.pulse.emitter.MovieClipEmitter) package com.roguedevelopment.pulse.emitter { import com.roguedevelopment.pulse.particle.*; import flash.display.*; import flash.events.*; import com.roguedevelopment.pulse.*; import flash.geom.*; import flash.utils.*; import com.roguedevelopment.pulse.simple.*; public final class MovieClipEmitter extends MovieClip implements IParticleEmitter { private var realEmitter:GenericEmitter; protected var origin:Point; protected var _clipName:String; private var _config:String; protected var _rootClip:Boolean; public function MovieClipEmitter(){ realEmitter = new GenericEmitter(20); origin = new Point(0, 0); super(); width = 10; height = 10; addEventListener(Event.ADDED_TO_STAGE, onAdded); addEventListener(Event.REMOVED_FROM_STAGE, onRemoved); addEventListener(Event.ENTER_FRAME, onEnterFrame); visible = false; } override public function stop():void{ realEmitter.stop(); } public function get rootEffect():Boolean{ return (_rootClip); } protected function setupEmitter():void{ var _local1:IParticleFactory; var _local2:Array; var _local3:Class; if (realEmitter != null){ realEmitter.stop(); }; _local2 = []; if ((((movieClipName == "")) || ((movieClipName == null)))){ _local1 = new GenericFactory(DotParticle, _local2, []); } else { _local3 = (getDefinitionByName(_clipName) as Class); _local1 = new GenericFactory(_local3, _local2, []); }; realEmitter.setFactory(_local1); SimpleParticles.configureEmitter(realEmitter, config); realEmitter.start(); realEmitter.x = x; realEmitter.y = y; if ((((parent is Sprite)) && (!(_rootClip)))){ realEmitter.root = parent; } else { realEmitter.root = stage; }; } public function set rootEffect(_arg1:Boolean):void{ _rootClip = _arg1; setupEmitter(); } public function setFactory(_arg1:IParticleFactory):void{ throw (new Error("MovieClip Emitter will worry about creating it's own factory based on the Flash authoring environment.")); } public function get movieClipName():String{ return (_clipName); } public function get config():String{ return (_config); } protected function onAdded(_arg1:Event):void{ if (PulseEngine.instance.root == null){ if (stage != null){ PulseEngine.instance.root = stage; } else { PulseEngine.instance.root = parent; }; }; setupEmitter(); } public function set config(_arg1:String):void{ _config = _arg1; setupEmitter(); } public function setSize(_arg1:Number, _arg2:Number):void{ trace(((("setSize: " + _arg1) + " ") + _arg2)); this.width = _arg1; this.height = _arg2; } protected function onRemoved(_arg1:Event):void{ realEmitter.stop(); } public function set movieClipName(_arg1:String):void{ _clipName = _arg1; setupEmitter(); } public function start():void{ realEmitter.start(); } protected function onEnterFrame(_arg1:Event):void{ var _local2:Point; if ((((realEmitter == null)) || ((realEmitter.root == null)))){ return; }; _local2 = localToGlobal(origin); _local2 = realEmitter.root.globalToLocal(_local2); realEmitter.x = _local2.x; realEmitter.y = _local2.y; } public function move(_arg1:Number, _arg2:Number):void{ trace(("moved " + _arg1)); } public function set pps(_arg1:Number):void{ realEmitter.pps = _arg1; } override public function set y(_arg1:Number):void{ super.y = _arg1; realEmitter.y = _arg1; } override public function set x(_arg1:Number):void{ super.x = _arg1; realEmitter.x = _arg1; } } }//package com.roguedevelopment.pulse.emitter
Section 84
//AngleRandomizerInitializer (com.roguedevelopment.pulse.initializers.AngleRandomizerInitializer) package com.roguedevelopment.pulse.initializers { public class AngleRandomizerInitializer extends ParameterRandomizerInitializer { public function AngleRandomizerInitializer(_arg1:Number, _arg2:Number){ super("angle", ((_arg1 * Math.PI) / 180), ((_arg2 * Math.PI) / 180), round); } } }//package com.roguedevelopment.pulse.initializers
Section 85
//IPulseInitializer (com.roguedevelopment.pulse.initializers.IPulseInitializer) package com.roguedevelopment.pulse.initializers { import com.roguedevelopment.pulse.particle.*; public interface IPulseInitializer { function init(_arg1:IParticle):void; } }//package com.roguedevelopment.pulse.initializers
Section 86
//ParameterInitializer (com.roguedevelopment.pulse.initializers.ParameterInitializer) package com.roguedevelopment.pulse.initializers { import com.roguedevelopment.pulse.particle.*; public class ParameterInitializer implements IPulseInitializer { protected var value:Object; protected var propName:String; public function ParameterInitializer(_arg1:String, _arg2:Object){ this.propName = _arg1; this.value = _arg2; } public function init(_arg1:IParticle):void{ var _local2:Object; _local2 = (_arg1 as Object); if (_local2.hasOwnProperty(propName)){ _local2[propName] = value; } else { if (_local2.hasOwnProperty("params")){ _local2.params[propName] = value; }; }; } } }//package com.roguedevelopment.pulse.initializers
Section 87
//ParameterRandomizerInitializer (com.roguedevelopment.pulse.initializers.ParameterRandomizerInitializer) package com.roguedevelopment.pulse.initializers { import com.roguedevelopment.pulse.particle.*; public class ParameterRandomizerInitializer implements IPulseInitializer { protected var maxValue:Number; protected var round:Boolean; protected var propName:String; protected var minValue:Number; public function ParameterRandomizerInitializer(_arg1:String, _arg2:Number, _arg3:Number, _arg4:Boolean=false){ this.minValue = _arg2; this.maxValue = _arg3; this.propName = _arg1; this.round = _arg4; } public function init(_arg1:IParticle):void{ var _local2:Object; var _local3:Number; _local2 = _arg1; _local3 = (minValue + (Math.random() * (maxValue - minValue))); if (round){ _local3 = Math.round(_local3); }; if (_local2.hasOwnProperty(propName)){ _local2[propName] = _local3; } else { if (_local2.hasOwnProperty("params")){ _local2.params[propName] = _local3; }; }; } } }//package com.roguedevelopment.pulse.initializers
Section 88
//RandomFrameInit (com.roguedevelopment.pulse.initializers.RandomFrameInit) package com.roguedevelopment.pulse.initializers { import com.roguedevelopment.pulse.particle.*; import flash.display.*; public class RandomFrameInit implements IPulseInitializer { public function init(_arg1:IParticle):void{ var mc:MovieClip; var particle = _arg1; if ((particle is MovieClip)){ mc = (particle as MovieClip); mc.gotoAndStop(Math.round((Math.random() * mc.totalFrames))); } else { if ((particle is Sprite)){ try { mc = ((particle as Sprite).getChildAt(0) as MovieClip); if (mc != null){ mc.gotoAndStop(Math.round((Math.random() * mc.totalFrames))); }; } catch(e:Error) { }; }; }; } } }//package com.roguedevelopment.pulse.initializers
Section 89
//ScaleRandomizerInitializer (com.roguedevelopment.pulse.initializers.ScaleRandomizerInitializer) package com.roguedevelopment.pulse.initializers { import com.roguedevelopment.pulse.particle.*; public class ScaleRandomizerInitializer implements IPulseInitializer { protected var maxValue:Number; protected var minValue:Number; public function ScaleRandomizerInitializer(_arg1:Number, _arg2:Number){ this.minValue = _arg1; this.maxValue = _arg2; } public function init(_arg1:IParticle):void{ var _local2:Object; var _local3:Number; _local2 = _arg1; _local3 = (minValue + (Math.random() * (maxValue - minValue))); _local2["scaleX"] = _local3; _local2["scaleY"] = _local3; } } }//package com.roguedevelopment.pulse.initializers
Section 90
//DotParticle (com.roguedevelopment.pulse.particle.DotParticle) package com.roguedevelopment.pulse.particle { public class DotParticle extends GenericParticle { protected var _color:uint;// = 0xFFFFFF protected var _size:Number;// = 1 public function DotParticle(){ _size = 1; _color = 0xFFFFFF; super(); redraw(); } protected function redraw():void{ graphics.clear(); graphics.beginFill(_color, 1); graphics.drawCircle(0, 0, _size); graphics.endFill(); } public function set size(_arg1:Number):void{ _size = _arg1; redraw(); } public function set color(_arg1:uint):void{ _color = _arg1; redraw(); } } }//package com.roguedevelopment.pulse.particle
Section 91
//GenericFactory (com.roguedevelopment.pulse.particle.GenericFactory) package com.roguedevelopment.pulse.particle { import flash.display.*; import com.roguedevelopment.pulse.initializers.*; public final class GenericFactory implements IParticleFactory { protected var partClass:Class; protected var recycled:Array; public var isRunning:Boolean;// = true protected var _initializers:Array; protected var _rules:Array; public function GenericFactory(_arg1:Class, _arg2:Array, _arg3:Array){ recycled = []; isRunning = true; super(); this.partClass = _arg1; _rules = _arg2; this.initializers = _arg3; } public function cleanup():void{ var _local1:IParticle; isRunning = false; for each (_local1 in recycled) { _local1.remove(); }; recycled = []; } public function newParticle():IParticle{ var _local1:IParticle; var _local2:IPulseInitializer; var _local3:Object; isRunning = true; if (recycled.length > 0){ _local1 = (recycled.shift() as IParticle); (_local1 as IRecyleableParticle).recycle(); } else { _local3 = new partClass(); if ((_local3 is IParticle)){ _local1 = (_local3 as IParticle); } else { if ((_local3 is Sprite)){ _local1 = new GenericParticle(); (_local1 as GenericParticle).addChild((_local3 as Sprite)); }; }; if ((_local1 is IRecyleableParticle)){ (_local1 as IRecyleableParticle).factory = this; }; }; _local1.rules = _rules.concat(); for each (_local2 in _initializers) { trace(_local2); _local2.init(_local1); }; return (_local1); } public function set initializers(_arg1:Array):void{ _initializers = _arg1; } public function recycle(_arg1:IParticle):void{ if (isRunning){ _arg1.visible = false; recycled.push(_arg1); } else { _arg1.remove(); }; } public function set rules(_arg1:Array):void{ _rules = _arg1; } } }//package com.roguedevelopment.pulse.particle
Section 92
//GenericParticle (com.roguedevelopment.pulse.particle.GenericParticle) package com.roguedevelopment.pulse.particle { import flash.display.*; import flash.geom.*; public class GenericParticle extends Sprite implements IRecyleableParticle { protected var _params:Object; protected var _birth:Number; protected var _factory:IParticleFactory; protected var _rules:Array; public function GenericParticle(){ _params = {angle:0, speed:0}; super(); _birth = new Date().time; } public function get rules():Array{ return (_rules); } public function set factory(_arg1:IParticleFactory):void{ _factory = _arg1; } public function get factory():IParticleFactory{ return (_factory); } public function get birthTime():Number{ return (_birth); } public function remove():void{ if (parent != null){ parent.removeChild(this); }; } public function get params():Object{ return (_params); } public function recycle():void{ _birth = new Date().time; scaleX = 1; rotation = 0; scaleY = 1; alpha = 1; visible = true; transform.colorTransform = new ColorTransform(); } public function set rules(_arg1:Array):void{ _rules = _arg1; } } }//package com.roguedevelopment.pulse.particle
Section 93
//ImageParticle (com.roguedevelopment.pulse.particle.ImageParticle) package com.roguedevelopment.pulse.particle { import flash.display.*; import flash.geom.*; public final class ImageParticle extends GenericParticle implements IRecyleableParticle { protected var imaged:Boolean;// = false public function ImageParticle(){ imaged = false; super(); } override public function recycle():void{ _birth = new Date().time; scaleX = 1; rotation = 0; scaleY = 1; alpha = 1; visible = true; transform.colorTransform = new ColorTransform(); } public function set image(_arg1:Class):void{ var _local2:Bitmap; if (imaged){ return; }; imaged = true; _local2 = new (_arg1); addChild(_local2); } } }//package com.roguedevelopment.pulse.particle
Section 94
//IParticle (com.roguedevelopment.pulse.particle.IParticle) package com.roguedevelopment.pulse.particle { public interface IParticle { function set alpha(_arg1:Number):void; function set visible(_arg1:Boolean):void; function get alpha():Number; function get params():Object; function get visible():Boolean; function set rotation(_arg1:Number):void; function get birthTime():Number; function get rotation():Number; function get scaleX():Number; function get scaleY():Number; function set x(_arg1:Number):void; function set y(_arg1:Number):void; function remove():void; function set rules(_arg1:Array):void; function get rules():Array; function get x():Number; function get y():Number; function set scaleX(_arg1:Number):void; function set scaleY(_arg1:Number):void; } }//package com.roguedevelopment.pulse.particle
Section 95
//IParticleFactory (com.roguedevelopment.pulse.particle.IParticleFactory) package com.roguedevelopment.pulse.particle { public interface IParticleFactory { function set initializers(_arg1:Array):void; function recycle(_arg1:IParticle):void; function cleanup():void; function newParticle():IParticle; function set rules(_arg1:Array):void; } }//package com.roguedevelopment.pulse.particle
Section 96
//IRecyleableParticle (com.roguedevelopment.pulse.particle.IRecyleableParticle) package com.roguedevelopment.pulse.particle { public interface IRecyleableParticle extends IParticle { function get factory():IParticleFactory; function recycle():void; function set factory(_arg1:IParticleFactory):void; } }//package com.roguedevelopment.pulse.particle
Section 97
//LineParticle (com.roguedevelopment.pulse.particle.LineParticle) package com.roguedevelopment.pulse.particle { public class LineParticle extends GenericParticle { protected var _color:uint;// = 0xFFFFFF protected var _size:Number;// = 1 public function LineParticle(){ _size = 1; _color = 0xFFFFFF; super(); redraw(); } protected function redraw():void{ graphics.clear(); graphics.lineStyle(1, _color); graphics.moveTo(0, 0); graphics.lineTo(_size, 0); } public function set size(_arg1:Number):void{ _size = _arg1; redraw(); } public function set color(_arg1:uint):void{ _color = _arg1; redraw(); } } }//package com.roguedevelopment.pulse.particle
Section 98
//AccelerationRule (com.roguedevelopment.pulse.rule.AccelerationRule) package com.roguedevelopment.pulse.rule { import com.roguedevelopment.pulse.particle.*; public final class AccelerationRule implements IPulseRule { protected var amount:Number;// = 1 public function AccelerationRule(_arg1:Number=1){ amount = 1; super(); this.amount = _arg1; } public function configure(_arg1:Array):void{ amount = _arg1[0]; } public function applyRule(_arg1:IParticle, _arg2:Number, _arg3:Number):void{ var _local4:Number; if (_arg1.params.hasOwnProperty("speed")){ _local4 = _arg1.params["speed"]; _local4 = (_local4 + amount); if ((((amount < 0)) && ((_local4 < 0)))){ _local4 = 0; }; }; _arg1.params["speed"] = _local4; } } }//package com.roguedevelopment.pulse.rule
Section 99
//BoundingBoxRule (com.roguedevelopment.pulse.rule.BoundingBoxRule) package com.roguedevelopment.pulse.rule { import com.roguedevelopment.pulse.particle.*; import flash.geom.*; public final class BoundingBoxRule implements IPulseRule { protected var box:Rectangle; public function BoundingBoxRule(_arg1:Rectangle=null){ this.box = _arg1; } public function applyRule(_arg1:IParticle, _arg2:Number, _arg3:Number):void{ var _local4:Number; var _local5:Number; var _local6:Number; var _local7:Number; _local4 = _arg1.params.angle; if ((((((((_arg1.x <= box.x)) && ((_local4 > (Math.PI / 2))))) && ((_local4 < ((3 * Math.PI) / 2))))) || ((((_arg1.x >= box.right)) && ((((_local4 > ((3 * Math.PI) / 2))) || ((_local4 < (Math.PI / 2))))))))){ _local5 = _arg1.params.speed; _local6 = (Math.cos(_local4) * _local5); _local7 = (Math.sin(_local4) * _local5); _local6 = (_local6 * -1); _local4 = Math.atan2(_local7, _local6); if (_local4 < 0){ _local4 = (_local4 + (2 * Math.PI)); }; if (_local4 > (2 * Math.PI)){ _local4 = (_local4 - (2 * Math.PI)); }; _arg1.params.angle = _local4; }; if ((((((((_arg1.y <= box.y)) && ((_local4 > Math.PI)))) && ((_local4 < (2 * Math.PI))))) || ((((((_arg1.y >= box.bottom)) && ((_local4 > 0)))) && ((_local4 < Math.PI)))))){ _local5 = _arg1.params.speed; _local6 = (Math.cos(_local4) * _local5); _local7 = (Math.sin(_local4) * _local5); _local7 = (_local7 * -1); _local4 = Math.atan2(_local7, _local6); if (_local4 < 0){ _local4 = (_local4 + (2 * Math.PI)); }; if (_local4 > 360){ _local4 = (_local4 - (2 * Math.PI)); }; _arg1.params.angle = _local4; }; } public function configure(_arg1:Array):void{ if (_arg1.length != 4){ return; }; box = new Rectangle(_arg1[0], _arg1[1], _arg1[2], _arg1[3]); } } }//package com.roguedevelopment.pulse.rule
Section 100
//ColorTransformRule (com.roguedevelopment.pulse.rule.ColorTransformRule) package com.roguedevelopment.pulse.rule { import com.roguedevelopment.pulse.particle.*; import flash.display.*; import flash.geom.*; public class ColorTransformRule implements IPulseRule { public var rMult:Number;// = 1 public var rOffset:Number;// = 0 public var endTime:Number; public var bMult:Number;// = 1 public var bOffset:Number;// = 0 public var startTime:Number; public var gMult:Number;// = 1 public var gOffset:Number;// = 0 public function ColorTransformRule(){ var _local1:ColorTransform; rMult = 1; gMult = 1; bMult = 1; rOffset = 0; gOffset = 0; bOffset = 0; super(); _local1 = new ColorTransform(); } public function configure(_arg1:Array):void{ if (_arg1.length != 8){ return; }; startTime = (_arg1.shift() as Number); endTime = (_arg1.shift() as Number); rMult = (_arg1.shift() as Number); gMult = (_arg1.shift() as Number); bMult = (_arg1.shift() as Number); rOffset = (_arg1.shift() as Number); gOffset = (_arg1.shift() as Number); bOffset = (_arg1.shift() as Number); } public function applyRule(_arg1:IParticle, _arg2:Number, _arg3:Number):void{ var _local4:Number; var _local5:DisplayObject; var _local6:Number; _local4 = (_arg2 - _arg1.birthTime); if ((((_local4 < startTime)) || ((_local4 > endTime)))){ return; }; _local5 = (_arg1 as DisplayObject); if (_local5 == null){ return; }; _local6 = ((_local4 - startTime) / (endTime - startTime)); _local5.transform.colorTransform = new ColorTransform((1 + ((rMult - 1) * _local6)), (1 + ((gMult - 1) * _local6)), (1 + ((bMult - 1) * _local6)), 1, (rOffset * _local6), (gOffset * _local6), (bOffset * _local6), 0); } } }//package com.roguedevelopment.pulse.rule
Section 101
//DeathRule (com.roguedevelopment.pulse.rule.DeathRule) package com.roguedevelopment.pulse.rule { import com.roguedevelopment.pulse.particle.*; import com.roguedevelopment.pulse.*; public final class DeathRule implements IPulseRule { protected var maxAge:Number; public function DeathRule(_arg1:Number=3000){ this.maxAge = _arg1; } public function applyRule(_arg1:IParticle, _arg2:Number, _arg3:Number):void{ if (_arg2 > (maxAge + _arg1.birthTime)){ PulseEngine.instance.removeParticle(_arg1); _arg1.rules.splice(_arg1.rules.indexOf(this), 1); }; } public function configure(_arg1:Array):void{ maxAge = (_arg1[0] as Number); } } }//package com.roguedevelopment.pulse.rule
Section 102
//FadeRule (com.roguedevelopment.pulse.rule.FadeRule) package com.roguedevelopment.pulse.rule { import com.roguedevelopment.pulse.particle.*; public final class FadeRule implements IPulseRule { protected var maxAge:Number; public function FadeRule(_arg1:Number=3000){ this.maxAge = _arg1; } public function applyRule(_arg1:IParticle, _arg2:Number, _arg3:Number):void{ var _local4:Number; if (_arg2 == _arg1.birthTime){ return; }; _local4 = (_arg2 - _arg1.birthTime); if (_local4 > maxAge){ _arg1.rules.splice(_arg1.rules.indexOf(this), 1); return; }; _arg1.alpha = (1 - (_local4 / maxAge)); } public function configure(_arg1:Array):void{ maxAge = (_arg1[0] as Number); } } }//package com.roguedevelopment.pulse.rule
Section 103
//GravityRule (com.roguedevelopment.pulse.rule.GravityRule) package com.roguedevelopment.pulse.rule { import com.roguedevelopment.pulse.particle.*; public final class GravityRule implements IPulseRule { protected var gravityAmount:Number; public function GravityRule(_arg1:Number=5){ this.gravityAmount = _arg1; } public function applyRule(_arg1:IParticle, _arg2:Number, _arg3:Number):void{ var _local4:Number; var _local5:Number; var _local6:Number; var _local7:Number; _local4 = _arg1.params.speed; _local5 = _arg1.params.angle; _local6 = (Math.cos(_local5) * _local4); _local7 = ((Math.sin(_local5) * _local4) + gravityAmount); _local5 = Math.atan2(_local7, _local6); if (_local5 < 0){ _local5 = (_local5 + (2 * Math.PI)); }; if (_local5 > (2 * Math.PI)){ _local5 = (_local5 - (2 * Math.PI)); }; _arg1.params.angle = _local5; _arg1.params.speed = Math.sqrt(((_local6 * _local6) + (_local7 * _local7))); } public function configure(_arg1:Array):void{ gravityAmount = (_arg1[0] as Number); } } }//package com.roguedevelopment.pulse.rule
Section 104
//IPulseRule (com.roguedevelopment.pulse.rule.IPulseRule) package com.roguedevelopment.pulse.rule { import com.roguedevelopment.pulse.particle.*; public interface IPulseRule { function configure(_arg1:Array):void; function applyRule(_arg1:IParticle, _arg2:Number, _arg3:Number):void; } }//package com.roguedevelopment.pulse.rule
Section 105
//MouseSwarmRule (com.roguedevelopment.pulse.rule.MouseSwarmRule) package com.roguedevelopment.pulse.rule { import com.roguedevelopment.pulse.particle.*; import flash.display.*; import flash.events.*; import flash.geom.*; public final class MouseSwarmRule implements IPulseRule { protected var mouse:Point; public function MouseSwarmRule(_arg1:Stage=null){ mouse = new Point(); super(); if (_arg1 != null){ _arg1.addEventListener(MouseEvent.MOUSE_MOVE, onMouseMove); }; } public function configure(_arg1:Array):void{ (_arg1[0] as Stage).addEventListener(MouseEvent.MOUSE_MOVE, onMouseMove); } public function applyRule(_arg1:IParticle, _arg2:Number, _arg3:Number):void{ var _local4:Number; var _local5:Number; _local4 = Math.atan2((mouse.y - _arg1.y), (mouse.x - _arg1.x)); if (_local4 < 0){ _local4 = (_local4 + (2 * Math.PI)); }; if (_arg1.params.angle < 0){ _arg1.params.angle = (_arg1.params.angle + (2 * Math.PI)); }; if (_arg1.params.angle > (2 * Math.PI)){ _arg1.params.angle = (_arg1.params.angle - (2 * Math.PI)); }; _local5 = (_arg1.params.angle - _local4); if ((((((_local5 > 0)) && ((_local5 <= Math.PI)))) || ((_local5 < -(Math.PI))))){ _arg1.params.angle = (_arg1.params.angle - Math.min(0.1, Math.abs(_local5))); } else { if ((((((_local5 >= -(Math.PI))) && ((_local5 < 0)))) || ((_local5 > Math.PI)))){ _arg1.params.angle = (_arg1.params.angle + Math.min(0.1, Math.abs(_local5))); }; }; } protected function onMouseMove(_arg1:MouseEvent):void{ mouse.x = _arg1.stageX; mouse.y = _arg1.stageY; } } }//package com.roguedevelopment.pulse.rule
Section 106
//MovementRule (com.roguedevelopment.pulse.rule.MovementRule) package com.roguedevelopment.pulse.rule { import com.roguedevelopment.pulse.particle.*; import com.roguedevelopment.pulse.*; public final class MovementRule implements IPulseRule { public function configure(_arg1:Array):void{ } public function applyRule(_arg1:IParticle, _arg2:Number, _arg3:Number):void{ var _local4:Number; var _local5:Number; var _local6:Number; var _local7:Number; var _local8:Number; _local4 = 1; _local5 = 0; if (_arg1.params.hasOwnProperty("speed")){ _local4 = _arg1.params["speed"]; }; if (_arg1.params.hasOwnProperty("angle")){ _local5 = _arg1.params["angle"]; }; _local6 = ((PulseEngine.PARTICLE_LOOP_TIME / 1000) * _local4); _local7 = (Math.cos(_local5) * _local6); _local8 = (Math.sin(_local5) * _local6); _arg1.x = (_arg1.x + _local7); _arg1.y = (_arg1.y + _local8); } } }//package com.roguedevelopment.pulse.rule
Section 107
//MovementStopRule (com.roguedevelopment.pulse.rule.MovementStopRule) package com.roguedevelopment.pulse.rule { import com.roguedevelopment.pulse.particle.*; import flash.geom.*; public final class MovementStopRule implements IPulseRule { protected var box:Rectangle; public function MovementStopRule(_arg1:Rectangle=null){ this.box = _arg1; } public function applyRule(_arg1:IParticle, _arg2:Number, _arg3:Number):void{ var _local4:IPulseRule; var _local5:int; if (box.contains(_arg1.x, _arg1.y)){ for each (_local4 in _arg1.rules) { if ((_local4 is MovementRule)){ _local5 = _arg1.rules.lastIndexOf(_local4); _arg1.rules.splice(_local5, 1); }; }; _arg1.params.speed = 0; }; } public function configure(_arg1:Array):void{ if (_arg1.length != 4){ return; }; box = new Rectangle(_arg1[0], _arg1[1], _arg1[2], _arg1[3]); } } }//package com.roguedevelopment.pulse.rule
Section 108
//PointSwarmRule (com.roguedevelopment.pulse.rule.PointSwarmRule) package com.roguedevelopment.pulse.rule { import com.roguedevelopment.pulse.particle.*; import flash.geom.*; public final class PointSwarmRule implements IPulseRule { protected var dest:Point; public function PointSwarmRule(_arg1:Point=null){ dest = new Point(); super(); if (_arg1 != null){ dest = _arg1; }; } public function configure(_arg1:Array):void{ if ((_arg1[0] is Point)){ dest = (_arg1[0] as Point); } else { dest.x = (_arg1[0] as Number); dest.y = (_arg1[1] as Number); }; } public function applyRule(_arg1:IParticle, _arg2:Number, _arg3:Number):void{ var _local4:Number; var _local5:Number; _local4 = Math.atan2((dest.y - _arg1.y), (dest.x - _arg1.x)); if (_local4 < 0){ _local4 = (_local4 + (2 * Math.PI)); }; if (_arg1.params.angle < 0){ _arg1.params.angle = (_arg1.params.angle + (2 * Math.PI)); }; if (_arg1.params.angle > (2 * Math.PI)){ _arg1.params.angle = (_arg1.params.angle - (2 * Math.PI)); }; _local5 = (_arg1.params.angle - _local4); if ((((((_local5 > 0)) && ((_local5 <= Math.PI)))) || ((_local5 < -(Math.PI))))){ _arg1.params.angle = (_arg1.params.angle - Math.min(0.1, Math.abs(_local5))); } else { if ((((((_local5 >= -(Math.PI))) && ((_local5 < 0)))) || ((_local5 > Math.PI)))){ _arg1.params.angle = (_arg1.params.angle + Math.min(0.1, Math.abs(_local5))); }; }; } } }//package com.roguedevelopment.pulse.rule
Section 109
//RotateRule (com.roguedevelopment.pulse.rule.RotateRule) package com.roguedevelopment.pulse.rule { import com.roguedevelopment.pulse.particle.*; public final class RotateRule implements IPulseRule { protected var min:Number; protected var max:Number; public function RotateRule(_arg1:Number=1, _arg2:Number=3){ this.min = _arg1; this.max = _arg2; } public function configure(_arg1:Array):void{ min = (_arg1[0] as Number); max = (_arg1[1] as Number); } public function applyRule(_arg1:IParticle, _arg2:Number, _arg3:Number):void{ if (!_arg1.params.hasOwnProperty("rotationSpeed")){ _arg1.params["rotationSpeed"] = (min + (Math.random() * (max - min))); }; _arg1.rotation = (_arg1.rotation + _arg1.params["rotationSpeed"]); } } }//package com.roguedevelopment.pulse.rule
Section 110
//RotateToAngleRule (com.roguedevelopment.pulse.rule.RotateToAngleRule) package com.roguedevelopment.pulse.rule { import com.roguedevelopment.pulse.particle.*; public final class RotateToAngleRule implements IPulseRule { public function configure(_arg1:Array):void{ } public function applyRule(_arg1:IParticle, _arg2:Number, _arg3:Number):void{ _arg1.rotation = ((_arg1.params.angle * 180) / Math.PI); } } }//package com.roguedevelopment.pulse.rule
Section 111
//ScaleRule (com.roguedevelopment.pulse.rule.ScaleRule) package com.roguedevelopment.pulse.rule { import com.roguedevelopment.pulse.particle.*; import com.roguedevelopment.*; public final class ScaleRule implements IPulseRule { protected var startScale:Number; protected var targetScale:Number; protected var maxAge:Number; public function ScaleRule(_arg1:Number=3000, _arg2:Number=1, _arg3:Number=5){ this.maxAge = _arg1; this.targetScale = _arg3; this.startScale = _arg2; } public function configure(_arg1:Array):void{ maxAge = (_arg1[0] as Number); startScale = (_arg1[1] as Number); targetScale = (_arg1[2] as Number); } public function applyRule(_arg1:IParticle, _arg2:Number, _arg3:Number):void{ var _local4:Number; _local4 = (_arg2 - _arg1.birthTime); if (_local4 > maxAge){ _arg1.rules.splice(_arg1.rules.indexOf(this), 1); return; }; if (startScale > targetScale){ _arg1.scaleX = (startScale - PennerEasing.sineEaseInOut(_local4, targetScale, startScale, maxAge)); } else { _arg1.scaleX = PennerEasing.sineEaseInOut(_local4, startScale, targetScale, maxAge); }; _arg1.scaleY = _arg1.scaleX; } } }//package com.roguedevelopment.pulse.rule
Section 112
//TweenRule (com.roguedevelopment.pulse.rule.TweenRule) package com.roguedevelopment.pulse.rule { import com.roguedevelopment.pulse.particle.*; import com.roguedevelopment.*; public final class TweenRule implements IPulseRule { protected var start:Number; protected var maxAge:Number; protected var ease:Function; protected var field:String; protected var end:Number; public function TweenRule(_arg1:String="", _arg2:Number=1, _arg3:Number=1, _arg4:Number=1, _arg5:Function=null){ this.field = _arg1; this.start = _arg2; this.end = _arg3; this.maxAge = _arg4; this.ease = _arg5; if (this.ease == null){ this.ease = PennerEasing.linearEaseNone; }; } public function configure(_arg1:Array):void{ field = _arg1[0]; start = _arg1[1]; end = _arg1[2]; maxAge = _arg1[3]; } public function applyRule(_arg1:IParticle, _arg2:Number, _arg3:Number):void{ var _local4:Number; var _local5:Object; _local4 = (_arg2 - _arg1.birthTime); if (_local4 > maxAge){ _arg1.rules.splice(_arg1.rules.indexOf(this), 1); return; }; _local5 = _arg1; if (end > start){ _local5[field] = ease(_local4, start, end, maxAge); } else { _local5[field] = (start - ease(_local4, end, start, maxAge)); }; } } }//package com.roguedevelopment.pulse.rule
Section 113
//XOscillatorRule (com.roguedevelopment.pulse.rule.XOscillatorRule) package com.roguedevelopment.pulse.rule { import com.roguedevelopment.pulse.particle.*; public final class XOscillatorRule implements IPulseRule { protected var amount:Number;// = 5 protected var dampen:Number;// = 100 public function XOscillatorRule(_arg1:Number=1, _arg2:Number=100){ amount = 5; dampen = 100; super(); this.amount = _arg1; this.dampen = _arg2; } public function configure(_arg1:Array):void{ amount = (_arg1[0] as Number); dampen = (_arg1[1] as Number); } public function applyRule(_arg1:IParticle, _arg2:Number, _arg3:Number):void{ _arg1.x = (_arg1.x + (Math.cos(((_arg2 - _arg1.birthTime) / dampen)) * amount)); } } }//package com.roguedevelopment.pulse.rule
Section 114
//SimpleParticles (com.roguedevelopment.pulse.simple.SimpleParticles) package com.roguedevelopment.pulse.simple { import com.roguedevelopment.pulse.particle.*; import flash.display.*; import com.roguedevelopment.pulse.emitter.*; import com.roguedevelopment.pulse.*; import com.adobe.serialization.json.*; import com.roguedevelopment.pulse.rule.*; import com.roguedevelopment.pulse.initializers.*; public class SimpleParticles { protected static var rules:Object = {scale:ScaleRule, fade:FadeRule, gravity:GravityRule, movement:MovementRule, lifespan:DeathRule, mouseSwarm:MouseSwarmRule, rotateToAngle:RotateToAngleRule, xOscillate:XOscillatorRule, tween:TweenRule, pointSwarm:PointSwarmRule, rotate:RotateRule, accel:AccelerationRule, bound:BoundingBoxRule, stop:MovementStopRule, colorTransform:ColorTransformRule}; public static function createEmitter(_arg1:Object):IParticleEmitter{ var _local2:GenericEmitter; var _local3:int; var _local4:BitmapData; var _local5:Bitmap; _local3 = 10; if (_arg1.hasOwnProperty("pps")){ _local3 = _arg1.pps; }; if (((_arg1.hasOwnProperty("bme")) && (_arg1.bme))){ _local4 = new BitmapData(PulseEngine.instance.root.stage.width, PulseEngine.instance.root.stage.height, true, 0); _local5 = new Bitmap(_local4); PulseEngine.instance.root.addChild(_local5); _local2 = new BitmapEmitter(_local3, _local4); } else { _local2 = new GenericEmitter(_local3); }; configureEmitterByObject(_local2, _arg1); return (_local2); } protected static function doInitializer(_arg1:String, _arg2:Object, _arg3:Array):Boolean{ var _local4:Array; _local4 = (_arg2 as Array); switch (_arg1){ case "startScale": _arg3.push(new ScaleRandomizerInitializer(_local4[0], _local4[1])); return (true); case "angle": _arg3.push(new AngleRandomizerInitializer(_local4[0], _local4[1])); return (true); case "randomFrame": _arg3.push(new RandomFrameInit()); return (true); }; return (false); } public static function configureEmitter(_arg1:GenericEmitter, _arg2:String):IParticleEmitter{ var r:RegExp; var d:JSONDecoder; var o:Object; var emitter = _arg1; var params = _arg2; try { r = /([a-zA-Z0-9_]+):/g; params = params.replace(r, "\"$1\":"); d = new JSONDecoder(params); o = d.getValue(); } catch(e:Error) { return (emitter); }; return (configureEmitterByObject(emitter, o)); } protected static function createLineFactory(_arg1:Object, _arg2:Array, _arg3:Array):IParticleFactory{ return (new GenericFactory(LineParticle, _arg2, _arg3)); } protected static function createImageFactory(_arg1:Object, _arg2:Array, _arg3:Array):IParticleFactory{ return (new GenericFactory(ImageParticle, _arg2, _arg3)); } protected static function createDotFactory(_arg1:Object, _arg2:Array, _arg3:Array):IParticleFactory{ return (new GenericFactory(DotParticle, _arg2, _arg3)); } public static function configureEmitterByObject(_arg1:GenericEmitter, _arg2:Object):IParticleEmitter{ var _local3:Boolean; var _local4:IParticleFactory; var _local5:Array; var _local6:Array; var _local7:String; var _local8:Array; _local3 = true; _local4 = _arg1.getFactory(); _local5 = []; _local6 = []; if (((_arg2.hasOwnProperty("minSpeed")) && (_arg2.hasOwnProperty("maxSpeed")))){ _local6.push(new ParameterRandomizerInitializer("speed", _arg2.minSpeed, _arg2.maxSpeed, true)); }; if (((_arg2.hasOwnProperty("minAngle")) && (_arg2.hasOwnProperty("maxAngle")))){ _local6.push(new AngleRandomizerInitializer(_arg2.minAngle, _arg2.maxAngle)); }; if (((_arg2.hasOwnProperty("minScale")) && (_arg2.hasOwnProperty("maxScale")))){ _local6.push(new ScaleRandomizerInitializer(_arg2.minScale, _arg2.maxScale)); }; for (_local7 in _arg2) { switch (_local7){ case "start": _local3 = _arg2.start; break; case "x": _arg1.x = _arg2.x; break; case "y": _arg1.y = _arg2.y; break; case "dot": _local4 = createDotFactory(_arg2[_local7], _local5, _local6); break; case "line": _local4 = createLineFactory(_arg2[_local7], _local5, _local6); break; case "image": _local6.push(new ParameterInitializer("image", _arg2[_local7])); _local4 = createImageFactory(_arg2[_local7], _local5, _local6); break; case "width": _arg1.width = (_arg2[_local7] as Number); break; case "height": _arg1.height = (_arg2[_local7] as Number); break; case "limit": _arg1.particleLimit = (_arg2[_local7] as Number); break; default: if (((!(doRule(_local7, _arg2[_local7], _local5))) && (!(doInitializer(_local7, _arg2[_local7], _local6))))){ if ((_arg2[_local7] is Array)){ _local8 = (_arg2[_local7] as Array); _local6.push(new ParameterRandomizerInitializer(_local7, _local8[0], _local8[1], true)); }; if ((_arg2[_local7] is Number)){ _local6.push(new ParameterInitializer(_local7, (_arg2[_local7] as Number))); }; }; break; }; }; if (_local4 == null){ _local4 = createDotFactory(null, _local5, _local6); } else { _local4.rules = _local5; _local4.initializers = _local6; }; _arg1.setFactory(_local4); if (_local3){ _arg1.start(); }; return (_arg1); } protected static function doRule(_arg1:String, _arg2:Object, _arg3:Array):Boolean{ var _local4:Class; var _local5:IPulseRule; if (!rules.hasOwnProperty(_arg1)){ return (false); }; _local4 = rules[_arg1]; _local5 = new (_local4); if ((_arg2 is Array)){ _local5.configure((_arg2 as Array)); } else { _local5.configure([_arg2]); }; _arg3.push(_local5); return (true); } } }//package com.roguedevelopment.pulse.simple
Section 115
//PulseEngine (com.roguedevelopment.pulse.PulseEngine) package com.roguedevelopment.pulse { import com.roguedevelopment.pulse.particle.*; import flash.display.*; import flash.events.*; import flash.utils.*; import com.roguedevelopment.pulse.rule.*; public final class PulseEngine { public var root:DisplayObjectContainer; protected var timer:Timer; protected var emitters:Array; protected var particles:Array; public var updateAfterTimer:Boolean;// = false protected var lastUpdate:Number; public static const PARTICLE_LOOP_TIME:Number = 30; protected static var _instance:PulseEngine; public function PulseEngine(){ emitters = []; particles = []; updateAfterTimer = false; super(); if (_instance != null){ throw (new Error("only one engine allowed")); }; timer = new Timer(PARTICLE_LOOP_TIME); timer.addEventListener(TimerEvent.TIMER, onTime); timer.start(); lastUpdate = new Date().time; } public function addParticle(_arg1:IParticle):void{ _arg1.visible = false; particles.push(_arg1); } public function addEmitter(_arg1:IParticleFactory):void{ emitters.push(_arg1); } public function removeParticle(_arg1:IParticle):void{ particles.splice(particles.indexOf(_arg1), 1); if ((_arg1 is IRecyleableParticle)){ (_arg1 as IRecyleableParticle).factory.recycle(_arg1); } else { _arg1.remove(); }; } protected function onTime(_arg1:TimerEvent):void{ var _local2:Date; var _local3:IParticle; var _local4:IPulseRule; _local2 = new Date(); for each (_local3 in particles) { _local3.visible = true; for each (_local4 in _local3.rules) { _local4.applyRule(_local3, _local2.time, lastUpdate); }; }; lastUpdate = _local2.time; if (updateAfterTimer){ _arg1.updateAfterEvent(); }; } public function stopAndRemoveAllParticles():void{ var _local1:IParticle; for each (_local1 in particles) { _local1.remove(); }; particles = []; } public static function get instance():PulseEngine{ if (_instance == null){ _instance = new (PulseEngine); }; return (_instance); } } }//package com.roguedevelopment.pulse
Section 116
//PennerEasing (com.roguedevelopment.PennerEasing) package com.roguedevelopment { public class PennerEasing { public static function quartEaseOut(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ _arg1 = ((_arg1 / _arg4) - 1); return (((-(_arg3) * ((((_arg1 * _arg1) * _arg1) * _arg1) - 1)) + _arg2)); } public static function circEaseInOut(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ _arg1 = (_arg1 / (_arg4 / 2)); if (_arg1 < 1){ return ((((-(_arg3) / 2) * (Math.sqrt((1 - (_arg1 * _arg1))) - 1)) + _arg2)); }; _arg1 = (_arg1 - 2); return ((((_arg3 / 2) * (Math.sqrt((1 - (_arg1 * _arg1))) + 1)) + _arg2)); } public static function expoEaseIn(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ return (((_arg1)==0) ? _arg2 : ((_arg3 * Math.pow(2, (10 * ((_arg1 / _arg4) - 1)))) + _arg2)); } public static function elasticEaseInOut(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Number, _arg6:Number):Number{ var _local7:Number; if (_arg1 == 0){ return (_arg2); }; _arg1 = (_arg1 / (_arg4 / 2)); if (_arg1 == 2){ return ((_arg2 + _arg3)); }; if (!_arg6){ _arg6 = (_arg4 * (0.3 * 1.5)); }; if (((!(_arg5)) || ((_arg5 < Math.abs(_arg3))))){ _arg5 = _arg3; _local7 = (_arg6 / 4); } else { _local7 = ((_arg6 / (2 * Math.PI)) * Math.asin((_arg3 / _arg5))); }; if (_arg1 < 1){ --_arg1; return (((-0.5 * ((_arg5 * Math.pow(2, (10 * _arg1))) * Math.sin(((((_arg1 * _arg4) - _local7) * (2 * Math.PI)) / _arg6)))) + _arg2)); }; --_arg1; return ((((((_arg5 * Math.pow(2, (-10 * _arg1))) * Math.sin(((((_arg1 * _arg4) - _local7) * (2 * Math.PI)) / _arg6))) * 0.5) + _arg3) + _arg2)); } public static function expoEaseInOut(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ if (_arg1 == 0){ return (_arg2); }; if (_arg1 == _arg4){ return ((_arg2 + _arg3)); }; _arg1 = (_arg1 / (_arg4 / 2)); if (_arg1 < 1){ return ((((_arg3 / 2) * Math.pow(2, (10 * (_arg1 - 1)))) + _arg2)); }; --_arg1; return ((((_arg3 / 2) * (-(Math.pow(2, (-10 * _arg1))) + 2)) + _arg2)); } public static function linearEaseNone(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ return ((((_arg3 * _arg1) / _arg4) + _arg2)); } public static function sineEaseInOut(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ return ((((-(_arg3) / 2) * (Math.cos(((Math.PI * _arg1) / _arg4)) - 1)) + _arg2)); } public static function quintEaseInOut(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ _arg1 = (_arg1 / (_arg4 / 2)); if (_arg1 < 1){ return ((((((((_arg3 / 2) * _arg1) * _arg1) * _arg1) * _arg1) * _arg1) + _arg2)); }; _arg1 = (_arg1 - 2); return ((((_arg3 / 2) * (((((_arg1 * _arg1) * _arg1) * _arg1) * _arg1) + 2)) + _arg2)); } public static function quartEaseIn(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ _arg1 = (_arg1 / _arg4); return ((((((_arg3 * _arg1) * _arg1) * _arg1) * _arg1) + _arg2)); } public static function quadEaseInOut(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ _arg1 = (_arg1 / (_arg4 / 2)); if (_arg1 < 1){ return (((((_arg3 / 2) * _arg1) * _arg1) + _arg2)); }; --_arg1; return ((((-(_arg3) / 2) * ((_arg1 * (_arg1 - 2)) - 1)) + _arg2)); } public static function cubicEaseOut(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ _arg1 = ((_arg1 / _arg4) - 1); return (((_arg3 * (((_arg1 * _arg1) * _arg1) + 1)) + _arg2)); } public static function bounceEaseOut(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ _arg1 = (_arg1 / _arg4); if (_arg1 < (1 / 2.75)){ return (((_arg3 * ((7.5625 * _arg1) * _arg1)) + _arg2)); }; if (_arg1 < (2 / 2.75)){ _arg1 = (_arg1 - (1.5 / 2.75)); return (((_arg3 * (((7.5625 * _arg1) * _arg1) + 0.75)) + _arg2)); }; if (_arg1 < (2.5 / 2.75)){ _arg1 = (_arg1 - (2.25 / 2.75)); return (((_arg3 * (((7.5625 * _arg1) * _arg1) + 0.9375)) + _arg2)); }; _arg1 = (_arg1 - (2.625 / 2.75)); return (((_arg3 * (((7.5625 * _arg1) * _arg1) + 0.984375)) + _arg2)); } public static function backEaseOut(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Number=1.70158):Number{ _arg1 = ((_arg1 / _arg4) - 1); return (((_arg3 * (((_arg1 * _arg1) * (((_arg5 + 1) * _arg1) + _arg5)) + 1)) + _arg2)); } public static function quadEaseIn(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ _arg1 = (_arg1 / _arg4); return ((((_arg3 * _arg1) * _arg1) + _arg2)); } public static function bounceEaseIn(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ return (((_arg3 - bounceEaseOut((_arg4 - _arg1), 0, _arg3, _arg4)) + _arg2)); } public static function quartEaseInOut(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ _arg1 = (_arg1 / (_arg4 / 2)); if (_arg1 < 1){ return (((((((_arg3 / 2) * _arg1) * _arg1) * _arg1) * _arg1) + _arg2)); }; _arg1 = (_arg1 - 2); return ((((-(_arg3) / 2) * ((((_arg1 * _arg1) * _arg1) * _arg1) - 2)) + _arg2)); } public static function cubicEaseIn(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ _arg1 = (_arg1 / _arg4); return (((((_arg3 * _arg1) * _arg1) * _arg1) + _arg2)); } public static function quintEaseIn(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ _arg1 = (_arg1 / _arg4); return (((((((_arg3 * _arg1) * _arg1) * _arg1) * _arg1) * _arg1) + _arg2)); } public static function sineEaseIn(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ return ((((-(_arg3) * Math.cos(((_arg1 / _arg4) * (Math.PI / 2)))) + _arg3) + _arg2)); } public static function backEaseIn(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Number=1.70158):Number{ _arg1 = (_arg1 / _arg4); return (((((_arg3 * _arg1) * _arg1) * (((_arg5 + 1) * _arg1) - _arg5)) + _arg2)); } public static function elasticEaseIn(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Number, _arg6:Number):Number{ var _local7:Number; if (_arg1 == 0){ return (_arg2); }; _arg1 = (_arg1 / _arg4); if (_arg1 == 1){ return ((_arg2 + _arg3)); }; if (!_arg6){ _arg6 = (_arg4 * 0.3); }; if (((!(_arg5)) || ((_arg5 < Math.abs(_arg3))))){ _arg5 = _arg3; _local7 = (_arg6 / 4); } else { _local7 = ((_arg6 / (2 * Math.PI)) * Math.asin((_arg3 / _arg5))); }; --_arg1; return ((-(((_arg5 * Math.pow(2, (10 * _arg1))) * Math.sin(((((_arg1 * _arg4) - _local7) * (2 * Math.PI)) / _arg6)))) + _arg2)); } public static function circEaseOut(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ _arg1 = ((_arg1 / _arg4) - 1); return (((_arg3 * Math.sqrt((1 - (_arg1 * _arg1)))) + _arg2)); } public static function circEaseIn(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ _arg1 = (_arg1 / _arg4); return (((-(_arg3) * (Math.sqrt((1 - (_arg1 * _arg1))) - 1)) + _arg2)); } public static function elasticEaseOut(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Number, _arg6:Number):Number{ var _local7:Number; if (_arg1 == 0){ return (_arg2); }; _arg1 = (_arg1 / _arg4); if (_arg1 == 1){ return ((_arg2 + _arg3)); }; if (!_arg6){ _arg6 = (_arg4 * 0.3); }; if (((!(_arg5)) || ((_arg5 < Math.abs(_arg3))))){ _arg5 = _arg3; _local7 = (_arg6 / 4); } else { _local7 = ((_arg6 / (2 * Math.PI)) * Math.asin((_arg3 / _arg5))); }; return (((((_arg5 * Math.pow(2, (-10 * _arg1))) * Math.sin(((((_arg1 * _arg4) - _local7) * (2 * Math.PI)) / _arg6))) + _arg3) + _arg2)); } public static function expoEaseOut(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ return (((_arg1)==_arg4) ? (_arg2 + _arg3) : ((_arg3 * (-(Math.pow(2, ((-10 * _arg1) / _arg4))) + 1)) + _arg2)); } public static function cubicEaseInOut(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ _arg1 = (_arg1 / (_arg4 / 2)); if (_arg1 < 1){ return ((((((_arg3 / 2) * _arg1) * _arg1) * _arg1) + _arg2)); }; _arg1 = (_arg1 - 2); return ((((_arg3 / 2) * (((_arg1 * _arg1) * _arg1) + 2)) + _arg2)); } public static function sineEaseOut(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ return (((_arg3 * Math.sin(((_arg1 / _arg4) * (Math.PI / 2)))) + _arg2)); } public static function backEaseInOut(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number, _arg5:Number=1.70158):Number{ _arg1 = (_arg1 / (_arg4 / 2)); if (_arg1 < 1){ _arg5 = (_arg5 * 1.525); return ((((_arg3 / 2) * ((_arg1 * _arg1) * (((_arg5 + 1) * _arg1) - _arg5))) + _arg2)); }; _arg1 = (_arg1 - 2); _arg5 = (_arg5 * 1.525); return ((((_arg3 / 2) * (((_arg1 * _arg1) * (((_arg5 + 1) * _arg1) + _arg5)) + 2)) + _arg2)); } public static function quintEaseOut(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ _arg1 = ((_arg1 / _arg4) - 1); return (((_arg3 * (((((_arg1 * _arg1) * _arg1) * _arg1) * _arg1) + 1)) + _arg2)); } public static function quadEaseOut(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ _arg1 = (_arg1 / _arg4); return ((((-(_arg3) * _arg1) * (_arg1 - 2)) + _arg2)); } public static function bounceEaseInOut(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number):Number{ if (_arg1 < (_arg4 / 2)){ return (((bounceEaseIn((_arg1 * 2), 0, _arg3, _arg4) * 0.5) + _arg2)); }; return ((((bounceEaseOut(((_arg1 * 2) - _arg4), 0, _arg3, _arg4) * 0.5) + (_arg3 * 0.5)) + _arg2)); } } }//package com.roguedevelopment
Section 117
//BaseScrollPane (fl.containers.BaseScrollPane) package fl.containers { import fl.core.*; import fl.controls.*; import flash.display.*; import flash.events.*; import flash.geom.*; import fl.events.*; public class BaseScrollPane extends UIComponent { protected var defaultLineScrollSize:Number;// = 4 protected var _maxHorizontalScrollPosition:Number;// = 0 protected var vScrollBar:Boolean; protected var disabledOverlay:Shape; protected var hScrollBar:Boolean; protected var availableWidth:Number; protected var _verticalPageScrollSize:Number;// = 0 protected var vOffset:Number;// = 0 protected var _verticalScrollBar:ScrollBar; protected var useFixedHorizontalScrolling:Boolean;// = false protected var contentWidth:Number;// = 0 protected var contentHeight:Number;// = 0 protected var _horizontalPageScrollSize:Number;// = 0 protected var background:DisplayObject; protected var _useBitmpScrolling:Boolean;// = false protected var contentPadding:Number;// = 0 protected var availableHeight:Number; protected var _horizontalScrollBar:ScrollBar; protected var contentScrollRect:Rectangle; protected var _horizontalScrollPolicy:String; protected var _verticalScrollPolicy:String; protected static const SCROLL_BAR_STYLES:Object = {upArrowDisabledSkin:"upArrowDisabledSkin", upArrowDownSkin:"upArrowDownSkin", upArrowOverSkin:"upArrowOverSkin", upArrowUpSkin:"upArrowUpSkin", downArrowDisabledSkin:"downArrowDisabledSkin", downArrowDownSkin:"downArrowDownSkin", downArrowOverSkin:"downArrowOverSkin", downArrowUpSkin:"downArrowUpSkin", thumbDisabledSkin:"thumbDisabledSkin", thumbDownSkin:"thumbDownSkin", thumbOverSkin:"thumbOverSkin", thumbUpSkin:"thumbUpSkin", thumbIcon:"thumbIcon", trackDisabledSkin:"trackDisabledSkin", trackDownSkin:"trackDownSkin", trackOverSkin:"trackOverSkin", trackUpSkin:"trackUpSkin", repeatDelay:"repeatDelay", repeatInterval:"repeatInterval"}; private static var defaultStyles:Object = {repeatDelay:500, repeatInterval:35, skin:"ScrollPane_upSkin", contentPadding:0, disabledAlpha:0.5}; public function BaseScrollPane(){ contentWidth = 0; contentHeight = 0; contentPadding = 0; vOffset = 0; _maxHorizontalScrollPosition = 0; _horizontalPageScrollSize = 0; _verticalPageScrollSize = 0; defaultLineScrollSize = 4; useFixedHorizontalScrolling = false; _useBitmpScrolling = false; super(); } protected function handleWheel(_arg1:MouseEvent):void{ if (((((!(enabled)) || (!(_verticalScrollBar.visible)))) || ((contentHeight <= availableHeight)))){ return; }; _verticalScrollBar.scrollPosition = (_verticalScrollBar.scrollPosition - (_arg1.delta * verticalLineScrollSize)); setVerticalScrollPosition(_verticalScrollBar.scrollPosition); dispatchEvent(new ScrollEvent(ScrollBarDirection.VERTICAL, _arg1.delta, horizontalScrollPosition)); } public function get verticalScrollPosition():Number{ return (_verticalScrollBar.scrollPosition); } protected function drawDisabledOverlay():void{ if (enabled){ if (contains(disabledOverlay)){ removeChild(disabledOverlay); }; } else { disabledOverlay.x = (disabledOverlay.y = contentPadding); disabledOverlay.width = availableWidth; disabledOverlay.height = availableHeight; disabledOverlay.alpha = (getStyleValue("disabledAlpha") as Number); addChild(disabledOverlay); }; } public function set verticalScrollPosition(_arg1:Number):void{ drawNow(); _verticalScrollBar.scrollPosition = _arg1; setVerticalScrollPosition(_verticalScrollBar.scrollPosition, false); } protected function setContentSize(_arg1:Number, _arg2:Number):void{ if ((((((contentWidth == _arg1)) || (useFixedHorizontalScrolling))) && ((contentHeight == _arg2)))){ return; }; contentWidth = _arg1; contentHeight = _arg2; invalidate(InvalidationType.SIZE); } public function get horizontalScrollPosition():Number{ return (_horizontalScrollBar.scrollPosition); } public function get horizontalScrollBar():ScrollBar{ return (_horizontalScrollBar); } override public function set enabled(_arg1:Boolean):void{ if (enabled == _arg1){ return; }; _verticalScrollBar.enabled = _arg1; _horizontalScrollBar.enabled = _arg1; super.enabled = _arg1; } public function get verticalLineScrollSize():Number{ return (_verticalScrollBar.lineScrollSize); } public function get horizontalScrollPolicy():String{ return (_horizontalScrollPolicy); } protected function calculateAvailableSize():void{ var _local1:Number; var _local2:Number; var _local3:Number; var _local4:Number; var _local5:Number; _local1 = ScrollBar.WIDTH; _local2 = (contentPadding = Number(getStyleValue("contentPadding"))); _local3 = ((height - (2 * _local2)) - vOffset); vScrollBar = (((_verticalScrollPolicy == ScrollPolicy.ON)) || ((((_verticalScrollPolicy == ScrollPolicy.AUTO)) && ((contentHeight > _local3))))); _local4 = ((width - (vScrollBar) ? _local1 : 0) - (2 * _local2)); _local5 = (useFixedHorizontalScrolling) ? _maxHorizontalScrollPosition : (contentWidth - _local4); hScrollBar = (((_horizontalScrollPolicy == ScrollPolicy.ON)) || ((((_horizontalScrollPolicy == ScrollPolicy.AUTO)) && ((_local5 > 0))))); if (hScrollBar){ _local3 = (_local3 - _local1); }; if (((((((hScrollBar) && (!(vScrollBar)))) && ((_verticalScrollPolicy == ScrollPolicy.AUTO)))) && ((contentHeight > _local3)))){ vScrollBar = true; _local4 = (_local4 - _local1); }; availableHeight = (_local3 + vOffset); availableWidth = _local4; } public function get maxVerticalScrollPosition():Number{ drawNow(); return (Math.max(0, (contentHeight - availableHeight))); } public function set horizontalScrollPosition(_arg1:Number):void{ drawNow(); _horizontalScrollBar.scrollPosition = _arg1; setHorizontalScrollPosition(_horizontalScrollBar.scrollPosition, false); } public function get horizontalLineScrollSize():Number{ return (_horizontalScrollBar.lineScrollSize); } public function set verticalPageScrollSize(_arg1:Number):void{ _verticalPageScrollSize = _arg1; invalidate(InvalidationType.SIZE); } public function get verticalScrollPolicy():String{ return (_verticalScrollPolicy); } protected function setHorizontalScrollPosition(_arg1:Number, _arg2:Boolean=false):void{ } public function get useBitmapScrolling():Boolean{ return (_useBitmpScrolling); } protected function handleScroll(_arg1:ScrollEvent):void{ if (_arg1.target == _verticalScrollBar){ setVerticalScrollPosition(_arg1.position); } else { setHorizontalScrollPosition(_arg1.position); }; } public function set verticalLineScrollSize(_arg1:Number):void{ _verticalScrollBar.lineScrollSize = _arg1; } public function get verticalScrollBar():ScrollBar{ return (_verticalScrollBar); } protected function setVerticalScrollPosition(_arg1:Number, _arg2:Boolean=false):void{ } public function set horizontalPageScrollSize(_arg1:Number):void{ _horizontalPageScrollSize = _arg1; invalidate(InvalidationType.SIZE); } override protected function draw():void{ if (isInvalid(InvalidationType.STYLES)){ setStyles(); drawBackground(); if (contentPadding != getStyleValue("contentPadding")){ invalidate(InvalidationType.SIZE, false); }; }; if (isInvalid(InvalidationType.SIZE, InvalidationType.STATE)){ drawLayout(); }; updateChildren(); super.draw(); } public function set horizontalScrollPolicy(_arg1:String):void{ _horizontalScrollPolicy = _arg1; invalidate(InvalidationType.SIZE); } override protected function configUI():void{ var _local1:Graphics; super.configUI(); contentScrollRect = new Rectangle(0, 0, 85, 85); _verticalScrollBar = new ScrollBar(); _verticalScrollBar.addEventListener(ScrollEvent.SCROLL, handleScroll, false, 0, true); _verticalScrollBar.visible = false; _verticalScrollBar.lineScrollSize = defaultLineScrollSize; addChild(_verticalScrollBar); copyStylesToChild(_verticalScrollBar, SCROLL_BAR_STYLES); _horizontalScrollBar = new ScrollBar(); _horizontalScrollBar.direction = ScrollBarDirection.HORIZONTAL; _horizontalScrollBar.addEventListener(ScrollEvent.SCROLL, handleScroll, false, 0, true); _horizontalScrollBar.visible = false; _horizontalScrollBar.lineScrollSize = defaultLineScrollSize; addChild(_horizontalScrollBar); copyStylesToChild(_horizontalScrollBar, SCROLL_BAR_STYLES); disabledOverlay = new Shape(); _local1 = disabledOverlay.graphics; _local1.beginFill(0xFFFFFF); _local1.drawRect(0, 0, width, height); _local1.endFill(); addEventListener(MouseEvent.MOUSE_WHEEL, handleWheel, false, 0, true); } protected function calculateContentWidth():void{ } public function get verticalPageScrollSize():Number{ if (isNaN(availableHeight)){ drawNow(); }; return (((((_verticalPageScrollSize == 0)) && (!(isNaN(availableHeight))))) ? availableHeight : _verticalPageScrollSize); } protected function drawLayout():void{ calculateAvailableSize(); calculateContentWidth(); background.width = width; background.height = height; if (vScrollBar){ _verticalScrollBar.visible = true; _verticalScrollBar.x = ((width - ScrollBar.WIDTH) - contentPadding); _verticalScrollBar.y = contentPadding; _verticalScrollBar.height = availableHeight; } else { _verticalScrollBar.visible = false; }; _verticalScrollBar.setScrollProperties(availableHeight, 0, (contentHeight - availableHeight), verticalPageScrollSize); setVerticalScrollPosition(_verticalScrollBar.scrollPosition, false); if (hScrollBar){ _horizontalScrollBar.visible = true; _horizontalScrollBar.x = contentPadding; _horizontalScrollBar.y = ((height - ScrollBar.WIDTH) - contentPadding); _horizontalScrollBar.width = availableWidth; } else { _horizontalScrollBar.visible = false; }; _horizontalScrollBar.setScrollProperties(availableWidth, 0, (useFixedHorizontalScrolling) ? _maxHorizontalScrollPosition : (contentWidth - availableWidth), horizontalPageScrollSize); setHorizontalScrollPosition(_horizontalScrollBar.scrollPosition, false); drawDisabledOverlay(); } protected function drawBackground():void{ var _local1:DisplayObject; _local1 = background; background = getDisplayObjectInstance(getStyleValue("skin")); background.width = width; background.height = height; addChildAt(background, 0); if (((!((_local1 == null))) && (!((_local1 == background))))){ removeChild(_local1); }; } public function set horizontalLineScrollSize(_arg1:Number):void{ _horizontalScrollBar.lineScrollSize = _arg1; } public function get horizontalPageScrollSize():Number{ if (isNaN(availableWidth)){ drawNow(); }; return (((((_horizontalPageScrollSize == 0)) && (!(isNaN(availableWidth))))) ? availableWidth : _horizontalPageScrollSize); } public function get maxHorizontalScrollPosition():Number{ drawNow(); return (Math.max(0, (contentWidth - availableWidth))); } protected function setStyles():void{ copyStylesToChild(_verticalScrollBar, SCROLL_BAR_STYLES); copyStylesToChild(_horizontalScrollBar, SCROLL_BAR_STYLES); } protected function updateChildren():void{ _verticalScrollBar.enabled = (_horizontalScrollBar.enabled = enabled); _verticalScrollBar.drawNow(); _horizontalScrollBar.drawNow(); } public function set verticalScrollPolicy(_arg1:String):void{ _verticalScrollPolicy = _arg1; invalidate(InvalidationType.SIZE); } public function set useBitmapScrolling(_arg1:Boolean):void{ _useBitmpScrolling = _arg1; invalidate(InvalidationType.STATE); } public static function getStyleDefinition():Object{ return (mergeStyles(defaultStyles, ScrollBar.getStyleDefinition())); } } }//package fl.containers
Section 118
//CellRenderer (fl.controls.listClasses.CellRenderer) package fl.controls.listClasses { import fl.controls.*; import flash.events.*; public class CellRenderer extends LabelButton implements ICellRenderer { protected var _data:Object; protected var _listData:ListData; private static var defaultStyles:Object = {upSkin:"CellRenderer_upSkin", downSkin:"CellRenderer_downSkin", overSkin:"CellRenderer_overSkin", disabledSkin:"CellRenderer_disabledSkin", selectedDisabledSkin:"CellRenderer_selectedDisabledSkin", selectedUpSkin:"CellRenderer_selectedUpSkin", selectedDownSkin:"CellRenderer_selectedDownSkin", selectedOverSkin:"CellRenderer_selectedOverSkin", textFormat:null, disabledTextFormat:null, embedFonts:null, textPadding:5}; public function CellRenderer():void{ toggle = true; focusEnabled = false; } override protected function toggleSelected(_arg1:MouseEvent):void{ } override public function get selected():Boolean{ return (super.selected); } public function set listData(_arg1:ListData):void{ _listData = _arg1; label = _listData.label; setStyle("icon", _listData.icon); } override public function set selected(_arg1:Boolean):void{ super.selected = _arg1; } public function set data(_arg1:Object):void{ _data = _arg1; } public function get listData():ListData{ return (_listData); } override public function setSize(_arg1:Number, _arg2:Number):void{ super.setSize(_arg1, _arg2); } override protected function drawLayout():void{ var _local1:Number; var _local2:Number; var _local3:Number; _local1 = Number(getStyleValue("textPadding")); _local2 = 0; if (icon != null){ icon.x = _local1; icon.y = Math.round(((height - icon.height) >> 1)); _local2 = (icon.width + _local1); }; if (label.length > 0){ textField.visible = true; _local3 = Math.max(0, ((width - _local2) - (_local1 * 2))); textField.width = _local3; textField.height = (textField.textHeight + 4); textField.x = (_local2 + _local1); textField.y = Math.round(((height - textField.height) >> 1)); } else { textField.visible = false; }; background.width = width; background.height = height; } public function get data():Object{ return (_data); } public static function getStyleDefinition():Object{ return (defaultStyles); } } }//package fl.controls.listClasses
Section 119
//ICellRenderer (fl.controls.listClasses.ICellRenderer) package fl.controls.listClasses { public interface ICellRenderer { function setSize(_arg1:Number, _arg2:Number):void; function get listData():ListData; function get data():Object; function setMouseState(_arg1:String):void; function set x(_arg1:Number):void; function set y(_arg1:Number):void; function set data(_arg1:Object):void; function set selected(_arg1:Boolean):void; function set listData(_arg1:ListData):void; function get selected():Boolean; } }//package fl.controls.listClasses
Section 120
//ListData (fl.controls.listClasses.ListData) package fl.controls.listClasses { import fl.core.*; public class ListData { protected var _index:uint; protected var _owner:UIComponent; protected var _label:String; protected var _icon:Object;// = null protected var _row:uint; protected var _column:uint; public function ListData(_arg1:String, _arg2:Object, _arg3:UIComponent, _arg4:uint, _arg5:uint, _arg6:uint=0){ _icon = null; super(); _label = _arg1; _icon = _arg2; _owner = _arg3; _index = _arg4; _row = _arg5; _column = _arg6; } public function get owner():UIComponent{ return (_owner); } public function get label():String{ return (_label); } public function get row():uint{ return (_row); } public function get index():uint{ return (_index); } public function get icon():Object{ return (_icon); } public function get column():uint{ return (_column); } } }//package fl.controls.listClasses
Section 121
//BaseButton (fl.controls.BaseButton) package fl.controls { import fl.core.*; import flash.display.*; import flash.events.*; import fl.events.*; import flash.utils.*; public class BaseButton extends UIComponent { protected var _selected:Boolean;// = false private var unlockedMouseState:String; protected var pressTimer:Timer; protected var mouseState:String; protected var background:DisplayObject; private var _mouseStateLocked:Boolean;// = false protected var _autoRepeat:Boolean;// = false private static var defaultStyles:Object = {upSkin:"Button_upSkin", downSkin:"Button_downSkin", overSkin:"Button_overSkin", disabledSkin:"Button_disabledSkin", selectedDisabledSkin:"Button_selectedDisabledSkin", selectedUpSkin:"Button_selectedUpSkin", selectedDownSkin:"Button_selectedDownSkin", selectedOverSkin:"Button_selectedOverSkin", focusRectSkin:null, focusRectPadding:null, repeatDelay:500, repeatInterval:35}; public function BaseButton(){ _selected = false; _autoRepeat = false; _mouseStateLocked = false; super(); buttonMode = true; mouseChildren = false; useHandCursor = false; setupMouseEvents(); setMouseState("up"); pressTimer = new Timer(1, 0); pressTimer.addEventListener(TimerEvent.TIMER, buttonDown, false, 0, true); } protected function endPress():void{ pressTimer.reset(); } public function set mouseStateLocked(_arg1:Boolean):void{ _mouseStateLocked = _arg1; if (_arg1 == false){ setMouseState(unlockedMouseState); } else { unlockedMouseState = mouseState; }; } public function get autoRepeat():Boolean{ return (_autoRepeat); } public function set autoRepeat(_arg1:Boolean):void{ _autoRepeat = _arg1; } override public function set enabled(_arg1:Boolean):void{ super.enabled = _arg1; mouseEnabled = _arg1; } public function get selected():Boolean{ return (_selected); } protected function mouseEventHandler(_arg1:MouseEvent):void{ if (_arg1.type == MouseEvent.MOUSE_DOWN){ setMouseState("down"); startPress(); } else { if ((((_arg1.type == MouseEvent.ROLL_OVER)) || ((_arg1.type == MouseEvent.MOUSE_UP)))){ setMouseState("over"); endPress(); } else { if (_arg1.type == MouseEvent.ROLL_OUT){ setMouseState("up"); endPress(); }; }; }; } public function setMouseState(_arg1:String):void{ if (_mouseStateLocked){ unlockedMouseState = _arg1; return; }; if (mouseState == _arg1){ return; }; mouseState = _arg1; invalidate(InvalidationType.STATE); } protected function startPress():void{ if (_autoRepeat){ pressTimer.delay = Number(getStyleValue("repeatDelay")); pressTimer.start(); }; dispatchEvent(new ComponentEvent(ComponentEvent.BUTTON_DOWN, true)); } protected function buttonDown(_arg1:TimerEvent):void{ if (!_autoRepeat){ endPress(); return; }; if (pressTimer.currentCount == 1){ pressTimer.delay = Number(getStyleValue("repeatInterval")); }; dispatchEvent(new ComponentEvent(ComponentEvent.BUTTON_DOWN, true)); } public function set selected(_arg1:Boolean):void{ if (_selected == _arg1){ return; }; _selected = _arg1; invalidate(InvalidationType.STATE); } override public function get enabled():Boolean{ return (super.enabled); } override protected function draw():void{ if (isInvalid(InvalidationType.STYLES, InvalidationType.STATE)){ drawBackground(); invalidate(InvalidationType.SIZE, false); }; if (isInvalid(InvalidationType.SIZE)){ drawLayout(); }; super.draw(); } protected function setupMouseEvents():void{ addEventListener(MouseEvent.ROLL_OVER, mouseEventHandler, false, 0, true); addEventListener(MouseEvent.MOUSE_DOWN, mouseEventHandler, false, 0, true); addEventListener(MouseEvent.MOUSE_UP, mouseEventHandler, false, 0, true); addEventListener(MouseEvent.ROLL_OUT, mouseEventHandler, false, 0, true); } protected function drawLayout():void{ background.width = width; background.height = height; } protected function drawBackground():void{ var _local1:String; var _local2:DisplayObject; _local1 = (enabled) ? mouseState : "disabled"; if (selected){ _local1 = (("selected" + _local1.substr(0, 1).toUpperCase()) + _local1.substr(1)); }; _local1 = (_local1 + "Skin"); _local2 = background; background = getDisplayObjectInstance(getStyleValue(_local1)); addChildAt(background, 0); if (((!((_local2 == null))) && (!((_local2 == background))))){ removeChild(_local2); }; } public static function getStyleDefinition():Object{ return (defaultStyles); } } }//package fl.controls
Section 122
//Button (fl.controls.Button) package fl.controls { import fl.core.*; import flash.display.*; import fl.managers.*; public class Button extends LabelButton implements IFocusManagerComponent { protected var emphasizedBorder:DisplayObject; protected var _emphasized:Boolean;// = false private static var defaultStyles:Object = {emphasizedSkin:"Button_emphasizedSkin", emphasizedPadding:2}; public static var createAccessibilityImplementation:Function; public function Button(){ _emphasized = false; super(); } override public function drawFocus(_arg1:Boolean):void{ var _local2:Number; var _local3:*; super.drawFocus(_arg1); if (_arg1){ _local2 = Number(getStyleValue("emphasizedPadding")); if ((((_local2 < 0)) || (!(_emphasized)))){ _local2 = 0; }; _local3 = getStyleValue("focusRectPadding"); _local3 = ((_local3)==null) ? 2 : _local3; _local3 = (_local3 + _local2); uiFocusRect.x = -(_local3); uiFocusRect.y = -(_local3); uiFocusRect.width = (width + (_local3 * 2)); uiFocusRect.height = (height + (_local3 * 2)); }; } public function set emphasized(_arg1:Boolean):void{ _emphasized = _arg1; invalidate(InvalidationType.STYLES); } override protected function draw():void{ if (((isInvalid(InvalidationType.STYLES)) || (isInvalid(InvalidationType.SIZE)))){ drawEmphasized(); }; super.draw(); if (emphasizedBorder != null){ setChildIndex(emphasizedBorder, (numChildren - 1)); }; } public function get emphasized():Boolean{ return (_emphasized); } override protected function initializeAccessibility():void{ if (Button.createAccessibilityImplementation != null){ Button.createAccessibilityImplementation(this); }; } protected function drawEmphasized():void{ var _local1:Object; var _local2:Number; if (emphasizedBorder != null){ removeChild(emphasizedBorder); }; emphasizedBorder = null; if (!_emphasized){ return; }; _local1 = getStyleValue("emphasizedSkin"); if (_local1 != null){ emphasizedBorder = getDisplayObjectInstance(_local1); }; if (emphasizedBorder != null){ addChildAt(emphasizedBorder, 0); _local2 = Number(getStyleValue("emphasizedPadding")); emphasizedBorder.x = (emphasizedBorder.y = -(_local2)); emphasizedBorder.width = (width + (_local2 * 2)); emphasizedBorder.height = (height + (_local2 * 2)); }; } public static function getStyleDefinition():Object{ return (UIComponent.mergeStyles(LabelButton.getStyleDefinition(), defaultStyles)); } } }//package fl.controls
Section 123
//ButtonLabelPlacement (fl.controls.ButtonLabelPlacement) package fl.controls { public class ButtonLabelPlacement { public static const TOP:String = "top"; public static const LEFT:String = "left"; public static const BOTTOM:String = "bottom"; public static const RIGHT:String = "right"; } }//package fl.controls
Section 124
//ColorPicker (fl.controls.ColorPicker) package fl.controls { import fl.core.*; import flash.display.*; import flash.events.*; import flash.geom.*; import fl.managers.*; import fl.events.*; import flash.text.*; import flash.ui.*; public class ColorPicker extends UIComponent implements IFocusManagerComponent { protected var paletteBG:DisplayObject; protected var customColors:Array; protected var palette:Sprite; protected var isOpen:Boolean;// = false protected var swatchButton:BaseButton; protected var selectedSwatch:Sprite; protected var textFieldBG:DisplayObject; protected var colorWell:DisplayObject; protected var rollOverColor:int;// = -1 protected var colorHash:Object; protected var swatchSelectedSkin:DisplayObject; protected var _showTextField:Boolean;// = true protected var currRowIndex:int; protected var doOpen:Boolean;// = false protected var currColIndex:int; protected var swatchMap:Array; protected var _selectedColor:uint; protected var _editable:Boolean;// = true public var textField:TextField; protected var swatches:Sprite; protected static const SWATCH_STYLES:Object = {disabledSkin:"swatchSkin", downSkin:"swatchSkin", overSkin:"swatchSkin", upSkin:"swatchSkin"}; protected static const POPUP_BUTTON_STYLES:Object = {disabledSkin:"disabledSkin", downSkin:"downSkin", overSkin:"overSkin", upSkin:"upSkin"}; public static var defaultColors:Array; private static var defaultStyles:Object = {upSkin:"ColorPicker_upSkin", disabledSkin:"ColorPicker_disabledSkin", overSkin:"ColorPicker_overSkin", downSkin:"ColorPicker_downSkin", colorWell:"ColorPicker_colorWell", swatchSkin:"ColorPicker_swatchSkin", swatchSelectedSkin:"ColorPicker_swatchSelectedSkin", swatchWidth:10, swatchHeight:10, columnCount:18, swatchPadding:1, textFieldSkin:"ColorPicker_textFieldSkin", textFieldWidth:null, textFieldHeight:null, textPadding:3, background:"ColorPicker_backgroundSkin", backgroundPadding:5, textFormat:null, focusRectSkin:null, focusRectPadding:null, embedFonts:false}; public function ColorPicker(){ rollOverColor = -1; _editable = true; _showTextField = true; isOpen = false; doOpen = false; super(); } public function set imeMode(_arg1:String):void{ _imeMode = _arg1; } protected function drawSwatchHighlight():void{ var _local1:Object; var _local2:Number; cleanUpSelected(); _local1 = getStyleValue("swatchSelectedSkin"); _local2 = (getStyleValue("swatchPadding") as Number); if (_local1 != null){ swatchSelectedSkin = getDisplayObjectInstance(_local1); swatchSelectedSkin.x = 0; swatchSelectedSkin.y = 0; swatchSelectedSkin.width = ((getStyleValue("swatchWidth") as Number) + 2); swatchSelectedSkin.height = ((getStyleValue("swatchHeight") as Number) + 2); }; } protected function setColorWellColor(_arg1:ColorTransform):void{ if (!colorWell){ return; }; colorWell.transform.colorTransform = _arg1; } override protected function isOurFocus(_arg1:DisplayObject):Boolean{ return ((((_arg1 == textField)) || (super.isOurFocus(_arg1)))); } public function open():void{ var _local1:IFocusManager; if (!_enabled){ return; }; doOpen = true; _local1 = focusManager; if (_local1){ _local1.defaultButtonEnabled = false; }; invalidate(InvalidationType.STATE); } protected function setTextEditable():void{ if (!showTextField){ return; }; textField.type = (editable) ? TextFieldType.INPUT : TextFieldType.DYNAMIC; textField.selectable = editable; } protected function createSwatch(_arg1:uint):Sprite{ var _local2:Sprite; var _local3:BaseButton; var _local4:Number; var _local5:Number; var _local6:Number; var _local7:Graphics; _local2 = new Sprite(); _local3 = new BaseButton(); _local3.focusEnabled = false; _local4 = (getStyleValue("swatchWidth") as Number); _local5 = (getStyleValue("swatchHeight") as Number); _local3.setSize(_local4, _local5); _local3.transform.colorTransform = new ColorTransform(0, 0, 0, 1, (_arg1 >> 16), ((_arg1 >> 8) & 0xFF), (_arg1 & 0xFF), 0); copyStylesToChild(_local3, SWATCH_STYLES); _local3.mouseEnabled = false; _local3.drawNow(); _local3.name = "color"; _local2.addChild(_local3); _local6 = (getStyleValue("swatchPadding") as Number); _local7 = _local2.graphics; _local7.beginFill(0); _local7.drawRect(-(_local6), -(_local6), (_local4 + (_local6 * 2)), (_local5 + (_local6 * 2))); _local7.endFill(); _local2.addEventListener(MouseEvent.CLICK, onSwatchClick, false, 0, true); _local2.addEventListener(MouseEvent.MOUSE_OVER, onSwatchOver, false, 0, true); _local2.addEventListener(MouseEvent.MOUSE_OUT, onSwatchOut, false, 0, true); return (_local2); } protected function onSwatchOut(_arg1:MouseEvent):void{ var _local2:ColorTransform; _local2 = _arg1.target.transform.colorTransform; dispatchEvent(new ColorPickerEvent(ColorPickerEvent.ITEM_ROLL_OUT, _local2.color)); } override protected function keyDownHandler(_arg1:KeyboardEvent):void{ var _local2:ColorTransform; var _local3:Sprite; switch (_arg1.keyCode){ case Keyboard.SHIFT: case Keyboard.CONTROL: return; }; if (_arg1.ctrlKey){ switch (_arg1.keyCode){ case Keyboard.DOWN: open(); break; case Keyboard.UP: close(); break; }; return; }; if (!isOpen){ switch (_arg1.keyCode){ case Keyboard.UP: case Keyboard.DOWN: case Keyboard.LEFT: case Keyboard.RIGHT: case Keyboard.SPACE: open(); return; }; }; textField.maxChars = ((((_arg1.keyCode == "#".charCodeAt(0))) || ((textField.text.indexOf("#") > -1)))) ? 7 : 6; switch (_arg1.keyCode){ case Keyboard.TAB: _local3 = findSwatch(_selectedColor); setSwatchHighlight(_local3); return; case Keyboard.HOME: currColIndex = (currRowIndex = 0); break; case Keyboard.END: currColIndex = (swatchMap[(swatchMap.length - 1)].length - 1); currRowIndex = (swatchMap.length - 1); break; case Keyboard.PAGE_DOWN: currRowIndex = (swatchMap.length - 1); break; case Keyboard.PAGE_UP: currRowIndex = 0; break; case Keyboard.ESCAPE: if (isOpen){ selectedColor = _selectedColor; }; close(); return; case Keyboard.ENTER: return; case Keyboard.UP: currRowIndex = Math.max(-1, (currRowIndex - 1)); if (currRowIndex == -1){ currRowIndex = (swatchMap.length - 1); }; break; case Keyboard.DOWN: currRowIndex = Math.min(swatchMap.length, (currRowIndex + 1)); if (currRowIndex == swatchMap.length){ currRowIndex = 0; }; break; case Keyboard.RIGHT: currColIndex = Math.min(swatchMap[currRowIndex].length, (currColIndex + 1)); if (currColIndex == swatchMap[currRowIndex].length){ currColIndex = 0; currRowIndex = Math.min(swatchMap.length, (currRowIndex + 1)); if (currRowIndex == swatchMap.length){ currRowIndex = 0; }; }; break; case Keyboard.LEFT: currColIndex = Math.max(-1, (currColIndex - 1)); if (currColIndex == -1){ currColIndex = (swatchMap[currRowIndex].length - 1); currRowIndex = Math.max(-1, (currRowIndex - 1)); if (currRowIndex == -1){ currRowIndex = (swatchMap.length - 1); }; }; break; default: return; }; _local2 = swatchMap[currRowIndex][currColIndex].getChildByName("color").transform.colorTransform; rollOverColor = _local2.color; setColorWellColor(_local2); setSwatchHighlight(swatchMap[currRowIndex][currColIndex]); setColorText(_local2.color); } public function get editable():Boolean{ return (_editable); } override protected function focusInHandler(_arg1:FocusEvent):void{ super.focusInHandler(_arg1); setIMEMode(true); } protected function onStageClick(_arg1:MouseEvent):void{ if (((!(contains((_arg1.target as DisplayObject)))) && (!(palette.contains((_arg1.target as DisplayObject)))))){ selectedColor = _selectedColor; close(); }; } protected function onSwatchOver(_arg1:MouseEvent):void{ var _local2:BaseButton; var _local3:ColorTransform; _local2 = (_arg1.target.getChildByName("color") as BaseButton); _local3 = _local2.transform.colorTransform; setColorWellColor(_local3); setSwatchHighlight((_arg1.target as Sprite)); setColorText(_local3.color); dispatchEvent(new ColorPickerEvent(ColorPickerEvent.ITEM_ROLL_OVER, _local3.color)); } override public function set enabled(_arg1:Boolean):void{ super.enabled = _arg1; if (!_arg1){ close(); }; swatchButton.enabled = _arg1; } override protected function keyUpHandler(_arg1:KeyboardEvent):void{ var _local2:uint; var _local3:ColorTransform; var _local4:String; var _local5:Sprite; if (!isOpen){ return; }; _local3 = new ColorTransform(); if (((editable) && (showTextField))){ _local4 = textField.text; if (_local4.indexOf("#") > -1){ _local4 = _local4.replace(/^\s+|\s+$/g, ""); _local4 = _local4.replace(/#/g, ""); }; _local2 = parseInt(_local4, 16); _local5 = findSwatch(_local2); setSwatchHighlight(_local5); _local3.color = _local2; setColorWellColor(_local3); } else { _local2 = rollOverColor; _local3.color = _local2; }; if (_arg1.keyCode != Keyboard.ENTER){ return; }; dispatchEvent(new ColorPickerEvent(ColorPickerEvent.ENTER, _local2)); _selectedColor = rollOverColor; setColorText(_local3.color); rollOverColor = _local3.color; dispatchEvent(new ColorPickerEvent(ColorPickerEvent.CHANGE, selectedColor)); close(); } protected function drawBG():void{ var _local1:Object; var _local2:Number; _local1 = getStyleValue("background"); if (_local1 != null){ paletteBG = (getDisplayObjectInstance(_local1) as Sprite); }; if (paletteBG == null){ return; }; _local2 = Number(getStyleValue("backgroundPadding")); paletteBG.width = (Math.max((showTextField) ? textFieldBG.width : 0, swatches.width) + (_local2 * 2)); paletteBG.height = ((swatches.y + swatches.height) + _local2); palette.addChildAt(paletteBG, 0); } protected function positionTextField():void{ var _local1:Number; var _local2:Number; if (!showTextField){ return; }; _local1 = (getStyleValue("backgroundPadding") as Number); _local2 = (getStyleValue("textPadding") as Number); textFieldBG.x = (paletteBG.x + _local1); textFieldBG.y = (paletteBG.y + _local1); textField.x = (textFieldBG.x + _local2); textField.y = (textFieldBG.y + _local2); } protected function setEmbedFonts():void{ var _local1:Object; _local1 = getStyleValue("embedFonts"); if (_local1 != null){ textField.embedFonts = _local1; }; } public function set showTextField(_arg1:Boolean):void{ invalidate(InvalidationType.STYLES); _showTextField = _arg1; } protected function addStageListener(_arg1:Event=null):void{ stage.addEventListener(MouseEvent.MOUSE_DOWN, onStageClick, false, 0, true); } protected function drawPalette():void{ if (isOpen){ stage.removeChild(palette); }; palette = new Sprite(); drawTextField(); drawSwatches(); drawBG(); } protected function showPalette():void{ var _local1:Sprite; if (isOpen){ positionPalette(); return; }; addEventListener(Event.ENTER_FRAME, addCloseListener, false, 0, true); stage.addChild(palette); isOpen = true; positionPalette(); dispatchEvent(new Event(Event.OPEN)); stage.focus = textField; _local1 = selectedSwatch; if (_local1 == null){ _local1 = findSwatch(_selectedColor); }; setSwatchHighlight(_local1); } public function set editable(_arg1:Boolean):void{ _editable = _arg1; invalidate(InvalidationType.STATE); } public function set colors(_arg1:Array):void{ customColors = _arg1; invalidate(InvalidationType.DATA); } protected function drawTextField():void{ var _local1:Number; var _local2:Number; var _local3:Object; var _local4:TextFormat; var _local5:TextFormat; if (!showTextField){ return; }; _local1 = (getStyleValue("backgroundPadding") as Number); _local2 = (getStyleValue("textPadding") as Number); textFieldBG = getDisplayObjectInstance(getStyleValue("textFieldSkin")); if (textFieldBG != null){ palette.addChild(textFieldBG); textFieldBG.x = (textFieldBG.y = _local1); }; _local3 = UIComponent.getStyleDefinition(); _local4 = (enabled) ? (_local3.defaultTextFormat as TextFormat) : (_local3.defaultDisabledTextFormat as TextFormat); textField.setTextFormat(_local4); _local5 = (getStyleValue("textFormat") as TextFormat); if (_local5 != null){ textField.setTextFormat(_local5); } else { _local5 = _local4; }; textField.defaultTextFormat = _local5; setEmbedFonts(); textField.restrict = "A-Fa-f0-9#"; textField.maxChars = 6; palette.addChild(textField); textField.text = " #888888 "; textField.height = (textField.textHeight + 3); textField.width = (textField.textWidth + 3); textField.text = ""; textField.x = (textField.y = (_local1 + _local2)); textFieldBG.width = (textField.width + (_local2 * 2)); textFieldBG.height = (textField.height + (_local2 * 2)); setTextEditable(); } protected function setColorText(_arg1:uint):void{ if (textField == null){ return; }; textField.text = ("#" + colorToString(_arg1)); } protected function colorToString(_arg1:uint):String{ var _local2:String; _local2 = _arg1.toString(16); while (_local2.length < 6) { _local2 = ("0" + _local2); }; return (_local2); } public function get imeMode():String{ return (_imeMode); } public function set selectedColor(_arg1:uint):void{ var _local2:ColorTransform; if (!_enabled){ return; }; _selectedColor = _arg1; rollOverColor = -1; currColIndex = (currRowIndex = 0); _local2 = new ColorTransform(); _local2.color = _arg1; setColorWellColor(_local2); invalidate(InvalidationType.DATA); } override protected function focusOutHandler(_arg1:FocusEvent):void{ if (_arg1.relatedObject == textField){ setFocus(); return; }; if (isOpen){ close(); }; super.focusOutHandler(_arg1); setIMEMode(false); } protected function onPopupButtonClick(_arg1:MouseEvent):void{ if (isOpen){ close(); } else { open(); }; } protected function positionPalette():void{ var _local1:Point; var _local2:Number; _local1 = swatchButton.localToGlobal(new Point(0, 0)); _local2 = (getStyleValue("backgroundPadding") as Number); if ((_local1.x + palette.width) > stage.stageWidth){ palette.x = ((_local1.x - palette.width) << 0); } else { palette.x = (((_local1.x + swatchButton.width) + _local2) << 0); }; palette.y = (Math.max(0, Math.min(_local1.y, (stage.stageHeight - palette.height))) << 0); } public function get hexValue():String{ if (colorWell == null){ return (colorToString(0)); }; return (colorToString(colorWell.transform.colorTransform.color)); } override public function get enabled():Boolean{ return (super.enabled); } protected function setSwatchHighlight(_arg1:Sprite):void{ var _local2:Number; var _local3:*; if (_arg1 == null){ if (palette.contains(swatchSelectedSkin)){ palette.removeChild(swatchSelectedSkin); }; return; } else { if (((!(palette.contains(swatchSelectedSkin))) && ((colors.length > 0)))){ palette.addChild(swatchSelectedSkin); } else { if (!colors.length){ return; }; }; }; _local2 = (getStyleValue("swatchPadding") as Number); palette.setChildIndex(swatchSelectedSkin, (palette.numChildren - 1)); swatchSelectedSkin.x = ((swatches.x + _arg1.x) - 1); swatchSelectedSkin.y = ((swatches.y + _arg1.y) - 1); _local3 = _arg1.getChildByName("color").transform.colorTransform.color; currColIndex = colorHash[_local3].col; currRowIndex = colorHash[_local3].row; } protected function onSwatchClick(_arg1:MouseEvent):void{ var _local2:ColorTransform; _local2 = _arg1.target.getChildByName("color").transform.colorTransform; _selectedColor = _local2.color; dispatchEvent(new ColorPickerEvent(ColorPickerEvent.CHANGE, selectedColor)); close(); } override protected function draw():void{ if (isInvalid(InvalidationType.STYLES, InvalidationType.DATA)){ setStyles(); drawPalette(); setEmbedFonts(); invalidate(InvalidationType.DATA, false); invalidate(InvalidationType.STYLES, false); }; if (isInvalid(InvalidationType.DATA)){ drawSwatchHighlight(); setColorDisplay(); }; if (isInvalid(InvalidationType.STATE)){ setTextEditable(); if (doOpen){ doOpen = false; showPalette(); }; colorWell.visible = enabled; }; if (isInvalid(InvalidationType.SIZE, InvalidationType.STYLES)){ swatchButton.setSize(width, height); swatchButton.drawNow(); colorWell.width = width; colorWell.height = height; }; super.draw(); } protected function drawSwatches():void{ var _local1:Number; var _local2:Number; var _local3:uint; var _local4:uint; var _local5:Number; var _local6:Number; var _local7:uint; var _local8:int; var _local9:uint; var _local10:Sprite; _local1 = (getStyleValue("backgroundPadding") as Number); _local2 = (showTextField) ? ((textFieldBG.y + textFieldBG.height) + _local1) : _local1; swatches = new Sprite(); palette.addChild(swatches); swatches.x = _local1; swatches.y = _local2; _local3 = (getStyleValue("columnCount") as uint); _local4 = (getStyleValue("swatchPadding") as uint); _local5 = (getStyleValue("swatchWidth") as Number); _local6 = (getStyleValue("swatchHeight") as Number); colorHash = {}; swatchMap = []; _local7 = Math.min(0x0400, colors.length); _local8 = -1; _local9 = 0; while (_local9 < _local7) { _local10 = createSwatch(colors[_local9]); _local10.x = ((_local5 + _local4) * (_local9 % _local3)); if (_local10.x == 0){ swatchMap.push([_local10]); _local8++; } else { swatchMap[_local8].push(_local10); }; colorHash[colors[_local9]] = {swatch:_local10, row:_local8, col:(swatchMap[_local8].length - 1)}; _local10.y = (Math.floor((_local9 / _local3)) * (_local6 + _local4)); swatches.addChild(_local10); _local9++; }; } override protected function configUI():void{ var _local1:uint; super.configUI(); tabChildren = false; if (_slot1.defaultColors == null){ _slot1.defaultColors = []; _local1 = 0; while (_local1 < 216) { _slot1.defaultColors.push(((((((((_local1 / 6) % 3) << 0) + (((_local1 / 108) << 0) * 3)) * 51) << 16) | (((_local1 % 6) * 51) << 8)) | ((((_local1 / 18) << 0) % 6) * 51))); _local1++; }; }; colorHash = {}; swatchMap = []; textField = new TextField(); textField.tabEnabled = false; swatchButton = new BaseButton(); swatchButton.focusEnabled = false; swatchButton.useHandCursor = false; swatchButton.autoRepeat = false; swatchButton.setSize(25, 25); swatchButton.addEventListener(MouseEvent.CLICK, onPopupButtonClick, false, 0, true); addChild(swatchButton); palette = new Sprite(); palette.tabChildren = false; palette.cacheAsBitmap = true; } public function get showTextField():Boolean{ return (_showTextField); } public function get colors():Array{ return (((customColors)!=null) ? customColors : _slot1.defaultColors); } protected function findSwatch(_arg1:uint):Sprite{ var _local2:Object; if (!swatchMap.length){ return (null); }; _local2 = colorHash[_arg1]; if (_local2 != null){ return (_local2.swatch); }; return (null); } protected function setColorDisplay():void{ var _local1:ColorTransform; var _local2:Sprite; if (!swatchMap.length){ return; }; _local1 = new ColorTransform(0, 0, 0, 1, (_selectedColor >> 16), ((_selectedColor >> 8) & 0xFF), (_selectedColor & 0xFF), 0); setColorWellColor(_local1); setColorText(_selectedColor); _local2 = findSwatch(_selectedColor); setSwatchHighlight(_local2); if (((swatchMap.length) && ((colorHash[_selectedColor] == undefined)))){ cleanUpSelected(); }; } protected function cleanUpSelected():void{ if (((swatchSelectedSkin) && (palette.contains(swatchSelectedSkin)))){ palette.removeChild(swatchSelectedSkin); }; } public function get selectedColor():uint{ if (colorWell == null){ return (0); }; return (colorWell.transform.colorTransform.color); } private function addCloseListener(_arg1:Event){ removeEventListener(Event.ENTER_FRAME, addCloseListener); if (!isOpen){ return; }; addStageListener(); } protected function removeStageListener(_arg1:Event=null):void{ stage.removeEventListener(MouseEvent.MOUSE_DOWN, onStageClick, false); } protected function setStyles():void{ var _local1:DisplayObject; var _local2:Object; _local1 = colorWell; _local2 = getStyleValue("colorWell"); if (_local2 != null){ colorWell = (getDisplayObjectInstance(_local2) as DisplayObject); }; addChildAt(colorWell, getChildIndex(swatchButton)); copyStylesToChild(swatchButton, POPUP_BUTTON_STYLES); swatchButton.drawNow(); if (((((!((_local1 == null))) && (contains(_local1)))) && (!((_local1 == colorWell))))){ removeChild(_local1); }; } public function close():void{ var _local1:IFocusManager; if (isOpen){ stage.removeChild(palette); isOpen = false; dispatchEvent(new Event(Event.CLOSE)); }; _local1 = focusManager; if (_local1){ _local1.defaultButtonEnabled = true; }; removeStageListener(); cleanUpSelected(); } public static function getStyleDefinition():Object{ return (defaultStyles); } } }//package fl.controls
Section 125
//ComboBox (fl.controls.ComboBox) package fl.controls { import fl.controls.listClasses.*; import fl.core.*; import flash.display.*; import flash.events.*; import flash.geom.*; import fl.data.*; import fl.managers.*; import fl.events.*; import flash.text.*; import flash.ui.*; public class ComboBox extends UIComponent implements IFocusManagerComponent { protected var _dropdownWidth:Number; protected var highlightedCell:int;// = -1 protected var _prompt:String; protected var isOpen:Boolean;// = false protected var list:List; protected var _rowCount:uint;// = 5 protected var currentIndex:int; protected var isKeyDown:Boolean;// = false protected var _labels:Array; protected var background:BaseButton; protected var inputField:TextInput; protected var listOverIndex:uint; protected var editableValue:String; protected var _editable:Boolean;// = false private var collectionItemImport:SimpleCollectionItem; protected static const BACKGROUND_STYLES:Object = {overSkin:"overSkin", downSkin:"downSkin", upSkin:"upSkin", disabledSkin:"disabledSkin", repeatInterval:"repeatInterval"}; protected static const LIST_STYLES:Object = {upSkin:"comboListUpSkin", overSkin:"comboListOverSkin", downSkin:"comobListDownSkin", disabledSkin:"comboListDisabledSkin", downArrowDisabledSkin:"downArrowDisabledSkin", downArrowDownSkin:"downArrowDownSkin", downArrowOverSkin:"downArrowOverSkin", downArrowUpSkin:"downArrowUpSkin", upArrowDisabledSkin:"upArrowDisabledSkin", upArrowDownSkin:"upArrowDownSkin", upArrowOverSkin:"upArrowOverSkin", upArrowUpSkin:"upArrowUpSkin", thumbDisabledSkin:"thumbDisabledSkin", thumbDownSkin:"thumbDownSkin", thumbOverSkin:"thumbOverSkin", thumbUpSkin:"thumbUpSkin", thumbIcon:"thumbIcon", trackDisabledSkin:"trackDisabledSkin", trackDownSkin:"trackDownSkin", trackOverSkin:"trackOverSkin", trackUpSkin:"trackUpSkin", repeatDelay:"repeatDelay", repeatInterval:"repeatInterval", textFormat:"textFormat", disabledAlpha:"disabledAlpha", skin:"listSkin"}; private static var defaultStyles:Object = {upSkin:"ComboBox_upSkin", downSkin:"ComboBox_downSkin", overSkin:"ComboBox_overSkin", disabledSkin:"ComboBox_disabledSkin", focusRectSkin:null, focusRectPadding:null, textFormat:null, disabledTextFormat:null, textPadding:3, buttonWidth:24, disabledAlpha:null, listSkin:null}; public static var createAccessibilityImplementation:Function; public function ComboBox(){ _rowCount = 5; _editable = false; isOpen = false; highlightedCell = -1; isKeyDown = false; super(); } protected function drawList():void{ list.rowCount = Math.max(0, Math.min(_rowCount, list.dataProvider.length)); } public function set imeMode(_arg1:String):void{ inputField.imeMode = _arg1; } public function get dropdown():List{ return (list); } public function get dropdownWidth():Number{ return (list.width); } public function sortItemsOn(_arg1:String, _arg2:Object=null){ return (list.sortItemsOn(_arg1, _arg2)); } protected function onEnter(_arg1:ComponentEvent):void{ _arg1.stopPropagation(); } public function removeItemAt(_arg1:uint):void{ list.removeItemAt(_arg1); invalidate(InvalidationType.DATA); } public function open():void{ currentIndex = selectedIndex; if (((isOpen) || ((length == 0)))){ return; }; dispatchEvent(new Event(Event.OPEN)); isOpen = true; addEventListener(Event.ENTER_FRAME, addCloseListener, false, 0, true); positionList(); list.scrollToSelected(); stage.addChild(list); } public function get selectedItem():Object{ return (list.selectedItem); } public function set text(_arg1:String):void{ if (!editable){ return; }; inputField.text = _arg1; } public function get labelField():String{ return (list.labelField); } override protected function keyDownHandler(_arg1:KeyboardEvent):void{ var _local2:int; var _local3:uint; var _local4:Number; var _local5:int; isKeyDown = true; if (_arg1.ctrlKey){ switch (_arg1.keyCode){ case Keyboard.UP: if (highlightedCell > -1){ selectedIndex = highlightedCell; dispatchEvent(new Event(Event.CHANGE)); }; close(); break; case Keyboard.DOWN: open(); break; }; return; }; _arg1.stopPropagation(); _local2 = Math.max(((calculateAvailableHeight() / list.rowHeight) << 0), 1); _local3 = selectedIndex; _local4 = ((highlightedCell)==-1) ? selectedIndex : highlightedCell; _local5 = -1; switch (_arg1.keyCode){ case Keyboard.SPACE: if (isOpen){ close(); } else { open(); }; return; case Keyboard.ESCAPE: if (isOpen){ if (highlightedCell > -1){ selectedIndex = selectedIndex; }; close(); }; return; case Keyboard.UP: _local5 = Math.max(0, (_local4 - 1)); break; case Keyboard.DOWN: _local5 = Math.min((length - 1), (_local4 + 1)); break; case Keyboard.PAGE_UP: _local5 = Math.max((_local4 - _local2), 0); break; case Keyboard.PAGE_DOWN: _local5 = Math.min((_local4 + _local2), (length - 1)); break; case Keyboard.HOME: _local5 = 0; break; case Keyboard.END: _local5 = (length - 1); break; case Keyboard.ENTER: if (((_editable) && ((highlightedCell == -1)))){ editableValue = inputField.text; selectedIndex = -1; } else { if (((isOpen) && ((highlightedCell > -1)))){ editableValue = null; selectedIndex = highlightedCell; dispatchEvent(new Event(Event.CHANGE)); }; }; dispatchEvent(new ComponentEvent(ComponentEvent.ENTER)); close(); return; default: if (editable){ break; }; _local5 = list.getNextIndexAtLetter(String.fromCharCode(_arg1.keyCode), _local4); break; }; if (_local5 > -1){ if (isOpen){ highlightCell(_local5); inputField.text = list.itemToLabel(getItemAt(_local5)); } else { highlightCell(); selectedIndex = _local5; dispatchEvent(new Event(Event.CHANGE)); }; }; } public function set dropdownWidth(_arg1:Number):void{ _dropdownWidth = _arg1; invalidate(InvalidationType.SIZE); } public function get editable():Boolean{ return (_editable); } override protected function focusInHandler(_arg1:FocusEvent):void{ super.focusInHandler(_arg1); if (editable){ stage.focus = inputField.textField; }; } protected function onStageClick(_arg1:MouseEvent):void{ if (!isOpen){ return; }; if (((!(contains((_arg1.target as DisplayObject)))) && (!(list.contains((_arg1.target as DisplayObject)))))){ if (highlightedCell != -1){ selectedIndex = highlightedCell; dispatchEvent(new Event(Event.CHANGE)); }; close(); }; } protected function handleDataChange(_arg1:DataChangeEvent):void{ invalidate(InvalidationType.DATA); } override protected function keyUpHandler(_arg1:KeyboardEvent):void{ isKeyDown = false; } protected function onListItemUp(_arg1:MouseEvent):void{ var _local2:*; stage.removeEventListener(MouseEvent.MOUSE_UP, onListItemUp); if (((!((_arg1.target is ICellRenderer))) || (!(list.contains((_arg1.target as DisplayObject)))))){ return; }; editableValue = null; _local2 = selectedIndex; selectedIndex = _arg1.target.listData.index; if (_local2 != selectedIndex){ dispatchEvent(new Event(Event.CHANGE)); }; close(); } public function removeAll():void{ list.removeAll(); inputField.text = ""; invalidate(InvalidationType.DATA); } public function set selectedItem(_arg1:Object):void{ list.selectedItem = _arg1; invalidate(InvalidationType.SELECTED); } protected function highlightCell(_arg1:int=-1):void{ var _local2:ICellRenderer; if (highlightedCell > -1){ _local2 = list.itemToCellRenderer(getItemAt(highlightedCell)); if (_local2 != null){ _local2.setMouseState("up"); }; }; if (_arg1 == -1){ return; }; list.scrollToIndex(_arg1); list.drawNow(); _local2 = list.itemToCellRenderer(getItemAt(_arg1)); if (_local2 != null){ _local2.setMouseState("over"); highlightedCell = _arg1; }; } public function itemToLabel(_arg1:Object):String{ if (_arg1 == null){ return (""); }; return (list.itemToLabel(_arg1)); } public function addItemAt(_arg1:Object, _arg2:uint):void{ list.addItemAt(_arg1, _arg2); invalidate(InvalidationType.DATA); } public function replaceItemAt(_arg1:Object, _arg2:uint):Object{ return (list.replaceItemAt(_arg1, _arg2)); } protected function showPrompt():void{ inputField.text = _prompt; } public function set rowCount(_arg1:uint):void{ _rowCount = _arg1; invalidate(InvalidationType.SIZE); } public function get restrict():String{ return (inputField.restrict); } protected function setEmbedFonts():void{ var _local1:Object; _local1 = getStyleValue("embedFonts"); if (_local1 != null){ inputField.textField.embedFonts = _local1; }; } public function sortItems(... _args){ return (list.sortItems.apply(list, _args)); } public function set labelField(_arg1:String):void{ list.labelField = _arg1; invalidate(InvalidationType.DATA); } public function set editable(_arg1:Boolean):void{ _editable = _arg1; drawTextField(); } public function set prompt(_arg1:String):void{ if (_arg1 == ""){ _prompt = null; } else { _prompt = _arg1; }; invalidate(InvalidationType.STATE); } public function get length():int{ return (list.length); } protected function drawTextField():void{ inputField.setStyle("upSkin", ""); inputField.setStyle("disabledSkin", ""); inputField.enabled = enabled; inputField.editable = _editable; inputField.textField.selectable = ((enabled) && (_editable)); inputField.mouseEnabled = (inputField.mouseChildren = ((enabled) && (_editable))); inputField.focusEnabled = false; if (_editable){ inputField.addEventListener(FocusEvent.FOCUS_IN, onInputFieldFocus, false, 0, true); inputField.addEventListener(FocusEvent.FOCUS_OUT, onInputFieldFocusOut, false, 0, true); } else { inputField.removeEventListener(FocusEvent.FOCUS_IN, onInputFieldFocus); inputField.removeEventListener(FocusEvent.FOCUS_OUT, onInputFieldFocusOut); }; } protected function onInputFieldFocusOut(_arg1:FocusEvent):void{ inputField.removeEventListener(ComponentEvent.ENTER, onEnter); selectedIndex = selectedIndex; } protected function passEvent(_arg1:Event):void{ dispatchEvent(_arg1); } public function get imeMode():String{ return (inputField.imeMode); } public function get labelFunction():Function{ return (list.labelFunction); } protected function calculateAvailableHeight():Number{ var _local1:Number; _local1 = Number(getStyleValue("contentPadding")); return ((list.height - (_local1 * 2))); } public function get selectedIndex():int{ return (list.selectedIndex); } override protected function focusOutHandler(_arg1:FocusEvent):void{ isKeyDown = false; if (isOpen){ if (((!(_arg1.relatedObject)) || (!(list.contains(_arg1.relatedObject))))){ if (((!((highlightedCell == -1))) && (!((highlightedCell == selectedIndex))))){ selectedIndex = highlightedCell; dispatchEvent(new Event(Event.CHANGE)); }; close(); }; }; super.focusOutHandler(_arg1); } public function get selectedLabel():String{ if (editableValue != null){ return (editableValue); }; if (selectedIndex == -1){ return (null); }; return (itemToLabel(selectedItem)); } public function get text():String{ return (inputField.text); } protected function onListChange(_arg1:Event):void{ editableValue = null; dispatchEvent(_arg1); invalidate(InvalidationType.SELECTED); if (isKeyDown){ return; }; close(); } protected function onToggleListVisibility(_arg1:MouseEvent):void{ _arg1.stopPropagation(); dispatchEvent(_arg1); if (isOpen){ close(); } else { open(); stage.addEventListener(MouseEvent.MOUSE_UP, onListItemUp, false, 0, true); }; } override protected function draw():void{ var _local1:*; _local1 = selectedIndex; if ((((_local1 == -1)) && (((((!((prompt == null))) || (editable))) || ((length == 0)))))){ _local1 = Math.max(-1, Math.min(_local1, (length - 1))); } else { editableValue = null; _local1 = Math.max(0, Math.min(_local1, (length - 1))); }; if (list.selectedIndex != _local1){ list.selectedIndex = _local1; invalidate(InvalidationType.SELECTED, false); }; if (isInvalid(InvalidationType.STYLES)){ setStyles(); setEmbedFonts(); invalidate(InvalidationType.SIZE, false); }; if (isInvalid(InvalidationType.SIZE, InvalidationType.DATA, InvalidationType.STATE)){ drawTextFormat(); drawLayout(); invalidate(InvalidationType.DATA); }; if (isInvalid(InvalidationType.DATA)){ drawList(); invalidate(InvalidationType.SELECTED, true); }; if (isInvalid(InvalidationType.SELECTED)){ if ((((_local1 == -1)) && (!((editableValue == null))))){ inputField.text = editableValue; } else { if (_local1 > -1){ if (length > 0){ inputField.horizontalScrollPosition = 0; inputField.text = itemToLabel(list.selectedItem); }; } else { if ((((_local1 == -1)) && (!((_prompt == null))))){ showPrompt(); } else { inputField.text = ""; }; }; }; if (((((editable) && ((selectedIndex > -1)))) && ((stage.focus == inputField.textField)))){ inputField.setSelection(0, inputField.length); }; }; drawTextField(); super.draw(); } public function addItem(_arg1:Object):void{ list.addItem(_arg1); invalidate(InvalidationType.DATA); } public function get rowCount():uint{ return (_rowCount); } override protected function configUI():void{ super.configUI(); background = new BaseButton(); background.focusEnabled = false; copyStylesToChild(background, BACKGROUND_STYLES); background.addEventListener(MouseEvent.MOUSE_DOWN, onToggleListVisibility, false, 0, true); addChild(background); inputField = new TextInput(); inputField.focusTarget = (this as IFocusManagerComponent); inputField.focusEnabled = false; inputField.addEventListener(Event.CHANGE, onTextInput, false, 0, true); addChild(inputField); list = new List(); list.focusEnabled = false; copyStylesToChild(list, LIST_STYLES); list.addEventListener(Event.CHANGE, onListChange, false, 0, true); list.addEventListener(ListEvent.ITEM_CLICK, onListChange, false, 0, true); list.addEventListener(ListEvent.ITEM_ROLL_OUT, passEvent, false, 0, true); list.addEventListener(ListEvent.ITEM_ROLL_OVER, passEvent, false, 0, true); list.verticalScrollBar.addEventListener(Event.SCROLL, passEvent, false, 0, true); } protected function positionList():void{ var _local1:Point; _local1 = localToGlobal(new Point(0, 0)); list.x = _local1.x; if (((_local1.y + height) + list.height) > stage.stageHeight){ list.y = (_local1.y - list.height); } else { list.y = (_local1.y + height); }; } public function get value():String{ var _local1:Object; if (editableValue != null){ return (editableValue); }; _local1 = selectedItem; if (((!(_editable)) && (!((_local1.data == null))))){ return (_local1.data); }; return (itemToLabel(_local1)); } public function get prompt():String{ return (_prompt); } public function set dataProvider(_arg1:DataProvider):void{ _arg1.addEventListener(DataChangeEvent.DATA_CHANGE, handleDataChange, false, 0, true); list.dataProvider = _arg1; invalidate(InvalidationType.DATA); } public function set restrict(_arg1:String):void{ if (((componentInspectorSetting) && ((_arg1 == "")))){ _arg1 = null; }; if (!_editable){ return; }; inputField.restrict = _arg1; } protected function onTextInput(_arg1:Event):void{ _arg1.stopPropagation(); if (!_editable){ return; }; editableValue = inputField.text; selectedIndex = -1; dispatchEvent(new Event(Event.CHANGE)); } protected function onInputFieldFocus(_arg1:FocusEvent):void{ inputField.addEventListener(ComponentEvent.ENTER, onEnter, false, 0, true); close(); } public function getItemAt(_arg1:uint):Object{ return (list.getItemAt(_arg1)); } override protected function initializeAccessibility():void{ if (ComboBox.createAccessibilityImplementation != null){ ComboBox.createAccessibilityImplementation(this); }; } protected function drawLayout():void{ var _local1:Number; var _local2:Number; _local1 = (getStyleValue("buttonWidth") as Number); _local2 = (getStyleValue("textPadding") as Number); background.setSize(width, height); inputField.x = (inputField.y = _local2); inputField.setSize(((width - _local1) - _local2), (height - _local2)); list.width = (isNaN(_dropdownWidth)) ? width : _dropdownWidth; background.enabled = enabled; background.drawNow(); } public function removeItem(_arg1:Object):Object{ return (list.removeItem(_arg1)); } private function addCloseListener(_arg1:Event){ removeEventListener(Event.ENTER_FRAME, addCloseListener); if (!isOpen){ return; }; stage.addEventListener(MouseEvent.MOUSE_DOWN, onStageClick, false, 0, true); } public function get dataProvider():DataProvider{ return (list.dataProvider); } public function get textField():TextInput{ return (inputField); } protected function setStyles():void{ copyStylesToChild(background, BACKGROUND_STYLES); copyStylesToChild(list, LIST_STYLES); } public function set labelFunction(_arg1:Function):void{ list.labelFunction = _arg1; invalidate(InvalidationType.DATA); } protected function drawTextFormat():void{ var _local1:TextFormat; _local1 = (getStyleValue((_enabled) ? "textFormat" : "disabledTextFormat") as TextFormat); if (_local1 == null){ _local1 = new TextFormat(); }; inputField.textField.defaultTextFormat = _local1; inputField.textField.setTextFormat(_local1); setEmbedFonts(); } public function set selectedIndex(_arg1:int):void{ list.selectedIndex = _arg1; highlightCell(); invalidate(InvalidationType.SELECTED); } public function close():void{ highlightCell(); highlightedCell = -1; if (!isOpen){ return; }; dispatchEvent(new Event(Event.CLOSE)); stage.removeEventListener(MouseEvent.MOUSE_DOWN, onStageClick); isOpen = false; stage.removeChild(list); } public static function getStyleDefinition():Object{ return (mergeStyles(defaultStyles, List.getStyleDefinition())); } } }//package fl.controls
Section 126
//LabelButton (fl.controls.LabelButton) package fl.controls { import fl.core.*; import flash.display.*; import flash.events.*; import fl.managers.*; import fl.events.*; import flash.text.*; import flash.ui.*; public class LabelButton extends BaseButton implements IFocusManagerComponent { protected var _labelPlacement:String;// = "right" protected var _toggle:Boolean;// = false protected var icon:DisplayObject; protected var oldMouseState:String; protected var mode:String;// = "center" public var textField:TextField; protected var _label:String;// = "Label" private static var defaultStyles:Object = {icon:null, upIcon:null, downIcon:null, overIcon:null, disabledIcon:null, selectedDisabledIcon:null, selectedUpIcon:null, selectedDownIcon:null, selectedOverIcon:null, textFormat:null, disabledTextFormat:null, textPadding:5, embedFonts:false}; public static var createAccessibilityImplementation:Function; public function LabelButton(){ _labelPlacement = ButtonLabelPlacement.RIGHT; _toggle = false; _label = "Label"; mode = "center"; super(); } protected function toggleSelected(_arg1:MouseEvent):void{ selected = !(selected); dispatchEvent(new Event(Event.CHANGE, true)); } public function get labelPlacement():String{ return (_labelPlacement); } override protected function keyDownHandler(_arg1:KeyboardEvent):void{ if (!enabled){ return; }; if (_arg1.keyCode == Keyboard.SPACE){ if (oldMouseState == null){ oldMouseState = mouseState; }; setMouseState("down"); startPress(); }; } protected function setEmbedFont(){ var _local1:Object; _local1 = getStyleValue("embedFonts"); if (_local1 != null){ textField.embedFonts = _local1; }; } override protected function keyUpHandler(_arg1:KeyboardEvent):void{ if (!enabled){ return; }; if (_arg1.keyCode == Keyboard.SPACE){ setMouseState(oldMouseState); oldMouseState = null; endPress(); dispatchEvent(new MouseEvent(MouseEvent.CLICK)); }; } override public function get selected():Boolean{ return ((_toggle) ? _selected : false); } public function set labelPlacement(_arg1:String):void{ _labelPlacement = _arg1; invalidate(InvalidationType.SIZE); } public function set toggle(_arg1:Boolean):void{ if (((!(_arg1)) && (super.selected))){ selected = false; }; _toggle = _arg1; if (_toggle){ addEventListener(MouseEvent.CLICK, toggleSelected, false, 0, true); } else { removeEventListener(MouseEvent.CLICK, toggleSelected); }; invalidate(InvalidationType.STATE); } public function get label():String{ return (_label); } override public function set selected(_arg1:Boolean):void{ _selected = _arg1; if (_toggle){ invalidate(InvalidationType.STATE); }; } override protected function draw():void{ if (textField.text != _label){ label = _label; }; if (isInvalid(InvalidationType.STYLES, InvalidationType.STATE)){ drawBackground(); drawIcon(); drawTextFormat(); invalidate(InvalidationType.SIZE, false); }; if (isInvalid(InvalidationType.SIZE)){ drawLayout(); }; if (isInvalid(InvalidationType.SIZE, InvalidationType.STYLES)){ if (((isFocused) && (focusManager.showFocusIndicator))){ drawFocus(true); }; }; validate(); } public function get toggle():Boolean{ return (_toggle); } override protected function configUI():void{ super.configUI(); textField = new TextField(); textField.type = TextFieldType.DYNAMIC; textField.selectable = false; addChild(textField); } override protected function drawLayout():void{ var _local1:Number; var _local2:String; var _local3:Number; var _local4:Number; var _local5:Number; var _local6:Number; var _local7:Number; var _local8:Number; _local1 = Number(getStyleValue("textPadding")); _local2 = ((((icon == null)) && ((mode == "center")))) ? ButtonLabelPlacement.TOP : _labelPlacement; textField.height = (textField.textHeight + 4); _local3 = (textField.textWidth + 4); _local4 = (textField.textHeight + 4); _local5 = ((icon)==null) ? 0 : (icon.width + _local1); _local6 = ((icon)==null) ? 0 : (icon.height + _local1); textField.visible = (label.length > 0); if (icon != null){ icon.x = Math.round(((width - icon.width) / 2)); icon.y = Math.round(((height - icon.height) / 2)); }; if (textField.visible == false){ textField.width = 0; textField.height = 0; } else { if ((((_local2 == ButtonLabelPlacement.BOTTOM)) || ((_local2 == ButtonLabelPlacement.TOP)))){ _local7 = Math.max(0, Math.min(_local3, (width - (2 * _local1)))); if ((height - 2) > _local4){ _local8 = _local4; } else { _local8 = (height - 2); }; _local3 = _local7; textField.width = _local3; _local4 = _local8; textField.height = _local4; textField.x = Math.round(((width - _local3) / 2)); textField.y = Math.round(((((height - textField.height) - _local6) / 2) + ((_local2)==ButtonLabelPlacement.BOTTOM) ? _local6 : 0)); if (icon != null){ icon.y = Math.round(((_local2)==ButtonLabelPlacement.BOTTOM) ? (textField.y - _local6) : ((textField.y + textField.height) + _local1)); }; } else { _local7 = Math.max(0, Math.min(_local3, ((width - _local5) - (2 * _local1)))); _local3 = _local7; textField.width = _local3; textField.x = Math.round(((((width - _local3) - _local5) / 2) + ((_local2)!=ButtonLabelPlacement.LEFT) ? _local5 : 0)); textField.y = Math.round(((height - textField.height) / 2)); if (icon != null){ icon.x = Math.round(((_local2)!=ButtonLabelPlacement.LEFT) ? (textField.x - _local5) : ((textField.x + _local3) + _local1)); }; }; }; super.drawLayout(); } override protected function initializeAccessibility():void{ if (LabelButton.createAccessibilityImplementation != null){ LabelButton.createAccessibilityImplementation(this); }; } protected function drawIcon():void{ var _local1:DisplayObject; var _local2:String; var _local3:Object; _local1 = icon; _local2 = (enabled) ? mouseState : "disabled"; if (selected){ _local2 = (("selected" + _local2.substr(0, 1).toUpperCase()) + _local2.substr(1)); }; _local2 = (_local2 + "Icon"); _local3 = getStyleValue(_local2); if (_local3 == null){ _local3 = getStyleValue("icon"); }; if (_local3 != null){ icon = getDisplayObjectInstance(_local3); }; if (icon != null){ addChildAt(icon, 1); }; if (((!((_local1 == null))) && (!((_local1 == icon))))){ removeChild(_local1); }; } public function set label(_arg1:String):void{ _label = _arg1; if (textField.text != _label){ textField.text = _label; dispatchEvent(new ComponentEvent(ComponentEvent.LABEL_CHANGE)); }; invalidate(InvalidationType.SIZE); invalidate(InvalidationType.STYLES); } protected function drawTextFormat():void{ var _local1:Object; var _local2:TextFormat; var _local3:TextFormat; _local1 = UIComponent.getStyleDefinition(); _local2 = (enabled) ? (_local1.defaultTextFormat as TextFormat) : (_local1.defaultDisabledTextFormat as TextFormat); textField.setTextFormat(_local2); _local3 = (getStyleValue((enabled) ? "textFormat" : "disabledTextFormat") as TextFormat); if (_local3 != null){ textField.setTextFormat(_local3); } else { _local3 = _local2; }; textField.defaultTextFormat = _local3; setEmbedFont(); } public static function getStyleDefinition():Object{ return (mergeStyles(defaultStyles, BaseButton.getStyleDefinition())); } } }//package fl.controls
Section 127
//List (fl.controls.List) package fl.controls { import fl.controls.listClasses.*; import fl.core.*; import flash.display.*; import flash.events.*; import flash.geom.*; import fl.managers.*; import flash.utils.*; import flash.ui.*; public class List extends SelectableList implements IFocusManagerComponent { protected var _labelField:String;// = "label" protected var _rowHeight:Number;// = 20 protected var _cellRenderer:Object; protected var _iconField:String;// = "icon" protected var _labelFunction:Function; protected var _iconFunction:Function; private static var defaultStyles:Object = {focusRectSkin:null, focusRectPadding:null}; public static var createAccessibilityImplementation:Function; public function List(){ _rowHeight = 20; _labelField = "label"; _iconField = "icon"; super(); } public function get iconField():String{ return (_iconField); } protected function doKeySelection(_arg1:int, _arg2:Boolean, _arg3:Boolean):void{ var _local4:Boolean; var _local5:int; var _local6:Array; var _local7:int; var _local8:int; _local4 = false; if (_arg2){ _local6 = []; _local7 = lastCaretIndex; _local8 = _arg1; if (_local7 == -1){ _local7 = ((caretIndex)!=-1) ? caretIndex : _arg1; }; if (_local7 > _local8){ _local8 = _local7; _local7 = _arg1; }; _local5 = _local7; while (_local5 <= _local8) { _local6.push(_local5); _local5++; }; selectedIndices = _local6; caretIndex = _arg1; _local4 = true; } else { selectedIndex = _arg1; caretIndex = (lastCaretIndex = _arg1); _local4 = true; }; if (_local4){ dispatchEvent(new Event(Event.CHANGE)); }; invalidate(InvalidationType.DATA); } override protected function drawList():void{ var _local1:Rectangle; var _local2:uint; var _local3:uint; var _local4:uint; var _local5:Object; var _local6:ICellRenderer; var _local7:Dictionary; var _local8:Dictionary; var _local9:Boolean; var _local10:String; var _local11:Object; var _local12:Sprite; var _local13:String; listHolder.x = (listHolder.y = contentPadding); _local1 = listHolder.scrollRect; _local1.x = _horizontalScrollPosition; _local1.y = (Math.floor(_verticalScrollPosition) % rowHeight); listHolder.scrollRect = _local1; listHolder.cacheAsBitmap = useBitmapScrolling; _local2 = Math.floor((_verticalScrollPosition / rowHeight)); _local3 = Math.min(length, ((_local2 + rowCount) + 1)); _local7 = (renderedItems = new Dictionary(true)); _local4 = _local2; while (_local4 < _local3) { _local7[_dataProvider.getItemAt(_local4)] = true; _local4++; }; _local8 = new Dictionary(true); while (activeCellRenderers.length > 0) { _local6 = (activeCellRenderers.pop() as ICellRenderer); _local5 = _local6.data; if ((((_local7[_local5] == null)) || ((invalidItems[_local5] == true)))){ availableCellRenderers.push(_local6); } else { _local8[_local5] = _local6; invalidItems[_local5] = true; }; list.removeChild((_local6 as DisplayObject)); }; invalidItems = new Dictionary(true); _local4 = _local2; while (_local4 < _local3) { _local9 = false; _local5 = _dataProvider.getItemAt(_local4); if (_local8[_local5] != null){ _local9 = true; _local6 = _local8[_local5]; delete _local8[_local5]; } else { if (availableCellRenderers.length > 0){ _local6 = (availableCellRenderers.pop() as ICellRenderer); } else { _local6 = (getDisplayObjectInstance(getStyleValue("cellRenderer")) as ICellRenderer); _local12 = (_local6 as Sprite); if (_local12 != null){ _local12.addEventListener(MouseEvent.CLICK, handleCellRendererClick, false, 0, true); _local12.addEventListener(MouseEvent.ROLL_OVER, handleCellRendererMouseEvent, false, 0, true); _local12.addEventListener(MouseEvent.ROLL_OUT, handleCellRendererMouseEvent, false, 0, true); _local12.addEventListener(Event.CHANGE, handleCellRendererChange, false, 0, true); _local12.doubleClickEnabled = true; _local12.addEventListener(MouseEvent.DOUBLE_CLICK, handleCellRendererDoubleClick, false, 0, true); if (_local12["setStyle"] != null){ for (_local13 in rendererStyles) { var _local16 = _local12; _local16["setStyle"](_local13, rendererStyles[_local13]); }; }; }; }; }; list.addChild((_local6 as Sprite)); activeCellRenderers.push(_local6); _local6.y = (rowHeight * (_local4 - _local2)); _local6.setSize((availableWidth + _maxHorizontalScrollPosition), rowHeight); _local10 = itemToLabel(_local5); _local11 = null; if (_iconFunction != null){ _local11 = _iconFunction(_local5); } else { if (_iconField != null){ _local11 = _local5[_iconField]; }; }; if (!_local9){ _local6.data = _local5; }; _local6.listData = new ListData(_local10, _local11, this, _local4, _local4, 0); _local6.selected = !((_selectedIndices.indexOf(_local4) == -1)); if ((_local6 is UIComponent)){ (_local6 as UIComponent).drawNow(); }; _local4++; }; } public function get iconFunction():Function{ return (_iconFunction); } public function set iconField(_arg1:String):void{ if (_arg1 == _iconField){ return; }; _iconField = _arg1; invalidate(InvalidationType.DATA); } override protected function keyDownHandler(_arg1:KeyboardEvent):void{ var _local2:int; if (!selectable){ return; }; switch (_arg1.keyCode){ case Keyboard.UP: case Keyboard.DOWN: case Keyboard.END: case Keyboard.HOME: case Keyboard.PAGE_UP: case Keyboard.PAGE_DOWN: moveSelectionVertically(_arg1.keyCode, ((_arg1.shiftKey) && (_allowMultipleSelection)), ((_arg1.ctrlKey) && (_allowMultipleSelection))); break; case Keyboard.LEFT: case Keyboard.RIGHT: moveSelectionHorizontally(_arg1.keyCode, ((_arg1.shiftKey) && (_allowMultipleSelection)), ((_arg1.ctrlKey) && (_allowMultipleSelection))); break; case Keyboard.SPACE: if (caretIndex == -1){ caretIndex = 0; }; doKeySelection(caretIndex, _arg1.shiftKey, _arg1.ctrlKey); scrollToSelected(); break; default: _local2 = getNextIndexAtLetter(String.fromCharCode(_arg1.keyCode), selectedIndex); if (_local2 > -1){ selectedIndex = _local2; scrollToSelected(); }; break; }; _arg1.stopPropagation(); } override public function itemToLabel(_arg1:Object):String{ if (_labelFunction != null){ return (String(_labelFunction(_arg1))); }; return (((_arg1[_labelField])!=null) ? String(_arg1[_labelField]) : ""); } public function get labelField():String{ return (_labelField); } override protected function moveSelectionVertically(_arg1:uint, _arg2:Boolean, _arg3:Boolean):void{ var _local4:int; var _local5:int; var _local6:int; _local4 = Math.max(Math.floor((calculateAvailableHeight() / rowHeight)), 1); _local5 = -1; _local6 = 0; switch (_arg1){ case Keyboard.UP: if (caretIndex > 0){ _local5 = (caretIndex - 1); }; break; case Keyboard.DOWN: if (caretIndex < (length - 1)){ _local5 = (caretIndex + 1); }; break; case Keyboard.PAGE_UP: if (caretIndex > 0){ _local5 = Math.max((caretIndex - _local4), 0); }; break; case Keyboard.PAGE_DOWN: if (caretIndex < (length - 1)){ _local5 = Math.min((caretIndex + _local4), (length - 1)); }; break; case Keyboard.HOME: if (caretIndex > 0){ _local5 = 0; }; break; case Keyboard.END: if (caretIndex < (length - 1)){ _local5 = (length - 1); }; break; }; if (_local5 >= 0){ doKeySelection(_local5, _arg2, _arg3); scrollToSelected(); }; } public function set labelField(_arg1:String):void{ if (_arg1 == _labelField){ return; }; _labelField = _arg1; invalidate(InvalidationType.DATA); } public function set rowCount(_arg1:uint):void{ var _local2:Number; var _local3:Number; _local2 = Number(getStyleValue("contentPadding")); _local3 = ((((_horizontalScrollPolicy == ScrollPolicy.ON)) || ((((_horizontalScrollPolicy == ScrollPolicy.AUTO)) && ((_maxHorizontalScrollPosition > 0)))))) ? 15 : 0; height = (((rowHeight * _arg1) + (2 * _local2)) + _local3); } override protected function setHorizontalScrollPosition(_arg1:Number, _arg2:Boolean=false):void{ list.x = -(_arg1); super.setHorizontalScrollPosition(_arg1, true); } public function set iconFunction(_arg1:Function):void{ if (_iconFunction == _arg1){ return; }; _iconFunction = _arg1; invalidate(InvalidationType.DATA); } public function get labelFunction():Function{ return (_labelFunction); } override protected function moveSelectionHorizontally(_arg1:uint, _arg2:Boolean, _arg3:Boolean):void{ } override protected function setVerticalScrollPosition(_arg1:Number, _arg2:Boolean=false):void{ invalidate(InvalidationType.SCROLL); super.setVerticalScrollPosition(_arg1, true); } protected function calculateAvailableHeight():Number{ var _local1:Number; _local1 = Number(getStyleValue("contentPadding")); return (((height - (_local1 * 2)) - ((((_horizontalScrollPolicy == ScrollPolicy.ON)) || ((((_horizontalScrollPolicy == ScrollPolicy.AUTO)) && ((_maxHorizontalScrollPosition > 0)))))) ? 15 : 0)); } override protected function draw():void{ var _local1:Boolean; _local1 = !((contentHeight == (rowHeight * length))); contentHeight = (rowHeight * length); if (isInvalid(InvalidationType.STYLES)){ setStyles(); drawBackground(); if (contentPadding != getStyleValue("contentPadding")){ invalidate(InvalidationType.SIZE, false); }; if (_cellRenderer != getStyleValue("cellRenderer")){ _invalidateList(); _cellRenderer = getStyleValue("cellRenderer"); }; }; if (((isInvalid(InvalidationType.SIZE, InvalidationType.STATE)) || (_local1))){ drawLayout(); }; if (isInvalid(InvalidationType.RENDERER_STYLES)){ updateRendererStyles(); }; if (isInvalid(InvalidationType.STYLES, InvalidationType.SIZE, InvalidationType.DATA, InvalidationType.SCROLL, InvalidationType.SELECTED)){ drawList(); }; updateChildren(); validate(); } override protected function configUI():void{ useFixedHorizontalScrolling = true; _horizontalScrollPolicy = ScrollPolicy.AUTO; _verticalScrollPolicy = ScrollPolicy.AUTO; super.configUI(); } override public function get rowCount():uint{ return (Math.ceil((calculateAvailableHeight() / rowHeight))); } override protected function initializeAccessibility():void{ if (List.createAccessibilityImplementation != null){ List.createAccessibilityImplementation(this); }; } override public function scrollToIndex(_arg1:int):void{ var _local2:uint; var _local3:uint; drawNow(); _local2 = (Math.floor(((_verticalScrollPosition + availableHeight) / rowHeight)) - 1); _local3 = Math.ceil((_verticalScrollPosition / rowHeight)); if (_arg1 < _local3){ verticalScrollPosition = (_arg1 * rowHeight); } else { if (_arg1 > _local2){ verticalScrollPosition = (((_arg1 + 1) * rowHeight) - availableHeight); }; }; } public function get rowHeight():Number{ return (_rowHeight); } public function set labelFunction(_arg1:Function):void{ if (_labelFunction == _arg1){ return; }; _labelFunction = _arg1; invalidate(InvalidationType.DATA); } public function set rowHeight(_arg1:Number):void{ _rowHeight = _arg1; invalidate(InvalidationType.SIZE); } public static function getStyleDefinition():Object{ return (mergeStyles(defaultStyles, SelectableList.getStyleDefinition())); } } }//package fl.controls
Section 128
//ScrollBar (fl.controls.ScrollBar) package fl.controls { import fl.core.*; import flash.events.*; import fl.events.*; public class ScrollBar extends UIComponent { private var _direction:String;// = "vertical" protected var inDrag:Boolean;// = false protected var upArrow:BaseButton; private var _pageScrollSize:Number;// = 0 protected var downArrow:BaseButton; private var _pageSize:Number;// = 10 private var thumbScrollOffset:Number; private var _maxScrollPosition:Number;// = 0 private var _scrollPosition:Number;// = 0 protected var track:BaseButton; private var _minScrollPosition:Number;// = 0 private var _lineScrollSize:Number;// = 1 protected var thumb:LabelButton; protected static const THUMB_STYLES:Object = {disabledSkin:"thumbDisabledSkin", downSkin:"thumbDownSkin", overSkin:"thumbOverSkin", upSkin:"thumbUpSkin", icon:"thumbIcon", textPadding:0}; public static const WIDTH:Number = 15; protected static const DOWN_ARROW_STYLES:Object = {disabledSkin:"downArrowDisabledSkin", downSkin:"downArrowDownSkin", overSkin:"downArrowOverSkin", upSkin:"downArrowUpSkin", repeatDelay:"repeatDelay", repeatInterval:"repeatInterval"}; protected static const UP_ARROW_STYLES:Object = {disabledSkin:"upArrowDisabledSkin", downSkin:"upArrowDownSkin", overSkin:"upArrowOverSkin", upSkin:"upArrowUpSkin", repeatDelay:"repeatDelay", repeatInterval:"repeatInterval"}; protected static const TRACK_STYLES:Object = {disabledSkin:"trackDisabledSkin", downSkin:"trackDownSkin", overSkin:"trackOverSkin", upSkin:"trackUpSkin", repeatDelay:"repeatDelay", repeatInterval:"repeatInterval"}; private static var defaultStyles:Object = {downArrowDisabledSkin:"ScrollArrowDown_disabledSkin", downArrowDownSkin:"ScrollArrowDown_downSkin", downArrowOverSkin:"ScrollArrowDown_overSkin", downArrowUpSkin:"ScrollArrowDown_upSkin", thumbDisabledSkin:"ScrollThumb_upSkin", thumbDownSkin:"ScrollThumb_downSkin", thumbOverSkin:"ScrollThumb_overSkin", thumbUpSkin:"ScrollThumb_upSkin", trackDisabledSkin:"ScrollTrack_skin", trackDownSkin:"ScrollTrack_skin", trackOverSkin:"ScrollTrack_skin", trackUpSkin:"ScrollTrack_skin", upArrowDisabledSkin:"ScrollArrowUp_disabledSkin", upArrowDownSkin:"ScrollArrowUp_downSkin", upArrowOverSkin:"ScrollArrowUp_overSkin", upArrowUpSkin:"ScrollArrowUp_upSkin", thumbIcon:"ScrollBar_thumbIcon", repeatDelay:500, repeatInterval:35}; public function ScrollBar(){ _pageSize = 10; _pageScrollSize = 0; _lineScrollSize = 1; _minScrollPosition = 0; _maxScrollPosition = 0; _scrollPosition = 0; _direction = ScrollBarDirection.VERTICAL; inDrag = false; super(); setStyles(); focusEnabled = false; } public function get minScrollPosition():Number{ return (_minScrollPosition); } public function set minScrollPosition(_arg1:Number):void{ setScrollProperties(_pageSize, _arg1, _maxScrollPosition); } public function setScrollPosition(_arg1:Number, _arg2:Boolean=true):void{ var _local3:Number; _local3 = scrollPosition; _scrollPosition = Math.max(_minScrollPosition, Math.min(_maxScrollPosition, _arg1)); if (_local3 == _scrollPosition){ return; }; if (_arg2){ dispatchEvent(new ScrollEvent(_direction, (scrollPosition - _local3), scrollPosition)); }; updateThumb(); } public function set scrollPosition(_arg1:Number):void{ setScrollPosition(_arg1, true); } public function get pageScrollSize():Number{ return (((_pageScrollSize)==0) ? _pageSize : _pageScrollSize); } public function set pageSize(_arg1:Number):void{ if (_arg1 > 0){ _pageSize = _arg1; }; } public function setScrollProperties(_arg1:Number, _arg2:Number, _arg3:Number, _arg4:Number=0):void{ this.pageSize = _arg1; _minScrollPosition = _arg2; _maxScrollPosition = _arg3; if (_arg4 >= 0){ _pageScrollSize = _arg4; }; enabled = (_maxScrollPosition > _minScrollPosition); setScrollPosition(_scrollPosition, false); updateThumb(); } override public function set enabled(_arg1:Boolean):void{ super.enabled = _arg1; downArrow.enabled = (track.enabled = (thumb.enabled = (upArrow.enabled = ((enabled) && ((_maxScrollPosition > _minScrollPosition)))))); updateThumb(); } protected function updateThumb():void{ var _local1:Number; _local1 = ((_maxScrollPosition - _minScrollPosition) + _pageSize); if ((((((track.height <= 12)) || ((_maxScrollPosition <= _minScrollPosition)))) || ((((_local1 == 0)) || (isNaN(_local1)))))){ thumb.height = 12; thumb.visible = false; } else { thumb.height = Math.max(13, ((_pageSize / _local1) * track.height)); thumb.y = (track.y + ((track.height - thumb.height) * ((_scrollPosition - _minScrollPosition) / (_maxScrollPosition - _minScrollPosition)))); thumb.visible = enabled; }; } protected function thumbPressHandler(_arg1:MouseEvent):void{ inDrag = true; thumbScrollOffset = (mouseY - thumb.y); thumb.mouseStateLocked = true; mouseChildren = false; stage.addEventListener(MouseEvent.MOUSE_MOVE, handleThumbDrag, false, 0, true); stage.addEventListener(MouseEvent.MOUSE_UP, thumbReleaseHandler, false, 0, true); } protected function thumbReleaseHandler(_arg1:MouseEvent):void{ inDrag = false; mouseChildren = true; thumb.mouseStateLocked = false; stage.removeEventListener(MouseEvent.MOUSE_MOVE, handleThumbDrag); stage.removeEventListener(MouseEvent.MOUSE_UP, thumbReleaseHandler); } public function set pageScrollSize(_arg1:Number):void{ if (_arg1 >= 0){ _pageScrollSize = _arg1; }; } protected function handleThumbDrag(_arg1:MouseEvent):void{ var _local2:Number; _local2 = Math.max(0, Math.min((track.height - thumb.height), ((mouseY - track.y) - thumbScrollOffset))); setScrollPosition((((_local2 / (track.height - thumb.height)) * (_maxScrollPosition - _minScrollPosition)) + _minScrollPosition)); } public function set direction(_arg1:String):void{ var _local2:Boolean; if (_direction == _arg1){ return; }; _direction = _arg1; if (isLivePreview){ return; }; setScaleY(1); _local2 = (_direction == ScrollBarDirection.HORIZONTAL); if (((_local2) && (componentInspectorSetting))){ if (rotation == 90){ return; }; setScaleX(-1); rotation = -90; }; if (!componentInspectorSetting){ if (((_local2) && ((rotation == 0)))){ rotation = -90; setScaleX(-1); } else { if (((!(_local2)) && ((rotation == -90)))){ rotation = 0; setScaleX(1); }; }; }; invalidate(InvalidationType.SIZE); } public function set lineScrollSize(_arg1:Number):void{ if (_arg1 > 0){ _lineScrollSize = _arg1; }; } override public function get height():Number{ return (((_direction)==ScrollBarDirection.HORIZONTAL) ? super.width : super.height); } protected function scrollPressHandler(_arg1:ComponentEvent):void{ var _local2:Number; var _local3:Number; _arg1.stopImmediatePropagation(); if (_arg1.currentTarget == upArrow){ setScrollPosition((_scrollPosition - _lineScrollSize)); } else { if (_arg1.currentTarget == downArrow){ setScrollPosition((_scrollPosition + _lineScrollSize)); } else { _local2 = (((track.mouseY / track.height) * (_maxScrollPosition - _minScrollPosition)) + _minScrollPosition); _local3 = ((pageScrollSize)==0) ? pageSize : pageScrollSize; if (_scrollPosition < _local2){ setScrollPosition(Math.min(_local2, (_scrollPosition + _local3))); } else { if (_scrollPosition > _local2){ setScrollPosition(Math.max(_local2, (_scrollPosition - _local3))); }; }; }; }; } public function get pageSize():Number{ return (_pageSize); } public function set maxScrollPosition(_arg1:Number):void{ setScrollProperties(_pageSize, _minScrollPosition, _arg1); } public function get scrollPosition():Number{ return (_scrollPosition); } override public function get enabled():Boolean{ return (super.enabled); } override protected function draw():void{ var _local1:Number; if (isInvalid(InvalidationType.SIZE)){ _local1 = super.height; downArrow.move(0, Math.max(upArrow.height, (_local1 - downArrow.height))); track.setSize(WIDTH, Math.max(0, (_local1 - (downArrow.height + upArrow.height)))); updateThumb(); }; if (isInvalid(InvalidationType.STYLES, InvalidationType.STATE)){ setStyles(); }; downArrow.drawNow(); upArrow.drawNow(); track.drawNow(); thumb.drawNow(); validate(); } override protected function configUI():void{ super.configUI(); track = new BaseButton(); track.move(0, 14); track.useHandCursor = false; track.autoRepeat = true; track.focusEnabled = false; addChild(track); thumb = new LabelButton(); thumb.label = ""; thumb.setSize(WIDTH, 15); thumb.move(0, 15); thumb.focusEnabled = false; addChild(thumb); downArrow = new BaseButton(); downArrow.setSize(WIDTH, 14); downArrow.autoRepeat = true; downArrow.focusEnabled = false; addChild(downArrow); upArrow = new BaseButton(); upArrow.setSize(WIDTH, 14); upArrow.move(0, 0); upArrow.autoRepeat = true; upArrow.focusEnabled = false; addChild(upArrow); upArrow.addEventListener(ComponentEvent.BUTTON_DOWN, scrollPressHandler, false, 0, true); downArrow.addEventListener(ComponentEvent.BUTTON_DOWN, scrollPressHandler, false, 0, true); track.addEventListener(ComponentEvent.BUTTON_DOWN, scrollPressHandler, false, 0, true); thumb.addEventListener(MouseEvent.MOUSE_DOWN, thumbPressHandler, false, 0, true); enabled = false; } public function get direction():String{ return (_direction); } public function get lineScrollSize():Number{ return (_lineScrollSize); } override public function setSize(_arg1:Number, _arg2:Number):void{ if (_direction == ScrollBarDirection.HORIZONTAL){ super.setSize(_arg2, _arg1); } else { super.setSize(_arg1, _arg2); }; } public function get maxScrollPosition():Number{ return (_maxScrollPosition); } override public function get width():Number{ return (((_direction)==ScrollBarDirection.HORIZONTAL) ? super.height : super.width); } protected function setStyles():void{ copyStylesToChild(downArrow, DOWN_ARROW_STYLES); copyStylesToChild(thumb, THUMB_STYLES); copyStylesToChild(track, TRACK_STYLES); copyStylesToChild(upArrow, UP_ARROW_STYLES); } public static function getStyleDefinition():Object{ return (defaultStyles); } } }//package fl.controls
Section 129
//ScrollBarDirection (fl.controls.ScrollBarDirection) package fl.controls { public class ScrollBarDirection { public static const HORIZONTAL:String = "horizontal"; public static const VERTICAL:String = "vertical"; } }//package fl.controls
Section 130
//ScrollPolicy (fl.controls.ScrollPolicy) package fl.controls { public class ScrollPolicy { public static const OFF:String = "off"; public static const ON:String = "on"; public static const AUTO:String = "auto"; } }//package fl.controls
Section 131
//SelectableList (fl.controls.SelectableList) package fl.controls { import fl.controls.listClasses.*; import fl.core.*; import flash.display.*; import flash.events.*; import fl.data.*; import fl.managers.*; import fl.events.*; import flash.utils.*; import fl.containers.*; import flash.ui.*; public class SelectableList extends BaseScrollPane implements IFocusManagerComponent { protected var invalidItems:Dictionary; protected var renderedItems:Dictionary; protected var listHolder:Sprite; protected var _allowMultipleSelection:Boolean;// = false protected var lastCaretIndex:int;// = -1 protected var _selectedIndices:Array; protected var availableCellRenderers:Array; protected var list:Sprite; protected var caretIndex:int;// = -1 protected var updatedRendererStyles:Object; protected var preChangeItems:Array; protected var activeCellRenderers:Array; protected var rendererStyles:Object; protected var _verticalScrollPosition:Number; protected var _dataProvider:DataProvider; protected var _horizontalScrollPosition:Number; private var collectionItemImport:SimpleCollectionItem; protected var _selectable:Boolean;// = true private static var defaultStyles:Object = {skin:"List_skin", cellRenderer:CellRenderer, contentPadding:null, disabledAlpha:null}; public static var createAccessibilityImplementation:Function; public function SelectableList(){ _allowMultipleSelection = false; _selectable = true; caretIndex = -1; lastCaretIndex = -1; super(); activeCellRenderers = []; availableCellRenderers = []; invalidItems = new Dictionary(true); renderedItems = new Dictionary(true); _selectedIndices = []; if (dataProvider == null){ dataProvider = new DataProvider(); }; verticalScrollPolicy = ScrollPolicy.AUTO; rendererStyles = {}; updatedRendererStyles = {}; } protected function drawList():void{ } public function set allowMultipleSelection(_arg1:Boolean):void{ if (_arg1 == _allowMultipleSelection){ return; }; _allowMultipleSelection = _arg1; if (((!(_arg1)) && ((_selectedIndices.length > 1)))){ _selectedIndices = [_selectedIndices.pop()]; invalidate(InvalidationType.DATA); }; } public function sortItemsOn(_arg1:String, _arg2:Object=null){ return (_dataProvider.sortOn(_arg1, _arg2)); } public function removeItemAt(_arg1:uint):Object{ return (_dataProvider.removeItemAt(_arg1)); } public function get selectedItem():Object{ return (((_selectedIndices.length)==0) ? null : _dataProvider.getItemAt(selectedIndex)); } override protected function keyDownHandler(_arg1:KeyboardEvent):void{ if (!selectable){ return; }; switch (_arg1.keyCode){ case Keyboard.UP: case Keyboard.DOWN: case Keyboard.END: case Keyboard.HOME: case Keyboard.PAGE_UP: case Keyboard.PAGE_DOWN: moveSelectionVertically(_arg1.keyCode, ((_arg1.shiftKey) && (_allowMultipleSelection)), ((_arg1.ctrlKey) && (_allowMultipleSelection))); _arg1.stopPropagation(); break; case Keyboard.LEFT: case Keyboard.RIGHT: moveSelectionHorizontally(_arg1.keyCode, ((_arg1.shiftKey) && (_allowMultipleSelection)), ((_arg1.ctrlKey) && (_allowMultipleSelection))); _arg1.stopPropagation(); break; }; } public function get selectable():Boolean{ return (_selectable); } public function itemToCellRenderer(_arg1:Object):ICellRenderer{ var _local2:*; var _local3:ICellRenderer; if (_arg1 != null){ for (_local2 in activeCellRenderers) { _local3 = (activeCellRenderers[_local2] as ICellRenderer); if (_local3.data == _arg1){ return (_local3); }; }; }; return (null); } public function getNextIndexAtLetter(_arg1:String, _arg2:int=-1):int{ var _local3:int; var _local4:Number; var _local5:Number; var _local6:Object; var _local7:String; if (length == 0){ return (-1); }; _arg1 = _arg1.toUpperCase(); _local3 = (length - 1); _local4 = 0; while (_local4 < _local3) { _local5 = ((_arg2 + 1) + _local4); if (_local5 > (length - 1)){ _local5 = (_local5 - length); }; _local6 = getItemAt(_local5); if (_local6 == null){ break; }; _local7 = itemToLabel(_local6); if (_local7 == null){ } else { if (_local7.charAt(0).toUpperCase() == _arg1){ return (_local5); }; }; _local4++; }; return (-1); } public function invalidateList():void{ _invalidateList(); invalidate(InvalidationType.DATA); } override public function set enabled(_arg1:Boolean):void{ super.enabled = _arg1; list.mouseChildren = _enabled; } public function get selectedIndices():Array{ return (_selectedIndices.concat()); } public function set selectable(_arg1:Boolean):void{ if (_arg1 == _selectable){ return; }; if (!_arg1){ selectedIndices = []; }; _selectable = _arg1; } public function itemToLabel(_arg1:Object):String{ return (_arg1["label"]); } public function addItemAt(_arg1:Object, _arg2:uint):void{ _dataProvider.addItemAt(_arg1, _arg2); invalidateList(); } public function replaceItemAt(_arg1:Object, _arg2:uint):Object{ return (_dataProvider.replaceItemAt(_arg1, _arg2)); } protected function handleDataChange(_arg1:DataChangeEvent):void{ var _local2:int; var _local3:int; var _local4:String; var _local5:uint; _local2 = _arg1.startIndex; _local3 = _arg1.endIndex; _local4 = _arg1.changeType; if (_local4 == DataChangeType.INVALIDATE_ALL){ clearSelection(); invalidateList(); } else { if (_local4 == DataChangeType.INVALIDATE){ _local5 = 0; while (_local5 < _arg1.items.length) { invalidateItem(_arg1.items[_local5]); _local5++; }; } else { if (_local4 == DataChangeType.ADD){ _local5 = 0; while (_local5 < _selectedIndices.length) { if (_selectedIndices[_local5] >= _local2){ _selectedIndices[_local5] = (_selectedIndices[_local5] + (_local2 - _local3)); }; _local5++; }; } else { if (_local4 == DataChangeType.REMOVE){ _local5 = 0; while (_local5 < _selectedIndices.length) { if (_selectedIndices[_local5] >= _local2){ if (_selectedIndices[_local5] <= _local3){ delete _selectedIndices[_local5]; } else { _selectedIndices[_local5] = (_selectedIndices[_local5] - ((_local2 - _local3) + 1)); }; }; _local5++; }; } else { if (_local4 == DataChangeType.REMOVE_ALL){ clearSelection(); } else { if (_local4 == DataChangeType.REPLACE){ } else { selectedItems = preChangeItems; preChangeItems = null; }; }; }; }; }; }; invalidate(InvalidationType.DATA); } protected function _invalidateList():void{ availableCellRenderers = []; while (activeCellRenderers.length > 0) { list.removeChild((activeCellRenderers.pop() as DisplayObject)); }; } protected function updateRendererStyles():void{ var _local1:Array; var _local2:uint; var _local3:uint; var _local4:String; _local1 = availableCellRenderers.concat(activeCellRenderers); _local2 = _local1.length; _local3 = 0; while (_local3 < _local2) { if (_local1[_local3].setStyle == null){ } else { for (_local4 in updatedRendererStyles) { _local1[_local3].setStyle(_local4, updatedRendererStyles[_local4]); }; _local1[_local3].drawNow(); }; _local3++; }; updatedRendererStyles = {}; } public function set selectedItem(_arg1:Object):void{ var _local2:int; _local2 = _dataProvider.getItemIndex(_arg1); selectedIndex = _local2; } public function sortItems(... _args){ return (_dataProvider.sort.apply(_dataProvider, _args)); } public function removeAll():void{ _dataProvider.removeAll(); } protected function handleCellRendererChange(_arg1:Event):void{ var _local2:ICellRenderer; var _local3:uint; _local2 = (_arg1.currentTarget as ICellRenderer); _local3 = _local2.listData.index; _dataProvider.invalidateItemAt(_local3); } protected function moveSelectionVertically(_arg1:uint, _arg2:Boolean, _arg3:Boolean):void{ } override protected function setHorizontalScrollPosition(_arg1:Number, _arg2:Boolean=false):void{ var _local3:Number; if (_arg1 == _horizontalScrollPosition){ return; }; _local3 = (_arg1 - _horizontalScrollPosition); _horizontalScrollPosition = _arg1; if (_arg2){ dispatchEvent(new ScrollEvent(ScrollBarDirection.HORIZONTAL, _local3, _arg1)); }; } public function scrollToSelected():void{ scrollToIndex(selectedIndex); } public function invalidateItem(_arg1:Object):void{ if (renderedItems[_arg1] == null){ return; }; invalidItems[_arg1] = true; invalidate(InvalidationType.DATA); } protected function handleCellRendererClick(_arg1:MouseEvent):void{ var _local2:ICellRenderer; var _local3:uint; var _local4:int; var _local5:int; var _local6:uint; if (!_enabled){ return; }; _local2 = (_arg1.currentTarget as ICellRenderer); _local3 = _local2.listData.index; if (((!(dispatchEvent(new ListEvent(ListEvent.ITEM_CLICK, false, true, _local2.listData.column, _local2.listData.row, _local3, _local2.data)))) || (!(_selectable)))){ return; }; _local4 = selectedIndices.indexOf(_local3); if (!_allowMultipleSelection){ if (_local4 != -1){ return; }; _local2.selected = true; _selectedIndices = [_local3]; lastCaretIndex = (caretIndex = _local3); } else { if (_arg1.shiftKey){ _local6 = ((_selectedIndices.length)>0) ? _selectedIndices[0] : _local3; _selectedIndices = []; if (_local6 > _local3){ _local5 = _local6; while (_local5 >= _local3) { _selectedIndices.push(_local5); _local5--; }; } else { _local5 = _local6; while (_local5 <= _local3) { _selectedIndices.push(_local5); _local5++; }; }; caretIndex = _local3; } else { if (_arg1.ctrlKey){ if (_local4 != -1){ _local2.selected = false; _selectedIndices.splice(_local4, 1); } else { _local2.selected = true; _selectedIndices.push(_local3); }; caretIndex = _local3; } else { _selectedIndices = [_local3]; lastCaretIndex = (caretIndex = _local3); }; }; }; dispatchEvent(new Event(Event.CHANGE)); invalidate(InvalidationType.DATA); } public function get length():uint{ return (_dataProvider.length); } public function get allowMultipleSelection():Boolean{ return (_allowMultipleSelection); } protected function onPreChange(_arg1:DataChangeEvent):void{ switch (_arg1.changeType){ case DataChangeType.REMOVE: case DataChangeType.ADD: case DataChangeType.INVALIDATE: case DataChangeType.REMOVE_ALL: case DataChangeType.REPLACE: case DataChangeType.INVALIDATE_ALL: break; default: preChangeItems = selectedItems; break; }; } public function getRendererStyle(_arg1:String, _arg2:int=-1):Object{ return (rendererStyles[_arg1]); } override protected function setVerticalScrollPosition(_arg1:Number, _arg2:Boolean=false):void{ var _local3:Number; if (_arg1 == _verticalScrollPosition){ return; }; _local3 = (_arg1 - _verticalScrollPosition); _verticalScrollPosition = _arg1; if (_arg2){ dispatchEvent(new ScrollEvent(ScrollBarDirection.VERTICAL, _local3, _arg1)); }; } protected function moveSelectionHorizontally(_arg1:uint, _arg2:Boolean, _arg3:Boolean):void{ } public function set selectedIndices(_arg1:Array):void{ if (!_selectable){ return; }; _selectedIndices = ((_arg1)==null) ? [] : _arg1.concat(); invalidate(InvalidationType.SELECTED); } public function get selectedIndex():int{ return (((_selectedIndices.length)==0) ? -1 : _selectedIndices[(_selectedIndices.length - 1)]); } override protected function draw():void{ super.draw(); } override protected function configUI():void{ super.configUI(); listHolder = new Sprite(); addChild(listHolder); listHolder.scrollRect = contentScrollRect; list = new Sprite(); listHolder.addChild(list); } public function addItem(_arg1:Object):void{ _dataProvider.addItem(_arg1); invalidateList(); } protected function handleCellRendererMouseEvent(_arg1:MouseEvent):void{ var _local2:ICellRenderer; var _local3:String; _local2 = (_arg1.target as ICellRenderer); _local3 = ((_arg1.type)==MouseEvent.ROLL_OVER) ? ListEvent.ITEM_ROLL_OVER : ListEvent.ITEM_ROLL_OUT; dispatchEvent(new ListEvent(_local3, false, false, _local2.listData.column, _local2.listData.row, _local2.listData.index, _local2.data)); } public function clearRendererStyle(_arg1:String, _arg2:int=-1):void{ delete rendererStyles[_arg1]; updatedRendererStyles[_arg1] = null; invalidate(InvalidationType.RENDERER_STYLES); } protected function handleCellRendererDoubleClick(_arg1:MouseEvent):void{ var _local2:ICellRenderer; var _local3:uint; if (!_enabled){ return; }; _local2 = (_arg1.currentTarget as ICellRenderer); _local3 = _local2.listData.index; dispatchEvent(new ListEvent(ListEvent.ITEM_DOUBLE_CLICK, false, true, _local2.listData.column, _local2.listData.row, _local3, _local2.data)); } public function get rowCount():uint{ return (0); } public function isItemSelected(_arg1:Object):Boolean{ return ((selectedItems.indexOf(_arg1) > -1)); } public function set dataProvider(_arg1:DataProvider):void{ if (_dataProvider != null){ _dataProvider.removeEventListener(DataChangeEvent.DATA_CHANGE, handleDataChange); _dataProvider.removeEventListener(DataChangeEvent.PRE_DATA_CHANGE, onPreChange); }; _dataProvider = _arg1; _dataProvider.addEventListener(DataChangeEvent.DATA_CHANGE, handleDataChange, false, 0, true); _dataProvider.addEventListener(DataChangeEvent.PRE_DATA_CHANGE, onPreChange, false, 0, true); clearSelection(); invalidateList(); } override protected function drawLayout():void{ super.drawLayout(); contentScrollRect = listHolder.scrollRect; contentScrollRect.width = availableWidth; contentScrollRect.height = availableHeight; listHolder.scrollRect = contentScrollRect; } public function getItemAt(_arg1:uint):Object{ return (_dataProvider.getItemAt(_arg1)); } override protected function initializeAccessibility():void{ if (SelectableList.createAccessibilityImplementation != null){ SelectableList.createAccessibilityImplementation(this); }; } public function scrollToIndex(_arg1:int):void{ } public function removeItem(_arg1:Object):Object{ return (_dataProvider.removeItem(_arg1)); } public function get dataProvider():DataProvider{ return (_dataProvider); } public function set maxHorizontalScrollPosition(_arg1:Number):void{ _maxHorizontalScrollPosition = _arg1; invalidate(InvalidationType.SIZE); } public function setRendererStyle(_arg1:String, _arg2:Object, _arg3:uint=0):void{ if (rendererStyles[_arg1] == _arg2){ return; }; updatedRendererStyles[_arg1] = _arg2; rendererStyles[_arg1] = _arg2; invalidate(InvalidationType.RENDERER_STYLES); } public function invalidateItemAt(_arg1:uint):void{ var _local2:Object; _local2 = _dataProvider.getItemAt(_arg1); if (_local2 != null){ invalidateItem(_local2); }; } public function set selectedItems(_arg1:Array):void{ var _local2:Array; var _local3:uint; var _local4:int; if (_arg1 == null){ selectedIndices = null; return; }; _local2 = []; _local3 = 0; while (_local3 < _arg1.length) { _local4 = _dataProvider.getItemIndex(_arg1[_local3]); if (_local4 != -1){ _local2.push(_local4); }; _local3++; }; selectedIndices = _local2; } public function clearSelection():void{ selectedIndex = -1; } override public function get maxHorizontalScrollPosition():Number{ return (_maxHorizontalScrollPosition); } public function get selectedItems():Array{ var _local1:Array; var _local2:uint; _local1 = []; _local2 = 0; while (_local2 < _selectedIndices.length) { _local1.push(_dataProvider.getItemAt(_selectedIndices[_local2])); _local2++; }; return (_local1); } public function set selectedIndex(_arg1:int):void{ selectedIndices = ((_arg1)==-1) ? null : [_arg1]; } public static function getStyleDefinition():Object{ return (mergeStyles(defaultStyles, BaseScrollPane.getStyleDefinition())); } } }//package fl.controls
Section 132
//TextInput (fl.controls.TextInput) package fl.controls { import fl.core.*; import flash.display.*; import flash.events.*; import fl.managers.*; import fl.events.*; import flash.text.*; import flash.ui.*; public class TextInput extends UIComponent implements IFocusManagerComponent { protected var _html:Boolean;// = false protected var _savedHTML:String; protected var background:DisplayObject; protected var _editable:Boolean;// = true public var textField:TextField; private static var defaultStyles:Object = {upSkin:"TextInput_upSkin", disabledSkin:"TextInput_disabledSkin", focusRectSkin:null, focusRectPadding:null, textFormat:null, disabledTextFormat:null, textPadding:0, embedFonts:false}; public static var createAccessibilityImplementation:Function; public function TextInput(){ _editable = true; _html = false; super(); } override public function drawFocus(_arg1:Boolean):void{ if (focusTarget != null){ focusTarget.drawFocus(_arg1); return; }; super.drawFocus(_arg1); } public function set imeMode(_arg1:String):void{ _imeMode = _arg1; } override protected function isOurFocus(_arg1:DisplayObject):Boolean{ return ((((_arg1 == textField)) || (super.isOurFocus(_arg1)))); } protected function handleKeyDown(_arg1:KeyboardEvent):void{ if (_arg1.keyCode == Keyboard.ENTER){ dispatchEvent(new ComponentEvent(ComponentEvent.ENTER, true)); }; } public function set text(_arg1:String):void{ textField.text = _arg1; _html = false; invalidate(InvalidationType.DATA); invalidate(InvalidationType.STYLES); } protected function updateTextFieldType():void{ textField.type = (((enabled) && (editable))) ? TextFieldType.INPUT : TextFieldType.DYNAMIC; textField.selectable = enabled; } public function get selectionEndIndex():int{ return (textField.selectionEndIndex); } public function get editable():Boolean{ return (_editable); } override protected function focusInHandler(_arg1:FocusEvent):void{ var _local2:IFocusManager; if (_arg1.target == this){ stage.focus = textField; }; _local2 = focusManager; if (((editable) && (_local2))){ _local2.showFocusIndicator = true; if (((textField.selectable) && ((textField.selectionBeginIndex == textField.selectionBeginIndex)))){ setSelection(0, textField.length); }; }; super.focusInHandler(_arg1); if (editable){ setIMEMode(true); }; } public function get selectionBeginIndex():int{ return (textField.selectionBeginIndex); } public function set alwaysShowSelection(_arg1:Boolean):void{ textField.alwaysShowSelection = _arg1; } override public function set enabled(_arg1:Boolean):void{ super.enabled = _arg1; updateTextFieldType(); } protected function setEmbedFont(){ var _local1:Object; _local1 = getStyleValue("embedFonts"); if (_local1 != null){ textField.embedFonts = _local1; }; } public function get horizontalScrollPosition():int{ return (textField.scrollH); } public function set condenseWhite(_arg1:Boolean):void{ textField.condenseWhite = _arg1; } public function set displayAsPassword(_arg1:Boolean):void{ textField.displayAsPassword = _arg1; } public function set horizontalScrollPosition(_arg1:int):void{ textField.scrollH = _arg1; } public function get restrict():String{ return (textField.restrict); } public function get textWidth():Number{ return (textField.textWidth); } public function get textHeight():Number{ return (textField.textHeight); } public function set editable(_arg1:Boolean):void{ _editable = _arg1; updateTextFieldType(); } public function get maxChars():int{ return (textField.maxChars); } public function get length():int{ return (textField.length); } public function getLineMetrics(_arg1:int):TextLineMetrics{ return (textField.getLineMetrics(_arg1)); } public function get imeMode():String{ return (_imeMode); } override protected function focusOutHandler(_arg1:FocusEvent):void{ super.focusOutHandler(_arg1); if (editable){ setIMEMode(false); }; } public function set htmlText(_arg1:String):void{ if (_arg1 == ""){ text = ""; return; }; _html = true; _savedHTML = _arg1; textField.htmlText = _arg1; invalidate(InvalidationType.DATA); invalidate(InvalidationType.STYLES); } public function get text():String{ return (textField.text); } override public function get enabled():Boolean{ return (super.enabled); } public function get condenseWhite():Boolean{ return (textField.condenseWhite); } public function get alwaysShowSelection():Boolean{ return (textField.alwaysShowSelection); } override protected function draw():void{ var _local1:Object; if (isInvalid(InvalidationType.STYLES, InvalidationType.STATE)){ drawTextFormat(); drawBackground(); _local1 = getStyleValue("embedFonts"); if (_local1 != null){ textField.embedFonts = _local1; }; invalidate(InvalidationType.SIZE, false); }; if (isInvalid(InvalidationType.SIZE)){ drawLayout(); }; super.draw(); } protected function handleTextInput(_arg1:TextEvent):void{ _arg1.stopPropagation(); dispatchEvent(new TextEvent(TextEvent.TEXT_INPUT, true, false, _arg1.text)); } override protected function configUI():void{ super.configUI(); tabChildren = true; textField = new TextField(); addChild(textField); updateTextFieldType(); textField.addEventListener(TextEvent.TEXT_INPUT, handleTextInput, false, 0, true); textField.addEventListener(Event.CHANGE, handleChange, false, 0, true); textField.addEventListener(KeyboardEvent.KEY_DOWN, handleKeyDown, false, 0, true); } public function setSelection(_arg1:int, _arg2:int):void{ textField.setSelection(_arg1, _arg2); } public function get displayAsPassword():Boolean{ return (textField.displayAsPassword); } public function appendText(_arg1:String):void{ textField.appendText(_arg1); } public function set restrict(_arg1:String):void{ if (((componentInspectorSetting) && ((_arg1 == "")))){ _arg1 = null; }; textField.restrict = _arg1; } public function get htmlText():String{ return (textField.htmlText); } protected function drawBackground():void{ var _local1:DisplayObject; var _local2:String; _local1 = background; _local2 = (enabled) ? "upSkin" : "disabledSkin"; background = getDisplayObjectInstance(getStyleValue(_local2)); if (background == null){ return; }; addChildAt(background, 0); if (((((!((_local1 == null))) && (!((_local1 == background))))) && (contains(_local1)))){ removeChild(_local1); }; } override public function setFocus():void{ stage.focus = textField; } protected function drawLayout():void{ var _local1:Number; _local1 = Number(getStyleValue("textPadding")); if (background != null){ background.width = width; background.height = height; }; textField.width = (width - (2 * _local1)); textField.height = (height - (2 * _local1)); textField.x = (textField.y = _local1); } public function set maxChars(_arg1:int):void{ textField.maxChars = _arg1; } public function get maxHorizontalScrollPosition():int{ return (textField.maxScrollH); } protected function drawTextFormat():void{ var _local1:Object; var _local2:TextFormat; var _local3:TextFormat; _local1 = UIComponent.getStyleDefinition(); _local2 = (enabled) ? (_local1.defaultTextFormat as TextFormat) : (_local1.defaultDisabledTextFormat as TextFormat); textField.setTextFormat(_local2); _local3 = (getStyleValue((enabled) ? "textFormat" : "disabledTextFormat") as TextFormat); if (_local3 != null){ textField.setTextFormat(_local3); } else { _local3 = _local2; }; textField.defaultTextFormat = _local3; setEmbedFont(); if (_html){ textField.htmlText = _savedHTML; }; } protected function handleChange(_arg1:Event):void{ _arg1.stopPropagation(); dispatchEvent(new Event(Event.CHANGE, true)); } public static function getStyleDefinition():Object{ return (defaultStyles); } } }//package fl.controls
Section 133
//ComponentShim (fl.core.ComponentShim) package fl.core { import flash.display.*; public dynamic class ComponentShim extends MovieClip { } }//package fl.core
Section 134
//InvalidationType (fl.core.InvalidationType) package fl.core { public class InvalidationType { public static const SIZE:String = "size"; public static const ALL:String = "all"; public static const DATA:String = "data"; public static const SCROLL:String = "scroll"; public static const STATE:String = "state"; public static const STYLES:String = "styles"; public static const SELECTED:String = "selected"; public static const RENDERER_STYLES:String = "rendererStyles"; } }//package fl.core
Section 135
//UIComponent (fl.core.UIComponent) package fl.core { import flash.display.*; import flash.events.*; import fl.managers.*; import fl.events.*; import flash.text.*; import flash.utils.*; import flash.system.*; public class UIComponent extends Sprite { protected var _enabled:Boolean;// = true private var _mouseFocusEnabled:Boolean;// = true protected var startHeight:Number; protected var _height:Number; protected var _oldIMEMode:String;// = null protected var startWidth:Number; public var focusTarget:IFocusManagerComponent; protected var errorCaught:Boolean;// = false protected var uiFocusRect:DisplayObject; protected var _width:Number; public var version:String;// = "3.0.0.15" protected var isFocused:Boolean;// = false protected var callLaterMethods:Dictionary; private var _focusEnabled:Boolean;// = true private var tempText:TextField; protected var invalidateFlag:Boolean;// = false protected var _inspector:Boolean;// = false protected var sharedStyles:Object; protected var invalidHash:Object; protected var isLivePreview:Boolean;// = false protected var _imeMode:String;// = null protected var instanceStyles:Object; protected var _x:Number; protected var _y:Number; public static var inCallLaterPhase:Boolean = false; private static var defaultStyles:Object = {focusRectSkin:"focusRectSkin", focusRectPadding:2, textFormat:new TextFormat("_sans", 11, 0, false, false, false, "", "", TextFormatAlign.LEFT, 0, 0, 0, 0), disabledTextFormat:new TextFormat("_sans", 11, 0x999999, false, false, false, "", "", TextFormatAlign.LEFT, 0, 0, 0, 0), defaultTextFormat:new TextFormat("_sans", 11, 0, false, false, false, "", "", TextFormatAlign.LEFT, 0, 0, 0, 0), defaultDisabledTextFormat:new TextFormat("_sans", 11, 0x999999, false, false, false, "", "", TextFormatAlign.LEFT, 0, 0, 0, 0)}; public static var createAccessibilityImplementation:Function; private static var focusManagers:Dictionary = new Dictionary(false); public function UIComponent(){ version = "3.0.0.15"; isLivePreview = false; invalidateFlag = false; _enabled = true; isFocused = false; _focusEnabled = true; _mouseFocusEnabled = true; _imeMode = null; _oldIMEMode = null; errorCaught = false; _inspector = false; super(); instanceStyles = {}; sharedStyles = {}; invalidHash = {}; callLaterMethods = new Dictionary(); StyleManager.registerInstance(this); configUI(); invalidate(InvalidationType.ALL); tabEnabled = (this is IFocusManagerComponent); focusRect = false; if (tabEnabled){ addEventListener(FocusEvent.FOCUS_IN, focusInHandler); addEventListener(FocusEvent.FOCUS_OUT, focusOutHandler); addEventListener(KeyboardEvent.KEY_DOWN, keyDownHandler); addEventListener(KeyboardEvent.KEY_UP, keyUpHandler); }; initializeFocusManager(); addEventListener(Event.ENTER_FRAME, hookAccessibility, false, 0, true); } public function drawFocus(_arg1:Boolean):void{ var _local2:Number; isFocused = _arg1; if (((!((uiFocusRect == null))) && (contains(uiFocusRect)))){ removeChild(uiFocusRect); uiFocusRect = null; }; if (_arg1){ uiFocusRect = (getDisplayObjectInstance(getStyleValue("focusRectSkin")) as Sprite); if (uiFocusRect == null){ return; }; _local2 = Number(getStyleValue("focusRectPadding")); uiFocusRect.x = -(_local2); uiFocusRect.y = -(_local2); uiFocusRect.width = (width + (_local2 * 2)); uiFocusRect.height = (height + (_local2 * 2)); addChildAt(uiFocusRect, 0); }; } private function callLaterDispatcher(_arg1:Event):void{ var _local2:Dictionary; var _local3:Object; if (_arg1.type == Event.ADDED_TO_STAGE){ removeEventListener(Event.ADDED_TO_STAGE, callLaterDispatcher); stage.addEventListener(Event.RENDER, callLaterDispatcher, false, 0, true); stage.invalidate(); return; }; _arg1.target.removeEventListener(Event.RENDER, callLaterDispatcher); if (stage == null){ addEventListener(Event.ADDED_TO_STAGE, callLaterDispatcher, false, 0, true); return; }; inCallLaterPhase = true; _local2 = callLaterMethods; for (_local3 in _local2) { _local3(); delete _local2[_local3]; }; inCallLaterPhase = false; } private function addedHandler(_arg1:Event):void{ removeEventListener("addedToStage", addedHandler); initializeFocusManager(); } protected function getStyleValue(_arg1:String):Object{ return (((instanceStyles[_arg1])==null) ? sharedStyles[_arg1] : instanceStyles[_arg1]); } protected function isOurFocus(_arg1:DisplayObject):Boolean{ return ((_arg1 == this)); } override public function get scaleX():Number{ return ((width / startWidth)); } override public function get scaleY():Number{ return ((height / startHeight)); } override public function set height(_arg1:Number):void{ if (_height == _arg1){ return; }; setSize(width, _arg1); } protected function keyDownHandler(_arg1:KeyboardEvent):void{ } protected function focusInHandler(_arg1:FocusEvent):void{ var _local2:IFocusManager; if (isOurFocus((_arg1.target as DisplayObject))){ _local2 = focusManager; if (((_local2) && (_local2.showFocusIndicator))){ drawFocus(true); isFocused = true; }; }; } public function setStyle(_arg1:String, _arg2:Object):void{ if ((((instanceStyles[_arg1] === _arg2)) && (!((_arg2 is TextFormat))))){ return; }; instanceStyles[_arg1] = _arg2; invalidate(InvalidationType.STYLES); } override public function get visible():Boolean{ return (super.visible); } public function get componentInspectorSetting():Boolean{ return (_inspector); } override public function get x():Number{ return ((isNaN(_x)) ? super.x : _x); } override public function get y():Number{ return ((isNaN(_y)) ? super.y : _y); } protected function setIMEMode(_arg1:Boolean){ var enabled = _arg1; if (_imeMode != null){ if (enabled){ IME.enabled = true; _oldIMEMode = IME.conversionMode; try { if (((!(errorCaught)) && (!((IME.conversionMode == IMEConversionMode.UNKNOWN))))){ IME.conversionMode = _imeMode; }; errorCaught = false; } catch(e:Error) { errorCaught = true; throw (new Error(("IME mode not supported: " + _imeMode))); }; } else { if (((!((IME.conversionMode == IMEConversionMode.UNKNOWN))) && (!((_oldIMEMode == IMEConversionMode.UNKNOWN))))){ IME.conversionMode = _oldIMEMode; }; IME.enabled = false; }; }; } public function set enabled(_arg1:Boolean):void{ if (_arg1 == _enabled){ return; }; _enabled = _arg1; invalidate(InvalidationType.STATE); } public function setSharedStyle(_arg1:String, _arg2:Object):void{ if ((((sharedStyles[_arg1] === _arg2)) && (!((_arg2 is TextFormat))))){ return; }; sharedStyles[_arg1] = _arg2; if (instanceStyles[_arg1] == null){ invalidate(InvalidationType.STYLES); }; } protected function keyUpHandler(_arg1:KeyboardEvent):void{ } public function set focusEnabled(_arg1:Boolean):void{ _focusEnabled = _arg1; } override public function set scaleX(_arg1:Number):void{ setSize((startWidth * _arg1), height); } public function get mouseFocusEnabled():Boolean{ return (_mouseFocusEnabled); } override public function set scaleY(_arg1:Number):void{ setSize(width, (startHeight * _arg1)); } protected function getDisplayObjectInstance(_arg1:Object):DisplayObject{ var classDef:Object; var skin = _arg1; classDef = null; if ((skin is Class)){ return ((new (skin) as DisplayObject)); }; if ((skin is DisplayObject)){ (skin as DisplayObject).x = 0; (skin as DisplayObject).y = 0; return ((skin as DisplayObject)); }; try { classDef = getDefinitionByName(skin.toString()); } catch(e:Error) { try { classDef = (loaderInfo.applicationDomain.getDefinition(skin.toString()) as Object); } catch(e:Error) { }; }; if (classDef == null){ return (null); }; return ((new (classDef) as DisplayObject)); } protected function copyStylesToChild(_arg1:UIComponent, _arg2:Object):void{ var _local3:String; for (_local3 in _arg2) { _arg1.setStyle(_local3, getStyleValue(_arg2[_local3])); }; } protected function beforeComponentParameters():void{ } protected function callLater(_arg1:Function):void{ if (inCallLaterPhase){ return; }; callLaterMethods[_arg1] = true; if (stage != null){ stage.addEventListener(Event.RENDER, callLaterDispatcher, false, 0, true); stage.invalidate(); } else { addEventListener(Event.ADDED_TO_STAGE, callLaterDispatcher, false, 0, true); }; } protected function createFocusManager():void{ if (focusManagers[stage] == null){ focusManagers[stage] = new FocusManager(stage); }; } override public function set visible(_arg1:Boolean):void{ var _local2:String; if (super.visible == _arg1){ return; }; super.visible = _arg1; _local2 = (_arg1) ? ComponentEvent.SHOW : ComponentEvent.HIDE; dispatchEvent(new ComponentEvent(_local2, true)); } protected function hookAccessibility(_arg1:Event):void{ removeEventListener(Event.ENTER_FRAME, hookAccessibility); initializeAccessibility(); } public function set componentInspectorSetting(_arg1:Boolean):void{ _inspector = _arg1; if (_inspector){ beforeComponentParameters(); } else { afterComponentParameters(); }; } override public function set x(_arg1:Number):void{ move(_arg1, _y); } public function drawNow():void{ draw(); } override public function set y(_arg1:Number):void{ move(_x, _arg1); } protected function checkLivePreview():Boolean{ var className:String; if (parent == null){ return (false); }; try { className = getQualifiedClassName(parent); } catch(e:Error) { }; return ((className == "fl.livepreview::LivePreviewParent")); } protected function focusOutHandler(_arg1:FocusEvent):void{ if (isOurFocus((_arg1.target as DisplayObject))){ drawFocus(false); isFocused = false; }; } public function set mouseFocusEnabled(_arg1:Boolean):void{ _mouseFocusEnabled = _arg1; } public function getFocus():InteractiveObject{ if (stage){ return (stage.focus); }; return (null); } protected function validate():void{ invalidHash = {}; } override public function get height():Number{ return (_height); } public function invalidate(_arg1:String="all", _arg2:Boolean=true):void{ invalidHash[_arg1] = true; if (_arg2){ this.callLater(draw); }; } public function get enabled():Boolean{ return (_enabled); } protected function getScaleX():Number{ return (super.scaleX); } protected function getScaleY():Number{ return (super.scaleY); } public function get focusEnabled():Boolean{ return (_focusEnabled); } protected function afterComponentParameters():void{ } protected function draw():void{ if (isInvalid(InvalidationType.SIZE, InvalidationType.STYLES)){ if (((isFocused) && (focusManager.showFocusIndicator))){ drawFocus(true); }; }; validate(); } protected function configUI():void{ var _local1:Number; var _local2:Number; var _local3:Number; isLivePreview = checkLivePreview(); _local1 = rotation; rotation = 0; _local2 = super.width; _local3 = super.height; var _local4 = 1; super.scaleY = _local4; super.scaleX = _local4; setSize(_local2, _local3); move(super.x, super.y); rotation = _local1; startWidth = _local2; startHeight = _local3; if (numChildren > 0){ removeChildAt(0); }; } protected function setScaleX(_arg1:Number):void{ super.scaleX = _arg1; } protected function setScaleY(_arg1:Number):void{ super.scaleY = _arg1; } private function initializeFocusManager():void{ if (stage == null){ addEventListener(Event.ADDED_TO_STAGE, addedHandler, false, 0, true); } else { createFocusManager(); }; } public function set focusManager(_arg1:IFocusManager):void{ UIComponent.focusManagers[this] = _arg1; } public function clearStyle(_arg1:String):void{ setStyle(_arg1, null); } protected function isInvalid(_arg1:String, ... _args):Boolean{ if (((invalidHash[_arg1]) || (invalidHash[InvalidationType.ALL]))){ return (true); }; while (_args.length > 0) { if (invalidHash[_args.pop()]){ return (true); }; }; return (false); } public function setSize(_arg1:Number, _arg2:Number):void{ _width = _arg1; _height = _arg2; invalidate(InvalidationType.SIZE); dispatchEvent(new ComponentEvent(ComponentEvent.RESIZE, false)); } override public function set width(_arg1:Number):void{ if (_width == _arg1){ return; }; setSize(_arg1, height); } public function setFocus():void{ if (stage){ stage.focus = this; }; } protected function initializeAccessibility():void{ if (UIComponent.createAccessibilityImplementation != null){ UIComponent.createAccessibilityImplementation(this); }; } public function get focusManager():IFocusManager{ var _local1:DisplayObject; _local1 = this; while (_local1) { if (UIComponent.focusManagers[_local1] != null){ return (IFocusManager(UIComponent.focusManagers[_local1])); }; _local1 = _local1.parent; }; return (null); } override public function get width():Number{ return (_width); } public function move(_arg1:Number, _arg2:Number):void{ _x = _arg1; _y = _arg2; super.x = Math.round(_arg1); super.y = Math.round(_arg2); dispatchEvent(new ComponentEvent(ComponentEvent.MOVE)); } public function validateNow():void{ invalidate(InvalidationType.ALL, false); draw(); } public function getStyle(_arg1:String):Object{ return (instanceStyles[_arg1]); } public static function getStyleDefinition():Object{ return (defaultStyles); } public static function mergeStyles(... _args):Object{ var _local2:Object; var _local3:uint; var _local4:uint; var _local5:Object; var _local6:String; _local2 = {}; _local3 = _args.length; _local4 = 0; while (_local4 < _local3) { _local5 = _args[_local4]; for (_local6 in _local5) { if (_local2[_local6] != null){ } else { _local2[_local6] = _args[_local4][_local6]; }; }; _local4++; }; return (_local2); } } }//package fl.core
Section 136
//DataProvider (fl.data.DataProvider) package fl.data { import flash.events.*; import fl.events.*; public class DataProvider extends EventDispatcher { protected var data:Array; public function DataProvider(_arg1:Object=null){ if (_arg1 == null){ data = []; } else { data = getDataFromObject(_arg1); }; } protected function dispatchPreChangeEvent(_arg1:String, _arg2:Array, _arg3:int, _arg4:int):void{ dispatchEvent(new DataChangeEvent(DataChangeEvent.PRE_DATA_CHANGE, _arg1, _arg2, _arg3, _arg4)); } public function invalidateItemAt(_arg1:int):void{ checkIndex(_arg1, (data.length - 1)); dispatchChangeEvent(DataChangeType.INVALIDATE, [data[_arg1]], _arg1, _arg1); } public function getItemIndex(_arg1:Object):int{ return (data.indexOf(_arg1)); } protected function getDataFromObject(_arg1:Object):Array{ var _local2:Array; var _local3:Array; var _local4:uint; var _local5:Object; var _local6:XML; var _local7:XMLList; var _local8:XML; var _local9:XMLList; var _local10:XML; var _local11:XMLList; var _local12:XML; if ((_arg1 is Array)){ _local3 = (_arg1 as Array); if (_local3.length > 0){ if ((((_local3[0] is String)) || ((_local3[0] is Number)))){ _local2 = []; _local4 = 0; while (_local4 < _local3.length) { _local5 = {label:String(_local3[_local4]), data:_local3[_local4]}; _local2.push(_local5); _local4++; }; return (_local2); }; }; return (_arg1.concat()); //unresolved jump }; if ((_arg1 is DataProvider)){ return (_arg1.toArray()); }; if ((_arg1 is XML)){ _local6 = (_arg1 as XML); _local2 = []; _local7 = _local6.*; for each (_local8 in _local7) { _arg1 = {}; _local9 = _local8.attributes(); for each (_local10 in _local9) { _arg1[_local10.localName()] = _local10.toString(); }; _local11 = _local8.*; for each (_local12 in _local11) { if (_local12.hasSimpleContent()){ _arg1[_local12.localName()] = _local12.toString(); }; }; _local2.push(_arg1); }; return (_local2); //unresolved jump }; throw (new TypeError((("Error: Type Coercion failed: cannot convert " + _arg1) + " to Array or DataProvider."))); } public function removeItemAt(_arg1:uint):Object{ var _local2:Array; checkIndex(_arg1, (data.length - 1)); dispatchPreChangeEvent(DataChangeType.REMOVE, data.slice(_arg1, (_arg1 + 1)), _arg1, _arg1); _local2 = data.splice(_arg1, 1); dispatchChangeEvent(DataChangeType.REMOVE, _local2, _arg1, _arg1); return (_local2[0]); } public function addItem(_arg1:Object):void{ dispatchPreChangeEvent(DataChangeType.ADD, [_arg1], (data.length - 1), (data.length - 1)); data.push(_arg1); dispatchChangeEvent(DataChangeType.ADD, [_arg1], (data.length - 1), (data.length - 1)); } public function sortOn(_arg1:Object, _arg2:Object=null){ var _local3:Array; dispatchPreChangeEvent(DataChangeType.SORT, data.concat(), 0, (data.length - 1)); _local3 = data.sortOn(_arg1, _arg2); dispatchChangeEvent(DataChangeType.SORT, data.concat(), 0, (data.length - 1)); return (_local3); } public function sort(... _args){ var _local2:Array; dispatchPreChangeEvent(DataChangeType.SORT, data.concat(), 0, (data.length - 1)); _local2 = data.sort.apply(data, _args); dispatchChangeEvent(DataChangeType.SORT, data.concat(), 0, (data.length - 1)); return (_local2); } public function addItems(_arg1:Object):void{ addItemsAt(_arg1, data.length); } public function concat(_arg1:Object):void{ addItems(_arg1); } public function clone():DataProvider{ return (new DataProvider(data)); } public function toArray():Array{ return (data.concat()); } public function get length():uint{ return (data.length); } public function addItemAt(_arg1:Object, _arg2:uint):void{ checkIndex(_arg2, data.length); dispatchPreChangeEvent(DataChangeType.ADD, [_arg1], _arg2, _arg2); data.splice(_arg2, 0, _arg1); dispatchChangeEvent(DataChangeType.ADD, [_arg1], _arg2, _arg2); } public function getItemAt(_arg1:uint):Object{ checkIndex(_arg1, (data.length - 1)); return (data[_arg1]); } override public function toString():String{ return ((("DataProvider [" + data.join(" , ")) + "]")); } public function invalidateItem(_arg1:Object):void{ var _local2:uint; _local2 = getItemIndex(_arg1); if (_local2 == -1){ return; }; invalidateItemAt(_local2); } protected function dispatchChangeEvent(_arg1:String, _arg2:Array, _arg3:int, _arg4:int):void{ dispatchEvent(new DataChangeEvent(DataChangeEvent.DATA_CHANGE, _arg1, _arg2, _arg3, _arg4)); } protected function checkIndex(_arg1:int, _arg2:int):void{ if ((((_arg1 > _arg2)) || ((_arg1 < 0)))){ throw (new RangeError((((("DataProvider index (" + _arg1) + ") is not in acceptable range (0 - ") + _arg2) + ")"))); }; } public function addItemsAt(_arg1:Object, _arg2:uint):void{ var _local3:Array; checkIndex(_arg2, data.length); _local3 = getDataFromObject(_arg1); dispatchPreChangeEvent(DataChangeType.ADD, _local3, _arg2, ((_arg2 + _local3.length) - 1)); data.splice.apply(data, [_arg2, 0].concat(_local3)); dispatchChangeEvent(DataChangeType.ADD, _local3, _arg2, ((_arg2 + _local3.length) - 1)); } public function replaceItem(_arg1:Object, _arg2:Object):Object{ var _local3:int; _local3 = getItemIndex(_arg2); if (_local3 != -1){ return (replaceItemAt(_arg1, _local3)); }; return (null); } public function removeItem(_arg1:Object):Object{ var _local2:int; _local2 = getItemIndex(_arg1); if (_local2 != -1){ return (removeItemAt(_local2)); }; return (null); } public function merge(_arg1:Object):void{ var _local2:Array; var _local3:uint; var _local4:uint; var _local5:uint; var _local6:Object; _local2 = getDataFromObject(_arg1); _local3 = _local2.length; _local4 = data.length; dispatchPreChangeEvent(DataChangeType.ADD, data.slice(_local4, data.length), _local4, (this.data.length - 1)); _local5 = 0; while (_local5 < _local3) { _local6 = _local2[_local5]; if (getItemIndex(_local6) == -1){ data.push(_local6); }; _local5++; }; if (data.length > _local4){ dispatchChangeEvent(DataChangeType.ADD, data.slice(_local4, data.length), _local4, (this.data.length - 1)); } else { dispatchChangeEvent(DataChangeType.ADD, [], -1, -1); }; } public function replaceItemAt(_arg1:Object, _arg2:uint):Object{ var _local3:Array; checkIndex(_arg2, (data.length - 1)); _local3 = [data[_arg2]]; dispatchPreChangeEvent(DataChangeType.REPLACE, _local3, _arg2, _arg2); data[_arg2] = _arg1; dispatchChangeEvent(DataChangeType.REPLACE, _local3, _arg2, _arg2); return (_local3[0]); } public function invalidate():void{ dispatchEvent(new DataChangeEvent(DataChangeEvent.DATA_CHANGE, DataChangeType.INVALIDATE_ALL, data.concat(), 0, data.length)); } public function removeAll():void{ var _local1:Array; _local1 = data.concat(); dispatchPreChangeEvent(DataChangeType.REMOVE_ALL, _local1, 0, _local1.length); data = []; dispatchChangeEvent(DataChangeType.REMOVE_ALL, _local1, 0, _local1.length); } } }//package fl.data
Section 137
//SimpleCollectionItem (fl.data.SimpleCollectionItem) package fl.data { public dynamic class SimpleCollectionItem { public var label:String; public var data:String; public function toString():String{ return ((((("[SimpleCollectionItem: " + label) + ",") + data) + "]")); } } }//package fl.data
Section 138
//ColorPickerEvent (fl.events.ColorPickerEvent) package fl.events { import flash.events.*; public class ColorPickerEvent extends Event { protected var _color:uint; public static const ITEM_ROLL_OUT:String = "itemRollOut"; public static const ITEM_ROLL_OVER:String = "itemRollOver"; public static const CHANGE:String = "change"; public static const ENTER:String = "enter"; public function ColorPickerEvent(_arg1:String, _arg2:uint){ super(_arg1, true); _color = _arg2; } override public function toString():String{ return (formatToString("ColorPickerEvent", "type", "bubbles", "cancelable", "color")); } public function get color():uint{ return (_color); } override public function clone():Event{ return (new ColorPickerEvent(type, color)); } } }//package fl.events
Section 139
//ComponentEvent (fl.events.ComponentEvent) package fl.events { import flash.events.*; public class ComponentEvent extends Event { public static const HIDE:String = "hide"; public static const BUTTON_DOWN:String = "buttonDown"; public static const MOVE:String = "move"; public static const RESIZE:String = "resize"; public static const ENTER:String = "enter"; public static const LABEL_CHANGE:String = "labelChange"; public static const SHOW:String = "show"; public function ComponentEvent(_arg1:String, _arg2:Boolean=false, _arg3:Boolean=false){ super(_arg1, _arg2, _arg3); } override public function toString():String{ return (formatToString("ComponentEvent", "type", "bubbles", "cancelable")); } override public function clone():Event{ return (new ComponentEvent(type, bubbles, cancelable)); } } }//package fl.events
Section 140
//DataChangeEvent (fl.events.DataChangeEvent) package fl.events { import flash.events.*; public class DataChangeEvent extends Event { protected var _items:Array; protected var _endIndex:uint; protected var _changeType:String; protected var _startIndex:uint; public static const PRE_DATA_CHANGE:String = "preDataChange"; public static const DATA_CHANGE:String = "dataChange"; public function DataChangeEvent(_arg1:String, _arg2:String, _arg3:Array, _arg4:int=-1, _arg5:int=-1):void{ super(_arg1); _changeType = _arg2; _startIndex = _arg4; _items = _arg3; _endIndex = ((_arg5)==-1) ? _startIndex : _arg5; } public function get changeType():String{ return (_changeType); } public function get startIndex():uint{ return (_startIndex); } public function get items():Array{ return (_items); } override public function clone():Event{ return (new DataChangeEvent(type, _changeType, _items, _startIndex, _endIndex)); } override public function toString():String{ return (formatToString("DataChangeEvent", "type", "changeType", "startIndex", "endIndex", "bubbles", "cancelable")); } public function get endIndex():uint{ return (_endIndex); } } }//package fl.events
Section 141
//DataChangeType (fl.events.DataChangeType) package fl.events { public class DataChangeType { public static const ADD:String = "add"; public static const REMOVE:String = "remove"; public static const REMOVE_ALL:String = "removeAll"; public static const CHANGE:String = "change"; public static const REPLACE:String = "replace"; public static const INVALIDATE:String = "invalidate"; public static const INVALIDATE_ALL:String = "invalidateAll"; public static const SORT:String = "sort"; } }//package fl.events
Section 142
//ListEvent (fl.events.ListEvent) package fl.events { import flash.events.*; public class ListEvent extends Event { protected var _index:int; protected var _item:Object; protected var _columnIndex:int; protected var _rowIndex:int; public static const ITEM_DOUBLE_CLICK:String = "itemDoubleClick"; public static const ITEM_ROLL_OUT:String = "itemRollOut"; public static const ITEM_ROLL_OVER:String = "itemRollOver"; public static const ITEM_CLICK:String = "itemClick"; public function ListEvent(_arg1:String, _arg2:Boolean=false, _arg3:Boolean=false, _arg4:int=-1, _arg5:int=-1, _arg6:int=-1, _arg7:Object=null){ super(_arg1, _arg2, _arg3); _rowIndex = _arg5; _columnIndex = _arg4; _index = _arg6; _item = _arg7; } public function get rowIndex():Object{ return (_rowIndex); } public function get index():int{ return (_index); } public function get item():Object{ return (_item); } public function get columnIndex():int{ return (_columnIndex); } override public function clone():Event{ return (new ListEvent(type, bubbles, cancelable, _columnIndex, _rowIndex)); } override public function toString():String{ return (formatToString("ListEvent", "type", "bubbles", "cancelable", "columnIndex", "rowIndex", "index", "item")); } } }//package fl.events
Section 143
//ScrollEvent (fl.events.ScrollEvent) package fl.events { import flash.events.*; public class ScrollEvent extends Event { private var _position:Number; private var _direction:String; private var _delta:Number; public static const SCROLL:String = "scroll"; public function ScrollEvent(_arg1:String, _arg2:Number, _arg3:Number){ super(ScrollEvent.SCROLL, false, false); _direction = _arg1; _delta = _arg2; _position = _arg3; } override public function clone():Event{ return (new ScrollEvent(_direction, _delta, _position)); } public function get position():Number{ return (_position); } override public function toString():String{ return (formatToString("ScrollEvent", "type", "bubbles", "cancelable", "direction", "delta", "position")); } public function get delta():Number{ return (_delta); } public function get direction():String{ return (_direction); } } }//package fl.events
Section 144
//FocusManager (fl.managers.FocusManager) package fl.managers { import fl.core.*; import fl.controls.*; import flash.display.*; import flash.events.*; import flash.text.*; import flash.utils.*; import flash.ui.*; public class FocusManager implements IFocusManager { private var focusableObjects:Dictionary; private var _showFocusIndicator:Boolean;// = true private var defButton:Button; private var focusableCandidates:Array; private var _form:DisplayObjectContainer; private var _defaultButtonEnabled:Boolean;// = true private var activated:Boolean;// = false private var _defaultButton:Button; private var calculateCandidates:Boolean;// = true private var lastFocus:InteractiveObject; private var lastAction:String; public function FocusManager(_arg1:DisplayObjectContainer){ activated = false; calculateCandidates = true; _showFocusIndicator = true; _defaultButtonEnabled = true; super(); focusableObjects = new Dictionary(true); if (_arg1 != null){ _form = _arg1; addFocusables(DisplayObject(_arg1)); _arg1.addEventListener(Event.ADDED, addedHandler); _arg1.addEventListener(Event.REMOVED, removedHandler); activate(); }; } public function get showFocusIndicator():Boolean{ return (_showFocusIndicator); } private function getIndexOfNextObject(_arg1:int, _arg2:Boolean, _arg3:Boolean, _arg4:String):int{ var _local5:int; var _local6:int; var _local7:DisplayObject; var _local8:IFocusManagerGroup; var _local9:int; var _local10:DisplayObject; var _local11:IFocusManagerGroup; _local5 = focusableCandidates.length; _local6 = _arg1; while (true) { if (_arg2){ _arg1--; } else { _arg1++; }; if (_arg3){ if (((_arg2) && ((_arg1 < 0)))){ break; }; if (((!(_arg2)) && ((_arg1 == _local5)))){ break; }; } else { _arg1 = ((_arg1 + _local5) % _local5); if (_local6 == _arg1){ break; }; }; if (isValidFocusCandidate(focusableCandidates[_arg1], _arg4)){ _local7 = DisplayObject(findFocusManagerComponent(focusableCandidates[_arg1])); if ((_local7 is IFocusManagerGroup)){ _local8 = IFocusManagerGroup(_local7); _local9 = 0; while (_local9 < focusableCandidates.length) { _local10 = focusableCandidates[_local9]; if ((_local10 is IFocusManagerGroup)){ _local11 = IFocusManagerGroup(_local10); if ((((_local11.groupName == _local8.groupName)) && (_local11.selected))){ _arg1 = _local9; break; }; }; _local9++; }; }; return (_arg1); }; }; return (_arg1); } public function set form(_arg1:DisplayObjectContainer):void{ _form = _arg1; } private function addFocusables(_arg1:DisplayObject, _arg2:Boolean=false):void{ var focusable:IFocusManagerComponent; var io:InteractiveObject; var doc:DisplayObjectContainer; var i:int; var child:DisplayObject; var o = _arg1; var skipTopLevel = _arg2; if (!skipTopLevel){ if ((o is IFocusManagerComponent)){ focusable = IFocusManagerComponent(o); if (focusable.focusEnabled){ if (((focusable.tabEnabled) && (isTabVisible(o)))){ focusableObjects[o] = true; calculateCandidates = true; }; o.addEventListener(Event.TAB_ENABLED_CHANGE, tabEnabledChangeHandler); o.addEventListener(Event.TAB_INDEX_CHANGE, tabIndexChangeHandler); }; } else { if ((o is InteractiveObject)){ io = (o as InteractiveObject); if (((((io) && (io.tabEnabled))) && ((findFocusManagerComponent(io) == io)))){ focusableObjects[io] = true; calculateCandidates = true; }; io.addEventListener(Event.TAB_ENABLED_CHANGE, tabEnabledChangeHandler); io.addEventListener(Event.TAB_INDEX_CHANGE, tabIndexChangeHandler); }; }; }; if ((o is DisplayObjectContainer)){ doc = DisplayObjectContainer(o); o.addEventListener(Event.TAB_CHILDREN_CHANGE, tabChildrenChangeHandler); if ((((((doc is Stage)) || ((doc.parent is Stage)))) || (doc.tabChildren))){ i = 0; while (i < doc.numChildren) { try { child = doc.getChildAt(i); if (child != null){ addFocusables(doc.getChildAt(i)); }; } catch(error:SecurityError) { }; i = (i + 1); }; }; }; } private function getChildIndex(_arg1:DisplayObjectContainer, _arg2:DisplayObject):int{ return (_arg1.getChildIndex(_arg2)); } private function mouseFocusChangeHandler(_arg1:FocusEvent):void{ if ((_arg1.relatedObject is TextField)){ return; }; _arg1.preventDefault(); } private function focusOutHandler(_arg1:FocusEvent):void{ var _local2:InteractiveObject; _local2 = (_arg1.target as InteractiveObject); } private function isValidFocusCandidate(_arg1:DisplayObject, _arg2:String):Boolean{ var _local3:IFocusManagerGroup; if (!isEnabledAndVisible(_arg1)){ return (false); }; if ((_arg1 is IFocusManagerGroup)){ _local3 = IFocusManagerGroup(_arg1); if (_arg2 == _local3.groupName){ return (false); }; }; return (true); } public function findFocusManagerComponent(_arg1:InteractiveObject):InteractiveObject{ var _local2:InteractiveObject; _local2 = _arg1; while (_arg1) { if ((((_arg1 is IFocusManagerComponent)) && (IFocusManagerComponent(_arg1).focusEnabled))){ return (_arg1); }; _arg1 = _arg1.parent; }; return (_local2); } private function sortFocusableObjectsTabIndex():void{ var _local1:Object; var _local2:InteractiveObject; focusableCandidates = []; for (_local1 in focusableObjects) { _local2 = InteractiveObject(_local1); if (((_local2.tabIndex) && (!(isNaN(Number(_local2.tabIndex)))))){ focusableCandidates.push(_local2); }; }; focusableCandidates.sort(sortByTabIndex); } private function removeFocusables(_arg1:DisplayObject):void{ var _local2:Object; var _local3:DisplayObject; if ((_arg1 is DisplayObjectContainer)){ _arg1.removeEventListener(Event.TAB_CHILDREN_CHANGE, tabChildrenChangeHandler); _arg1.removeEventListener(Event.TAB_INDEX_CHANGE, tabIndexChangeHandler); for (_local2 in focusableObjects) { _local3 = DisplayObject(_local2); if (DisplayObjectContainer(_arg1).contains(_local3)){ if (_local3 == lastFocus){ lastFocus = null; }; _local3.removeEventListener(Event.TAB_ENABLED_CHANGE, tabEnabledChangeHandler); delete focusableObjects[_local2]; calculateCandidates = true; }; }; }; } private function addedHandler(_arg1:Event):void{ var _local2:DisplayObject; _local2 = DisplayObject(_arg1.target); if (_local2.stage){ addFocusables(DisplayObject(_arg1.target)); }; } private function getTopLevelFocusTarget(_arg1:InteractiveObject):InteractiveObject{ while (_arg1 != InteractiveObject(form)) { if ((((((((_arg1 is IFocusManagerComponent)) && (IFocusManagerComponent(_arg1).focusEnabled))) && (IFocusManagerComponent(_arg1).mouseFocusEnabled))) && (UIComponent(_arg1).enabled))){ return (_arg1); }; _arg1 = _arg1.parent; if (_arg1 == null){ break; }; }; return (null); } private function tabChildrenChangeHandler(_arg1:Event):void{ var _local2:DisplayObjectContainer; if (_arg1.target != _arg1.currentTarget){ return; }; calculateCandidates = true; _local2 = DisplayObjectContainer(_arg1.target); if (_local2.tabChildren){ addFocusables(_local2, true); } else { removeFocusables(_local2); }; } public function sendDefaultButtonEvent():void{ defButton.dispatchEvent(new MouseEvent(MouseEvent.CLICK)); } public function getFocus():InteractiveObject{ var _local1:InteractiveObject; _local1 = form.stage.focus; return (findFocusManagerComponent(_local1)); } private function isEnabledAndVisible(_arg1:DisplayObject):Boolean{ var _local2:DisplayObjectContainer; var _local3:TextField; var _local4:SimpleButton; _local2 = DisplayObject(form).parent; while (_arg1 != _local2) { if ((_arg1 is UIComponent)){ if (!UIComponent(_arg1).enabled){ return (false); }; } else { if ((_arg1 is TextField)){ _local3 = TextField(_arg1); if ((((_local3.type == TextFieldType.DYNAMIC)) || (!(_local3.selectable)))){ return (false); }; } else { if ((_arg1 is SimpleButton)){ _local4 = SimpleButton(_arg1); if (!_local4.enabled){ return (false); }; }; }; }; if (!_arg1.visible){ return (false); }; _arg1 = _arg1.parent; }; return (true); } public function set defaultButton(_arg1:Button):void{ var _local2:Button; _local2 = (_arg1) ? Button(_arg1) : null; if (_local2 != _defaultButton){ if (_defaultButton){ _defaultButton.emphasized = false; }; if (defButton){ defButton.emphasized = false; }; _defaultButton = _local2; defButton = _local2; if (_local2){ _local2.emphasized = true; }; }; } private function deactivateHandler(_arg1:Event):void{ var _local2:InteractiveObject; _local2 = InteractiveObject(_arg1.target); } public function setFocus(_arg1:InteractiveObject):void{ if ((_arg1 is IFocusManagerComponent)){ IFocusManagerComponent(_arg1).setFocus(); } else { form.stage.focus = _arg1; }; } private function setFocusToNextObject(_arg1:FocusEvent):void{ var _local2:InteractiveObject; if (!hasFocusableObjects()){ return; }; _local2 = getNextFocusManagerComponent(_arg1.shiftKey); if (_local2){ setFocus(_local2); }; } private function hasFocusableObjects():Boolean{ var _local1:Object; for (_local1 in focusableObjects) { return (true); }; return (false); } private function tabIndexChangeHandler(_arg1:Event):void{ calculateCandidates = true; } private function sortFocusableObjects():void{ var _local1:Object; var _local2:InteractiveObject; focusableCandidates = []; for (_local1 in focusableObjects) { _local2 = InteractiveObject(_local1); if (((((_local2.tabIndex) && (!(isNaN(Number(_local2.tabIndex)))))) && ((_local2.tabIndex > 0)))){ sortFocusableObjectsTabIndex(); return; }; focusableCandidates.push(_local2); }; focusableCandidates.sort(sortByDepth); } private function keyFocusChangeHandler(_arg1:FocusEvent):void{ showFocusIndicator = true; if ((((((_arg1.keyCode == Keyboard.TAB)) || ((_arg1.keyCode == 0)))) && (!(_arg1.isDefaultPrevented())))){ setFocusToNextObject(_arg1); _arg1.preventDefault(); }; } private function getIndexOfFocusedObject(_arg1:DisplayObject):int{ var _local2:int; var _local3:int; _local2 = focusableCandidates.length; _local3 = 0; _local3 = 0; while (_local3 < _local2) { if (focusableCandidates[_local3] == _arg1){ return (_local3); }; _local3++; }; return (-1); } public function hideFocus():void{ } private function removedHandler(_arg1:Event):void{ var _local2:int; var _local3:DisplayObject; var _local4:InteractiveObject; _local3 = DisplayObject(_arg1.target); if ((((_local3 is IFocusManagerComponent)) && ((focusableObjects[_local3] == true)))){ if (_local3 == lastFocus){ IFocusManagerComponent(lastFocus).drawFocus(false); lastFocus = null; }; _local3.removeEventListener(Event.TAB_ENABLED_CHANGE, tabEnabledChangeHandler); delete focusableObjects[_local3]; calculateCandidates = true; } else { if ((((_local3 is InteractiveObject)) && ((focusableObjects[_local3] == true)))){ _local4 = (_local3 as InteractiveObject); if (_local4){ if (_local4 == lastFocus){ lastFocus = null; }; delete focusableObjects[_local4]; calculateCandidates = true; }; _local3.addEventListener(Event.TAB_ENABLED_CHANGE, tabEnabledChangeHandler); }; }; removeFocusables(_local3); } private function sortByDepth(_arg1:InteractiveObject, _arg2:InteractiveObject):Number{ var _local3:String; var _local4:String; var _local5:int; var _local6:String; var _local7:String; var _local8:String; var _local9:DisplayObject; var _local10:DisplayObject; _local3 = ""; _local4 = ""; _local8 = "0000"; _local9 = DisplayObject(_arg1); _local10 = DisplayObject(_arg2); while (((!((_local9 == DisplayObject(form)))) && (_local9.parent))) { _local5 = getChildIndex(_local9.parent, _local9); _local6 = _local5.toString(16); if (_local6.length < 4){ _local7 = (_local8.substring(0, (4 - _local6.length)) + _local6); }; _local3 = (_local7 + _local3); _local9 = _local9.parent; }; while (((!((_local10 == DisplayObject(form)))) && (_local10.parent))) { _local5 = getChildIndex(_local10.parent, _local10); _local6 = _local5.toString(16); if (_local6.length < 4){ _local7 = (_local8.substring(0, (4 - _local6.length)) + _local6); }; _local4 = (_local7 + _local4); _local10 = _local10.parent; }; return (((_local3 > _local4)) ? 1 : ((_local3 < _local4)) ? -1 : 0); } public function get defaultButton():Button{ return (_defaultButton); } private function activateHandler(_arg1:Event):void{ var _local2:InteractiveObject; _local2 = InteractiveObject(_arg1.target); if (lastFocus){ if ((lastFocus is IFocusManagerComponent)){ IFocusManagerComponent(lastFocus).setFocus(); } else { form.stage.focus = lastFocus; }; }; lastAction = "ACTIVATE"; } public function showFocus():void{ } public function set defaultButtonEnabled(_arg1:Boolean):void{ _defaultButtonEnabled = _arg1; } public function getNextFocusManagerComponent(_arg1:Boolean=false):InteractiveObject{ var _local2:DisplayObject; var _local3:String; var _local4:int; var _local5:Boolean; var _local6:int; var _local7:int; var _local8:IFocusManagerGroup; if (!hasFocusableObjects()){ return (null); }; if (calculateCandidates){ sortFocusableObjects(); calculateCandidates = false; }; _local2 = form.stage.focus; _local2 = DisplayObject(findFocusManagerComponent(InteractiveObject(_local2))); _local3 = ""; if ((_local2 is IFocusManagerGroup)){ _local8 = IFocusManagerGroup(_local2); _local3 = _local8.groupName; }; _local4 = getIndexOfFocusedObject(_local2); _local5 = false; _local6 = _local4; if (_local4 == -1){ if (_arg1){ _local4 = focusableCandidates.length; }; _local5 = true; }; _local7 = getIndexOfNextObject(_local4, _arg1, _local5, _local3); return (findFocusManagerComponent(focusableCandidates[_local7])); } private function mouseDownHandler(_arg1:MouseEvent):void{ var _local2:InteractiveObject; if (_arg1.isDefaultPrevented()){ return; }; _local2 = getTopLevelFocusTarget(InteractiveObject(_arg1.target)); if (!_local2){ return; }; showFocusIndicator = false; if (((((!((_local2 == lastFocus))) || ((lastAction == "ACTIVATE")))) && (!((_local2 is TextField))))){ setFocus(_local2); }; lastAction = "MOUSEDOWN"; } private function isTabVisible(_arg1:DisplayObject):Boolean{ var _local2:DisplayObjectContainer; _local2 = _arg1.parent; while (((((_local2) && (!((_local2 is Stage))))) && (!(((_local2.parent) && ((_local2.parent is Stage))))))) { if (!_local2.tabChildren){ return (false); }; _local2 = _local2.parent; }; return (true); } public function get nextTabIndex():int{ return (0); } private function keyDownHandler(_arg1:KeyboardEvent):void{ if (_arg1.keyCode == Keyboard.TAB){ lastAction = "KEY"; if (calculateCandidates){ sortFocusableObjects(); calculateCandidates = false; }; }; if (((((((defaultButtonEnabled) && ((_arg1.keyCode == Keyboard.ENTER)))) && (defaultButton))) && (defButton.enabled))){ sendDefaultButtonEvent(); }; } private function focusInHandler(_arg1:FocusEvent):void{ var _local2:InteractiveObject; var _local3:Button; _local2 = InteractiveObject(_arg1.target); if (form.contains(_local2)){ lastFocus = findFocusManagerComponent(InteractiveObject(_local2)); if ((lastFocus is Button)){ _local3 = Button(lastFocus); if (defButton){ defButton.emphasized = false; defButton = _local3; _local3.emphasized = true; }; } else { if (((defButton) && (!((defButton == _defaultButton))))){ defButton.emphasized = false; defButton = _defaultButton; _defaultButton.emphasized = true; }; }; }; } private function tabEnabledChangeHandler(_arg1:Event):void{ var _local2:InteractiveObject; var _local3:Boolean; calculateCandidates = true; _local2 = InteractiveObject(_arg1.target); _local3 = (focusableObjects[_local2] == true); if (_local2.tabEnabled){ if (((!(_local3)) && (isTabVisible(_local2)))){ if (!(_local2 is IFocusManagerComponent)){ _local2.focusRect = false; }; focusableObjects[_local2] = true; }; } else { if (_local3){ delete focusableObjects[_local2]; }; }; } public function set showFocusIndicator(_arg1:Boolean):void{ _showFocusIndicator = _arg1; } public function get form():DisplayObjectContainer{ return (_form); } private function sortByTabIndex(_arg1:InteractiveObject, _arg2:InteractiveObject):int{ return (((_arg1.tabIndex > _arg2.tabIndex)) ? 1 : ((_arg1.tabIndex < _arg2.tabIndex)) ? -1 : sortByDepth(_arg1, _arg2)); } public function activate():void{ if (activated){ return; }; form.stage.addEventListener(FocusEvent.MOUSE_FOCUS_CHANGE, mouseFocusChangeHandler, false, 0, true); form.stage.addEventListener(FocusEvent.KEY_FOCUS_CHANGE, keyFocusChangeHandler, false, 0, true); form.addEventListener(FocusEvent.FOCUS_IN, focusInHandler, true); form.addEventListener(FocusEvent.FOCUS_OUT, focusOutHandler, true); form.stage.addEventListener(Event.ACTIVATE, activateHandler, false, 0, true); form.stage.addEventListener(Event.DEACTIVATE, deactivateHandler, false, 0, true); form.addEventListener(MouseEvent.MOUSE_DOWN, mouseDownHandler); form.addEventListener(KeyboardEvent.KEY_DOWN, keyDownHandler, true); activated = true; if (lastFocus){ setFocus(lastFocus); }; } public function deactivate():void{ form.stage.removeEventListener(FocusEvent.MOUSE_FOCUS_CHANGE, mouseFocusChangeHandler); form.stage.removeEventListener(FocusEvent.KEY_FOCUS_CHANGE, keyFocusChangeHandler); form.removeEventListener(FocusEvent.FOCUS_IN, focusInHandler, true); form.removeEventListener(FocusEvent.FOCUS_OUT, focusOutHandler, true); form.stage.removeEventListener(Event.ACTIVATE, activateHandler); form.stage.removeEventListener(Event.DEACTIVATE, deactivateHandler); form.removeEventListener(MouseEvent.MOUSE_DOWN, mouseDownHandler); form.removeEventListener(KeyboardEvent.KEY_DOWN, keyDownHandler, true); activated = false; } public function get defaultButtonEnabled():Boolean{ return (_defaultButtonEnabled); } } }//package fl.managers
Section 145
//IFocusManager (fl.managers.IFocusManager) package fl.managers { import fl.controls.*; import flash.display.*; public interface IFocusManager { function getFocus():InteractiveObject; function deactivate():void; function set defaultButton(_arg1:Button):void; function set showFocusIndicator(_arg1:Boolean):void; function get defaultButtonEnabled():Boolean; function get nextTabIndex():int; function get defaultButton():Button; function get showFocusIndicator():Boolean; function setFocus(_arg1:InteractiveObject):void; function activate():void; function showFocus():void; function set defaultButtonEnabled(_arg1:Boolean):void; function hideFocus():void; function findFocusManagerComponent(_arg1:InteractiveObject):InteractiveObject; function getNextFocusManagerComponent(_arg1:Boolean=false):InteractiveObject; } }//package fl.managers
Section 146
//IFocusManagerComponent (fl.managers.IFocusManagerComponent) package fl.managers { public interface IFocusManagerComponent { function set focusEnabled(_arg1:Boolean):void; function drawFocus(_arg1:Boolean):void; function setFocus():void; function get focusEnabled():Boolean; function get tabEnabled():Boolean; function get tabIndex():int; function get mouseFocusEnabled():Boolean; } }//package fl.managers
Section 147
//IFocusManagerGroup (fl.managers.IFocusManagerGroup) package fl.managers { public interface IFocusManagerGroup { function set groupName(_arg1:String):void; function set selected(_arg1:Boolean):void; function get groupName():String; function get selected():Boolean; } }//package fl.managers
Section 148
//StyleManager (fl.managers.StyleManager) package fl.managers { import fl.core.*; import flash.text.*; import flash.utils.*; public class StyleManager { private var globalStyles:Object; private var classToDefaultStylesDict:Dictionary; private var styleToClassesHash:Object; private var classToStylesDict:Dictionary; private var classToInstancesDict:Dictionary; private static var _instance:StyleManager; public function StyleManager(){ styleToClassesHash = {}; classToInstancesDict = new Dictionary(true); classToStylesDict = new Dictionary(true); classToDefaultStylesDict = new Dictionary(true); globalStyles = UIComponent.getStyleDefinition(); } public static function clearComponentStyle(_arg1:Object, _arg2:String):void{ var _local3:Class; var _local4:Object; _local3 = getClassDef(_arg1); _local4 = getInstance().classToStylesDict[_local3]; if (((!((_local4 == null))) && (!((_local4[_arg2] == null))))){ delete _local4[_arg2]; invalidateComponentStyle(_local3, _arg2); }; } private static function getClassDef(_arg1:Object):Class{ var component = _arg1; if ((component is Class)){ return ((component as Class)); }; try { return ((getDefinitionByName(getQualifiedClassName(component)) as Class)); } catch(e:Error) { if ((component is UIComponent)){ try { return ((component.loaderInfo.applicationDomain.getDefinition(getQualifiedClassName(component)) as Class)); } catch(e:Error) { }; }; }; return (null); } public static function clearStyle(_arg1:String):void{ setStyle(_arg1, null); } public static function setComponentStyle(_arg1:Object, _arg2:String, _arg3:Object):void{ var _local4:Class; var _local5:Object; _local4 = getClassDef(_arg1); _local5 = getInstance().classToStylesDict[_local4]; if (_local5 == null){ _local5 = (getInstance().classToStylesDict[_local4] = {}); }; if (_local5 == _arg3){ return; }; _local5[_arg2] = _arg3; invalidateComponentStyle(_local4, _arg2); } private static function setSharedStyles(_arg1:UIComponent):void{ var _local2:StyleManager; var _local3:Class; var _local4:Object; var _local5:String; _local2 = getInstance(); _local3 = getClassDef(_arg1); _local4 = _local2.classToDefaultStylesDict[_local3]; for (_local5 in _local4) { _arg1.setSharedStyle(_local5, getSharedStyle(_arg1, _local5)); }; } public static function getComponentStyle(_arg1:Object, _arg2:String):Object{ var _local3:Class; var _local4:Object; _local3 = getClassDef(_arg1); _local4 = getInstance().classToStylesDict[_local3]; return (((_local4)==null) ? null : _local4[_arg2]); } private static function getInstance(){ if (_instance == null){ _instance = new (StyleManager); }; return (_instance); } private static function invalidateComponentStyle(_arg1:Class, _arg2:String):void{ var _local3:Dictionary; var _local4:Object; var _local5:UIComponent; _local3 = getInstance().classToInstancesDict[_arg1]; if (_local3 == null){ return; }; for (_local4 in _local3) { _local5 = (_local4 as UIComponent); if (_local5 == null){ } else { _local5.setSharedStyle(_arg2, getSharedStyle(_local5, _arg2)); }; }; } private static function invalidateStyle(_arg1:String):void{ var _local2:Dictionary; var _local3:Object; _local2 = getInstance().styleToClassesHash[_arg1]; if (_local2 == null){ return; }; for (_local3 in _local2) { invalidateComponentStyle(Class(_local3), _arg1); }; } public static function registerInstance(_arg1:UIComponent):void{ var inst:StyleManager; var classDef:Class; var target:Class; var defaultStyles:Object; var styleToClasses:Object; var n:String; var instance = _arg1; inst = getInstance(); classDef = getClassDef(instance); if (classDef == null){ return; }; if (inst.classToInstancesDict[classDef] == null){ inst.classToInstancesDict[classDef] = new Dictionary(true); target = classDef; while (defaultStyles == null) { if (target["getStyleDefinition"] != null){ defaultStyles = target["getStyleDefinition"](); break; }; try { target = (instance.loaderInfo.applicationDomain.getDefinition(getQualifiedSuperclassName(target)) as Class); } catch(err:Error) { try { target = (getDefinitionByName(getQualifiedSuperclassName(target)) as Class); } catch(e:Error) { defaultStyles = UIComponent.getStyleDefinition(); break; }; }; }; styleToClasses = inst.styleToClassesHash; for (n in defaultStyles) { if (styleToClasses[n] == null){ styleToClasses[n] = new Dictionary(true); }; styleToClasses[n][classDef] = true; }; inst.classToDefaultStylesDict[classDef] = defaultStyles; inst.classToStylesDict[classDef] = {}; }; inst.classToInstancesDict[classDef][instance] = true; setSharedStyles(instance); } public static function getStyle(_arg1:String):Object{ return (getInstance().globalStyles[_arg1]); } private static function getSharedStyle(_arg1:UIComponent, _arg2:String):Object{ var _local3:Class; var _local4:StyleManager; var _local5:Object; _local3 = getClassDef(_arg1); _local4 = getInstance(); _local5 = _local4.classToStylesDict[_local3][_arg2]; if (_local5 != null){ return (_local5); }; _local5 = _local4.globalStyles[_arg2]; if (_local5 != null){ return (_local5); }; return (_local4.classToDefaultStylesDict[_local3][_arg2]); } public static function setStyle(_arg1:String, _arg2:Object):void{ var _local3:Object; _local3 = getInstance().globalStyles; if ((((_local3[_arg1] === _arg2)) && (!((_arg2 is TextFormat))))){ return; }; _local3[_arg1] = _arg2; invalidateStyle(_arg1); } } }//package fl.managers
Section 149
//Input (General.Input) package General { import flash.display.*; import flash.events.*; public class Input { public static var mouseOffsetX:Number = 0; private static var keyArr:Array; public static var mouseDragX:Number = 0; public static var mouseDragY:Number = 0; public static var mouseOffsetY:Number = 0; public static var ascii:Array; public static var mouseX:Number = 0; public static var mouseY:Number = 0; public static var mouseOver:Boolean = false; private static var bufferSize:int; public static var mouse:Sprite = new Sprite(); public static var mouseDown:Boolean = false; public static var mouseReleased:Boolean = false; public static var lastKey:int = 0; public static var m_stageMc:Sprite; private static var keyState:Array; public static var timeSinceLastKey = 0; public static var mousePressed:Boolean = false; private static var keyBuffer:Array; public function Input(_arg1:Sprite){ var _local2:int; var _local3:int; super(); m_stageMc = _arg1; ascii = new Array(222); fillAscii(); keyState = new Array(222); keyArr = new Array(); _local2 = 0; while (_local2 < 222) { keyState[_local2] = new int(0); if (ascii[_local2] != undefined){ keyArr.push(_local2); }; _local2++; }; bufferSize = 5; keyBuffer = new Array(bufferSize); _local3 = 0; while (_local3 < bufferSize) { keyBuffer[_local3] = new Array(0, 0); _local3++; }; _arg1.stage.addEventListener(KeyboardEvent.KEY_DOWN, keyPress, false, 0, true); _arg1.stage.addEventListener(KeyboardEvent.KEY_UP, keyRelease, false, 0, true); _arg1.stage.addEventListener(MouseEvent.MOUSE_DOWN, mousePress, false, 0, true); _arg1.stage.addEventListener(MouseEvent.CLICK, mouseRelease, false, 0, true); _arg1.stage.addEventListener(MouseEvent.MOUSE_MOVE, mouseMove, false, 0, true); _arg1.stage.addEventListener(Event.MOUSE_LEAVE, mouseLeave, false, 0, true); mouse.graphics.lineStyle(0.1, 0, 100); mouse.graphics.moveTo(0, 0); mouse.graphics.lineTo(0, 0.1); } public function mouseRelease(_arg1:MouseEvent){ mouseDown = false; mouseReleased = true; } public function keyPress(_arg1:KeyboardEvent){ keyState[_arg1.keyCode] = Math.max(keyState[_arg1.keyCode], 1); lastKey = _arg1.keyCode; } private function fillAscii(){ ascii[65] = "A"; ascii[66] = "B"; ascii[67] = "C"; ascii[68] = "D"; ascii[69] = "E"; ascii[70] = "F"; ascii[71] = "G"; ascii[72] = "H"; ascii[73] = "I"; ascii[74] = "J"; ascii[75] = "K"; ascii[76] = "L"; ascii[77] = "M"; ascii[78] = "N"; ascii[79] = "O"; ascii[80] = "P"; ascii[81] = "Q"; ascii[82] = "R"; ascii[83] = "S"; ascii[84] = "T"; ascii[85] = "U"; ascii[86] = "V"; ascii[87] = "W"; ascii[88] = "X"; ascii[89] = "Y"; ascii[90] = "Z"; ascii[48] = "0"; ascii[49] = "1"; ascii[50] = "2"; ascii[51] = "3"; ascii[52] = "4"; ascii[53] = "5"; ascii[54] = "6"; ascii[55] = "7"; ascii[56] = "8"; ascii[57] = "9"; ascii[32] = "Spacebar"; ascii[17] = "Ctrl"; ascii[16] = "Shift"; ascii[192] = "~"; ascii[38] = "up"; ascii[40] = "down"; ascii[37] = "left"; ascii[39] = "right"; ascii[96] = "Numpad 0"; ascii[97] = "Numpad 1"; ascii[98] = "Numpad 2"; ascii[99] = "Numpad 3"; ascii[100] = "Numpad 4"; ascii[101] = "Numpad 5"; ascii[102] = "Numpad 6"; ascii[103] = "Numpad 7"; ascii[104] = "Numpad 8"; ascii[105] = "Numpad 9"; ascii[111] = "Numpad /"; ascii[106] = "Numpad *"; ascii[109] = "Numpad -"; ascii[107] = "Numpad +"; ascii[110] = "Numpad ."; ascii[45] = "Insert"; ascii[46] = "Delete"; ascii[33] = "Page Up"; ascii[34] = "Page Down"; ascii[35] = "End"; ascii[36] = "Home"; ascii[112] = "F1"; ascii[113] = "F2"; ascii[114] = "F3"; ascii[115] = "F4"; ascii[116] = "F5"; ascii[117] = "F6"; ascii[118] = "F7"; ascii[119] = "F8"; ascii[188] = ","; ascii[190] = "."; ascii[186] = ";"; ascii[222] = "'"; ascii[219] = "["; ascii[221] = "]"; ascii[189] = "-"; ascii[187] = "+"; ascii[220] = "\\"; ascii[191] = "/"; ascii[9] = "TAB"; ascii[8] = "Backspace"; } public function mouseMove(_arg1:MouseEvent){ if (mouseDown != _arg1.buttonDown){ mouseDown = _arg1.buttonDown; mouseReleased = !(_arg1.buttonDown); mousePressed = _arg1.buttonDown; mouseDragX = 0; mouseDragY = 0; }; mouseX = (_arg1.stageX - m_stageMc.x); mouseY = (_arg1.stageY - m_stageMc.y); mouseOffsetX = (mouseX - mouse.x); mouseOffsetY = (mouseY - mouse.y); if (mouseDown){ mouseDragX = (mouseDragX + mouseOffsetX); mouseDragY = (mouseDragY + mouseOffsetY); }; mouse.x = mouseX; mouse.y = mouseY; } public function keyRelease(_arg1:KeyboardEvent){ var _local2:int; keyState[_arg1.keyCode] = -1; _local2 = (bufferSize - 1); while (_local2 > 0) { keyBuffer[_local2] = keyBuffer[(_local2 - 1)]; _local2--; }; keyBuffer[0] = [_arg1.keyCode, 0]; } public function mouseLeave(_arg1:Event){ mouseReleased = mouseDown; mouseDown = false; } public function mousePress(_arg1:MouseEvent){ mousePressed = true; mouseDown = true; mouseDragX = 0; mouseDragY = 0; } public static function getKeyHold(_arg1:int):int{ return (Math.max(0, keyState[_arg1])); } public static function update(){ var _local1:int; var _local2:int; _local1 = 0; while (_local1 < keyArr.length) { if (keyState[keyArr[_local1]] != 0){ var _local3 = keyState; var _local4 = keyArr[_local1]; var _local5 = (_local3[_local4] + 1); _local3[_local4] = _local5; }; _local1++; }; _local2 = 0; while (_local2 < bufferSize) { _local3 = keyBuffer[_local2]; _local4 = 1; _local5 = (_local3[_local4] + 1); _local3[_local4] = _local5; _local2++; }; mouseReleased = false; mousePressed = false; mouseOver = false; } public static function isKeyPressed(_arg1:int):Boolean{ timeSinceLastKey = 0; return ((keyState[_arg1] == 1)); } public static function isKeyDown(_arg1:int):Boolean{ return ((keyState[_arg1] > 0)); } public static function getKeyString(_arg1:uint):String{ return (ascii[_arg1]); } public static function isKeyReleased(_arg1:int):Boolean{ return ((keyState[_arg1] == -1)); } public static function isKeyInBuffer(_arg1:int, _arg2:int, _arg3:int){ return ((((keyBuffer[_arg2][0] == _arg1)) && ((keyBuffer[_arg2][1] <= _arg3)))); } } }//package General
Section 150
//MochiDigits (mochi.as3.MochiDigits) package mochi.as3 { public final class MochiDigits { private var Sibling:MochiDigits; private var Fragment:Number; private var Encoder:Number; public function MochiDigits(_arg1:Number=0, _arg2:uint=0):void{ Encoder = 0; setValue(_arg1, _arg2); } public function set value(_arg1:Number):void{ setValue(_arg1); } public function reencode():void{ var _local1:uint; _local1 = int((2147483647 * Math.random())); Fragment = (Fragment ^ (_local1 ^ Encoder)); Encoder = _local1; } public function toString():String{ var _local1:String; _local1 = String.fromCharCode((Fragment ^ Encoder)); if (Sibling != null){ _local1 = (_local1 + Sibling.toString()); }; return (_local1); } public function get value():Number{ return (Number(this.toString())); } public function setValue(_arg1:Number=0, _arg2:uint=0):void{ var _local3:String; _local3 = _arg1.toString(); var _temp1 = _arg2; _arg2 = (_arg2 + 1); Fragment = (_local3.charCodeAt(_temp1) ^ Encoder); if (_arg2 < _local3.length){ Sibling = new MochiDigits(_arg1, _arg2); } else { Sibling = null; }; reencode(); } public function addValue(_arg1:Number):void{ value = (value + _arg1); } } }//package mochi.as3
Section 151
//MochiScores (mochi.as3.MochiScores) package mochi.as3 { import flash.display.*; import flash.text.*; public class MochiScores { private static var boardID:String; public static var onErrorHandler:Object; public static var onCloseHandler:Object; public static function showLeaderboard(_arg1:Object=null):void{ var n:Number; var options = _arg1; if (options != null){ if (options.clip != null){ if ((options.clip is Sprite)){ MochiServices.setContainer(options.clip); }; delete options.clip; } else { MochiServices.setContainer(); }; MochiServices.stayOnTop(); if (options.name != null){ if ((options.name is TextField)){ if (options.name.text.length > 0){ options.name = options.name.text; }; }; }; if (options.score != null){ if ((options.score is TextField)){ if (options.score.text.length > 0){ options.score = options.score.text; }; } else { if ((options.score is MochiDigits)){ options.score = options.score.value; }; }; n = Number(options.score); if (isNaN(n)){ trace((("ERROR: Submitted score '" + options.score) + "' will be rejected, score is 'Not a Number'")); } else { if ((((n == Number.NEGATIVE_INFINITY)) || ((n == Number.POSITIVE_INFINITY)))){ trace((("ERROR: Submitted score '" + options.score) + "' will be rejected, score is an infinite")); } else { if (Math.floor(n) != n){ trace((("WARNING: Submitted score '" + options.score) + "' will be truncated")); }; options.score = n; }; }; }; if (options.onDisplay != null){ options.onDisplay(); } else { if (MochiServices.clip != null){ if ((MochiServices.clip is MovieClip)){ MochiServices.clip.stop(); } else { trace("Warning: Container is not a MovieClip, cannot call default onDisplay."); }; }; }; } else { options = {}; if ((MochiServices.clip is MovieClip)){ MochiServices.clip.stop(); } else { trace("Warning: Container is not a MovieClip, cannot call default onDisplay."); }; }; if (options.onClose != null){ onCloseHandler = options.onClose; } else { onCloseHandler = function ():void{ if ((MochiServices.clip is MovieClip)){ MochiServices.clip.play(); } else { trace("Warning: Container is not a MovieClip, cannot call default onClose."); }; }; }; if (options.onError != null){ onErrorHandler = options.onError; } else { onErrorHandler = null; }; if (options.boardID == null){ if (MochiScores.boardID != null){ options.boardID = MochiScores.boardID; }; }; trace("[MochiScores] NOTE: Security Sandbox Violation errors below are normal"); MochiServices.send("scores_showLeaderboard", {options:options}, null, onClose); } public static function closeLeaderboard():void{ MochiServices.send("scores_closeLeaderboard"); } public static function getPlayerInfo(_arg1:Object, _arg2:Object=null):void{ MochiServices.send("scores_getPlayerInfo", null, _arg1, _arg2); } public static function requestList(_arg1:Object, _arg2:Object=null):void{ MochiServices.send("scores_requestList", null, _arg1, _arg2); } public static function scoresArrayToObjects(_arg1:Object):Object{ var _local2:Object; var _local3:Number; var _local4:Number; var _local5:Object; var _local6:Object; var _local7:String; var _local8:String; _local2 = {}; for (_local7 in _arg1) { if (typeof(_arg1[_local7]) == "object"){ if (((!((_arg1[_local7].cols == null))) && (!((_arg1[_local7].rows == null))))){ _local2[_local7] = []; _local5 = _arg1[_local7]; _local4 = 0; while (_local4 < _local5.rows.length) { _local6 = {}; _local3 = 0; while (_local3 < _local5.cols.length) { _local6[_local5.cols[_local3]] = _local5.rows[_local4][_local3]; _local3++; }; _local2[_local7].push(_local6); _local4++; }; } else { _local2[_local7] = {}; for (_local8 in _arg1[_local7]) { _local2[_local7][_local8] = _arg1[_local7][_local8]; }; }; } else { _local2[_local7] = _arg1[_local7]; }; }; return (_local2); } public static function submit(_arg1:Number, _arg2:String, _arg3:Object=null, _arg4:Object=null):void{ _arg1 = Number(_arg1); if (isNaN(_arg1)){ trace((("ERROR: Submitted score '" + String(_arg1)) + "' will be rejected, score is 'Not a Number'")); } else { if ((((_arg1 == Number.NEGATIVE_INFINITY)) || ((_arg1 == Number.POSITIVE_INFINITY)))){ trace((("ERROR: Submitted score '" + String(_arg1)) + "' will be rejected, score is an infinite")); } else { if (Math.floor(_arg1) != _arg1){ trace((("WARNING: Submitted score '" + String(_arg1)) + "' will be truncated")); }; _arg1 = Number(_arg1); }; }; MochiServices.send("scores_submit", {score:_arg1, name:_arg2}, _arg3, _arg4); } public static function onClose(_arg1:Object=null):void{ if (_arg1 != null){ if (_arg1.error != null){ if (_arg1.error == true){ if (onErrorHandler != null){ if (_arg1.errorCode == null){ _arg1.errorCode = "IOError"; }; onErrorHandler(_arg1.errorCode); MochiServices.doClose(); return; }; }; }; }; onCloseHandler(); MochiServices.doClose(); } public static function setBoardID(_arg1:String):void{ MochiScores.boardID = _arg1; MochiServices.send("scores_setBoardID", {boardID:_arg1}); } } }//package mochi.as3
Section 152
//MochiServices (mochi.as3.MochiServices) package mochi.as3 { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.utils.*; import flash.system.*; public class MochiServices { private static var _container:Object; private static var _connected:Boolean = false; private static var _swfVersion:String; public static var netupAttempted:Boolean = false; private static var _sendChannel:LocalConnection; private static var _clip:MovieClip; private static var _loader:Loader; private static var _id:String; private static var _listenChannel:LocalConnection; public static var widget:Boolean = false; private static var _timer:Timer; private static var _sendChannelName:String; private static var _connecting:Boolean = false; public static var onError:Object; private static var _listenChannelName:String = "__ms_"; private static var _servicesURL:String = "http://www.mochiads.com/static/lib/services/services.swf"; public static var netup:Boolean = true; public static function isNetworkAvailable():Boolean{ return (!((Security.sandboxType == "localWithFile"))); } public static function get connected():Boolean{ return (_connected); } private static function flush(_arg1:Boolean):void{ var _local2:Object; var _local3:Object; if (_clip != null){ if (_clip._queue != null){ while (_clip._queue.length > 0) { _local2 = _clip._queue.shift(); _local3 = null; if (_local2 != null){ if (_local2.callbackID != null){ _local3 = _clip._callbacks[_local2.callbackID]; }; delete _clip._callbacks[_local2.callbackID]; if (((_arg1) && (!((_local3 == null))))){ handleError(_local2.args, _local3.callbackObject, _local3.callbackMethod); }; }; }; }; }; } public static function send(_arg1:String, _arg2:Object=null, _arg3:Object=null, _arg4:Object=null):void{ if (_connected){ _sendChannel.send(_sendChannelName, "onReceive", {methodName:_arg1, args:_arg2, callbackID:_clip._nextcallbackID}); } else { if ((((_clip == null)) || (!(_connecting)))){ onError("NotConnected"); handleError(_arg2, _arg3, _arg4); flush(true); return; }; _clip._queue.push({methodName:_arg1, args:_arg2, callbackID:_clip._nextcallbackID}); }; if (_clip != null){ if (((!((_clip._callbacks == null))) && (!((_clip._nextcallbackID == null))))){ _clip._callbacks[_clip._nextcallbackID] = {callbackObject:_arg3, callbackMethod:_arg4}; _clip._nextcallbackID++; }; }; } private static function init(_arg1:String, _arg2:Object):void{ _id = _arg1; if (_arg2 != null){ _container = _arg2; loadCommunicator(_arg1, _container); }; } public static function get childClip():Object{ return (_clip); } private static function clickMovie(_arg1:String, _arg2:Function):MovieClip{ var _local3:Array; var _local4:int; var _local5:Array; var _local6:Array; var _local7:MovieClip; var _local8:LocalConnection; var _local9:String; var _local10:ByteArray; var _local11:ByteArray; var _local12:uint; var _local13:uint; var _local14:Loader; _local3 = [150, 21, 0, 7, 1, 0, 0, 0, 0, 98, 116, 110, 0, 7, 2, 0, 0, 0, 0, 116, 104, 105, 115, 0, 28, 150, 22, 0, 0, 99, 114, 101, 97, 116, 101, 69, 109, 112, 116, 121, 77, 111, 118, 105, 101, 67, 108, 105, 112, 0, 82, 135, 1, 0, 0, 23, 150, 13, 0, 4, 0, 0, 111, 110, 82, 101, 108, 101, 97, 115, 101, 0, 142, 8, 0, 0, 0, 0, 2, 42, 0, 114, 0, 150, 17, 0, 0, 32, 0, 7, 1, 0, 0, 0, 8, 0, 0, 115, 112, 108, 105, 116, 0, 82, 135, 1, 0, 1, 23, 150, 7, 0, 4, 1, 7, 0, 0, 0, 0, 78, 150, 8, 0, 0, 95, 98, 108, 97, 110, 107, 0, 154, 1, 0, 0, 150, 7, 0, 0, 99, 108, 105, 99, 107, 0, 150, 7, 0, 4, 1, 7, 1, 0, 0, 0, 78, 150, 27, 0, 7, 2, 0, 0, 0, 7, 0, 0, 0, 0, 0, 76, 111, 99, 97, 108, 67, 111, 110, 110, 101, 99, 116, 105, 111, 110, 0, 64, 150, 6, 0, 0, 115, 101, 110, 100, 0, 82, 79, 150, 15, 0, 4, 0, 0, 95, 97, 108, 112, 104, 97, 0, 7, 0, 0, 0, 0, 79, 150, 23, 0, 7, 0xFF, 0, 0xFF, 0, 7, 1, 0, 0, 0, 4, 0, 0, 98, 101, 103, 105, 110, 70, 105, 108, 108, 0, 82, 23, 150, 25, 0, 7, 0, 0, 0, 0, 7, 0, 0, 0, 0, 7, 2, 0, 0, 0, 4, 0, 0, 109, 111, 118, 101, 84, 111, 0, 82, 23, 150, 25, 0, 7, 100, 0, 0, 0, 7, 0, 0, 0, 0, 7, 2, 0, 0, 0, 4, 0, 0, 108, 105, 110, 101, 84, 111, 0, 82, 23, 150, 25, 0, 7, 100, 0, 0, 0, 7, 100, 0, 0, 0, 7, 2, 0, 0, 0, 4, 0, 0, 108, 105, 110, 101, 84, 111, 0, 82, 23, 150, 25, 0, 7, 0, 0, 0, 0, 7, 100, 0, 0, 0, 7, 2, 0, 0, 0, 4, 0, 0, 108, 105, 110, 101, 84, 111, 0, 82, 23, 150, 25, 0, 7, 0, 0, 0, 0, 7, 0, 0, 0, 0, 7, 2, 0, 0, 0, 4, 0, 0, 108, 105, 110, 101, 84, 111, 0, 82, 23, 150, 16, 0, 7, 0, 0, 0, 0, 4, 0, 0, 101, 110, 100, 70, 105, 108, 108, 0, 82, 23]; _local5 = [104, 0, 31, 64, 0, 7, 208, 0, 0, 12, 1, 0, 67, 2, 0xFF, 0xFF, 0xFF, 63, 3]; _local6 = [0, 64, 0, 0, 0]; _local7 = new MovieClip(); _local8 = new LocalConnection(); _local9 = ((("_click_" + Math.floor((Math.random() * 999999))) + "_") + Math.floor(new Date().getTime())); _local8 = new LocalConnection(); _local7.lc = _local8; _local7.click = _arg2; _local8.client = _local7; _local8.connect(_local9); _local10 = new ByteArray(); _local11 = new ByteArray(); _local11.endian = Endian.LITTLE_ENDIAN; _local11.writeShort(1); _local11.writeUTFBytes(((_arg1 + " ") + _local9)); _local11.writeByte(0); _local12 = ((_local3.length + _local11.length) + 4); _local13 = (_local12 + 35); _local10.endian = Endian.LITTLE_ENDIAN; _local10.writeUTFBytes("FWS"); _local10.writeByte(8); _local10.writeUnsignedInt(_local13); for each (_local4 in _local5) { _local10.writeByte(_local4); }; _local10.writeUnsignedInt(_local12); _local10.writeByte(136); _local10.writeShort(_local11.length); _local10.writeBytes(_local11); for each (_local4 in _local3) { _local10.writeByte(_local4); }; for each (_local4 in _local6) { _local10.writeByte(_local4); }; _local14 = new Loader(); _local14.loadBytes(_local10); _local7.addChild(_local14); return (_local7); } public static function stayOnTop():void{ _container.addEventListener(Event.ENTER_FRAME, MochiServices.bringToTop, false, 0, true); if (_clip != null){ _clip.visible = true; }; } public static function addLinkEvent(_arg1:String, _arg2:String, _arg3:DisplayObjectContainer, _arg4:Function=null):void{ var vars:Object; var avm1Click:DisplayObject; var s:String; var i:Number; var x:String; var req:URLRequest; var loader:Loader; var setURL:Function; var err:Function; var complete:Function; var url = _arg1; var burl = _arg2; var btn = _arg3; var onClick = _arg4; vars = new Object(); vars["mav"] = getVersion(); vars["swfv"] = "9"; vars["swfurl"] = btn.loaderInfo.loaderURL; vars["fv"] = Capabilities.version; vars["os"] = Capabilities.os; vars["lang"] = Capabilities.language; vars["scres"] = ((Capabilities.screenResolutionX + "x") + Capabilities.screenResolutionY); s = "?"; i = 0; for (x in vars) { if (i != 0){ s = (s + "&"); }; i = (i + 1); s = (((s + x) + "=") + escape(vars[x])); }; req = new URLRequest("http://x.mochiads.com/linkping.swf"); loader = new Loader(); setURL = function (_arg1:String):void{ var _local2:Rectangle; if (avm1Click){ btn.removeChild(avm1Click); }; avm1Click = clickMovie(_arg1, onClick); _local2 = btn.getBounds(btn); btn.addChild(avm1Click); avm1Click.x = _local2.x; avm1Click.y = _local2.y; avm1Click.scaleX = (0.01 * _local2.width); avm1Click.scaleY = (0.01 * _local2.height); }; err = function (_arg1:Object):void{ netup = false; _arg1.target.removeEventListener(_arg1.type, arguments.callee); setURL(burl); }; complete = function (_arg1:Object):void{ _arg1.target.removeEventListener(_arg1.type, arguments.callee); }; if (netup){ setURL((url + s)); } else { setURL(burl); }; if (!((netupAttempted) || (_connected))){ netupAttempted = true; loader.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, err); loader.contentLoaderInfo.addEventListener(Event.COMPLETE, complete); loader.load(req); }; } public static function disconnect():void{ if (((_connected) || (_connecting))){ if (_clip != null){ if (_clip.parent != null){ if ((_clip.parent is Sprite)){ Sprite(_clip.parent).removeChild(_clip); _clip = null; }; }; }; _connecting = (_connected = false); flush(true); try { _listenChannel.close(); } catch(error:Error) { }; }; if (_timer != null){ try { _timer.stop(); } catch(error:Error) { }; }; } public static function allowDomains(_arg1:String):String{ var _local2:String; if (Security.sandboxType != "application"){ Security.allowDomain("*"); Security.allowInsecureDomain("*"); }; if (_arg1.indexOf("http://") != -1){ _local2 = _arg1.split("/")[2].split(":")[0]; if (Security.sandboxType != "application"){ Security.allowDomain(_local2); Security.allowInsecureDomain(_local2); }; }; return (_local2); } public static function getVersion():String{ return ("3.0"); } public static function doClose():void{ _container.removeEventListener(Event.ENTER_FRAME, MochiServices.bringToTop); if (_clip.parent != null){ Sprite(_clip.parent).removeChild(_clip); }; } private static function onStatus(_arg1:StatusEvent):void{ switch (_arg1.level){ case "error": _connected = false; _listenChannel.connect(_listenChannelName); break; }; } public static function get id():String{ return (_id); } private static function urlOptions(_arg1:Object):Object{ var _local2:Object; var _local3:String; var _local4:Array; var _local5:Number; var _local6:Array; _local2 = {}; _local3 = _arg1.loaderInfo.parameters.mochiad_options; if (_local3){ _local4 = _local3.split("&"); _local5 = 0; while (_local5 < _local4.length) { _local6 = _local4[_local5].split("="); _local2[unescape(_local6[0])] = unescape(_local6[1]); _local5++; }; }; return (_local2); } public static function setContainer(_arg1:Object=null, _arg2:Boolean=true):void{ if (_arg1 != null){ if ((_arg1 is Sprite)){ _container = _arg1; }; }; if (_arg2){ if ((_container is Sprite)){ Sprite(_container).addChild(_clip); }; }; } private static function handleError(_arg1:Object, _arg2:Object, _arg3:Object):void{ var args = _arg1; var callbackObject = _arg2; var callbackMethod = _arg3; if (args != null){ if (args.onError != null){ args.onError.apply(null, ["NotConnected"]); }; if (((!((args.options == null))) && (!((args.options.onError == null))))){ args.options.onError.apply(null, ["NotConnected"]); }; }; if (callbackMethod != null){ args = {}; args.error = true; args.errorCode = "NotConnected"; if (((!((callbackObject == null))) && ((callbackMethod is String)))){ try { var _local5 = callbackObject; _local5[callbackMethod](args); } catch(error:Error) { }; } else { if (callbackMethod != null){ try { callbackMethod.apply(args); } catch(error:Error) { }; }; }; }; } private static function initComChannels():void{ if (!_connected){ _sendChannel.addEventListener(StatusEvent.STATUS, MochiServices.onStatus); _sendChannel.send(_sendChannelName, "onReceive", {methodName:"handshakeDone"}); _sendChannel.send(_sendChannelName, "onReceive", {methodName:"registerGame", id:_id, clip:_container, version:getVersion(), parentURL:_container.loaderInfo.loaderURL}); _listenChannel.addEventListener(StatusEvent.STATUS, MochiServices.onStatus); _clip.onReceive = function (_arg1:Object):void{ var cb:String; var cblst:Object; var method:*; var methodName:String; var obj:Object; var pkg = _arg1; cb = pkg.callbackID; cblst = this.client._callbacks[cb]; if (!cblst){ return; }; method = cblst.callbackMethod; methodName = ""; obj = cblst.callbackObject; if (((obj) && ((typeof(method) == "string")))){ methodName = method; if (obj[method] != null){ method = obj[method]; } else { trace((("Error: Method " + method) + " does not exist.")); }; }; if (method != undefined){ try { method.apply(obj, pkg.args); } catch(error:Error) { trace(((("Error invoking callback method '" + methodName) + "': ") + error.toString())); }; } else { if (obj != null){ try { obj(pkg.args); } catch(error:Error) { trace(("Error invoking method on object: " + error.toString())); }; }; }; delete this.client._callbacks[cb]; }; _clip.onError = function ():void{ MochiServices.onError("IOError"); }; trace("connected!"); _connecting = false; _connected = true; while (_clip._queue.length > 0) { _sendChannel.send(_sendChannelName, "onReceive", _clip._queue.shift()); }; }; } private static function listen():void{ _listenChannel = new LocalConnection(); _listenChannel.client = _clip; _clip.handshake = function (_arg1:Object):void{ MochiServices.comChannelName = _arg1.newChannel; }; _listenChannel.allowDomain("*", "localhost"); _listenChannel.allowInsecureDomain("*", "localhost"); _listenChannel.connect(_listenChannelName); trace("Waiting for MochiAds services to connect..."); } public static function set comChannelName(_arg1:String):void{ if (_arg1 != null){ if (_arg1.length > 3){ _sendChannelName = (_arg1 + "_fromgame"); initComChannels(); }; }; } private static function loadCommunicator(_arg1:String, _arg2:Object):MovieClip{ var clipname:String; var f:Function; var req:URLRequest; var vars:URLVariables; var id = _arg1; var clip = _arg2; clipname = ("_mochiservices_com_" + id); if (_clip != null){ return (_clip); }; if (!MochiServices.isNetworkAvailable()){ return (null); }; if (urlOptions(clip).servicesURL != undefined){ _servicesURL = urlOptions(clip).servicesURL; }; MochiServices.allowDomains(_servicesURL); _clip = createEmptyMovieClip(clip, clipname, 10336, false); _loader = new Loader(); f = function (_arg1:Object):void{ _clip._mochiad_ctr_failed = true; trace("MochiServices could not load."); MochiServices.disconnect(); MochiServices.onError("IOError"); }; _listenChannelName = (_listenChannelName + ((Math.floor(new Date().getTime()) + "_") + Math.floor((Math.random() * 99999)))); _loader.contentLoaderInfo.addEventListener(IOErrorEvent.IO_ERROR, f); req = new URLRequest(_servicesURL); vars = new URLVariables(); vars.listenLC = _listenChannelName; vars.mochiad_options = clip.loaderInfo.parameters.mochiad_options; if (widget){ vars.widget = true; }; req.data = vars; listen(); _loader.load(req); _clip.addChild(_loader); _clip._mochiservices_com = _loader; _sendChannel = new LocalConnection(); _clip._queue = []; _clip._nextcallbackID = 0; _clip._callbacks = {}; _timer = new Timer(10000, 1); _timer.addEventListener(TimerEvent.TIMER, connectWait); _timer.start(); return (_clip); } public static function get clip():Object{ return (_container); } public static function bringToTop(_arg1:Event):void{ var e = _arg1; if (MochiServices.clip != null){ if (MochiServices.childClip != null){ try { if (MochiServices.clip.numChildren > 1){ MochiServices.clip.setChildIndex(MochiServices.childClip, (MochiServices.clip.numChildren - 1)); }; } catch(errorObject:Error) { trace("Warning: Depth sort error."); _container.removeEventListener(Event.ENTER_FRAME, MochiServices.bringToTop); }; }; }; } public static function connect(_arg1:String, _arg2:Object, _arg3:Object=null):void{ var id = _arg1; var clip = _arg2; var onError = _arg3; if ((clip is DisplayObject)){ if (((!(_connected)) && ((_clip == null)))){ trace("MochiServices Connecting..."); _connecting = true; init(id, clip); }; } else { trace("Error, MochiServices requires a Sprite, Movieclip or instance of the stage."); }; if (onError != null){ MochiServices.onError = onError; } else { if (MochiServices.onError == null){ MochiServices.onError = function (_arg1:String):void{ trace(_arg1); }; }; }; } public static function createEmptyMovieClip(_arg1:Object, _arg2:String, _arg3:Number, _arg4:Boolean=true):MovieClip{ var mc:MovieClip; var parent = _arg1; var name = _arg2; var depth = _arg3; var doAdd = _arg4; mc = new MovieClip(); if (doAdd){ if (((false) && (depth))){ parent.addChildAt(mc, depth); } else { parent.addChild(mc); }; }; try { parent[name] = mc; } catch(e:Error) { throw (new Error("MochiServices requires a clip that is an instance of a dynamic class. If your class extends Sprite or MovieClip, you must make it dynamic.")); }; mc["_name"] = name; return (mc); } public static function connectWait(_arg1:TimerEvent):void{ if (!_connected){ _clip._mochiad_ctr_failed = true; trace("MochiServices could not load. (timeout)"); MochiServices.disconnect(); MochiServices.onError("IOError"); }; } } }//package mochi.as3
Section 153
//DoubleRamp (src.levels.DoubleRamp) package src.levels { public class DoubleRamp { public static var SourceXML:String = "<root> <floor x="473.1" y="-50" width="10.58" height="43.13" rotation="0"></floor> <floor x="254.09" y="285.275" width="9" height="6" rotation="0"></floor> <floor x="259.305" y="285.085" width="9" height="6" rotation="-0.0830070997243525"></floor> <floor x="265.74" y="284.315" width="9" height="6" rotation="-0.17016757466725585"></floor> <floor x="271.895" y="282.935" width="9" height="6" rotation="-0.2663434735426984"></floor> <floor x="277.29499999999996" y="281.165" width="9" height="6" rotation="-0.3818714922992451"></floor> <floor x="283.01" y="278.575" width="9" height="6" rotation="-0.47509559069636126"></floor> <floor x="288.085" y="275.53499999999997" width="9" height="6" rotation="-0.5818808557175301"></floor> <floor x="293.35" y="271.54" width="9" height="6" rotation="-0.699242750235271"></floor> <floor x="298.425" y="266.625" width="9" height="6" rotation="-0.8427811267071015"></floor> <floor x="302.435" y="261.3" width="9" height="6" rotation="-0.9977787984252032"></floor> <floor x="305.225" y="255.885" width="9" height="6" rotation="-1.1748520468976147"></floor> <floor x="307.125" y="249.935" width="9" height="6" rotation="-1.3247453302907948"></floor> <floor x="307.835" y="244.73499999999999" width="9" height="6" rotation="-1.4926568630605637"></floor> <floor x="248.01" y="285.085" width="9" height="6" rotation="0.06796646339153686"></floor> <floor x="241.48499999999999" y="284.225" width="9" height="6" rotation="0.18719730901713472"></floor> <floor x="235.26999999999998" y="282.765" width="9" height="6" rotation="0.275629438382131"></floor> <floor x="229.675" y="280.86" width="9" height="6" rotation="0.3692139811427647"></floor> <floor x="224.00500000000002" y="278.15" width="9" height="6" rotation="0.47703966547705134"></floor> <floor x="217.89499999999998" y="274.34000000000003" width="9" height="6" rotation="0.6288802635734486"></floor> <floor x="214.08499999999998" y="271.14" width="9" height="6" rotation="0.7541055051607"></floor> <floor x="64.255" y="186.87" width="12.690000000000001" height="101" rotation="0"></floor> <floor x="338.355" y="189.405" width="12.690000000000001" height="101" rotation="0"></floor> <floor x="353.135" y="247.675" width="96.53" height="17.56" rotation="0"></floor> <floor x="160.09" y="285.275" width="9" height="6" rotation="0"></floor> <floor x="165.305" y="285.085" width="9" height="6" rotation="-0.0830070997243525"></floor> <floor x="171.74" y="284.315" width="9" height="6" rotation="-0.17016757466725585"></floor> <floor x="177.895" y="282.935" width="9" height="6" rotation="-0.2663434735426984"></floor> <floor x="183.29500000000002" y="281.165" width="9" height="6" rotation="-0.3818714922992451"></floor> <floor x="189.01" y="278.575" width="9" height="6" rotation="-0.47509559069636126"></floor> <floor x="194.08499999999998" y="275.53499999999997" width="9" height="6" rotation="-0.5818808557175301"></floor> <floor x="199.35" y="271.54" width="9" height="6" rotation="-0.699242750235271"></floor> <floor x="210.61999999999998" y="266.61" width="3.53" height="2.83" rotation="0.34413842830780517"></floor> <floor x="154.01" y="285.085" width="9" height="6" rotation="0.06796646339153686"></floor> <floor x="147.48499999999999" y="284.225" width="9" height="6" rotation="0.18719730901713472"></floor> <floor x="141.27" y="282.765" width="9" height="6" rotation="0.275629438382131"></floor> <floor x="135.675" y="280.86" width="9" height="6" rotation="0.3692139811427647"></floor> <floor x="130.005" y="278.15" width="9" height="6" rotation="0.47703966547705134"></floor> <floor x="123.89500000000001" y="274.34000000000003" width="9" height="6" rotation="0.6288802635734486"></floor> <floor x="118.38499999999999" y="269.775" width="9" height="6" rotation="0.7541055051607"></floor> <floor x="113.53" y="264.4" width="9" height="6" rotation="0.9110305683628696"></floor> <floor x="109.975" y="258.86" width="9" height="6" rotation="1.0755750308525185"></floor> <floor x="107.63499999999999" y="253.23499999999999" width="9" height="6" rotation="1.2233194175806157"></floor> <floor x="106.41" y="248.08499999999998" width="9" height="6" rotation="1.3837047964322264"></floor> <floor x="105.875" y="242.45999999999998" width="9" height="6" rotation="1.5042281630190728"></floor> <floor x="60.489999999999995" y="244.9" width="96.53" height="17.56" rotation="0"></floor> <floor x="203.03" y="266.815" width="3.53" height="2.83" rotation="-0.4699606564446741"></floor> <floor x="206.69" y="267.71500000000003" width="5.46" height="6" rotation="0"></floor> <entity x="300.71999999999997" y="228.5" width="3" height="3" type="coin"></entity> <entity x="300.46999999999997" y="211.75" width="3" height="3" type="coin"></entity> <entity x="300.46999999999997" y="196.5" width="3" height="3" type="coin"></entity> <entity x="300.46999999999997" y="181.5" width="3" height="3" type="coin"></entity> <entity x="300.46999999999997" y="166.75" width="3" height="3" type="snow"></entity> <entity x="111.22" y="223.25" width="3" height="3" type="coin"></entity> <entity x="110.97" y="206.5" width="3" height="3" type="coin"></entity> <entity x="110.97" y="191.25" width="3" height="3" type="coin"></entity> <entity x="110.97" y="176.25" width="3" height="3" type="coin"></entity> <entity x="110.97" y="161.5" width="3" height="3" type="snow"></entity> <entity x="221.115" y="239.5" width="3" height="3" type="coin"></entity> <entity x="188.865" y="239" width="3" height="3" type="live"></entity> <start x="206.58499999999998" y="256.71"></start></root>"; public static var Cost:int = 500; } }//package src.levels
Section 154
//Level (src.levels.Level) package src.levels { public class Level { public var RightEnd:int;// = 850 public var Locked:Boolean;// = false public var Completed:Boolean;// = false public var Cost:int;// = 0 public var Title:String;// = "" public var LeftEnd:int;// = 50 public var SourceXML:String;// = "" public function Level(){ SourceXML = ""; Cost = 0; Completed = false; Locked = false; Title = ""; LeftEnd = 50; RightEnd = 850; super(); } } }//package src.levels
Section 155
//level_1 (src.levels.level_1) package src.levels { public class level_1 { public static var SourceXML:String = "<root> <floor x="473.1" y="-50" width="10.58" height="43.13" rotation="0"></floor> <floor x="832" y="287.37" width="101.05" height="1" rotation="0"></floor> <floor x="932.9950000000001" y="287.37" width="101.05" height="1" rotation="0"></floor> <floor x="634.38" y="287.605" width="8.61" height="1.5" rotation="0.05294731206670226"></floor> <floor x="631.755" y="287.18" width="8.61" height="1.5" rotation="0.14548943378833487"></floor> <floor x="629.605" y="286.53000000000003" width="8.61" height="1.5" rotation="0.2359616371512511"></floor> <floor x="627.505" y="285.68" width="8.61" height="1.5" rotation="0.3358876163249498"></floor> <floor x="625.105" y="284.28000000000003" width="8.61" height="1.5" rotation="0.4757117344043803"></floor> <floor x="622.855" y="282.73" width="8.61" height="1.5" rotation="0.5973046608227033"></floor> <floor x="620.855" y="280.88" width="8.61" height="1.5" rotation="0.7199256227756606"></floor> <floor x="618.605" y="278.53000000000003" width="8.61" height="1.5" rotation="0.818780933429311"></floor> <floor x="616.345" y="275.43" width="8.61" height="1.5" rotation="0.9472720683565392"></floor> <floor x="556.605" y="287.605" width="8.61" height="1.5" rotation="-0.05294731206670226"></floor> <floor x="559.23" y="287.18" width="8.61" height="1.5" rotation="-0.14548943378833487"></floor> <floor x="561.38" y="286.53000000000003" width="8.61" height="1.5" rotation="-0.2359616371512511"></floor> <floor x="563.48" y="285.68" width="8.61" height="1.5" rotation="-0.3358876163249498"></floor> <floor x="565.88" y="284.28000000000003" width="8.61" height="1.5" rotation="-0.4757117344043803"></floor> <floor x="568.13" y="282.73" width="8.61" height="1.5" rotation="-0.5973046608227033"></floor> <floor x="570.13" y="280.88" width="8.61" height="1.5" rotation="-0.7199256227756606"></floor> <floor x="572.38" y="278.53000000000003" width="8.61" height="1.5" rotation="-0.818780933429311"></floor> <floor x="574.645" y="275.43" width="8.61" height="1.5" rotation="-0.9472720683565392"></floor> <floor x="434.59" y="269.555" width="8.61" height="1.5" rotation="1.2959188446320782"></floor> <floor x="454.925" y="287.58000000000004" width="8.61" height="1.5" rotation="0.05294731206670226"></floor> <floor x="452.3" y="287.15500000000003" width="8.61" height="1.5" rotation="0.14548943378833487"></floor> <floor x="450.15" y="286.505" width="8.61" height="1.5" rotation="0.2359616371512511"></floor> <floor x="448.05" y="285.65500000000003" width="8.61" height="1.5" rotation="0.3358876163249498"></floor> <floor x="445.65" y="284.255" width="8.61" height="1.5" rotation="0.4757117344043803"></floor> <floor x="443.4" y="282.70500000000004" width="8.61" height="1.5" rotation="0.5973046608227033"></floor> <floor x="441.4" y="280.855" width="8.61" height="1.5" rotation="0.7199256227756606"></floor> <floor x="439.15" y="278.505" width="8.61" height="1.5" rotation="0.818780933429311"></floor> <floor x="436.89" y="275.40500000000003" width="8.61" height="1.5" rotation="0.9472720683565392"></floor> <floor x="435.93999999999994" y="273.505" width="8.61" height="1.5" rotation="1.0590272565610424"></floor> <floor x="434.985" y="271.20500000000004" width="8.61" height="1.5" rotation="1.162794130633873"></floor> <floor x="418.59" y="269.555" width="8.61" height="1.5" rotation="-1.2959188446320782"></floor> <floor x="666.12" y="287.46999999999997" width="101.07000000000001" height="1" rotation="0"></floor> <floor x="398.25" y="287.58000000000004" width="8.61" height="1.5" rotation="-0.05294731206670226"></floor> <floor x="400.875" y="287.15500000000003" width="8.61" height="1.5" rotation="-0.14548943378833487"></floor> <floor x="403.025" y="286.505" width="8.61" height="1.5" rotation="-0.2359616371512511"></floor> <floor x="405.125" y="285.65500000000003" width="8.61" height="1.5" rotation="-0.3358876163249498"></floor> <floor x="407.525" y="284.255" width="8.61" height="1.5" rotation="-0.4757117344043803"></floor> <floor x="409.775" y="282.70500000000004" width="8.61" height="1.5" rotation="-0.5973046608227033"></floor> <floor x="411.775" y="280.855" width="8.61" height="1.5" rotation="-0.7199256227756606"></floor> <floor x="414.025" y="278.505" width="8.61" height="1.5" rotation="-0.818780933429311"></floor> <floor x="416.28999999999996" y="275.40500000000003" width="8.61" height="1.5" rotation="-0.9472720683565392"></floor> <floor x="417.235" y="273.505" width="8.61" height="1.5" rotation="-1.0590272565610424"></floor> <floor x="418.18999999999994" y="271.20500000000004" width="8.61" height="1.5" rotation="-1.162794130633873"></floor> <floor x="426.575" y="268.03000000000003" width="14.62" height="6" rotation="0"></floor> <floor x="595.5649999999999" y="273.73" width="37.6" height="4.4" rotation="0"></floor> <floor x="347.485" y="287.37" width="101.08" height="1" rotation="0"></floor> <floor x="789.575" y="289.19" width="101.03999999999999" height="1" rotation="0.3761886146528022"></floor> <floor x="695.9399999999999" y="289.15500000000003" width="101.05" height="1" rotation="-0.3761886146528022"></floor> <floor x="297.075" y="285.69" width="101.05" height="1" rotation="0.3761886146528022"></floor> <floor x="203.45" y="285.65500000000003" width="101.06" height="1" rotation="-0.3761886146528022"></floor> <floor x="504.975" y="287.495" width="101.08" height="1" rotation="0"></floor> <floor x="50.985" y="287.37" width="101.06" height="1" rotation="0"></floor> <floor x="151.98" y="287.37" width="101.06" height="1" rotation="0"></floor> <entity x="309" y="255.99" width="3" height="3" type="coin"></entity> <entity x="422.895" y="235.19" width="3" height="3" type="coin"></entity> <entity x="430.91" y="235.19" width="3" height="3" type="coin"></entity> <entity x="426.51000000000005" y="220.39000000000001" width="3" height="3" type="snow"></entity> <entity x="426.31000000000006" y="208.19" width="3" height="3" type="live"></entity> <entity x="596.525" y="232.59" width="3" height="3" type="snow"></entity> <entity x="584.9449999999999" y="245.79000000000002" width="3" height="3" type="coin"></entity> <entity x="607.545" y="245.79000000000002" width="3" height="3" type="coin"></entity> <start x="366.305" y="271.64"></start></root>"; public static var Cost:int = 200; } }//package src.levels
Section 156
//level_2 (src.levels.level_2) package src.levels { public class level_2 { public static var SourceXML:String = "<root> <floor x="473.1" y="-50" width="10.58" height="43.13" rotation="0"></floor> <floor x="930.9950000000001" y="288.37" width="101.06" height="1" rotation="0"></floor> <floor x="632.38" y="288.605" width="8.61" height="1.5" rotation="0.05294731206670226"></floor> <floor x="629.755" y="288.18" width="8.61" height="1.5" rotation="0.14548943378833487"></floor> <floor x="627.605" y="287.53000000000003" width="8.61" height="1.5" rotation="0.2359616371512511"></floor> <floor x="625.505" y="286.68" width="8.61" height="1.5" rotation="0.3358876163249498"></floor> <floor x="623.105" y="285.28000000000003" width="8.61" height="1.5" rotation="0.4757117344043803"></floor> <floor x="620.855" y="283.73" width="8.61" height="1.5" rotation="0.5973046608227033"></floor> <floor x="618.855" y="281.88" width="8.61" height="1.5" rotation="0.7199256227756606"></floor> <floor x="616.605" y="279.53000000000003" width="8.61" height="1.5" rotation="0.818780933429311"></floor> <floor x="614.345" y="276.43" width="8.61" height="1.5" rotation="0.9472720683565392"></floor> <floor x="554.605" y="288.605" width="8.61" height="1.5" rotation="-0.05294731206670226"></floor> <floor x="557.23" y="288.18" width="8.61" height="1.5" rotation="-0.14548943378833487"></floor> <floor x="559.38" y="287.53000000000003" width="8.61" height="1.5" rotation="-0.2359616371512511"></floor> <floor x="561.48" y="286.68" width="8.61" height="1.5" rotation="-0.3358876163249498"></floor> <floor x="563.88" y="285.28000000000003" width="8.61" height="1.5" rotation="-0.4757117344043803"></floor> <floor x="566.13" y="283.73" width="8.61" height="1.5" rotation="-0.5973046608227033"></floor> <floor x="568.13" y="281.88" width="8.61" height="1.5" rotation="-0.7199256227756606"></floor> <floor x="570.38" y="279.53000000000003" width="8.61" height="1.5" rotation="-0.818780933429311"></floor> <floor x="572.645" y="276.43" width="8.61" height="1.5" rotation="-0.9472720683565392"></floor> <floor x="794.0899999999999" y="271.055" width="8.61" height="1.5" rotation="-1.2959188446320782"></floor> <floor x="773.75" y="289.08000000000004" width="8.61" height="1.5" rotation="-0.05294731206670226"></floor> <floor x="776.375" y="288.65500000000003" width="8.61" height="1.5" rotation="-0.14548943378833487"></floor> <floor x="778.525" y="288.005" width="8.61" height="1.5" rotation="-0.2359616371512511"></floor> <floor x="780.625" y="287.15500000000003" width="8.61" height="1.5" rotation="-0.3358876163249498"></floor> <floor x="783.025" y="285.755" width="8.61" height="1.5" rotation="-0.4757117344043803"></floor> <floor x="785.275" y="284.20500000000004" width="8.61" height="1.5" rotation="-0.5973046608227033"></floor> <floor x="787.275" y="282.355" width="8.61" height="1.5" rotation="-0.7199256227756606"></floor> <floor x="789.525" y="280.005" width="8.61" height="1.5" rotation="-0.818780933429311"></floor> <floor x="791.79" y="276.90500000000003" width="8.61" height="1.5" rotation="-0.9472720683565392"></floor> <floor x="792.74" y="275.005" width="8.61" height="1.5" rotation="-1.0590272565610424"></floor> <floor x="793.6899999999999" y="272.70500000000004" width="8.61" height="1.5" rotation="-1.162794130633873"></floor> <floor x="810.0899999999999" y="271.055" width="8.61" height="1.5" rotation="1.2959188446320782"></floor> <floor x="830.425" y="289.08000000000004" width="8.61" height="1.5" rotation="0.05294731206670226"></floor> <floor x="827.8" y="288.65500000000003" width="8.61" height="1.5" rotation="0.14548943378833487"></floor> <floor x="825.65" y="288.005" width="8.61" height="1.5" rotation="0.2359616371512511"></floor> <floor x="823.55" y="287.15500000000003" width="8.61" height="1.5" rotation="0.3358876163249498"></floor> <floor x="821.15" y="285.755" width="8.61" height="1.5" rotation="0.4757117344043803"></floor> <floor x="818.9" y="284.20500000000004" width="8.61" height="1.5" rotation="0.5973046608227033"></floor> <floor x="816.9" y="282.355" width="8.61" height="1.5" rotation="0.7199256227756606"></floor> <floor x="814.65" y="280.005" width="8.61" height="1.5" rotation="0.818780933429311"></floor> <floor x="812.39" y="276.90500000000003" width="8.61" height="1.5" rotation="0.9472720683565392"></floor> <floor x="811.4399999999999" y="275.005" width="8.61" height="1.5" rotation="1.0590272565610424"></floor> <floor x="810.49" y="272.70500000000004" width="8.61" height="1.5" rotation="1.162794130633873"></floor> <floor x="802.105" y="269.53000000000003" width="14.62" height="6" rotation="0"></floor> <floor x="593.5649999999999" y="274.73" width="37.6" height="4.4" rotation="0"></floor> <floor x="559.175" y="291.685" width="101.06" height="1" rotation="0.3761886146528022"></floor> <floor x="805.8149999999999" y="288.94" width="101.09" height="1" rotation="0"></floor> <floor x="48.985" y="288.37" width="101.07000000000001" height="1" rotation="0"></floor> <floor x="498.06000000000006" y="273.145" width="28.65" height="1" rotation="0"></floor> <floor x="149.98" y="288.37" width="101.08" height="1" rotation="0"></floor> <floor x="290.175" y="295.685" width="101.07000000000001" height="1" rotation="0.3761886146528022"></floor> <floor x="167.95" y="295.65500000000003" width="101.08" height="1" rotation="-0.3761886146528022"></floor> <floor x="229.06" y="277.145" width="28.65" height="1" rotation="0"></floor> <floor x="399.59000000000003" y="270.555" width="8.61" height="1.5" rotation="1.2959188446320782"></floor> <floor x="419.925" y="288.58000000000004" width="8.61" height="1.5" rotation="0.05294731206670226"></floor> <floor x="417.3" y="288.15500000000003" width="8.61" height="1.5" rotation="0.14548943378833487"></floor> <floor x="415.15" y="287.505" width="8.61" height="1.5" rotation="0.2359616371512511"></floor> <floor x="413.05" y="286.65500000000003" width="8.61" height="1.5" rotation="0.3358876163249498"></floor> <floor x="410.65" y="285.255" width="8.61" height="1.5" rotation="0.4757117344043803"></floor> <floor x="408.4" y="283.70500000000004" width="8.61" height="1.5" rotation="0.5973046608227033"></floor> <floor x="406.4" y="281.855" width="8.61" height="1.5" rotation="0.7199256227756606"></floor> <floor x="404.15" y="279.505" width="8.61" height="1.5" rotation="0.818780933429311"></floor> <floor x="401.89" y="276.40500000000003" width="8.61" height="1.5" rotation="0.9472720683565392"></floor> <floor x="400.94" y="274.505" width="8.61" height="1.5" rotation="1.0590272565610424"></floor> <floor x="399.985" y="272.20500000000004" width="8.61" height="1.5" rotation="1.162794130633873"></floor> <floor x="383.59000000000003" y="270.555" width="8.61" height="1.5" rotation="-1.2959188446320782"></floor> <floor x="363.25" y="288.58000000000004" width="8.61" height="1.5" rotation="-0.05294731206670226"></floor> <floor x="365.875" y="288.15500000000003" width="8.61" height="1.5" rotation="-0.14548943378833487"></floor> <floor x="368.025" y="287.505" width="8.61" height="1.5" rotation="-0.2359616371512511"></floor> <floor x="370.125" y="286.65500000000003" width="8.61" height="1.5" rotation="-0.3358876163249498"></floor> <floor x="372.525" y="285.255" width="8.61" height="1.5" rotation="-0.4757117344043803"></floor> <floor x="374.775" y="283.70500000000004" width="8.61" height="1.5" rotation="-0.5973046608227033"></floor> <floor x="376.775" y="281.855" width="8.61" height="1.5" rotation="-0.7199256227756606"></floor> <floor x="379.025" y="279.505" width="8.61" height="1.5" rotation="-0.818780933429311"></floor> <floor x="381.29" y="276.40500000000003" width="8.61" height="1.5" rotation="-0.9472720683565392"></floor> <floor x="382.235" y="274.505" width="8.61" height="1.5" rotation="-1.0590272565610424"></floor> <floor x="383.19" y="272.20500000000004" width="8.61" height="1.5" rotation="-1.162794130633873"></floor> <floor x="391.575" y="269.03000000000003" width="14.62" height="6" rotation="0"></floor> <floor x="312.485" y="288.37" width="101.1" height="1" rotation="0"></floor> <floor x="436.945" y="291.65500000000003" width="101.08" height="1" rotation="-0.3761886146528022"></floor> <floor x="428.975" y="288.495" width="101.1" height="1" rotation="0"></floor> <floor x="874.0899999999999" y="271.055" width="8.61" height="1.5" rotation="-1.2959188446320782"></floor> <floor x="853.75" y="289.08000000000004" width="8.61" height="1.5" rotation="-0.05294731206670226"></floor> <floor x="856.375" y="288.65500000000003" width="8.61" height="1.5" rotation="-0.14548943378833487"></floor> <floor x="858.525" y="288.005" width="8.61" height="1.5" rotation="-0.2359616371512511"></floor> <floor x="860.625" y="287.15500000000003" width="8.61" height="1.5" rotation="-0.3358876163249498"></floor> <floor x="863.025" y="285.755" width="8.61" height="1.5" rotation="-0.4757117344043803"></floor> <floor x="865.275" y="284.20500000000004" width="8.61" height="1.5" rotation="-0.5973046608227033"></floor> <floor x="867.275" y="282.355" width="8.61" height="1.5" rotation="-0.7199256227756606"></floor> <floor x="869.525" y="280.005" width="8.61" height="1.5" rotation="-0.818780933429311"></floor> <floor x="871.79" y="276.90500000000003" width="8.61" height="1.5" rotation="-0.9472720683565392"></floor> <floor x="872.74" y="275.005" width="8.61" height="1.5" rotation="-1.0590272565610424"></floor> <floor x="873.6899999999999" y="272.70500000000004" width="8.61" height="1.5" rotation="-1.162794130633873"></floor> <floor x="890.0899999999999" y="271.055" width="8.61" height="1.5" rotation="1.2959188446320782"></floor> <floor x="910.425" y="289.08000000000004" width="8.61" height="1.5" rotation="0.05294731206670226"></floor> <floor x="907.8" y="288.65500000000003" width="8.61" height="1.5" rotation="0.14548943378833487"></floor> <floor x="905.65" y="288.005" width="8.61" height="1.5" rotation="0.2359616371512511"></floor> <floor x="903.55" y="287.15500000000003" width="8.61" height="1.5" rotation="0.3358876163249498"></floor> <floor x="901.15" y="285.755" width="8.61" height="1.5" rotation="0.4757117344043803"></floor> <floor x="898.9" y="284.20500000000004" width="8.61" height="1.5" rotation="0.5973046608227033"></floor> <floor x="896.9" y="282.355" width="8.61" height="1.5" rotation="0.7199256227756606"></floor> <floor x="894.65" y="280.005" width="8.61" height="1.5" rotation="0.818780933429311"></floor> <floor x="892.39" y="276.90500000000003" width="8.61" height="1.5" rotation="0.9472720683565392"></floor> <floor x="891.4399999999999" y="275.005" width="8.61" height="1.5" rotation="1.0590272565610424"></floor> <floor x="890.49" y="272.70500000000004" width="8.61" height="1.5" rotation="1.162794130633873"></floor> <floor x="882.1049999999999" y="269.53000000000003" width="14.62" height="6" rotation="0"></floor> <floor x="1030.4" y="288.365" width="101.1" height="1" rotation="0"></floor> <floor x="791" y="288.87" width="101.07000000000001" height="1" rotation="0"></floor> <floor x="664.12" y="288.46999999999997" width="101.09" height="1" rotation="0"></floor> <floor x="748.575" y="290.69" width="101.06" height="1" rotation="0.3761886146528022"></floor> <floor x="654.9399999999999" y="290.65500000000003" width="101.07000000000001" height="1" rotation="-0.3761886146528022"></floor> <entity x="387.93" y="251.885" width="3" height="3" type="coin"></entity> <entity x="395.43" y="240.885" width="3" height="3" type="coin"></entity> <entity x="390.18" y="231.885" width="3" height="3" type="snow"></entity> <entity x="393.43" y="223.635" width="3" height="3" type="live"></entity> <entity x="693.0649999999999" y="261.135" width="3" height="3" type="coin"></entity> <entity x="713.3149999999999" y="260.635" width="3" height="3" type="coin"></entity> <entity x="802.3149999999999" y="240.315" width="3" height="3" type="coin"></entity> <entity x="802.0649999999999" y="228.815" width="3" height="3" type="snow"></entity> <entity x="583.8149999999999" y="250.635" width="3" height="3" type="coin"></entity> <entity x="604.0649999999999" y="250.135" width="3" height="3" type="coin"></entity> <entity x="593.8149999999999" y="236.135" width="3" height="3" type="coin"></entity> <entity x="593.5649999999999" y="224.635" width="3" height="3" type="snow"></entity> <entity x="792.3149999999999" y="252.135" width="3" height="3" type="coin"></entity> <entity x="812.5649999999999" y="251.635" width="3" height="3" type="coin"></entity> <entity x="881.975" y="226.5" width="3" height="3" type="live"></entity> <start x="141.005" y="282.74"></start></root>"; public static var Cost:int = 200; } }//package src.levels
Section 157
//level_3 (src.levels.level_3) package src.levels { public class level_3 { public static var SourceXML:String = "<root> <floor x="870.6800000000001" y="246.775" width="30.240000000000002" height="5.2" rotation="0"></floor> <floor x="473.1" y="-50" width="10.580000000000002" height="43.13" rotation="0"></floor> <floor x="809.8" y="292.175" width="9" height="6" rotation="-0.06796646339153686"></floor> <floor x="816.325" y="291.32000000000005" width="9" height="6" rotation="-0.18719730901713472"></floor> <floor x="822.5350000000001" y="289.86" width="9" height="6" rotation="-0.275629438382131"></floor> <floor x="828.1300000000001" y="287.95" width="9" height="6" rotation="-0.3692139811427647"></floor> <floor x="833.8050000000001" y="285.245" width="9" height="6" rotation="-0.47703966547705134"></floor> <floor x="839.915" y="281.43" width="9" height="6" rotation="-0.6288802635734486"></floor> <floor x="845.4300000000001" y="276.86" width="9" height="6" rotation="-0.7541055051607"></floor> <floor x="850.2800000000001" y="271.485" width="9" height="6" rotation="-0.9110305683628696"></floor> <floor x="853.835" y="265.95500000000004" width="9" height="6" rotation="-1.0755750308525185"></floor> <floor x="856.1800000000001" y="260.33000000000004" width="9" height="6" rotation="-1.2233194175806157"></floor> <floor x="857.4050000000001" y="255.18" width="9" height="6" rotation="-1.3837047964322264"></floor> <floor x="857.9350000000001" y="249.53000000000003" width="9" height="6" rotation="-1.5042281630190728"></floor> <floor x="803.715" y="292.37" width="9" height="6" rotation="0"></floor> <floor x="952.0800000000002" y="256.975" width="101.04" height="1" rotation="0"></floor> <floor x="894.8800000000001" y="251.375" width="23.04" height="2" rotation="0.5819051181398855"></floor> <floor x="653.8050000000001" y="288.61" width="8.610000000000001" height="1.5" rotation="-0.23599223010713297"></floor> <floor x="736.63" y="246.68" width="30.240000000000002" height="5.2" rotation="0"></floor> <floor x="669.4950000000001" y="270.675" width="7.110000000000001" height="1.32" rotation="-1.3055338576224806"></floor> <floor x="656.135" y="287.62" width="8.610000000000001" height="1.5" rotation="-0.3469336831764292"></floor> <floor x="657.71" y="286.62" width="8.610000000000001" height="1.5" rotation="-0.5080249447424414"></floor> <floor x="661.51" y="283.95" width="8.610000000000001" height="1.5" rotation="-0.6569144665595785"></floor> <floor x="664.345" y="281.075" width="8.610000000000001" height="1.5" rotation="-0.8067852762491778"></floor> <floor x="666.5600000000001" y="278.095" width="8.610000000000001" height="1.5" rotation="-0.9723774333163594"></floor> <floor x="668.595" y="274.22" width="8.610000000000001" height="1.5" rotation="-1.1217175944851414"></floor> <floor x="650.195" y="289.44500000000005" width="8.610000000000001" height="1.5" rotation="-0.13578565141822713"></floor> <floor x="157.88000000000002" y="288.78000000000003" width="8.610000000000001" height="1.5" rotation="-0.23599223010713297"></floor> <floor x="622.0600000000001" y="271.77000000000004" width="8.610000000000001" height="1.5" rotation="1.2959188446320782"></floor> <floor x="173.57" y="270.855" width="7.110000000000001" height="1.32" rotation="-1.3055338576224806"></floor> <floor x="160.21" y="287.8" width="8.610000000000001" height="1.5" rotation="-0.3469336831764292"></floor> <floor x="161.78500000000003" y="286.8" width="8.610000000000001" height="1.5" rotation="-0.5080249447424414"></floor> <floor x="165.59" y="284.13" width="8.610000000000001" height="1.5" rotation="-0.6569144665595785"></floor> <floor x="168.42000000000002" y="281.255" width="8.610000000000001" height="1.5" rotation="-0.8067852762491778"></floor> <floor x="170.63500000000002" y="278.275" width="8.610000000000001" height="1.5" rotation="-0.9723774333163594"></floor> <floor x="172.67000000000002" y="274.4" width="8.610000000000001" height="1.5" rotation="-1.1217175944851414"></floor> <floor x="1.29" y="289.86" width="101.06" height="1" rotation="0"></floor> <floor x="154.27" y="289.625" width="8.610000000000001" height="1.5" rotation="-0.13578565141822713"></floor> <floor x="642.385" y="289.795" width="8.610000000000001" height="1.5" rotation="0.05294731206670226"></floor> <floor x="639.76" y="289.37" width="8.610000000000001" height="1.5" rotation="0.14548943378833487"></floor> <floor x="637.61" y="288.72" width="8.610000000000001" height="1.5" rotation="0.2359616371512511"></floor> <floor x="635.51" y="287.87" width="8.610000000000001" height="1.5" rotation="0.3358876163249498"></floor> <floor x="633.11" y="286.47" width="8.610000000000001" height="1.5" rotation="0.4757117344043803"></floor> <floor x="630.86" y="284.92" width="8.610000000000001" height="1.5" rotation="0.5973046608227033"></floor> <floor x="628.86" y="283.07000000000005" width="8.610000000000001" height="1.5" rotation="0.7198891965892961"></floor> <floor x="626.61" y="280.72" width="8.610000000000001" height="1.5" rotation="0.818780933429311"></floor> <floor x="624.36" y="277.62" width="8.610000000000001" height="1.5" rotation="0.9472720683565392"></floor> <floor x="623.4100000000001" y="275.72" width="8.610000000000001" height="1.5" rotation="1.0590272565610424"></floor> <floor x="622.46" y="273.42" width="8.610000000000001" height="1.5" rotation="1.162794130633873"></floor> <floor x="797.51" y="292.08000000000004" width="9" height="6" rotation="0.06796646339153686"></floor> <floor x="790.985" y="291.225" width="9" height="6" rotation="0.18719730901713472"></floor> <floor x="784.7650000000001" y="289.76000000000005" width="9" height="6" rotation="0.275629438382131"></floor> <floor x="779.1700000000001" y="287.855" width="9" height="6" rotation="0.3692139811427647"></floor> <floor x="773.4950000000001" y="285.15" width="9" height="6" rotation="0.47703966547705134"></floor> <floor x="767.385" y="281.33500000000004" width="9" height="6" rotation="0.6288802635734486"></floor> <floor x="761.88" y="276.775" width="9" height="6" rotation="0.7541055051607"></floor> <floor x="757.0200000000001" y="271.4" width="9" height="6" rotation="0.9110305683628696"></floor> <floor x="753.465" y="265.86" width="9" height="6" rotation="1.0755750308525185"></floor> <floor x="751.13" y="260.235" width="9" height="6" rotation="1.2233194175806157"></floor> <floor x="749.905" y="255.08500000000004" width="9" height="6" rotation="1.3837047964322264"></floor> <floor x="749.365" y="249.45" width="9" height="6" rotation="1.5042281630190728"></floor> <floor x="803.585" y="292.275" width="9" height="6" rotation="0"></floor> <floor x="312.04" y="289.90500000000003" width="101.04" height="1" rotation="0"></floor> <floor x="429.175" y="262.02000000000004" width="23.04" height="2" rotation="0.5819051181398855"></floor> <floor x="244.70999999999998" y="272.32000000000005" width="15.030000000000001" height="11.67" rotation="0"></floor> <floor x="181.36" y="272.65500000000003" width="15.030000000000001" height="11.67" rotation="0"></floor> <floor x="484.7" y="279.275" width="36.980000000000004" height="2.0300000000000002" rotation="0.6752643996121094"></floor> <floor x="771.23" y="289.95500000000004" width="101.04" height="1" rotation="0"></floor> <floor x="266.055" y="278.98" width="36.980000000000004" height="2.0300000000000002" rotation="0.6752643996121094"></floor> <floor x="411.025" y="261.97" width="23.04" height="2" rotation="-0.5819051181398855"></floor> <floor x="688.445" y="268.32000000000005" width="36.980000000000004" height="2.0300000000000002" rotation="0"></floor> <floor x="420.26000000000005" y="267.345" width="101.04" height="1" rotation="0"></floor> <floor x="707.7" y="256.675" width="36.980000000000004" height="2.0300000000000002" rotation="-0.6752643996121094"></floor> <floor x="548.0600000000001" y="289.94500000000005" width="101.04" height="1" rotation="0"></floor> <floor x="605.7" y="279.575" width="36.980000000000004" height="2.0300000000000002" rotation="-0.6752643996121094"></floor> <floor x="670.23" y="289.95500000000004" width="101.04" height="1" rotation="0"></floor> <floor x="728.8100000000001" y="277.13" width="14.820000000000002" height="65.74000000000001" rotation="0"></floor> <floor x="1053.0800000000002" y="256.975" width="101.04" height="1" rotation="0"></floor> <floor x="102.29" y="289.86" width="101.06" height="1" rotation="0"></floor> <floor x="221.055" y="288.36" width="8.610000000000001" height="1.5" rotation="-0.23599223010713297"></floor> <floor x="236.74500000000003" y="270.43" width="7.110000000000001" height="1.32" rotation="-1.3055338576224806"></floor> <floor x="223.385" y="287.375" width="8.610000000000001" height="1.5" rotation="-0.3469336831764292"></floor> <floor x="224.95999999999998" y="286.375" width="8.610000000000001" height="1.5" rotation="-0.5080249447424414"></floor> <floor x="228.76" y="283.70500000000004" width="8.610000000000001" height="1.5" rotation="-0.6569144665595785"></floor> <floor x="231.59500000000003" y="280.83000000000004" width="8.610000000000001" height="1.5" rotation="-0.8067852762491778"></floor> <floor x="233.81" y="277.85" width="8.610000000000001" height="1.5" rotation="-0.9723774333163594"></floor> <floor x="235.84500000000003" y="273.975" width="8.610000000000001" height="1.5" rotation="-1.1217175944851414"></floor> <floor x="217.44500000000002" y="289.2" width="8.610000000000001" height="1.5" rotation="-0.13578565141822713"></floor> <floor x="189.31" y="271.525" width="8.610000000000001" height="1.5" rotation="1.2959188446320782"></floor> <floor x="209.635" y="289.55" width="8.610000000000001" height="1.5" rotation="0.05294731206670226"></floor> <floor x="207.01" y="289.125" width="8.610000000000001" height="1.5" rotation="0.14548943378833487"></floor> <floor x="204.85999999999999" y="288.475" width="8.610000000000001" height="1.5" rotation="0.2359616371512511"></floor> <floor x="202.76000000000002" y="287.625" width="8.610000000000001" height="1.5" rotation="0.3358876163249498"></floor> <floor x="200.36" y="286.225" width="8.610000000000001" height="1.5" rotation="0.4757117344043803"></floor> <floor x="198.11" y="284.675" width="8.610000000000001" height="1.5" rotation="0.5973046608227033"></floor> <floor x="196.11" y="282.825" width="8.610000000000001" height="1.5" rotation="0.7199256227756606"></floor> <floor x="193.86" y="280.475" width="8.610000000000001" height="1.5" rotation="0.818780933429311"></floor> <floor x="191.61" y="277.375" width="8.610000000000001" height="1.5" rotation="0.9472720683565392"></floor> <floor x="190.66000000000003" y="275.475" width="8.610000000000001" height="1.5" rotation="1.0590272565610424"></floor> <floor x="189.71" y="273.175" width="8.610000000000001" height="1.5" rotation="1.162794130633873"></floor> <floor x="355.7" y="279.075" width="36.980000000000004" height="2.0300000000000002" rotation="-0.6752643996121094"></floor> <entity x="182.03500000000003" y="206.95999999999998" width="3" height="3" type="undefined"></entity> <entity x="729.5150000000001" y="234.95999999999998" width="3" height="3" type="undefined"></entity> <entity x="854.0550000000001" y="235.20999999999998" width="3" height="3" type="coin"></entity> <entity x="853.8050000000001" y="221.95999999999998" width="3" height="3" type="coin"></entity> <entity x="853.8050000000001" y="206.45999999999998" width="3" height="3" type="coin"></entity> <entity x="753.8050000000001" y="230.95999999999998" width="3" height="3" type="coin"></entity> <entity x="753.5550000000001" y="217.70999999999998" width="3" height="3" type="coin"></entity> <entity x="753.5550000000001" y="202.21" width="3" height="3" type="coin"></entity> <entity x="803.8050000000001" y="244.70999999999998" width="3" height="3" type="snow"></entity> <entity x="753.5550000000001" y="188.21" width="3" height="3" type="snow"></entity> <entity x="853.4399999999999" y="190.96" width="3" height="3" type="snow"></entity> <entity x="803.69" y="214.95999999999998" width="3" height="3" type="snow"></entity> <entity x="803.69" y="229.45999999999998" width="3" height="3" type="coin"></entity> <entity x="244.49500000000003" y="248.21000000000004" width="3" height="3" type="coin"></entity> <entity x="181.995" y="249.96000000000004" width="3" height="3" type="coin"></entity> <start x="308.3" y="280.92"></start></root>"; public static var Cost:int = 200; } }//package src.levels
Section 158
//level_4 (src.levels.level_4) package src.levels { public class level_4 { public static var SourceXML:String = "<root> <floor x="635.255" y="288.46" width="8.61" height="1.5" rotation="0.23599223010713297"></floor> <floor x="489.68" y="244.775" width="30.24" height="5.2" rotation="0"></floor> <floor x="619.5649999999999" y="270.525" width="7.109999999999999" height="1.3199999999999998" rotation="1.3055338576224806"></floor> <floor x="632.925" y="287.46999999999997" width="8.61" height="1.5" rotation="0.3469336831764292"></floor> <floor x="631.35" y="286.46999999999997" width="8.61" height="1.5" rotation="0.5080249447424414"></floor> <floor x="627.545" y="283.8" width="8.61" height="1.5" rotation="0.6569144665595785"></floor> <floor x="624.7149999999999" y="280.93" width="8.61" height="1.5" rotation="0.8067852762491778"></floor> <floor x="622.5" y="277.945" width="8.61" height="1.5" rotation="0.9723774333163594"></floor> <floor x="620.4649999999999" y="274.06" width="8.61" height="1.5" rotation="1.1217175944851414"></floor> <floor x="638.865" y="289.29499999999996" width="8.61" height="1.5" rotation="0.13578565141822713"></floor> <floor x="851.3" y="289.95" width="101.03999999999999" height="1" rotation="0"></floor> <floor x="473.1" y="-50" width="10.58" height="43.13" rotation="0"></floor> <floor x="698.4300000000001" y="288.885" width="8.61" height="1.5" rotation="0.23599223010713297"></floor> <floor x="667" y="271.61" width="8.61" height="1.5" rotation="-1.2959188446320782"></floor> <floor x="682.74" y="270.95" width="7.109999999999999" height="1.3199999999999998" rotation="1.3055338576224806"></floor> <floor x="696.1" y="287.895" width="8.61" height="1.5" rotation="0.3469336831764292"></floor> <floor x="694.525" y="286.895" width="8.61" height="1.5" rotation="0.5080249447424414"></floor> <floor x="690.72" y="284.225" width="8.61" height="1.5" rotation="0.6569144665595785"></floor> <floor x="687.89" y="281.355" width="8.61" height="1.5" rotation="0.8067852762491778"></floor> <floor x="685.675" y="278.37" width="8.61" height="1.5" rotation="0.9723774333163594"></floor> <floor x="683.64" y="274.485" width="8.61" height="1.5" rotation="1.1217175944851414"></floor> <floor x="754.02" y="289.96" width="101.06" height="1" rotation="0"></floor> <floor x="702.04" y="289.71999999999997" width="8.61" height="1.5" rotation="0.13578565141822713"></floor> <floor x="646.675" y="289.645" width="8.61" height="1.5" rotation="-0.05294731206670226"></floor> <floor x="649.3" y="289.21999999999997" width="8.61" height="1.5" rotation="-0.14548943378833487"></floor> <floor x="651.45" y="288.57" width="8.61" height="1.5" rotation="-0.2359616371512511"></floor> <floor x="653.55" y="287.71999999999997" width="8.61" height="1.5" rotation="-0.3358876163249498"></floor> <floor x="655.95" y="286.32" width="8.61" height="1.5" rotation="-0.4757117344043803"></floor> <floor x="658.2" y="284.77" width="8.61" height="1.5" rotation="-0.5973046608227033"></floor> <floor x="660.2" y="282.91999999999996" width="8.61" height="1.5" rotation="-0.7199256227756606"></floor> <floor x="662.45" y="280.57" width="8.61" height="1.5" rotation="-0.818780933429311"></floor> <floor x="664.7" y="277.46999999999997" width="8.61" height="1.5" rotation="-0.9472720683565392"></floor> <floor x="665.65" y="275.56" width="8.61" height="1.5" rotation="-1.0590272565610424"></floor> <floor x="666.6" y="273.26" width="8.61" height="1.5" rotation="-1.162794130633873"></floor> <floor x="428.8" y="290.175" width="9" height="6" rotation="-0.06796646339153686"></floor> <floor x="435.325" y="289.32" width="9" height="6" rotation="-0.18719730901713472"></floor> <floor x="441.53999999999996" y="287.86" width="9" height="6" rotation="-0.275629438382131"></floor> <floor x="447.13500000000005" y="285.95" width="9" height="6" rotation="-0.3692139811427647"></floor> <floor x="452.81000000000006" y="283.245" width="9" height="6" rotation="-0.47703966547705134"></floor> <floor x="458.91999999999996" y="279.43" width="9" height="6" rotation="-0.6288802635734486"></floor> <floor x="464.43" y="274.86" width="9" height="6" rotation="-0.7541055051607"></floor> <floor x="469.285" y="269.485" width="9" height="6" rotation="-0.9110305683628696"></floor> <floor x="472.84" y="263.95500000000004" width="9" height="6" rotation="-1.0755750308525185"></floor> <floor x="475.18" y="258.33000000000004" width="9" height="6" rotation="-1.2233194175806157"></floor> <floor x="476.4" y="253.18" width="9" height="6" rotation="-1.3837047964322264"></floor> <floor x="476.93999999999994" y="247.53000000000003" width="9" height="6" rotation="-1.5042281630190728"></floor> <floor x="422.71999999999997" y="290.37" width="9" height="6" rotation="0"></floor> <floor x="596.6800000000001" y="261.975" width="23.04" height="2" rotation="0.5819051181398855"></floor> <floor x="537.08" y="255.175" width="101.03999999999999" height="1" rotation="0"></floor> <floor x="513.88" y="249.375" width="23.04" height="2" rotation="0.5819051181398855"></floor> <floor x="611.6" y="272.40500000000003" width="15.030000000000001" height="11.67" rotation="0"></floor> <floor x="674.95" y="272.75" width="15.030000000000001" height="11.67" rotation="0"></floor> <floor x="210.055" y="288.36" width="8.61" height="1.5" rotation="-0.23599223010713297"></floor> <floor x="355.63" y="244.68" width="30.24" height="5.2" rotation="0"></floor> <floor x="225.74499999999998" y="270.43" width="7.109999999999999" height="1.3199999999999998" rotation="-1.3055338576224806"></floor> <floor x="212.385" y="287.375" width="8.61" height="1.5" rotation="-0.3469336831764292"></floor> <floor x="213.95999999999998" y="286.375" width="8.61" height="1.5" rotation="-0.5080249447424414"></floor> <floor x="217.76" y="283.70500000000004" width="8.61" height="1.5" rotation="-0.6569144665595785"></floor> <floor x="220.59499999999997" y="280.83000000000004" width="8.61" height="1.5" rotation="-0.8067852762491778"></floor> <floor x="222.81" y="277.85" width="8.61" height="1.5" rotation="-0.9723774333163594"></floor> <floor x="224.84499999999997" y="273.975" width="8.61" height="1.5" rotation="-1.1217175944851414"></floor> <floor x="206.445" y="289.2" width="8.61" height="1.5" rotation="-0.13578565141822713"></floor> <floor x="146.88" y="288.78000000000003" width="8.61" height="1.5" rotation="-0.23599223010713297"></floor> <floor x="178.31" y="271.525" width="8.61" height="1.5" rotation="1.2959188446320782"></floor> <floor x="162.565" y="270.855" width="7.109999999999999" height="1.3199999999999998" rotation="-1.3055338576224806"></floor> <floor x="149.20999999999998" y="287.8" width="8.61" height="1.5" rotation="-0.3469336831764292"></floor> <floor x="150.785" y="286.8" width="8.61" height="1.5" rotation="-0.5080249447424414"></floor> <floor x="154.59" y="284.13" width="8.61" height="1.5" rotation="-0.6569144665595785"></floor> <floor x="157.42000000000002" y="281.255" width="8.61" height="1.5" rotation="-0.8067852762491778"></floor> <floor x="159.635" y="278.275" width="8.61" height="1.5" rotation="-0.9723774333163594"></floor> <floor x="161.67000000000002" y="274.4" width="8.61" height="1.5" rotation="-1.1217175944851414"></floor> <floor x="91.28999999999999" y="289.86" width="101.06" height="1" rotation="0"></floor> <floor x="143.27" y="289.625" width="8.61" height="1.5" rotation="-0.13578565141822713"></floor> <floor x="198.635" y="289.55" width="8.61" height="1.5" rotation="0.05294731206670226"></floor> <floor x="196.01" y="289.125" width="8.61" height="1.5" rotation="0.14548943378833487"></floor> <floor x="193.85999999999999" y="288.475" width="8.61" height="1.5" rotation="0.2359616371512511"></floor> <floor x="191.76" y="287.625" width="8.61" height="1.5" rotation="0.3358876163249498"></floor> <floor x="189.35999999999999" y="286.225" width="8.61" height="1.5" rotation="0.4757117344043803"></floor> <floor x="187.10999999999999" y="284.675" width="8.61" height="1.5" rotation="0.5973046608227033"></floor> <floor x="185.10999999999999" y="282.825" width="8.61" height="1.5" rotation="0.7199256227756606"></floor> <floor x="182.85999999999999" y="280.475" width="8.61" height="1.5" rotation="0.818780933429311"></floor> <floor x="180.60999999999999" y="277.375" width="8.61" height="1.5" rotation="0.9472720683565392"></floor> <floor x="179.66" y="275.475" width="8.61" height="1.5" rotation="1.0590272565610424"></floor> <floor x="178.70999999999998" y="273.175" width="8.61" height="1.5" rotation="1.162794130633873"></floor> <floor x="416.51000000000005" y="290.08000000000004" width="9" height="6" rotation="0.06796646339153686"></floor> <floor x="409.985" y="289.225" width="9" height="6" rotation="0.18719730901713472"></floor> <floor x="403.77" y="287.76" width="9" height="6" rotation="0.275629438382131"></floor> <floor x="398.175" y="285.855" width="9" height="6" rotation="0.3692139811427647"></floor> <floor x="392.5" y="283.15" width="9" height="6" rotation="0.47703966547705134"></floor> <floor x="386.39" y="279.335" width="9" height="6" rotation="0.6288802635734486"></floor> <floor x="380.88" y="274.775" width="9" height="6" rotation="0.7541055051607"></floor> <floor x="376.025" y="269.4" width="9" height="6" rotation="0.9110305683628696"></floor> <floor x="372.46999999999997" y="263.86" width="9" height="6" rotation="1.0755750308525185"></floor> <floor x="370.13" y="258.235" width="9" height="6" rotation="1.2233194175806157"></floor> <floor x="368.90500000000003" y="253.08499999999998" width="9" height="6" rotation="1.3837047964322264"></floor> <floor x="368.37" y="247.45" width="9" height="6" rotation="1.5042281630190728"></floor> <floor x="422.59" y="290.275" width="9" height="6" rotation="0"></floor> <floor x="248.63000000000002" y="261.88" width="23.04" height="2" rotation="-0.5819051181398855"></floor> <floor x="308.23" y="255.08" width="101.03999999999999" height="1" rotation="0"></floor> <floor x="331.43" y="249.28000000000003" width="23.04" height="2" rotation="-0.5819051181398855"></floor> <floor x="233.70999999999998" y="272.32" width="15.030000000000001" height="11.67" rotation="0"></floor> <floor x="170.35999999999999" y="272.65500000000003" width="15.030000000000001" height="11.67" rotation="0"></floor> <entity x="472.215" y="232.95999999999998" width="3" height="3" type="coin"></entity> <entity x="473.215" y="216.45999999999998" width="3" height="3" type="coin"></entity> <entity x="477.715" y="199.95999999999998" width="3" height="3" type="coin"></entity> <entity x="485.715" y="188.95999999999998" width="3" height="3" type="coin"></entity> <entity x="372.71500000000003" y="231.70999999999998" width="3" height="3" type="coin"></entity> <entity x="370.46500000000003" y="215.70999999999998" width="3" height="3" type="coin"></entity> <entity x="364.71500000000003" y="198.45999999999998" width="3" height="3" type="coin"></entity> <entity x="354.21500000000003" y="187.70999999999998" width="3" height="3" type="coin"></entity> <entity x="378.71500000000003" y="206.95999999999998" width="3" height="3" type="snow"></entity> <entity x="467.715" y="206.45999999999998" width="3" height="3" type="snow"></entity> <entity x="420.215" y="228.70999999999998" width="3" height="3" type="live"></entity> <entity x="420.465" y="242.45999999999998" width="3" height="3" type="live"></entity> <entity x="371.96500000000003" y="175.95999999999998" width="3" height="3" type="coin"></entity> <entity x="471.215" y="174.70999999999998" width="3" height="3" type="coin"></entity> <entity x="674.92" y="258.21" width="3" height="3" type="coin"></entity> <entity x="610.17" y="242.70999999999998" width="3" height="3" type="coin"></entity> <entity x="170.75" y="251.20999999999998" width="3" height="3" type="coin"></entity> <entity x="240.25" y="247.20999999999998" width="3" height="3" type="coin"></entity> <start x="292.9" y="245.42"></start></root>"; public static var Cost:int = 200; } }//package src.levels
Section 159
//level5 (src.levels.level5) package src.levels { public class level5 { public static var SourceXML:String = "<root> <floor x="473.1" y="-50" width="10.58" height="43.13" rotation="0"></floor> <floor x="655.65" y="287.31" width="8.61" height="1.5" rotation="0.23599223010713297"></floor> <floor x="624.22" y="270.04499999999996" width="8.61" height="1.5" rotation="-1.2959188446320782"></floor> <floor x="639.96" y="269.385" width="7.109999999999999" height="1.3199999999999998" rotation="1.3055338576224806"></floor> <floor x="653.3149999999999" y="286.32" width="8.61" height="1.5" rotation="0.3469336831764292"></floor> <floor x="651.745" y="285.32" width="8.61" height="1.5" rotation="0.5080249447424414"></floor> <floor x="647.9399999999999" y="282.65500000000003" width="8.61" height="1.5" rotation="0.6569144665595785"></floor> <floor x="645.11" y="279.78000000000003" width="8.61" height="1.5" rotation="0.8067852762491778"></floor> <floor x="642.895" y="276.79499999999996" width="8.61" height="1.5" rotation="0.9723774333163594"></floor> <floor x="640.86" y="272.91999999999996" width="8.61" height="1.5" rotation="1.1217175944851414"></floor> <floor x="659.26" y="288.15" width="8.61" height="1.5" rotation="0.13578565141822713"></floor> <floor x="603.895" y="288.075" width="8.61" height="1.5" rotation="-0.05294731206670226"></floor> <floor x="606.52" y="287.65" width="8.61" height="1.5" rotation="-0.14548943378833487"></floor> <floor x="608.67" y="286.995" width="8.61" height="1.5" rotation="-0.2359616371512511"></floor> <floor x="610.77" y="286.145" width="8.61" height="1.5" rotation="-0.3358876163249498"></floor> <floor x="613.17" y="284.745" width="8.61" height="1.5" rotation="-0.4757117344043803"></floor> <floor x="615.42" y="283.195" width="8.61" height="1.5" rotation="-0.5973046608227033"></floor> <floor x="617.42" y="281.34499999999997" width="8.61" height="1.5" rotation="-0.7199256227756606"></floor> <floor x="619.67" y="278.995" width="8.61" height="1.5" rotation="-0.818780933429311"></floor> <floor x="621.92" y="275.895" width="8.61" height="1.5" rotation="-0.9472720683565392"></floor> <floor x="622.87" y="273.995" width="8.61" height="1.5" rotation="-1.0590272565610424"></floor> <floor x="623.8149999999999" y="271.695" width="8.61" height="1.5" rotation="-1.162794130633873"></floor> <floor x="524.26" y="290.86" width="9" height="6" rotation="-0.06796646339153686"></floor> <floor x="530.7850000000001" y="290" width="9" height="6" rotation="-0.18719730901713472"></floor> <floor x="537.005" y="288.53000000000003" width="9" height="6" rotation="-0.275629438382131"></floor> <floor x="542.6" y="286.635" width="9" height="6" rotation="-0.3692139811427647"></floor> <floor x="548.275" y="283.91999999999996" width="9" height="6" rotation="-0.47703966547705134"></floor> <floor x="554.385" y="280.11" width="9" height="6" rotation="-0.6288802635734486"></floor> <floor x="559.895" y="275.54499999999996" width="9" height="6" rotation="-0.7541055051607"></floor> <floor x="564.75" y="270.16999999999996" width="9" height="6" rotation="-0.9110305683628696"></floor> <floor x="567.3100000000001" y="265.8" width="9" height="6" rotation="-1.0755750308525185"></floor> <floor x="710.545" y="288.61" width="101.03999999999999" height="1" rotation="0"></floor> <floor x="815.425" y="283.46999999999997" width="19.240000000000002" height="2" rotation="0.6643004863206927"></floor> <floor x="789.75" y="288.05" width="3.9" height="2" rotation="-0.6271168809987024"></floor> <floor x="806.3149999999999" y="276.695" width="3.78" height="2" rotation="0.5039378873063678"></floor> <floor x="803.03" y="275.51" width="3.9" height="2" rotation="0.17829323581350234"></floor> <floor x="799.455" y="275.445" width="3.9" height="2" rotation="-0.12417531617298758"></floor> <floor x="792.8149999999999" y="282.82" width="11.67" height="2" rotation="-1.156705963574323"></floor> <floor x="796.365" y="276.66999999999996" width="3.9" height="2" rotation="-0.6271168809987024"></floor> <floor x="861.485" y="288.635" width="101.06" height="1" rotation="0"></floor> <floor x="936.675" y="283.71999999999997" width="19.240000000000002" height="2" rotation="0.6643004863206927"></floor> <floor x="911" y="288.3" width="3.9" height="2" rotation="-0.6271168809987024"></floor> <floor x="927.57" y="276.945" width="3.78" height="2" rotation="0.5039378873063678"></floor> <floor x="924.28" y="275.76" width="3.9" height="2" rotation="0.17829323581350234"></floor> <floor x="920.7049999999999" y="275.695" width="3.9" height="2" rotation="-0.12417531617298758"></floor> <floor x="914.0649999999999" y="283.07" width="11.67" height="2" rotation="-1.156705963574323"></floor> <floor x="917.615" y="276.91999999999996" width="3.9" height="2" rotation="-0.6271168809987024"></floor> <floor x="991.485" y="288.885" width="101.06" height="1" rotation="0"></floor> <floor x="864.675" y="283.71999999999997" width="19.240000000000002" height="2" rotation="-0.6643004863206927"></floor> <floor x="890.35" y="288.3" width="3.9" height="2" rotation="0.6271168809987024"></floor> <floor x="873.78" y="276.945" width="3.78" height="2" rotation="-0.5039378873063678"></floor> <floor x="877.07" y="275.76" width="3.9" height="2" rotation="-0.17829323581350234"></floor> <floor x="880.6450000000001" y="275.695" width="3.9" height="2" rotation="0.12417531617298758"></floor> <floor x="887.2850000000001" y="283.07" width="11.67" height="2" rotation="1.156705963574323"></floor> <floor x="883.735" y="276.91999999999996" width="3.9" height="2" rotation="0.6271168809987024"></floor> <floor x="760.675" y="283.46999999999997" width="19.240000000000002" height="2" rotation="-0.6643004863206927"></floor> <floor x="786.35" y="288.05" width="3.9" height="2" rotation="0.6271168809987024"></floor> <floor x="769.78" y="276.695" width="3.78" height="2" rotation="-0.5039378873063678"></floor> <floor x="773.0649999999999" y="275.51" width="3.9" height="2" rotation="-0.17829323581350234"></floor> <floor x="776.645" y="275.445" width="3.9" height="2" rotation="0.12417531617298758"></floor> <floor x="783.2850000000001" y="282.82" width="11.67" height="2" rotation="1.156705963574323"></floor> <floor x="779.735" y="276.66999999999996" width="3.9" height="2" rotation="0.6271168809987024"></floor> <floor x="626.635" y="264.615" width="4.08" height="2" rotation="-0.9529860406460112"></floor> <floor x="632.14" y="261.835" width="5.33" height="2.1" rotation="0.00967321701987514"></floor> <floor x="637.7" y="264.685" width="4.08" height="2" rotation="0.9529860406460112"></floor> <floor x="635.55" y="262.495" width="2.96" height="2" rotation="0.5644627019648516"></floor> <floor x="628.8" y="262.38" width="2.96" height="2" rotation="-0.5644627019648516"></floor> <floor x="592.96" y="286.945" width="8.61" height="1.5" rotation="0.23599223010713297"></floor> <floor x="577.26" y="268.995" width="7.109999999999999" height="1.3199999999999998" rotation="1.3055338576224806"></floor> <floor x="590.61" y="285.96999999999997" width="8.61" height="1.5" rotation="0.3469336831764292"></floor> <floor x="589.0350000000001" y="284.96999999999997" width="8.61" height="1.5" rotation="0.5080249447424414"></floor> <floor x="585.235" y="282.29499999999996" width="8.61" height="1.5" rotation="0.6569144665595785"></floor> <floor x="582.4100000000001" y="279.41999999999996" width="8.61" height="1.5" rotation="0.8067852762491778"></floor> <floor x="580.1850000000001" y="276.445" width="8.61" height="1.5" rotation="0.9723774333163594"></floor> <floor x="578.1600000000001" y="272.54499999999996" width="8.61" height="1.5" rotation="1.1217175944851414"></floor> <floor x="596.5600000000001" y="287.8" width="8.61" height="1.5" rotation="0.13578565141822713"></floor> <floor x="569.4350000000001" y="261.445" width="5.33" height="2.1" rotation="0.00967321701987514"></floor> <floor x="575.01" y="264.29499999999996" width="4.08" height="2" rotation="0.9529860406460112"></floor> <floor x="572.86" y="262.12" width="2.96" height="2" rotation="0.5644627019648516"></floor> <floor x="387.125" y="287.28000000000003" width="8.61" height="1.5" rotation="-0.23599223010713297"></floor> <floor x="418.555" y="270.025" width="8.61" height="1.5" rotation="1.2959188446320782"></floor> <floor x="402.815" y="269.36" width="7.109999999999999" height="1.3199999999999998" rotation="-1.3055338576224806"></floor> <floor x="389.45500000000004" y="286.3" width="8.61" height="1.5" rotation="-0.3469336831764292"></floor> <floor x="391.03000000000003" y="285.3" width="8.61" height="1.5" rotation="-0.5080249447424414"></floor> <floor x="394.835" y="282.635" width="8.61" height="1.5" rotation="-0.6569144665595785"></floor> <floor x="397.665" y="279.76" width="8.61" height="1.5" rotation="-0.8067852762491778"></floor> <floor x="399.88" y="276.775" width="8.61" height="1.5" rotation="-0.9723774333163594"></floor> <floor x="401.915" y="272.9" width="8.61" height="1.5" rotation="-1.1217175944851414"></floor> <floor x="383.515" y="288.125" width="8.61" height="1.5" rotation="-0.13578565141822713"></floor> <floor x="438.88" y="288.05" width="8.61" height="1.5" rotation="0.05294731206670226"></floor> <floor x="436.255" y="287.625" width="8.61" height="1.5" rotation="0.14548943378833487"></floor> <floor x="434.105" y="286.975" width="8.61" height="1.5" rotation="0.2359616371512511"></floor> <floor x="432.005" y="286.125" width="8.61" height="1.5" rotation="0.3358876163249498"></floor> <floor x="429.605" y="284.725" width="8.61" height="1.5" rotation="0.4757117344043803"></floor> <floor x="427.355" y="283.175" width="8.61" height="1.5" rotation="0.5973046608227033"></floor> <floor x="425.355" y="281.325" width="8.61" height="1.5" rotation="0.7199256227756606"></floor> <floor x="423.105" y="278.975" width="8.61" height="1.5" rotation="0.818780933429311"></floor> <floor x="420.855" y="275.875" width="8.61" height="1.5" rotation="0.9472720683565392"></floor> <floor x="419.9" y="273.975" width="8.61" height="1.5" rotation="1.0590272565610424"></floor> <floor x="418.95500000000004" y="271.675" width="8.61" height="1.5" rotation="1.162794130633873"></floor> <floor x="518.51" y="290.835" width="9" height="6" rotation="0.06796646339153686"></floor> <floor x="511.985" y="289.975" width="9" height="6" rotation="0.18719730901713472"></floor> <floor x="505.77" y="288.51" width="9" height="6" rotation="0.275629438382131"></floor> <floor x="500.175" y="286.61" width="9" height="6" rotation="0.3692139811427647"></floor> <floor x="494.5" y="283.9" width="9" height="6" rotation="0.47703966547705134"></floor> <floor x="488.39" y="280.09000000000003" width="9" height="6" rotation="0.6288802635734486"></floor> <floor x="482.88" y="275.52" width="9" height="6" rotation="0.7541055051607"></floor> <floor x="478.025" y="270.145" width="9" height="6" rotation="0.9110305683628696"></floor> <floor x="475.45500000000004" y="265.78000000000003" width="9" height="6" rotation="1.0755750308525185"></floor> <floor x="332.23" y="288.585" width="101.03999999999999" height="1" rotation="0"></floor> <floor x="227.35" y="283.445" width="19.240000000000002" height="2" rotation="-0.6643004863206927"></floor> <floor x="253.025" y="288.03000000000003" width="3.9" height="2" rotation="0.6271168809987024"></floor> <floor x="236.455" y="276.675" width="3.78" height="2" rotation="-0.5039378873063678"></floor> <floor x="239.74499999999998" y="275.49" width="3.9" height="2" rotation="-0.17829323581350234"></floor> <floor x="243.32" y="275.41999999999996" width="3.9" height="2" rotation="0.12417531617298758"></floor> <floor x="249.95999999999998" y="282.79499999999996" width="11.67" height="2" rotation="1.156705963574323"></floor> <floor x="246.41" y="276.65" width="3.9" height="2" rotation="0.6271168809987024"></floor> <floor x="181.29000000000002" y="288.615" width="101.06" height="1" rotation="0"></floor> <floor x="106.1" y="283.695" width="19.240000000000002" height="2" rotation="-0.6643004863206927"></floor> <floor x="131.775" y="288.28000000000003" width="3.9" height="2" rotation="0.6271168809987024"></floor> <floor x="115.205" y="276.925" width="3.78" height="2" rotation="-0.5039378873063678"></floor> <floor x="118.495" y="275.74" width="3.9" height="2" rotation="-0.17829323581350234"></floor> <floor x="122.06500000000001" y="275.66999999999996" width="3.9" height="2" rotation="0.12417531617298758"></floor> <floor x="128.70999999999998" y="283.04499999999996" width="11.67" height="2" rotation="1.156705963574323"></floor> <floor x="125.16" y="276.9" width="3.9" height="2" rotation="0.6271168809987024"></floor> <floor x="51.29" y="288.865" width="101.06" height="1" rotation="0"></floor> <floor x="178.1" y="283.695" width="19.240000000000002" height="2" rotation="0.6643004863206927"></floor> <floor x="152.425" y="288.28000000000003" width="3.9" height="2" rotation="-0.6271168809987024"></floor> <floor x="168.995" y="276.925" width="3.78" height="2" rotation="0.5039378873063678"></floor> <floor x="165.7" y="275.74" width="3.9" height="2" rotation="0.17829323581350234"></floor> <floor x="162.13" y="275.66999999999996" width="3.9" height="2" rotation="-0.12417531617298758"></floor> <floor x="155.49" y="283.04499999999996" width="11.67" height="2" rotation="-1.156705963574323"></floor> <floor x="159.04000000000002" y="276.9" width="3.9" height="2" rotation="-0.6271168809987024"></floor> <floor x="282.1" y="283.445" width="19.240000000000002" height="2" rotation="0.6643004863206927"></floor> <floor x="256.425" y="288.03000000000003" width="3.9" height="2" rotation="-0.6271168809987024"></floor> <floor x="272.995" y="276.675" width="3.78" height="2" rotation="0.5039378873063678"></floor> <floor x="269.70500000000004" y="275.49" width="3.9" height="2" rotation="0.17829323581350234"></floor> <floor x="266.13" y="275.41999999999996" width="3.9" height="2" rotation="-0.12417531617298758"></floor> <floor x="259.49" y="282.79499999999996" width="11.67" height="2" rotation="-1.156705963574323"></floor> <floor x="263.04" y="276.65" width="3.9" height="2" rotation="-0.6271168809987024"></floor> <floor x="416.14" y="264.59499999999997" width="4.08" height="2" rotation="0.9529860406460112"></floor> <floor x="410.63500000000005" y="261.815" width="5.33" height="2.1" rotation="-0.00967321701987514"></floor> <floor x="405.075" y="264.665" width="4.08" height="2" rotation="-0.9529860406460112"></floor> <floor x="407.225" y="262.475" width="2.96" height="2" rotation="-0.5644627019648516"></floor> <floor x="413.975" y="262.36" width="2.96" height="2" rotation="0.5644627019648516"></floor> <floor x="449.81499999999994" y="286.925" width="8.61" height="1.5" rotation="-0.23599223010713297"></floor> <floor x="465.515" y="268.975" width="7.109999999999999" height="1.3199999999999998" rotation="-1.3055338576224806"></floor> <floor x="452.16499999999996" y="285.95" width="8.61" height="1.5" rotation="-0.3469336831764292"></floor> <floor x="453.735" y="284.95" width="8.61" height="1.5" rotation="-0.5080249447424414"></floor> <floor x="457.53999999999996" y="282.275" width="8.61" height="1.5" rotation="-0.6569144665595785"></floor> <floor x="460.36" y="279.4" width="8.61" height="1.5" rotation="-0.8067852762491778"></floor> <floor x="462.59" y="276.425" width="8.61" height="1.5" rotation="-0.9723774333163594"></floor> <floor x="464.61" y="272.525" width="8.61" height="1.5" rotation="-1.1217175944851414"></floor> <floor x="446.215" y="287.775" width="8.61" height="1.5" rotation="-0.13578565141822713"></floor> <floor x="473.34" y="261.425" width="5.33" height="2.1" rotation="-0.00967321701987514"></floor> <floor x="467.765" y="264.275" width="4.08" height="2" rotation="-0.9529860406460112"></floor> <floor x="469.91499999999996" y="262.1" width="2.96" height="2" rotation="-0.5644627019648516"></floor> <entity x="254.49" y="261.96" width="3" height="3" type="coin"></entity> <entity x="141.865" y="265.71" width="3" height="3" type="coin"></entity> <entity x="469.20500000000004" y="238.45999999999998" width="3" height="3" type="coin"></entity> <entity x="457.20500000000004" y="222.20999999999998" width="3" height="3" type="coin"></entity> <entity x="441.20500000000004" y="207.70999999999998" width="3" height="3" type="coin"></entity> <entity x="441.20500000000004" y="192.70999999999998" width="3" height="3" type="snow"></entity> <entity x="440.70500000000004" y="179.45999999999998" width="3" height="3" type="live"></entity> <entity x="569.88" y="245.45999999999998" width="3" height="3" type="coin"></entity> <entity x="572.13" y="222.70999999999998" width="3" height="3" type="coin"></entity> <entity x="631.61" y="242.45999999999998" width="3" height="3" type="coin"></entity> <entity x="631.61" y="214.45999999999998" width="3" height="3" type="coin"></entity> <entity x="631.61" y="185.95999999999998" width="3" height="3" type="coin"></entity> <entity x="631.36" y="163.45999999999998" width="3" height="3" type="coin"></entity> <entity x="900.985" y="264.96" width="3" height="3" type="coin"></entity> <entity x="788.4449999999999" y="268.71" width="3" height="3" type="coin"></entity> <start x="332.65" y="277.29499999999996"></start></root>"; public static var Cost:int = 200; } }//package src.levels
Section 160
//level6 (src.levels.level6) package src.levels { public class level6 { public static var SourceXML:String = "<root> <floor x="473.1" y="-50" width="10.58" height="43.13" rotation="0"></floor> <floor x="782.335" y="270.88" width="8.61" height="1.5" rotation="0.23599223010713297"></floor> <floor x="766.64" y="252.95999999999998" width="7.109999999999999" height="1.3199999999999998" rotation="1.3055338576224806"></floor> <floor x="780" y="269.9" width="8.61" height="1.5" rotation="0.3469336831764292"></floor> <floor x="778.4350000000001" y="268.9" width="8.61" height="1.5" rotation="0.5080249447424414"></floor> <floor x="774.625" y="266.235" width="8.61" height="1.5" rotation="0.6569144665595785"></floor> <floor x="771.79" y="263.36" width="8.61" height="1.5" rotation="0.8067852762491778"></floor> <floor x="769.575" y="260.375" width="8.61" height="1.5" rotation="0.9723774333163594"></floor> <floor x="767.54" y="256.5" width="8.61" height="1.5" rotation="1.1217175944851414"></floor> <floor x="597.3" y="212.25" width="19.240000000000002" height="2" rotation="0.6643004863206927"></floor> <floor x="571.365" y="217.545" width="3.9" height="2" rotation="-0.6271168809987024"></floor> <floor x="588.2" y="205.475" width="3.78" height="2" rotation="0.5039378873063678"></floor> <floor x="584.9" y="204.29500000000002" width="3.9" height="2" rotation="0.17829323581350234"></floor> <floor x="581.325" y="204.225" width="3.9" height="2" rotation="-0.12417531617298758"></floor> <floor x="574.6899999999999" y="211.6" width="11.67" height="2" rotation="-1.156705963574323"></floor> <floor x="578.25" y="205.45" width="3.9" height="2" rotation="-0.6271168809987024"></floor> <floor x="915.9649999999999" y="258.82" width="101.06" height="1" rotation="0"></floor> <floor x="1034.5549999999998" y="281.7" width="19.240000000000002" height="2" rotation="0.6643004863206927"></floor> <floor x="1025.46" y="274.925" width="3.78" height="2" rotation="0.5039378873063678"></floor> <floor x="1022.165" y="273.745" width="3.9" height="2" rotation="0.17829323581350234"></floor> <floor x="1089.365" y="286.87" width="101.06" height="1" rotation="0"></floor> <floor x="978.0350000000001" y="272.08000000000004" width="3.9" height="2" rotation="0.6271168809987024"></floor> <floor x="968.325" y="259.475" width="3.9" height="2" rotation="0.12417531617298758"></floor> <floor x="974.9649999999999" y="266.85" width="11.67" height="2" rotation="1.156705963574323"></floor> <floor x="971.415" y="260.7" width="3.9" height="2" rotation="0.6271168809987024"></floor> <floor x="791.96" y="267.05" width="19.240000000000002" height="2" rotation="-0.6643004863206927"></floor> <floor x="801.0600000000001" y="260.275" width="3.78" height="2" rotation="-0.5039378873063678"></floor> <floor x="804.345" y="259.09499999999997" width="3.9" height="2" rotation="-0.17829323581350234"></floor> <floor x="764.375" y="248.26" width="4.08" height="2" rotation="0.9529860406460112"></floor> <floor x="762.225" y="246.075" width="2.96" height="2" rotation="0.5644627019648516"></floor> <floor x="753.24" y="243.925" width="8.61" height="1.5" rotation="0.23599223010713297"></floor> <floor x="737.54" y="225.975" width="7.109999999999999" height="1.3199999999999998" rotation="1.3055338576224806"></floor> <floor x="750.89" y="242.95" width="8.61" height="1.5" rotation="0.3469336831764292"></floor> <floor x="749.3149999999999" y="241.95" width="8.61" height="1.5" rotation="0.5080249447424414"></floor> <floor x="745.515" y="239.275" width="8.61" height="1.5" rotation="0.6569144665595785"></floor> <floor x="742.6899999999999" y="236.4" width="8.61" height="1.5" rotation="0.8067852762491778"></floor> <floor x="740.4649999999999" y="233.425" width="8.61" height="1.5" rotation="0.9723774333163594"></floor> <floor x="738.4399999999999" y="229.525" width="8.61" height="1.5" rotation="1.1217175944851414"></floor> <floor x="756.8399999999999" y="244.775" width="8.61" height="1.5" rotation="0.13578565141822713"></floor> <floor x="735.29" y="221.275" width="4.08" height="2" rotation="0.9529860406460112"></floor> <floor x="733.14" y="219.1" width="2.96" height="2" rotation="0.5644627019648516"></floor> <floor x="822.195" y="253.38000000000002" width="8.61" height="1.5" rotation="-0.818780933429311"></floor> <floor x="862.1850000000001" y="257.685" width="8.61" height="1.5" rotation="0.23599223010713297"></floor> <floor x="830.7450000000001" y="240.43" width="8.61" height="1.5" rotation="-1.2959188446320782"></floor> <floor x="846.49" y="239.76" width="7.109999999999999" height="1.3199999999999998" rotation="1.3055338576224806"></floor> <floor x="859.845" y="256.70500000000004" width="8.61" height="1.5" rotation="0.3469336831764292"></floor> <floor x="858.2700000000001" y="255.705" width="8.61" height="1.5" rotation="0.5080249447424414"></floor> <floor x="854.47" y="253.035" width="8.61" height="1.5" rotation="0.6569144665595785"></floor> <floor x="851.64" y="250.16" width="8.61" height="1.5" rotation="0.8067852762491778"></floor> <floor x="849.4200000000001" y="247.18" width="8.61" height="1.5" rotation="0.9723774333163594"></floor> <floor x="847.39" y="243.305" width="8.61" height="1.5" rotation="1.1217175944851414"></floor> <floor x="865.7950000000001" y="258.53000000000003" width="8.61" height="1.5" rotation="0.13578565141822713"></floor> <floor x="810.42" y="258.45500000000004" width="8.61" height="1.5" rotation="-0.05294731206670226"></floor> <floor x="813.045" y="258.03000000000003" width="8.61" height="1.5" rotation="-0.14548943378833487"></floor> <floor x="815.1899999999999" y="257.38" width="8.61" height="1.5" rotation="-0.2359616371512511"></floor> <floor x="817.295" y="256.53000000000003" width="8.61" height="1.5" rotation="-0.3358876163249498"></floor> <floor x="819.695" y="255.13000000000002" width="8.61" height="1.5" rotation="-0.4757117344043803"></floor> <floor x="821.945" y="253.58" width="8.61" height="1.5" rotation="-0.5973046608227033"></floor> <floor x="823.945" y="251.725" width="8.61" height="1.5" rotation="-0.7199256227756606"></floor> <floor x="826.195" y="249.38000000000002" width="8.61" height="1.5" rotation="-0.818780933429311"></floor> <floor x="828.445" y="246.28000000000003" width="8.61" height="1.5" rotation="-0.9472720683565392"></floor> <floor x="829.3950000000001" y="244.38000000000002" width="8.61" height="1.5" rotation="-1.0590272565610424"></floor> <floor x="830.345" y="242.08" width="8.61" height="1.5" rotation="-1.162794130633873"></floor> <floor x="833.1700000000001" y="235" width="4.08" height="2" rotation="-0.9529860406460112"></floor> <floor x="838.6700000000001" y="232.215" width="5.33" height="2.1" rotation="0.00967321701987514"></floor> <floor x="844.235" y="235.065" width="4.08" height="2" rotation="0.9529860406460112"></floor> <floor x="842.085" y="232.88000000000002" width="2.96" height="2" rotation="0.5644627019648516"></floor> <floor x="835.335" y="232.76" width="2.96" height="2" rotation="-0.5644627019648516"></floor> <floor x="969.9649999999999" y="273.02" width="101.06" height="1" rotation="0"></floor> <floor x="664.2" y="217.53000000000003" width="8.61" height="1.5" rotation="0.13578565141822713"></floor> <floor x="608.825" y="217.455" width="8.61" height="1.5" rotation="-0.05294731206670226"></floor> <floor x="611.45" y="217.03000000000003" width="8.61" height="1.5" rotation="-0.14548943378833487"></floor> <floor x="724.385" y="216.885" width="8.61" height="1.5" rotation="0.23599223010713297"></floor> <floor x="692.95" y="199.63" width="8.61" height="1.5" rotation="-1.2959188446320782"></floor> <floor x="708.6899999999999" y="198.95999999999998" width="7.109999999999999" height="1.3199999999999998" rotation="1.3055338576224806"></floor> <floor x="722.05" y="215.90500000000003" width="8.61" height="1.5" rotation="0.3469336831764292"></floor> <floor x="720.475" y="214.90500000000003" width="8.61" height="1.5" rotation="0.5080249447424414"></floor> <floor x="716.675" y="212.23499999999999" width="8.61" height="1.5" rotation="0.6569144665595785"></floor> <floor x="713.8399999999999" y="209.35999999999999" width="8.61" height="1.5" rotation="0.8067852762491778"></floor> <floor x="711.625" y="206.38000000000002" width="8.61" height="1.5" rotation="0.9723774333163594"></floor> <floor x="709.5899999999999" y="202.505" width="8.61" height="1.5" rotation="1.1217175944851414"></floor> <floor x="728" y="217.725" width="8.61" height="1.5" rotation="0.13578565141822713"></floor> <floor x="672.17" y="217.85" width="8.61" height="1.5" rotation="-0.05294731206670226"></floor> <floor x="675.25" y="217.225" width="8.61" height="1.5" rotation="-0.14548943378833487"></floor> <floor x="677.4" y="216.58" width="8.61" height="1.5" rotation="-0.2359616371512511"></floor> <floor x="679.5" y="215.725" width="8.61" height="1.5" rotation="-0.3358876163249498"></floor> <floor x="681.9" y="214.33" width="8.61" height="1.5" rotation="-0.4757117344043803"></floor> <floor x="684.15" y="212.78000000000003" width="8.61" height="1.5" rotation="-0.5973046608227033"></floor> <floor x="686.15" y="210.93" width="8.61" height="1.5" rotation="-0.7199256227756606"></floor> <floor x="688.4" y="208.58" width="8.61" height="1.5" rotation="-0.818780933429311"></floor> <floor x="690.65" y="205.475" width="8.61" height="1.5" rotation="-0.9472720683565392"></floor> <floor x="691.6" y="203.57999999999998" width="8.61" height="1.5" rotation="-1.0590272565610424"></floor> <floor x="692.55" y="201.28" width="8.61" height="1.5" rotation="-1.162794130633873"></floor> <floor x="695.375" y="194.2" width="4.08" height="2" rotation="-0.9529860406460112"></floor> <floor x="700.875" y="191.41500000000002" width="5.33" height="2.1" rotation="0.00967321701987514"></floor> <floor x="706.4300000000001" y="194.26500000000001" width="4.08" height="2" rotation="0.9529860406460112"></floor> <floor x="704.28" y="192.07999999999998" width="2.96" height="2" rotation="0.5644627019648516"></floor> <floor x="697.53" y="191.95999999999998" width="2.96" height="2" rotation="-0.5644627019648516"></floor> <floor x="660.58" y="216.685" width="8.61" height="1.5" rotation="0.23599223010713297"></floor> <floor x="629.15" y="199.43" width="8.61" height="1.5" rotation="-1.2959188446320782"></floor> <floor x="644.895" y="198.76" width="7.109999999999999" height="1.3199999999999998" rotation="1.3055338576224806"></floor> <floor x="658.25" y="215.705" width="8.61" height="1.5" rotation="0.3469336831764292"></floor> <floor x="656.675" y="214.705" width="8.61" height="1.5" rotation="0.5080249447424414"></floor> <floor x="652.875" y="212.035" width="8.61" height="1.5" rotation="0.6569144665595785"></floor> <floor x="650.045" y="209.16" width="8.61" height="1.5" rotation="0.8067852762491778"></floor> <floor x="647.825" y="206.18" width="8.61" height="1.5" rotation="0.9723774333163594"></floor> <floor x="645.795" y="202.305" width="8.61" height="1.5" rotation="1.1217175944851414"></floor> <floor x="613.6" y="216.38000000000002" width="8.61" height="1.5" rotation="-0.2359616371512511"></floor> <floor x="615.7" y="215.53000000000003" width="8.61" height="1.5" rotation="-0.3358876163249498"></floor> <floor x="619.635" y="213.1" width="8.61" height="1.5" rotation="-0.5973046608227033"></floor> <floor x="622.35" y="210.725" width="8.61" height="1.5" rotation="-0.7199256227756606"></floor> <floor x="624.6" y="208.38000000000002" width="8.61" height="1.5" rotation="-0.818780933429311"></floor> <floor x="626.85" y="205.28000000000003" width="8.61" height="1.5" rotation="-0.9472720683565392"></floor> <floor x="627.8" y="203.38" width="8.61" height="1.5" rotation="-1.0590272565610424"></floor> <floor x="628.75" y="201.07999999999998" width="8.61" height="1.5" rotation="-1.162794130633873"></floor> <floor x="631.575" y="194" width="4.08" height="2" rotation="-0.9529860406460112"></floor> <floor x="637.075" y="191.215" width="5.33" height="2.1" rotation="0.00967321701987514"></floor> <floor x="642.63" y="194.065" width="4.08" height="2" rotation="0.9529860406460112"></floor> <floor x="640.48" y="191.88" width="2.96" height="2" rotation="0.5644627019648516"></floor> <floor x="633.73" y="191.76" width="2.96" height="2" rotation="-0.5644627019648516"></floor> <floor x="357.335" y="271.875" width="8.61" height="1.5" rotation="-0.23599223010713297"></floor> <floor x="373.025" y="253.955" width="7.109999999999999" height="1.3199999999999998" rotation="-1.3055338576224806"></floor> <floor x="359.665" y="270.895" width="8.61" height="1.5" rotation="-0.3469336831764292"></floor> <floor x="361.235" y="269.895" width="8.61" height="1.5" rotation="-0.5080249447424414"></floor> <floor x="365.04" y="267.23" width="8.61" height="1.5" rotation="-0.6569144665595785"></floor> <floor x="367.875" y="264.355" width="8.61" height="1.5" rotation="-0.8067852762491778"></floor> <floor x="370.09000000000003" y="261.37" width="8.61" height="1.5" rotation="-0.9723774333163594"></floor> <floor x="372.125" y="257.495" width="8.61" height="1.5" rotation="-1.1217175944851414"></floor> <floor x="542.36" y="213.24499999999998" width="19.240000000000002" height="2" rotation="-0.6643004863206927"></floor> <floor x="568.0350000000001" y="217.825" width="3.9" height="2" rotation="0.6271168809987024"></floor> <floor x="551.4649999999999" y="206.46999999999997" width="3.78" height="2" rotation="-0.5039378873063678"></floor> <floor x="554.755" y="205.29000000000002" width="3.9" height="2" rotation="-0.17829323581350234"></floor> <floor x="558.33" y="205.21999999999997" width="3.9" height="2" rotation="0.12417531617298758"></floor> <floor x="564.97" y="212.59499999999997" width="11.67" height="2" rotation="1.156705963574323"></floor> <floor x="561.415" y="206.445" width="3.9" height="2" rotation="0.6271168809987024"></floor> <floor x="223.7" y="259.815" width="101.06" height="1" rotation="0"></floor> <floor x="105.10999999999999" y="282.695" width="19.240000000000002" height="2" rotation="-0.6643004863206927"></floor> <floor x="114.21" y="275.91999999999996" width="3.78" height="2" rotation="-0.5039378873063678"></floor> <floor x="117.505" y="274.74" width="3.9" height="2" rotation="-0.17829323581350234"></floor> <floor x="50.3" y="287.865" width="101.06" height="1" rotation="0"></floor> <floor x="161.635" y="273.075" width="3.9" height="2" rotation="-0.6271168809987024"></floor> <floor x="171.34" y="260.46999999999997" width="3.9" height="2" rotation="-0.12417531617298758"></floor> <floor x="164.7" y="267.84499999999997" width="11.67" height="2" rotation="-1.156705963574323"></floor> <floor x="168.25" y="261.695" width="3.9" height="2" rotation="-0.6271168809987024"></floor> <floor x="347.71" y="268.04499999999996" width="19.240000000000002" height="2" rotation="0.6643004863206927"></floor> <floor x="338.605" y="261.27" width="3.78" height="2" rotation="0.5039378873063678"></floor> <floor x="335.315" y="260.21999999999997" width="3.9" height="2" rotation="0.13762509767947637"></floor> <floor x="375.28499999999997" y="249.26" width="4.08" height="2" rotation="-0.9529860406460112"></floor> <floor x="377.5" y="247.2" width="2.96" height="2" rotation="-0.46972920213690117"></floor> <floor x="386.425" y="244.92" width="8.61" height="1.5" rotation="-0.23599223010713297"></floor> <floor x="402.125" y="226.96999999999997" width="7.109999999999999" height="1.3199999999999998" rotation="-1.3055338576224806"></floor> <floor x="388.775" y="243.945" width="8.61" height="1.5" rotation="-0.3469336831764292"></floor> <floor x="390.34499999999997" y="242.945" width="8.61" height="1.5" rotation="-0.5080249447424414"></floor> <floor x="394.15" y="240.26999999999998" width="8.61" height="1.5" rotation="-0.6569144665595785"></floor> <floor x="396.96999999999997" y="237.39499999999998" width="8.61" height="1.5" rotation="-0.8067852762491778"></floor> <floor x="399.2" y="234.42" width="8.61" height="1.5" rotation="-0.9723774333163594"></floor> <floor x="401.225" y="230.51999999999998" width="8.61" height="1.5" rotation="-1.1217175944851414"></floor> <floor x="382.825" y="245.76999999999998" width="8.61" height="1.5" rotation="-0.13578565141822713"></floor> <floor x="404.375" y="222.26999999999998" width="4.08" height="2" rotation="-0.9529860406460112"></floor> <floor x="406.525" y="220.09499999999997" width="2.96" height="2" rotation="-0.5644627019648516"></floor> <floor x="317.46500000000003" y="254.375" width="8.61" height="1.5" rotation="0.818780933429311"></floor> <floor x="277.485" y="258.68" width="8.61" height="1.5" rotation="-0.23599223010713297"></floor> <floor x="308.915" y="241.425" width="8.61" height="1.5" rotation="1.2959188446320782"></floor> <floor x="293.175" y="240.75500000000002" width="7.109999999999999" height="1.3199999999999998" rotation="-1.3055338576224806"></floor> <floor x="279.815" y="257.7" width="8.61" height="1.5" rotation="-0.3469336831764292"></floor> <floor x="281.385" y="256.7" width="8.61" height="1.5" rotation="-0.5080249447424414"></floor> <floor x="285.195" y="254.03000000000003" width="8.61" height="1.5" rotation="-0.6569144665595785"></floor> <floor x="288.025" y="251.15500000000003" width="8.61" height="1.5" rotation="-0.8067852762491778"></floor> <floor x="290.24" y="248.175" width="8.61" height="1.5" rotation="-0.9723774333163594"></floor> <floor x="292.275" y="244.3" width="8.61" height="1.5" rotation="-1.1217175944851414"></floor> <floor x="273.87" y="259.525" width="8.61" height="1.5" rotation="-0.13578565141822713"></floor> <floor x="329.24" y="259.45" width="8.61" height="1.5" rotation="0.05816724126514944"></floor> <floor x="326.615" y="259.025" width="8.61" height="1.5" rotation="0.14490270326182553"></floor> <floor x="324.46500000000003" y="258.375" width="8.61" height="1.5" rotation="0.2359616371512511"></floor> <floor x="322.365" y="257.525" width="8.61" height="1.5" rotation="0.3358876163249498"></floor> <floor x="319.96500000000003" y="256.125" width="8.61" height="1.5" rotation="0.4757117344043803"></floor> <floor x="317.71500000000003" y="254.575" width="8.61" height="1.5" rotation="0.5973046608227033"></floor> <floor x="315.71500000000003" y="252.725" width="8.61" height="1.5" rotation="0.7199256227756606"></floor> <floor x="313.46500000000003" y="250.375" width="8.61" height="1.5" rotation="0.818780933429311"></floor> <floor x="311.21500000000003" y="247.275" width="8.61" height="1.5" rotation="0.9472720683565392"></floor> <floor x="310.26" y="245.375" width="8.61" height="1.5" rotation="1.0590272565610424"></floor> <floor x="309.315" y="243.075" width="8.61" height="1.5" rotation="1.162794130633873"></floor> <floor x="306.495" y="235.99499999999998" width="4.08" height="2" rotation="0.9529860406460112"></floor> <floor x="300.995" y="233.20999999999998" width="5.33" height="2.1" rotation="-0.00967321701987514"></floor> <floor x="295.435" y="236.06" width="4.08" height="2" rotation="-0.9529860406460112"></floor> <floor x="297.585" y="233.875" width="2.96" height="2" rotation="-0.5644627019648516"></floor> <floor x="304.335" y="233.75500000000002" width="2.96" height="2" rotation="0.5644627019648516"></floor> <floor x="169.7" y="274.01" width="101.06" height="1" rotation="0"></floor> <floor x="475.465" y="218.525" width="8.61" height="1.5" rotation="-0.13578565141822713"></floor> <floor x="530.8399999999999" y="218.45" width="8.61" height="1.5" rotation="0.05294731206670226"></floor> <floor x="528.2149999999999" y="218.025" width="8.61" height="1.5" rotation="0.14548943378833487"></floor> <floor x="415.275" y="217.88000000000002" width="8.61" height="1.5" rotation="-0.23599223010713297"></floor> <floor x="446.715" y="200.625" width="8.61" height="1.5" rotation="1.2959188446320782"></floor> <floor x="430.96999999999997" y="199.95499999999998" width="7.109999999999999" height="1.3199999999999998" rotation="-1.3055338576224806"></floor> <floor x="417.61" y="216.9" width="8.61" height="1.5" rotation="-0.3469336831764292"></floor> <floor x="419.18999999999994" y="215.9" width="8.61" height="1.5" rotation="-0.5080249447424414"></floor> <floor x="422.985" y="213.225" width="8.61" height="1.5" rotation="-0.6569144665595785"></floor> <floor x="425.82" y="210.35" width="8.61" height="1.5" rotation="-0.8067852762491778"></floor> <floor x="428.03999999999996" y="207.375" width="8.61" height="1.5" rotation="-0.9723774333163594"></floor> <floor x="430.07" y="203.5" width="8.61" height="1.5" rotation="-1.1217175944851414"></floor> <floor x="411.66499999999996" y="218.725" width="8.61" height="1.5" rotation="-0.13578565141822713"></floor> <floor x="467.88500000000005" y="218.78000000000003" width="8.61" height="1.5" rotation="0.05294731206670226"></floor> <floor x="464.41499999999996" y="218.225" width="8.61" height="1.5" rotation="0.14548943378833487"></floor> <floor x="462.265" y="217.575" width="8.61" height="1.5" rotation="0.2359616371512511"></floor> <floor x="460.16499999999996" y="216.725" width="8.61" height="1.5" rotation="0.3358876163249498"></floor> <floor x="457.765" y="215.325" width="8.61" height="1.5" rotation="0.4757117344043803"></floor> <floor x="455.515" y="213.775" width="8.61" height="1.5" rotation="0.5973046608227033"></floor> <floor x="453.515" y="211.925" width="8.61" height="1.5" rotation="0.7199256227756606"></floor> <floor x="451.265" y="209.575" width="8.61" height="1.5" rotation="0.818780933429311"></floor> <floor x="449.015" y="206.475" width="8.61" height="1.5" rotation="0.9472720683565392"></floor> <floor x="448.06499999999994" y="204.575" width="8.61" height="1.5" rotation="1.0590272565610424"></floor> <floor x="447.11" y="202.275" width="8.61" height="1.5" rotation="1.162794130633873"></floor> <floor x="444.28999999999996" y="195.195" width="4.08" height="2" rotation="0.9529860406460112"></floor> <floor x="438.78999999999996" y="192.41" width="5.33" height="2.1" rotation="-0.00967321701987514"></floor> <floor x="433.23" y="195.26" width="4.08" height="2" rotation="-0.9529860406460112"></floor> <floor x="435.38" y="193.075" width="2.96" height="2" rotation="-0.5644627019648516"></floor> <floor x="442.13" y="192.95499999999998" width="2.96" height="2" rotation="0.5644627019648516"></floor> <floor x="479.08000000000004" y="217.68" width="8.61" height="1.5" rotation="-0.23599223010713297"></floor> <floor x="510.515" y="200.425" width="8.61" height="1.5" rotation="1.2959188446320782"></floor> <floor x="494.77" y="199.755" width="7.109999999999999" height="1.3199999999999998" rotation="-1.3055338576224806"></floor> <floor x="481.41499999999996" y="216.7" width="8.61" height="1.5" rotation="-0.3469336831764292"></floor> <floor x="482.985" y="215.7" width="8.61" height="1.5" rotation="-0.5080249447424414"></floor> <floor x="486.78999999999996" y="213.03000000000003" width="8.61" height="1.5" rotation="-0.6569144665595785"></floor> <floor x="489.62" y="210.15500000000003" width="8.61" height="1.5" rotation="-0.8067852762491778"></floor> <floor x="491.84" y="207.175" width="8.61" height="1.5" rotation="-0.9723774333163594"></floor> <floor x="493.87" y="203.3" width="8.61" height="1.5" rotation="-1.1217175944851414"></floor> <floor x="526.0649999999999" y="217.375" width="8.61" height="1.5" rotation="0.2359616371512511"></floor> <floor x="523.9649999999999" y="216.525" width="8.61" height="1.5" rotation="0.3358876163249498"></floor> <floor x="521.5649999999999" y="215.125" width="8.61" height="1.5" rotation="0.4757117344043803"></floor> <floor x="519.3149999999999" y="213.575" width="8.61" height="1.5" rotation="0.5973046608227033"></floor> <floor x="517.3149999999999" y="211.725" width="8.61" height="1.5" rotation="0.7199256227756606"></floor> <floor x="515.0649999999999" y="209.375" width="8.61" height="1.5" rotation="0.818780933429311"></floor> <floor x="512.8149999999999" y="206.275" width="8.61" height="1.5" rotation="0.9472720683565392"></floor> <floor x="511.86" y="204.375" width="8.61" height="1.5" rotation="1.0590272565610424"></floor> <floor x="510.91499999999996" y="202.075" width="8.61" height="1.5" rotation="1.162794130633873"></floor> <floor x="508.09" y="194.995" width="4.08" height="2" rotation="0.9529860406460112"></floor> <floor x="502.59" y="192.20999999999998" width="5.33" height="2.1" rotation="-0.00967321701987514"></floor> <floor x="497.025" y="195.06" width="4.08" height="2" rotation="-0.9529860406460112"></floor> <floor x="499.18" y="192.875" width="2.96" height="2" rotation="-0.5644627019648516"></floor> <floor x="505.93" y="192.755" width="2.96" height="2" rotation="0.5644627019648516"></floor> <entity x="182.43" y="222.45999999999998" width="3" height="3" type="coin"></entity> <entity x="301.385" y="207.95999999999998" width="3" height="3" type="coin"></entity> <entity x="439.03999999999996" y="167.20999999999998" width="3" height="3" type="coin"></entity> <entity x="438.78999999999996" y="145.20999999999998" width="3" height="3" type="coin"></entity> <entity x="438.53999999999996" y="124.71" width="3" height="3" type="coin"></entity> <entity x="353.90500000000003" y="226.57" width="3" height="3" type="live"></entity> <entity x="569.375" y="175.57" width="3" height="3" type="live"></entity> <entity x="964.4" y="238.82" width="3" height="3" type="coin"></entity> <entity x="838.6899999999999" y="210.32" width="3" height="3" type="coin"></entity> <entity x="736.1899999999999" y="196.32" width="3" height="3" type="coin"></entity> <entity x="700.265" y="170.57" width="3" height="3" type="live"></entity> <entity x="726.265" y="186.32" width="3" height="3" type="snow"></entity> <entity x="636.265" y="130.065" width="3" height="3" type="snow"></entity> <entity x="404.43" y="196.82" width="3" height="3" type="snow"></entity> <entity x="353.68" y="213.82" width="3" height="3" type="snow"></entity> <entity x="502.68" y="176.32" width="3" height="3" type="coin"></entity> <entity x="502.43" y="160.815" width="3" height="3" type="coin"></entity> <start x="231.16" y="240.295"></start></root>"; public static var Cost:int = 200; } }//package src.levels
Section 161
//level7 (src.levels.level7) package src.levels { public class level7 { public static var SourceXML:String = "<root> <floor x="473.1" y="-50" width="10.58" height="43.13" rotation="0"></floor> <floor x="653.75" y="293.15500000000003" width="9" height="6" rotation="-0.06796646339153686"></floor> <floor x="660.275" y="292.31" width="9" height="6" rotation="-0.18719730901713472"></floor> <floor x="666.475" y="290.86" width="9" height="6" rotation="-0.275629438382131"></floor> <floor x="672.075" y="288.935" width="9" height="6" rotation="-0.3692139811427647"></floor> <floor x="677.75" y="286.235" width="9" height="6" rotation="-0.47703966547705134"></floor> <floor x="683.85" y="282.40500000000003" width="9" height="6" rotation="-0.6288802635734486"></floor> <floor x="689.375" y="277.86" width="9" height="6" rotation="-0.7541055051607"></floor> <floor x="694.225" y="272.46" width="9" height="6" rotation="-0.9110305683628696"></floor> <floor x="697.775" y="266.935" width="9" height="6" rotation="-1.0755750308525185"></floor> <floor x="700.125" y="261.31" width="9" height="6" rotation="-1.2233194175806157"></floor> <floor x="701.35" y="256.15500000000003" width="9" height="6" rotation="-1.3837047964322264"></floor> <floor x="701.875" y="250.51" width="9" height="6" rotation="-1.5042281630190728"></floor> <floor x="381.995" y="285.34499999999997" width="8.61" height="1.5" rotation="-0.818780933429311"></floor> <floor x="421.975" y="289.65500000000003" width="8.61" height="1.5" rotation="0.23599223010713297"></floor> <floor x="390.54499999999996" y="272.395" width="8.61" height="1.5" rotation="-1.2959188446320782"></floor> <floor x="406.28000000000003" y="271.735" width="7.109999999999999" height="1.3199999999999998" rotation="1.3055338576224806"></floor> <floor x="419.65" y="288.66999999999996" width="8.61" height="1.5" rotation="0.3469336831764292"></floor> <floor x="418.075" y="287.66999999999996" width="8.61" height="1.5" rotation="0.5080249447424414"></floor> <floor x="414.275" y="285.01" width="8.61" height="1.5" rotation="0.6569144665595785"></floor> <floor x="411.425" y="282.135" width="8.61" height="1.5" rotation="0.8067852762491778"></floor> <floor x="409.21999999999997" y="279.145" width="8.61" height="1.5" rotation="0.9723774333163594"></floor> <floor x="407.18" y="275.27" width="8.61" height="1.5" rotation="1.1217175944851414"></floor> <floor x="425.6" y="290.495" width="8.61" height="1.5" rotation="0.13578565141822713"></floor> <floor x="370.21999999999997" y="290.41999999999996" width="8.61" height="1.5" rotation="-0.05294731206670226"></floor> <floor x="372.84499999999997" y="289.995" width="8.61" height="1.5" rotation="-0.14548943378833487"></floor> <floor x="374.995" y="289.34499999999997" width="8.61" height="1.5" rotation="-0.2359616371512511"></floor> <floor x="377.09499999999997" y="288.495" width="8.61" height="1.5" rotation="-0.3358876163249498"></floor> <floor x="379.495" y="287.09499999999997" width="8.61" height="1.5" rotation="-0.4757117344043803"></floor> <floor x="381.745" y="285.54499999999996" width="8.61" height="1.5" rotation="-0.5973046608227033"></floor> <floor x="383.745" y="283.695" width="8.61" height="1.5" rotation="-0.7199256227756606"></floor> <floor x="385.995" y="281.34499999999997" width="8.61" height="1.5" rotation="-0.818780933429311"></floor> <floor x="388.245" y="278.245" width="8.61" height="1.5" rotation="-0.9472720683565392"></floor> <floor x="389.195" y="276.34499999999997" width="8.61" height="1.5" rotation="-1.0590272565610424"></floor> <floor x="390.145" y="274.04499999999996" width="8.61" height="1.5" rotation="-1.162794130633873"></floor> <floor x="392.95500000000004" y="266.96500000000003" width="4.08" height="2" rotation="-0.9529860406460112"></floor> <floor x="398.45500000000004" y="264.185" width="5.33" height="2.1" rotation="0.00967321701987514"></floor> <floor x="404.02" y="267.03000000000003" width="4.08" height="2" rotation="0.9529860406460112"></floor> <floor x="401.87" y="264.84499999999997" width="2.96" height="2" rotation="0.5644627019648516"></floor> <floor x="395.12" y="264.735" width="2.96" height="2" rotation="-0.5644627019648516"></floor> <floor x="473.55" y="290.585" width="101.06" height="1" rotation="0"></floor> <floor x="548.75" y="285.665" width="19.240000000000002" height="2" rotation="0.6643004863206927"></floor> <floor x="523.075" y="290.245" width="3.9" height="2" rotation="-0.6271168809987024"></floor> <floor x="539.65" y="278.885" width="3.78" height="2" rotation="0.5039378873063678"></floor> <floor x="536.35" y="277.71" width="3.9" height="2" rotation="0.17829323581350234"></floor> <floor x="532.775" y="277.635" width="3.9" height="2" rotation="-0.12417531617298758"></floor> <floor x="526.15" y="285.01" width="11.67" height="2" rotation="-1.156705963574323"></floor> <floor x="529.7" y="278.865" width="3.9" height="2" rotation="-0.6271168809987024"></floor> <floor x="476.75" y="285.665" width="19.240000000000002" height="2" rotation="-0.6643004863206927"></floor> <floor x="502.425" y="290.245" width="3.9" height="2" rotation="0.6271168809987024"></floor> <floor x="485.85" y="278.885" width="3.78" height="2" rotation="-0.5039378873063678"></floor> <floor x="489.15" y="277.71" width="3.9" height="2" rotation="-0.17829323581350234"></floor> <floor x="492.725" y="277.635" width="3.9" height="2" rotation="0.12417531617298758"></floor> <floor x="499.35" y="285.01" width="11.67" height="2" rotation="1.156705963574323"></floor> <floor x="495.8" y="278.865" width="3.9" height="2" rotation="0.6271168809987024"></floor> <floor x="603.55" y="290.835" width="101.06" height="1" rotation="0"></floor> <floor x="701.855" y="205.94" width="5.6" height="92" rotation="0"></floor> <floor x="80.11" y="293.18" width="9" height="6" rotation="0.06796646339153686"></floor> <floor x="73.58500000000001" y="292.33000000000004" width="9" height="6" rotation="0.18719730901713472"></floor> <floor x="67.385" y="290.88" width="9" height="6" rotation="0.275629438382131"></floor> <floor x="61.779999999999994" y="288.95500000000004" width="9" height="6" rotation="0.3692139811427647"></floor> <floor x="56.11" y="286.255" width="9" height="6" rotation="0.47703966547705134"></floor> <floor x="50.010000000000005" y="282.43" width="9" height="6" rotation="0.6288802635734486"></floor> <floor x="44.485" y="277.88" width="9" height="6" rotation="0.7541055051607"></floor> <floor x="39.635000000000005" y="272.48" width="9" height="6" rotation="0.9110305683628696"></floor> <floor x="36.075" y="266.95500000000004" width="9" height="6" rotation="1.0755750308525185"></floor> <floor x="33.730000000000004" y="261.33000000000004" width="9" height="6" rotation="1.2233194175806157"></floor> <floor x="32.505" y="256.18" width="9" height="6" rotation="1.3837047964322264"></floor> <floor x="31.98" y="250.53000000000003" width="9" height="6" rotation="1.5042281630190728"></floor> <floor x="351.855" y="285.375" width="8.61" height="1.5" rotation="0.818780933429311"></floor> <floor x="311.875" y="289.68" width="8.61" height="1.5" rotation="-0.23599223010713297"></floor> <floor x="343.305" y="272.425" width="8.61" height="1.5" rotation="1.2959188446320782"></floor> <floor x="327.565" y="271.755" width="7.109999999999999" height="1.3199999999999998" rotation="-1.3055338576224806"></floor> <floor x="314.20500000000004" y="288.7" width="8.61" height="1.5" rotation="-0.3469336831764292"></floor> <floor x="315.78000000000003" y="287.7" width="8.61" height="1.5" rotation="-0.5080249447424414"></floor> <floor x="319.585" y="285.03000000000003" width="8.61" height="1.5" rotation="-0.6569144665595785"></floor> <floor x="322.415" y="282.15500000000003" width="8.61" height="1.5" rotation="-0.8067852762491778"></floor> <floor x="324.63" y="279.175" width="8.61" height="1.5" rotation="-0.9723774333163594"></floor> <floor x="326.665" y="275.3" width="8.61" height="1.5" rotation="-1.1217175944851414"></floor> <floor x="308.26" y="290.525" width="8.61" height="1.5" rotation="-0.13578565141822713"></floor> <floor x="363.63" y="290.45" width="8.61" height="1.5" rotation="0.05294731206670226"></floor> <floor x="361.005" y="290.025" width="8.61" height="1.5" rotation="0.14548943378833487"></floor> <floor x="358.855" y="289.375" width="8.61" height="1.5" rotation="0.2359616371512511"></floor> <floor x="356.755" y="288.525" width="8.61" height="1.5" rotation="0.3358876163249498"></floor> <floor x="354.355" y="287.125" width="8.61" height="1.5" rotation="0.4757117344043803"></floor> <floor x="352.105" y="285.575" width="8.61" height="1.5" rotation="0.5973046608227033"></floor> <floor x="350.105" y="283.725" width="8.61" height="1.5" rotation="0.7199256227756606"></floor> <floor x="347.855" y="281.375" width="8.61" height="1.5" rotation="0.818780933429311"></floor> <floor x="345.605" y="278.275" width="8.61" height="1.5" rotation="0.9472720683565392"></floor> <floor x="344.65500000000003" y="276.375" width="8.61" height="1.5" rotation="1.0590272565610424"></floor> <floor x="343.70500000000004" y="274.075" width="8.61" height="1.5" rotation="1.162794130633873"></floor> <floor x="340.885" y="266.995" width="4.08" height="2" rotation="0.9529860406460112"></floor> <floor x="335.385" y="264.21" width="5.33" height="2.1" rotation="-0.00967321701987514"></floor> <floor x="329.825" y="267.06" width="4.08" height="2" rotation="-0.9529860406460112"></floor> <floor x="331.975" y="264.875" width="2.96" height="2" rotation="-0.5644627019648516"></floor> <floor x="338.725" y="264.755" width="2.96" height="2" rotation="0.5644627019648516"></floor> <floor x="260.29" y="290.615" width="101.06" height="1" rotation="0"></floor> <floor x="185.1" y="285.695" width="19.240000000000002" height="2" rotation="-0.6643004863206927"></floor> <floor x="210.775" y="290.275" width="3.9" height="2" rotation="0.6271168809987024"></floor> <floor x="194.2" y="278.91999999999996" width="3.78" height="2" rotation="-0.5039378873063678"></floor> <floor x="197.495" y="277.74" width="3.9" height="2" rotation="-0.17829323581350234"></floor> <floor x="201.07" y="277.66999999999996" width="3.9" height="2" rotation="0.12417531617298758"></floor> <floor x="207.70999999999998" y="285.04499999999996" width="11.67" height="2" rotation="1.156705963574323"></floor> <floor x="204.16" y="278.895" width="3.9" height="2" rotation="0.6271168809987024"></floor> <floor x="257.1" y="285.695" width="19.240000000000002" height="2" rotation="0.6643004863206927"></floor> <floor x="231.425" y="290.275" width="3.9" height="2" rotation="-0.6271168809987024"></floor> <floor x="247.99499999999998" y="278.91999999999996" width="3.78" height="2" rotation="0.5039378873063678"></floor> <floor x="244.705" y="277.74" width="3.9" height="2" rotation="0.17829323581350234"></floor> <floor x="241.13000000000002" y="277.66999999999996" width="3.9" height="2" rotation="-0.12417531617298758"></floor> <floor x="234.49" y="285.04499999999996" width="11.67" height="2" rotation="-1.156705963574323"></floor> <floor x="238.04000000000002" y="278.895" width="3.9" height="2" rotation="-0.6271168809987024"></floor> <floor x="130.29000000000002" y="290.865" width="101.06" height="1" rotation="0"></floor> <floor x="32" y="205.96999999999997" width="5.6" height="92" rotation="0"></floor> <floor x="719.3050000000001" y="165.55" width="40.260000000000005" height="11.34" rotation="0"></floor> <floor x="727.78" y="138.85" width="8.98" height="47" rotation="-0.10577001990274736"></floor> <floor x="14.37" y="165.675" width="40.260000000000005" height="11.34" rotation="0"></floor> <floor x="5.89" y="138.98" width="8.98" height="47" rotation="0.10577001990274736"></floor> <entity x="19" y="152.23499999999999" width="3" height="3" type="coin"></entity> <entity x="28" y="151.98499999999999" width="3" height="3" type="coin"></entity> <entity x="23" y="144.48499999999999" width="3" height="3" type="coin"></entity> <entity x="28.25" y="144.23499999999999" width="3" height="3" type="coin"></entity> <entity x="26.75" y="135.73499999999999" width="3" height="3" type="coin"></entity> <entity x="43.5" y="214.23499999999999" width="3" height="3" type="coin"></entity> <entity x="42.75" y="189.48499999999999" width="3" height="3" type="snow"></entity> <entity x="692.65" y="175.73499999999999" width="3" height="3" type="snow"></entity> <entity x="692.4" y="204.73499999999999" width="3" height="3" type="coin"></entity> <entity x="708.2149999999999" y="153.65" width="3" height="3" type="coin"></entity> <entity x="719.4649999999999" y="153.4" width="3" height="3" type="coin"></entity> <entity x="707.9649999999999" y="145.65" width="3" height="3" type="coin"></entity> <entity x="716.2149999999999" y="145.65" width="3" height="3" type="coin"></entity> <entity x="708.2149999999999" y="137.65" width="3" height="3" type="coin"></entity> <entity x="714.7149999999999" y="137.4" width="3" height="3" type="coin"></entity> <entity x="514.29" y="270.96500000000003" width="3" height="3" type="coin"></entity> <entity x="221.975" y="272.46500000000003" width="3" height="3" type="coin"></entity> <entity x="391.53499999999997" y="230.465" width="3" height="3" type="coin"></entity> <entity x="347.03499999999997" y="230.465" width="3" height="3" type="coin"></entity> <entity x="382.78499999999997" y="214.965" width="3" height="3" type="coin"></entity> <entity x="354.53499999999997" y="213.965" width="3" height="3" type="coin"></entity> <entity x="367.78499999999997" y="188.715" width="3" height="3" type="coin"></entity> <entity x="367.28499999999997" y="170.465" width="3" height="3" type="coin"></entity> <entity x="382.03499999999997" y="169.965" width="3" height="3" type="snow"></entity> <entity x="350.53499999999997" y="170.715" width="3" height="3" type="snow"></entity> <start x="287.645" y="284.33000000000004"></start></root>"; public static var Cost:int = 200; } }//package src.levels
Section 162
//Child (src.Objects.Child) package src.Objects { import flash.display.*; import src.*; import Box2D.Common.Math.*; import Box2D.Dynamics.*; import Box2D.Collision.Shapes.*; import flash.geom.*; import flash.media.*; import flash.utils.*; public class Child { private var m_world:b2World; private var ContactNum:uint; var DrawingSurface:MovieClip; private var PlayerCar:Car; private var TimerID:uint; var childB:b2Body; private var Child1StartPos:Number; private var Child2StartPos:Number; private var Child3StartPos:Number; private var Child4StartPos:Number; private var Child5StartPos:Number; private var Active:Boolean;// = true var childS:b2Shape; var ChildMov:MovieClip; var childBd:b2BodyDef; private static var ST:SoundTransform = new SoundTransform(0.8); private static var CheckPointSound:checkpoint_sound; public function Child(_arg1:b2World, _arg2:MovieClip, _arg3:Car, _arg4:Number, _arg5:Number){ var _local6:b2PolygonDef; childBd = new b2BodyDef(); ChildMov = new ChildMovie(); Active = true; super(); m_world = _arg1; PlayerCar = _arg3; _local6 = new b2PolygonDef(); _local6.SetAsBox((100 / CarGame.m_physScale), (30 / CarGame.m_physScale)); _local6.isSensor = true; childBd.position.Set(_arg4, _arg5); childB = _arg1.CreateBody(childBd); childS = childB.CreateShape(_local6); childB.SetMassFromShapes(); DrawingSurface = _arg2; DrawingSurface.addChild(ChildMov); childS.SetUserData(this); ChildMov.x = (childB.GetPosition().x * Main.ScaleMultiplier); ChildMov.y = (childB.GetPosition().y * Main.ScaleMultiplier); Child1StartPos = ChildMov.child_1.x; Child2StartPos = ChildMov.child_2.x; Child3StartPos = ChildMov.child_3.x; Child4StartPos = ChildMov.child_4.x; Child5StartPos = ChildMov.child_5.x; } function FollowCar(){ } function ChildFollowPoint(_arg1:MovieClip, _arg2:Number, _arg3:Number=2){ if (_arg2 > _arg1.x){ _arg1.x = (_arg1.x + _arg3); return; }; if (_arg2 < _arg1.x){ _arg1.x = (_arg1.x - _arg3); }; } public function Update(){ var _local1:Number; if ((((ContactNum > 0)) && ((TimerID == 0)))){ FollowCar(); _local1 = PlayerCar.CarBody.GetLinearVelocity().x; if ((((_local1 > -0.2)) && ((_local1 < 0.2)))){ trace("Settimer"); if (TimerID == 0){ TimerID = setTimeout(AddCheckpoint, 1500); }; GroupWithCar(); } else { trace("run"); RunFromCar(); clearTimeout(TimerID); TimerID = 0; }; } else { ReturnToOriginalPos(); }; } public function RemoveContact(){ ContactNum--; if (ContactNum == 0){ clearTimeout(TimerID); TimerID = 0; }; } public function AddContact(){ ContactNum++; } public function Destroy(){ DrawingSurface.removeChild(ChildMov); clearTimeout(TimerID); } public function GetActive():Boolean{ return (Active); } public function Draw(){ } function RunFromCar(){ var _local1:Point; var _local2:Point; var _local3:Point; _local1 = new Point(PlayerCar.GetCarSpriteX(), 0); _local2 = ChildMov.parent.localToGlobal(_local1); _local3 = ChildMov.globalToLocal(_local2); ChildFollowPoint(ChildMov.child_1, ((_local3.x + 20) + (Math.random() * 2)), 4); ChildFollowPoint(ChildMov.child_2, ((_local3.x + 55) + (Math.random() * 2)), 4); ChildFollowPoint(ChildMov.child_3, ((_local3.x - 50) + (Math.random() * 2)), 4); ChildFollowPoint(ChildMov.child_4, ((_local3.x - 25) + (Math.random() * 2)), 4); ChildFollowPoint(ChildMov.child_5, (_local3.x + (Math.random() * 2)), 4); } function AddCheckpoint(){ trace("add checkpoint"); PlayerCar.CollectedCheckpoints++; childB.DestroyShape(childS); m_world.DestroyBody(childB); Child.PlayCheckpointSound(); Active = false; } function GroupWithCar(){ var _local1:Point; var _local2:Point; var _local3:Point; _local1 = new Point(PlayerCar.GetCarSpriteX(), 0); _local2 = ChildMov.parent.localToGlobal(_local1); _local3 = ChildMov.globalToLocal(_local2); trace(("GroupWithCar " + _local3.x)); ChildFollowPoint(ChildMov.child_1, (_local3.x + (Math.random() * 2)), 1); ChildFollowPoint(ChildMov.child_2, (_local3.x + (Math.random() * 2)), 1); ChildFollowPoint(ChildMov.child_3, (_local3.x + (Math.random() * 2)), 1); ChildFollowPoint(ChildMov.child_4, (_local3.x + (Math.random() * 2)), 1); ChildFollowPoint(ChildMov.child_5, (_local3.x + (Math.random() * 2)), 1); } function ReturnToOriginalPos(){ ChildFollowPoint(ChildMov.child_1, (Child1StartPos + (Math.random() * 10))); ChildFollowPoint(ChildMov.child_2, (Child2StartPos + (Math.random() * 10))); ChildFollowPoint(ChildMov.child_3, (Child3StartPos + (Math.random() * 10))); ChildFollowPoint(ChildMov.child_4, (Child4StartPos + (Math.random() * 10))); ChildFollowPoint(ChildMov.child_5, (Child5StartPos + (Math.random() * 10))); } public function GetPosition():b2Vec2{ return (childB.GetWorldCenter()); } static function PlayCheckpointSound(){ if (CheckPointSound == null){ CheckPointSound = new checkpoint_sound(); }; CheckPointSound.play(0, 1); } } }//package src.Objects
Section 163
//CoinObject (src.Objects.CoinObject) package src.Objects { import flash.display.*; import src.*; import Box2D.Dynamics.*; import Box2D.Collision.Shapes.*; import flash.media.*; public class CoinObject { private var m_world:b2World; private var WasHit:Boolean; var DrawingSurface:MovieClip; var coinB:b2Body; var CoinSprite:coinsprite; var coinS:b2Shape; var coinBd:b2BodyDef; private var GameEngine:CarGame; private var Destroyed:Boolean;// = false private static var ST:SoundTransform = new SoundTransform(0.7); private static var CoinSound:coin_sound; public function CoinObject(_arg1:b2World, _arg2:MovieClip, _arg3:CarGame, _arg4:Number, _arg5:Number){ var _local6:b2CircleDef; coinBd = new b2BodyDef(); CoinSprite = new coinsprite(); Destroyed = false; super(); GameEngine = _arg3; m_world = _arg1; _local6 = new b2CircleDef(); _local6.radius = (60 / CarGame.m_physScale); _local6.isSensor = true; coinBd.position.Set(_arg4, _arg5); coinB = _arg1.CreateBody(coinBd); coinS = coinB.CreateShape(_local6); coinB.SetMassFromShapes(); DrawingSurface = _arg2; DrawingSurface.addChild(CoinSprite); coinS.SetUserData(this); CoinSprite.x = (coinB.GetPosition().x * Main.ScaleMultiplier); CoinSprite.y = (coinB.GetPosition().y * Main.ScaleMultiplier); } public function Hit(){ if (!WasHit){ WasHit = true; GameEngine.AddScore(50); CoinObject.PlayCoinSound(); coinB.DestroyShape(coinS); m_world.DestroyBody(coinB); Destroy(); }; } public function Destroy(){ if (!Destroyed){ Destroyed = true; DrawingSurface.removeChild(CoinSprite); }; } public function Draw(){ } public function Update(){ } static function PlayCoinSound(){ if (CoinSound == null){ CoinSound = new coin_sound(); }; CoinSound.play(0, 1); } } }//package src.Objects
Section 164
//live (src.Objects.live) package src.Objects { import flash.display.*; import src.*; import Box2D.Dynamics.*; import Box2D.Collision.Shapes.*; import flash.media.*; public class live { private var m_world:b2World; private var WasHit:Boolean; var coinB:b2Body; var DrawingSurface:MovieClip; var coinS:b2Shape; var LiveSprite:livesprite; private var GameEngine:CarGame; private var Destroyed:Boolean;// = false var coinBd:b2BodyDef; private static var ST:SoundTransform = new SoundTransform(0.7); private static var CoinSound:coin_sound; public function live(_arg1:b2World, _arg2:MovieClip, _arg3:CarGame, _arg4:Number, _arg5:Number){ var _local6:b2CircleDef; coinBd = new b2BodyDef(); LiveSprite = new livesprite(); Destroyed = false; super(); GameEngine = _arg3; m_world = _arg1; _local6 = new b2CircleDef(); _local6.radius = (60 / CarGame.m_physScale); _local6.isSensor = true; coinBd.position.Set(_arg4, _arg5); coinB = _arg1.CreateBody(coinBd); coinS = coinB.CreateShape(_local6); coinB.SetMassFromShapes(); DrawingSurface = _arg2; DrawingSurface.addChild(LiveSprite); coinS.SetUserData(this); LiveSprite.x = (coinB.GetPosition().x * Main.ScaleMultiplier); LiveSprite.y = (coinB.GetPosition().y * Main.ScaleMultiplier); } public function Hit(){ if (!WasHit){ WasHit = true; GameEngine.AddLive(1); CoinObject.PlayCoinSound(); coinB.DestroyShape(coinS); m_world.DestroyBody(coinB); Destroy(); }; } public function Destroy(){ if (!Destroyed){ Destroyed = true; DrawingSurface.removeChild(LiveSprite); }; } public function Draw(){ } public function Update(){ } static function PlayCoinSound(){ if (CoinSound == null){ CoinSound = new coin_sound(); }; CoinSound.play(0, 1); } } }//package src.Objects
Section 165
//SnowObject (src.Objects.SnowObject) package src.Objects { import flash.display.*; import src.*; import Box2D.Dynamics.*; import Box2D.Collision.Shapes.*; import flash.media.*; public class SnowObject { private var m_world:b2World; private var WasHit:Boolean; var DrawingSurface:MovieClip; var coinB:b2Body; var CoinSprite:snow; var coinS:b2Shape; var coinBd:b2BodyDef; private var GameEngine:CarGame; private var Destroyed:Boolean;// = false private static var ST:SoundTransform = new SoundTransform(0.7); private static var SnowSound:snow_sound; public function SnowObject(_arg1:b2World, _arg2:MovieClip, _arg3:CarGame, _arg4:Number, _arg5:Number){ var _local6:b2CircleDef; coinBd = new b2BodyDef(); CoinSprite = new snow(); Destroyed = false; super(); GameEngine = _arg3; m_world = _arg1; _local6 = new b2CircleDef(); _local6.radius = (60 / CarGame.m_physScale); _local6.isSensor = true; coinBd.position.Set(_arg4, _arg5); coinB = _arg1.CreateBody(coinBd); coinS = coinB.CreateShape(_local6); coinB.SetMassFromShapes(); DrawingSurface = _arg2; Draw(); coinS.SetUserData(this); CoinSprite.x = (coinB.GetPosition().x * Main.ScaleMultiplier); CoinSprite.y = (coinB.GetPosition().y * Main.ScaleMultiplier); DrawingSurface.addChild(CoinSprite); } public function Hit(){ if (!WasHit){ WasHit = true; GameEngine.AddTime(10); coinB.DestroyShape(coinS); m_world.DestroyBody(coinB); SnowObject.PlaySnowSound(); Destroy(); }; } public function Destroy(){ if (!Destroyed){ DrawingSurface.removeChild(CoinSprite); Destroyed = true; }; } public function Draw(){ } public function Update(){ } static function PlaySnowSound(){ if (SnowSound == null){ SnowSound = new snow_sound(); }; SnowSound.play(0, 1); } } }//package src.Objects
Section 166
//ObjectPreloader (src.Preloader.ObjectPreloader) package src.Preloader { import flash.display.*; import flash.events.*; import flash.net.*; public class ObjectPreloader { var Complete:Boolean;// = false var ContentLoader:Loader; public function ObjectPreloader(){ Complete = false; ContentLoader = new Loader(); super(); ContentLoader.contentLoaderInfo.addEventListener(Event.COMPLETE, LoadComplete); } public function Load(_arg1:URLRequest){ trace(("load " + _arg1.url)); ContentLoader.load(_arg1); } public function IsComplete():Boolean{ return (Complete); } function LoadComplete(_arg1:Event){ Complete = true; } } }//package src.Preloader
Section 167
//Preloader (src.Preloader.Preloader) package src.Preloader { import flash.display.*; import src.*; import flash.events.*; import flash.net.*; import flash.text.*; import flash.system.*; public dynamic class Preloader extends MovieClip { public var intro_btn:SimpleButton; var LoaderList:Array; public var mc_menu:Menu; var URLoaderList:Array; public var dtf_loading:TextField; public function Preloader(){ URLoaderList = new Array(); LoaderList = new Array(); super(); addFrameScript(0, frame1, 1, frame2, 137, frame138); this.dtf_loading.text = String("0"); LoadFlashVars(); LoadExternalFiles(); this.addEventListener(Event.ENTER_FRAME, FrameFunc); } function LoadExternalFiles(){ } function GetLoadingPercents():int{ var _local1:int; var _local2:int; var _local3:int; var _local4:URLPreloader; var _local5:ObjectPreloader; _local2 = stage.loaderInfo.bytesTotal; _local3 = stage.loaderInfo.bytesLoaded; _local1 = 0; while (_local1 < URLoaderList.length) { _local4 = URLoaderList[_local1]; if (_local4.ContentLoader.bytesTotal == 0){ return (0); }; _local2 = (_local2 + _local4.ContentLoader.bytesTotal); _local3 = (_local3 + _local4.ContentLoader.bytesLoaded); _local1++; }; _local1 = 0; while (_local1 < LoaderList.length) { _local5 = LoaderList[_local1]; if (_local5.ContentLoader.contentLoaderInfo.bytesTotal == 0){ return (0); }; _local2 = (_local2 + _local5.ContentLoader.contentLoaderInfo.bytesTotal); _local3 = (_local3 + _local5.ContentLoader.contentLoaderInfo.bytesLoaded); _local1++; }; trace(("totalLoadedBytes " + _local3)); trace(("totalBytes " + _local2)); return (int(((100 * _local3) / _local2))); } function frame1(){ stop(); } function LoadingComplete():Boolean{ var _local1:int; if (stage.loaderInfo.bytesTotal != stage.loaderInfo.bytesLoaded){ return (false); }; _local1 = 0; while (_local1 < URLoaderList.length) { if (!URLoaderList[_local1].IsComplete()){ return (false); }; _local1++; }; _local1 = 0; while (_local1 < LoaderList.length) { if (!LoaderList[_local1].IsComplete()){ return (false); }; _local1++; }; return (true); } function frame2(){ intro_btn.addEventListener(MouseEvent.CLICK, Click); } public function Click(_arg1:Event){ navigateToURL(new URLRequest("http://www.twilightgamer.com/track.php?id=2"), "_blank"); } function FrameFunc(_arg1:Event){ var _local2:int; if (LoadingComplete()){ this.removeEventListener(Event.ENTER_FRAME, FrameFunc); play(); } else { _local2 = GetLoadingPercents(); this.dtf_loading.text = String(_local2); }; } function frame138(){ mc_menu.ShowStart(); stop(); } function LoadFlashVars(){ } } }//package src.Preloader
Section 168
//URLPreloader (src.Preloader.URLPreloader) package src.Preloader { import flash.events.*; import flash.net.*; public class URLPreloader { public var ContentLoader:URLLoader; var _Owner:Preloader; var Complete:Boolean;// = false public function URLPreloader(_arg1:Preloader){ ContentLoader = new URLLoader(); Complete = false; super(); _Owner = _arg1; ContentLoader.addEventListener(Event.COMPLETE, LoadComplete); ContentLoader.addEventListener(IOErrorEvent.IO_ERROR, onError); } public function IsComplete():Boolean{ return (Complete); } function onError(_arg1:IOErrorEvent){ (_Owner.mc_debug as TextArea).appendText(("\nonError! " + _arg1.errorID)); } function LoadComplete(_arg1:Event){ Complete = true; } } }//package src.Preloader
Section 169
//BContactListener (src.BContactListener) package src { import Box2D.Dynamics.*; import Box2D.Collision.Shapes.*; import Box2D.Dynamics.Joints.*; import Box2D.Collision.*; import Box2D.Common.*; import Box2D.Dynamics.Contacts.*; import src.Objects.*; public class BContactListener extends b2ContactListener { override public function Persist(_arg1:b2ContactPoint):void{ var _local2:*; var _local3:*; _local2 = _arg1.shape1.GetUserData(); _local3 = _arg1.shape2.GetUserData(); } override public function Add(_arg1:b2ContactPoint):void{ var _local2:*; var _local3:*; _local2 = _arg1.shape1.GetUserData(); _local3 = _arg1.shape2.GetUserData(); if ((((((_local2 is CoinObject)) || ((_local2 is SnowObject)))) || ((_local2 is live)))){ _local2.Hit(); return; }; if ((((((_local3 is CoinObject)) || ((_local3 is SnowObject)))) || ((_local3 is live)))){ _local3.Hit(); return; }; if ((((_local2 is Child)) && ((_local3 is Car)))){ _local2.AddContact(); return; }; if ((((_local3 is Child)) && ((_local2 is Car)))){ _local3.AddContact(); return; }; if ((((((_local2 is Car)) && (_arg1.shape1.IsSensor()))) && ((_local3 is CarGame)))){ _local2.SetCrashed(); }; if ((((((_local3 is Car)) && (_arg1.shape2.IsSensor()))) && ((_local2 is CarGame)))){ _local3.SetCrashed(); }; } override public function Remove(_arg1:b2ContactPoint):void{ var _local2:*; var _local3:*; _local2 = _arg1.shape1.GetUserData(); _local3 = _arg1.shape2.GetUserData(); if ((((_local2 is Child)) && ((_local3 is Car)))){ _local2.RemoveContact(); }; if ((((_local3 is Child)) && ((_local2 is Car)))){ _local3.RemoveContact(); }; } override public function Result(_arg1:b2ContactResult):void{ var _local2:*; var _local3:*; _local2 = _arg1.shape1.GetUserData(); _local3 = _arg1.shape2.GetUserData(); if ((_local2 is Suspension)){ _local2.setContacted(true); }; if ((_local3 is Suspension)){ _local3.setContacted(true); }; if ((((_local2 is Car)) && ((_local3 is CarGame)))){ _local2.SetHitResulted(_arg1.normalImpulse); }; if ((((_local3 is Car)) && ((_local2 is CarGame)))){ _local3.SetHitResulted(_arg1.normalImpulse); }; } } }//package src
Section 170
//BikeBody (src.BikeBody) package src { import flash.display.*; import flash.geom.*; public class BikeBody extends MovieClip { var Vehicle:Car; public var OwnerGame:CarGame; public var body_mc:MovieClip; public var m_BikeColor:String;// = "0xFF00FF" public var bike_mc:MovieClip; public var m_Color:String;// = "0x0000FF" public function BikeBody(_arg1:String, _arg2:String){ m_Color = "0x0000FF"; m_BikeColor = "0xFF00FF"; super(); addFrameScript(0, frame1, 20, frame21, 40, frame41, 62, frame63, 82, frame83, 103, frame104, 123, frame124, 144, frame145, 163, frame164, 184, frame185, 204, frame205, 225, frame226, 245, frame246, 246, frame247, 271, frame272); m_Color = _arg1; m_BikeColor = _arg2; trace(("m_Color " + m_Color)); } function frame272(){ OwnerGame.m_MainMovie.ResetCar(); } function frame164(){ gotoAndStop(1); SetReadyForNextTrick(); } function frame205(){ gotoAndStop(1); SetReadyForNextTrick(); } public function PlayTrick(_arg1:int){ switch (_arg1){ case 1: this.gotoAndPlay("trick1"); break; case 2: this.gotoAndPlay("trick2"); break; case 3: this.gotoAndPlay("trick3"); break; case 4: this.gotoAndPlay("trick4"); break; case 5: this.gotoAndPlay("trick5"); break; case 6: this.gotoAndPlay("trick6"); break; }; } function frame226(){ this.CheckIfStop(); } function frame185(){ this.CheckIfStop(); } function frame21(){ this.CheckIfStop(); } function frame1(){ stop(); } function SetReadyForNextTrick(){ Vehicle.CurrentTrick = 0; } public function SetVehicle(_arg1:Car){ Vehicle = _arg1; OwnerGame = Vehicle.OwnerGame; } function frame104(){ this.CheckIfStop(); } public function ColorBody(){ var _local1:ColorTransform; if (body_mc != null){ _local1 = new ColorTransform(); _local1.color = m_Color; trace(("Color " + m_Color)); body_mc.color_mc.transform.colorTransform = _local1; }; } function frame246(){ gotoAndStop(1); SetReadyForNextTrick(); } function frame247(){ SendDestroySuspensionCommand(); } function frame83(){ gotoAndStop(1); SetReadyForNextTrick(); } function frame124(){ gotoAndStop(1); SetReadyForNextTrick(); } function frame41(){ gotoAndStop(1); SetReadyForNextTrick(); } public function FinalizeTrick(){ if (currentFrame > 1){ this.play(); }; } function SendDestroySuspensionCommand(){ OwnerGame.IceCreamTruck.DestroySuspension(); } public function PlayBadLanding(){ this.gotoAndPlay("crash"); } public function CheckIfStop(){ if (((Vehicle) && ((Vehicle.CurrentTrick > 0)))){ stop(); }; } public function ColorBike(){ var _local1:ColorTransform; if (bike_mc != null){ _local1 = new ColorTransform(); _local1.color = m_BikeColor; trace(("Color " + m_Color)); bike_mc.color_mc.transform.colorTransform = _local1; }; } function frame145(){ this.CheckIfStop(); } function frame63(){ this.CheckIfStop(); } } }//package src
Section 171
//BikerRagDoll (src.BikerRagDoll) package src { import flash.display.*; import Box2D.Common.Math.*; import Box2D.Dynamics.*; import Box2D.Collision.Shapes.*; import Box2D.Dynamics.Joints.*; import Box2D.Collision.*; import Box2D.Common.*; import Box2D.Dynamics.Contacts.*; public class BikerRagDoll { public var Body:b2Body; public var Plecho:b2Body; var HandShape:b2Shape; var m_OwnerGame:CarGame; var BodyMovie:RagdollBody; public var Hand:b2Body; public var Shin:b2Body; var PlechoShape:b2Shape; var m_DrawingSurface:MovieClip; var BodyDef:b2CircleDef; var ShinShape:b2Shape; public var Hip:b2Body; var HipShape:b2Shape; var m_World:b2World; var BodyShape:b2Shape; public function BikerRagDoll(_arg1:CarGame, _arg2:MovieClip, _arg3:Number, _arg4:Number){ var _local5:b2BodyDef; BodyDef = new b2CircleDef(); BodyMovie = new RagdollBody(); super(); m_World = _arg1.m_world; m_OwnerGame = _arg1; m_DrawingSurface = _arg2; m_DrawingSurface.addChild(BodyMovie); BodyDef.filter.groupIndex = 2; BodyDef.radius = (55 / CarGame.m_physScale); BodyDef.density = 10; BodyDef.filter.groupIndex = -1; BodyDef.userData = BodyMovie; _local5 = new b2BodyDef(); _local5.position.Set(_arg3, _arg4); _local5.linearDamping = 0.05; Body = _arg1.m_world.CreateBody(_local5); BodyShape = Body.CreateShape(BodyDef); Body.SetMassFromShapes(); trace(("m_OwnerGame.IceCreamTruck.GetTotalSpeed() " + m_OwnerGame.IceCreamTruck.GetTotalSpeed())); if (m_OwnerGame.IceCreamTruck.LeftDirection){ BodyMovie.scaleX = 1; } else { BodyMovie.scaleX = -1; }; Body.SetLinearVelocity(new b2Vec2(m_OwnerGame.IceCreamTruck.CarBody.GetLinearVelocity().x, 0)); Body.SetAngularVelocity((m_OwnerGame.IceCreamTruck.CarBody.GetLinearVelocity().x / 5)); } public function Destroy(){ m_World.DestroyBody(Body); m_DrawingSurface.removeChild(BodyMovie); } public function Update(){ var _local1:int; _local1 = Main.ScaleMultiplier; BodyDef.userData.x = (Body.GetPosition().x * _local1); BodyDef.userData.y = (Body.GetPosition().y * _local1); BodyDef.userData.rotation = (Body.GetAngle() * (180 / Math.PI)); } } }//package src
Section 172
//BikeUpgrade (src.BikeUpgrade) package src { import fl.controls.*; import flash.display.*; import flash.events.*; import flash.geom.*; import flash.text.*; public class BikeUpgrade extends MovieClip { const MaxUpgrade:int = 3; const NotEnoughMoney:String = "YOU HAVE NOT ENOUGH MONEY TO PUrCHaSE THIS UPGRadE!"; const UpgradeBikeFirst:String = "YOU SHOULD UPGRADE YOUR BIKE To PuRchAse ThiS UPgRade!"; const BikeCost:int = 1000; const UpgradeCost:int = 200; public var BikeLevel:int;// = 0 public var weight_btn:SimpleButton; public var not_enough_mc:MovieClip; public var engine_dtf:TextField; public var Engine:int;// = 0 public var are_you_sure_mc:MovieClip; public var aero_btn:SimpleButton; public var bike_color_mc:ColorPicker; public var Weight:int;// = 0 public var engine_mc:MovieClip; var BikeUpgradeType:int;// = 1 public var weight_mc:MovieClip; public var engine_btn:SimpleButton; var PlayerInfoS:PlayerInfo; public var body1_mc:MovieClip; public var next_btn:SimpleButton; public var aero_mc:MovieClip; public var bike_1:MovieClip; public var bike_2:MovieClip; public var bike_3:MovieClip; var UpgradeType:int;// = 0 public var body2_mc:MovieClip; public var Aero:int;// = 0 public var player_color_mc:ColorPicker; public var weight_dtf:TextField; public var bike_sel_2:SimpleButton; public var bike_sel_3:SimpleButton; public var bike_sel_1:MovieClip; public var body3_mc:MovieClip; public var aero_dtf:TextField; public var player_money_dtf:TextField; public function BikeUpgrade(){ Engine = 0; Aero = 0; Weight = 0; BikeLevel = 0; UpgradeType = 0; BikeUpgradeType = 1; super(); not_enough_mc.visible = false; are_you_sure_mc.visible = false; engine_btn.addEventListener(MouseEvent.CLICK, EngineBtnClick); aero_btn.addEventListener(MouseEvent.CLICK, AeroBtnClick); weight_btn.addEventListener(MouseEvent.CLICK, WeightBtnClick); are_you_sure_mc.cancel_btn.addEventListener(MouseEvent.CLICK, HideAreYouSure); are_you_sure_mc.ok_btn.addEventListener(MouseEvent.CLICK, ApplyUpgrade); not_enough_mc.ok_btn.addEventListener(MouseEvent.CLICK, HideNotEnough); bike_2.mouseEnabled = false; bike_2.mouseChildren = false; body2_mc.mouseEnabled = false; body2_mc.mouseChildren = false; bike_3.mouseEnabled = false; bike_3.mouseChildren = false; body3_mc.mouseEnabled = false; body3_mc.mouseChildren = false; bike_sel_2.addEventListener(MouseEvent.CLICK, UpgradeBike2); bike_sel_3.addEventListener(MouseEvent.CLICK, UpgradeBike3); player_color_mc.addEventListener(Event.CHANGE, ChangeColor); bike_color_mc.addEventListener(Event.CHANGE, ChangeColor); ChangeColor(null); } function RefreshBikes(){ var _local1:ColorTransform; var _local2:ColorTransform; _local1 = new ColorTransform(); _local1.color = 0x111111; _local1.alphaMultiplier = 0.5; _local2 = new ColorTransform(); _local2.alphaMultiplier = 0; switch (BikeLevel){ case 0: bike_1.transform.colorTransform = new ColorTransform(); body1_mc.transform.colorTransform = new ColorTransform(); bike_2.transform.colorTransform = new ColorTransform(); body2_mc.transform.colorTransform = new ColorTransform(); bike_3.transform.colorTransform = new ColorTransform(); body3_mc.transform.colorTransform = new ColorTransform(); bike_sel_1.visible = true; bike_sel_2.transform.colorTransform = _local2; bike_sel_3.transform.colorTransform = _local2; break; case 1: bike_1.transform.colorTransform = _local1; body1_mc.transform.colorTransform = _local1; bike_sel_1.visible = false; bike_sel_2.transform.colorTransform = new ColorTransform(); bike_sel_3.transform.colorTransform = _local2; break; case 2: bike_1.transform.colorTransform = _local1; body1_mc.transform.colorTransform = _local1; bike_2.transform.colorTransform = _local1; body2_mc.transform.colorTransform = _local1; bike_sel_1.visible = false; bike_sel_2.transform.colorTransform = _local2; bike_sel_3.transform.colorTransform = new ColorTransform(); break; }; } function HideNotEnough(_arg1:Event){ not_enough_mc.visible = false; } function HideAreYouSure(_arg1:Event){ are_you_sure_mc.visible = false; } function ApplyUpgrade(_arg1:Event){ switch (UpgradeType){ case 1: Engine++; switch (Engine){ case 1: engine_mc.gotoAndPlay("to_level_1"); break; case 2: engine_mc.gotoAndPlay("to_level_2"); break; case 3: engine_mc.gotoAndPlay("to_level_3"); break; }; PlayerInfoS.AddScore(-(UpgradeCost)); break; case 2: Aero++; switch (Aero){ case 1: aero_mc.gotoAndPlay("to_level_1"); break; case 2: aero_mc.gotoAndPlay("to_level_2"); break; case 3: aero_mc.gotoAndPlay("to_level_3"); break; }; PlayerInfoS.AddScore(-(UpgradeCost)); break; case 3: Weight++; switch (Weight){ case 1: weight_mc.gotoAndPlay("to_level_1"); break; case 2: weight_mc.gotoAndPlay("to_level_2"); break; case 3: weight_mc.gotoAndPlay("to_level_3"); break; }; PlayerInfoS.AddScore(-(UpgradeCost)); break; case 4: BikeLevel = BikeUpgradeType; if (BikeUpgradeType == 1){ PlayerInfoS.AddScore(-(BikeCost)); } else { PlayerInfoS.AddScore((-2 * BikeCost)); }; break; }; UpgradeType = 0; RefreshIndicators(); RefreshBikes(); are_you_sure_mc.visible = false; } function EngineBtnClick(_arg1:Event){ if (Engine < MaxUpgrade){ if (BikeLevel >= Engine){ if (PlayerInfoS.GetScore() >= UpgradeCost){ UpgradeType = 1; ApplyUpgrade(null); } else { not_enough_mc.text_dtf.text = NotEnoughMoney; not_enough_mc.visible = true; }; } else { not_enough_mc.text_dtf.text = UpgradeBikeFirst; not_enough_mc.visible = true; }; }; } public function Show(_arg1:int, _arg2:int, _arg3:int, _arg4:int, _arg5:PlayerInfo){ PlayerInfoS = _arg5; Engine = _arg1; Aero = _arg2; BikeLevel = _arg4; Weight = _arg3; switch (Engine){ case 0: engine_mc.gotoAndStop("0level"); break; case 1: engine_mc.gotoAndStop("1level"); break; case 2: engine_mc.gotoAndStop("2level"); break; case 3: engine_mc.gotoAndStop("max"); break; }; switch (Aero){ case 0: aero_mc.gotoAndStop("0level"); break; case 1: aero_mc.gotoAndStop("1level"); break; case 2: aero_mc.gotoAndStop("2level"); break; case 3: aero_mc.gotoAndStop("max"); break; }; switch (Weight){ case 0: weight_mc.gotoAndStop("0level"); break; case 1: weight_mc.gotoAndStop("1level"); break; case 2: weight_mc.gotoAndStop("2level"); break; case 3: weight_mc.gotoAndStop("max"); break; }; RefreshIndicators(); RefreshBikes(); this.visible = true; } function AeroBtnClick(_arg1:Event){ if (Aero < MaxUpgrade){ if (BikeLevel >= Aero){ if (PlayerInfoS.GetScore() >= UpgradeCost){ UpgradeType = 2; ApplyUpgrade(null); } else { not_enough_mc.text_dtf.text = NotEnoughMoney; not_enough_mc.visible = true; }; } else { not_enough_mc.text_dtf.text = UpgradeBikeFirst; not_enough_mc.visible = true; }; }; } function WeightBtnClick(_arg1:Event){ if (Weight < MaxUpgrade){ if (BikeLevel >= Weight){ if (PlayerInfoS.GetScore() >= UpgradeCost){ UpgradeType = 3; ApplyUpgrade(null); } else { not_enough_mc.text_dtf.text = NotEnoughMoney; not_enough_mc.visible = true; }; } else { not_enough_mc.text_dtf.text = UpgradeBikeFirst; not_enough_mc.visible = true; }; }; } function RefreshIndicators(){ player_money_dtf.text = ("MONEY: $" + PlayerInfoS.GetScore()); if (Engine < MaxUpgrade){ engine_dtf.text = ("$" + UpgradeCost); } else { engine_dtf.text = "MAX LEVEL"; }; if (Aero < MaxUpgrade){ aero_dtf.text = ("$" + UpgradeCost); } else { aero_dtf.text = "MAX LEVEL"; }; if (Weight < MaxUpgrade){ weight_dtf.text = ("$" + UpgradeCost); } else { weight_dtf.text = "MAX LEVEL"; }; } function ChangeColor(_arg1:Event){ var _local2:ColorTransform; var _local3:ColorTransform; _local2 = new ColorTransform(); _local2.color = ("0x" + player_color_mc.hexValue); body1_mc.color_mc.transform.colorTransform = _local2; body2_mc.color_mc.transform.colorTransform = _local2; body3_mc.color_mc.transform.colorTransform = _local2; _local3 = new ColorTransform(); _local3.color = ("0x" + bike_color_mc.hexValue); bike_1.color_mc.transform.colorTransform = _local3; bike_2.color_mc.transform.colorTransform = _local3; bike_3.color_mc.transform.colorTransform = _local3; } function UpgradeBike2(_arg1:Event){ if (BikeLevel < 1){ if (PlayerInfoS.GetScore() >= BikeCost){ UpgradeType = 4; BikeUpgradeType = 1; are_you_sure_mc.text_dtf.text = (("ARE YOU SURE WANT TO PURCHASE THIS BIKE?\nIT COSTS $" + BikeCost) + "!"); are_you_sure_mc.visible = true; } else { not_enough_mc.text_dtf.text = "YoU Have NOT EnoUgH\nmONeY to\nPurCHAse tHiS BIKE!"; not_enough_mc.visible = true; }; }; } function UpgradeBike3(_arg1:Event){ if (BikeLevel < 2){ if (PlayerInfoS.GetScore() >= (2 * BikeCost)){ UpgradeType = 4; BikeUpgradeType = 2; are_you_sure_mc.text_dtf.text = (("ARE YOU SURE WANT TO PURCHASE THIS BIKE?\nIT COSTS $" + (2 * BikeCost)) + "!"); are_you_sure_mc.visible = true; } else { not_enough_mc.text_dtf.text = "YoU Have NOT EnoUgH\nmONeY to\nPurCHAse tHiS BIKE!"; not_enough_mc.visible = true; }; }; } } }//package src
Section 173
//Car (src.Car) package src { import flash.display.*; import Box2D.Common.Math.*; import Box2D.Dynamics.*; import Box2D.Collision.Shapes.*; import Box2D.Dynamics.Joints.*; import Box2D.Collision.*; import Box2D.Common.*; import Box2D.Dynamics.Contacts.*; import flash.utils.*; import General.*; public class Car { private const MaxLandingCheckLen:int = 5; public var CollectedCheckpoints:uint;// = 0 var m_MainMovie:MovieClip; var Dead:Boolean; public var FrontWheelMovie:BikeWheel; var BodyMovie:BikeBody; var BikerShape:b2Shape; private var EngineTorque:Number;// = 8000 var DeathIntervalID:uint; var LeftDirection:Boolean;// = false var ForwardFlips:int; public var OwnerGame:CarGame; public var CurrentPower:int;// = 1 private var LastBodyAngle:Number;// = 0 var BikerRagDoll1:BikerRagDoll; var RearSuspension:Suspension; private var TotalRotation:Number;// = 0 private var BodyHitImpulse:Number;// = 0 private var EngineMaxSpeed:Number;// = -50 private var RotationTorque:Number;// = 10000 var CarShape:b2Shape; var FramesInAir:int;// = 0 var FrontSuspension:Suspension; private var OverallLevel:int;// = 0 private var LandingCheckFrames:int; var BodyDef:b2PolygonDef; var TrickArray:Array; private var LastFrameWasInAir:Boolean;// = true public var RearWheelMovie:BikeWheel; public var CurrentTrick:int;// = 0 public var CarBody:b2Body; var Backflips:int; public function Car(_arg1:CarGame, _arg2:MovieClip, _arg3:Number, _arg4:Number, _arg5:String, _arg6:String){ var _local7:b2CircleDef; var _local8:b2BodyDef; var _local9:b2MassData; CollectedCheckpoints = 0; BodyDef = new b2PolygonDef(); FrontSuspension = new Suspension(); RearSuspension = new Suspension(); LeftDirection = false; FrontWheelMovie = new BikeWheel(); RearWheelMovie = new BikeWheel(); BodyHitImpulse = 0; EngineTorque = 8000; EngineMaxSpeed = -50; RotationTorque = 10000; OverallLevel = 0; LastFrameWasInAir = true; LastBodyAngle = 0; TotalRotation = 0; CurrentTrick = 0; CurrentPower = 1; FramesInAir = 0; TrickArray = new Array(); super(); OwnerGame = _arg1; m_MainMovie = _arg2; BodyMovie = new BikeBody(_arg5, _arg6); BodyMovie.SetVehicle(this); BodyMovie.scaleX = 0.27; BodyMovie.scaleY = 0.27; BodyDef.filter.groupIndex = 2; BodyDef.SetAsOrientedBox((75 / CarGame.m_physScale), (30 / CarGame.m_physScale)); BodyDef.density = 10; BodyDef.filter.groupIndex = -1; BodyDef.userData = BodyMovie; _local7 = new b2CircleDef(); _local7.isSensor = true; _local7.radius = (50 / CarGame.m_physScale); _local7.localPosition = new b2Vec2(0, -2); _local8 = new b2BodyDef(); _local8.position.Set(_arg3, (_arg4 - 0.5)); _local8.linearDamping = 0.05; CarBody = OwnerGame.m_world.CreateBody(_local8); CarShape = CarBody.CreateShape(BodyDef); CarShape.SetUserData(this); BikerShape = CarBody.CreateShape(_local7); BikerShape.SetUserData(this); _local9 = new b2MassData(); _local9.center = new b2Vec2(0, 1.25); _local9.I = 500; _local9.mass = 40; CarBody.SetMass(_local9); CarBody.AllowSleeping(false); FrontSuspension.Create(OwnerGame.m_world, CarBody, FrontWheelMovie, (_arg3 + 2.33333), _arg4); RearSuspension.Create(OwnerGame.m_world, CarBody, RearWheelMovie, (_arg3 - 2.33333), _arg4); trace(("CarBody.GetMass() " + CarBody.GetMass())); m_MainMovie.addChild(BodyMovie); m_MainMovie.addChild(FrontWheelMovie); m_MainMovie.addChild(RearWheelMovie); Draw(); SoundEffects.StartEngineLoop(); } public function GetCarSpriteX():Number{ return (BodyDef.userData.x); } public function BodyHitWorld():Boolean{ return ((BodyHitImpulse > 0)); } public function UpdateControlInput(){ var _local1:Boolean; var _local2:Boolean; var _local3:Boolean; var _local4:Boolean; var _local5:Boolean; var _local6:Suspension; var _local7:Suspension; var _local8:Boolean; var _local9:Boolean; var _local10:Number; var _local11:Boolean; var _local12:Number; var _local13:Number; _local1 = Input.isKeyDown(37); _local2 = Input.isKeyDown(39); _local3 = Input.isKeyDown(32); _local4 = Input.isKeyDown(38); _local5 = Input.isKeyDown(40); _local6 = FrontSuspension; _local7 = RearSuspension; if (!Dead){ CarBody.m_angularDamping = 0.3; if (((((!(RearSuspension.getContacted())) && (!(FrontSuspension.getContacted())))) && (!(BodyHitWorld())))){ _local10 = Math.abs((RearSuspension.GetWheelRotation() / 150)); if (LeftDirection){ _local12 = RotationTorque; } else { _local12 = RotationTorque; }; if (CurrentTrick > 0){ CarBody.m_angularDamping = 3; } else { if (((_local2) || (_local1))){ if (_local2){ CarBody.ApplyTorque(_local12); }; if (_local1){ CarBody.ApplyTorque(-(_local12)); }; CarBody.m_angularDamping = 5; }; }; if (_local5){ CarBody.ApplyForce(new b2Vec2((-(RotationTorque) / 7), 0), CarBody.GetWorldPoint(new b2Vec2(0, 0))); }; if (_local4){ CarBody.ApplyForce(new b2Vec2((RotationTorque / 7), 0), CarBody.GetWorldPoint(new b2Vec2(0, 0))); }; } else { if (CarBody.GetLinearVelocity().x < -6){ LeftDirection = true; }; if (CarBody.GetLinearVelocity().x > 6){ LeftDirection = false; }; if (((_local5) || (_local4))){ if (LeftDirection){ _local13 = -(EngineMaxSpeed); _local6 = RearSuspension; _local7 = FrontSuspension; if (_local5){ _local8 = true; }; if (_local4){ _local9 = true; }; } else { _local13 = EngineMaxSpeed; _local6 = FrontSuspension; _local7 = RearSuspension; if (_local5){ _local9 = true; }; if (_local4){ _local8 = true; }; }; if (_local8){ _local6.FreeWheels(); _local7.Axle.EnableMotor(true); _local7.Axle.SetMaxMotorTorque((EngineTorque + (CurrentPower * 1000))); _local7.Axle.SetMotorSpeed(_local13); _local10 = Math.abs((_local7.GetWheelRotation() / 150)); smoke.CurrentAlpha = Math.abs((0.6 - Math.abs((_local7.GetWheelRotation() / 70)))); }; if (_local9){ _local7.Stops(_local13); _local6.Stops(_local13); }; if (_local11){ _local6.FreeWheels(); _local7.Axle.EnableMotor(true); _local7.Axle.SetMaxMotorTorque((EngineTorque * 0.5)); _local7.Axle.SetMotorSpeed(-(_local13)); _local10 = Math.abs((_local7.GetWheelRotation() / 150)); smoke.CurrentAlpha = Math.abs((0.6 - Math.abs((_local7.GetWheelRotation() / 70)))); }; } else { RearSuspension.FreeWheels(); FrontSuspension.FreeWheels(); smoke.CurrentAlpha = 0.1; _local10 = 0.1; }; SoundEffects.SetEngineVolume(_local10); }; }; } public function SetHitResulted(_arg1:Number){ BodyHitImpulse = _arg1; } public function SetOverallLevel(_arg1:int){ OverallLevel = _arg1; FrontSuspension.SetShockLevel(_arg1); RearSuspension.SetShockLevel(_arg1); } public function GetTotalSpeed():Number{ return (Math.sqrt(((CarBody.GetLinearVelocity().x * CarBody.GetLinearVelocity().x) + (CarBody.GetLinearVelocity().y * CarBody.GetLinearVelocity().y)))); } public function GetCenter():b2Vec2{ return (CarBody.GetWorldCenter()); } public function SetAeroLevel(_arg1:int){ switch (_arg1){ case 1: default: RotationTorque = (12000 + (OverallLevel * 5000)); break; case 2: RotationTorque = (16000 + (OverallLevel * 5500)); break; case 3: RotationTorque = (20000 + (OverallLevel * 6000)); break; }; } function UpdateTricks(){ var _local1:Number; if (LastFrameWasInAir){ if (((((RearSuspension.getContacted()) || (FrontSuspension.getContacted()))) || (BodyHitWorld()))){ if (CurrentTrick != 0){ CurrentTrick = 0; TrickArray.splice(0, TrickArray.length); SetCrashed(); }; if (LandingCheckFrames == MaxLandingCheckLen){ if (((RearSuspension.getContacted()) && (FrontSuspension.getContacted()))){ if ((((FramesInAir > 100)) && ((CurrentPower < 5)))){ CurrentPower++; }; }; }; if (LandingCheckFrames > 0){ LandingCheckFrames--; } else { if (BodyHitWorld()){ CurrentPower = 1; CurrentTrick = 0; TrickArray.splice(0, TrickArray.length); OwnerGame.FailedTricks(); LastFrameWasInAir = false; SoundEffects.PlayCrowdBooSound(); } else { trace("contact"); trace(("TotalRotation " + TotalRotation)); OwnerGame.SetTricks(TrickArray, Backflips, ForwardFlips); LastFrameWasInAir = false; }; }; } else { trace("in air"); trace((" CarBody.GetAngle() " + CarBody.GetAngle())); trace((" LastBodyAngle " + LastBodyAngle)); _local1 = (CarBody.GetAngle() - LastBodyAngle); TotalRotation = (TotalRotation + _local1); if (TotalRotation > ((2 * Math.PI) - 0.523598776)){ if (!LeftDirection){ ForwardFlips++; OwnerGame.SetRotationTrick(ForwardFlips); } else { Backflips++; OwnerGame.SetRotationTrick(-(Backflips)); }; TotalRotation = -0.523598776; }; if (TotalRotation < ((-2 * Math.PI) + 0.523598776)){ if (LeftDirection){ ForwardFlips++; OwnerGame.SetRotationTrick(ForwardFlips); } else { Backflips++; OwnerGame.SetRotationTrick(-(Backflips)); }; TotalRotation = 0.523598776; }; trace(("TotalRotation " + TotalRotation)); LastBodyAngle = CarBody.GetAngle(); LandingCheckFrames = MaxLandingCheckLen; LastFrameWasInAir = true; FramesInAir++; if (CurrentTrick == 0){ if (Input.isKeyDown(90)){ CurrentTrick = 1; BodyMovie.PlayTrick(CurrentTrick); SoundEffects.PlayTrickSound(1); TrickArray.push(new Trick(1)); OwnerGame.SetTrick(new Trick(1)); } else { if (Input.isKeyDown(88)){ CurrentTrick = 2; BodyMovie.PlayTrick(CurrentTrick); SoundEffects.PlayTrickSound(2); TrickArray.push(new Trick(2)); OwnerGame.SetTrick(new Trick(2)); } else { if (Input.isKeyDown(67)){ CurrentTrick = 3; BodyMovie.PlayTrick(CurrentTrick); SoundEffects.PlayTrickSound(3); TrickArray.push(new Trick(3)); OwnerGame.SetTrick(new Trick(3)); } else { if (Input.isKeyDown(86)){ CurrentTrick = 4; BodyMovie.PlayTrick(CurrentTrick); SoundEffects.PlayTrickSound(4); TrickArray.push(new Trick(4)); OwnerGame.SetTrick(new Trick(4)); } else { if (Input.isKeyDown(66)){ CurrentTrick = 5; BodyMovie.PlayTrick(CurrentTrick); SoundEffects.PlayTrickSound(5); TrickArray.push(new Trick(5)); OwnerGame.SetTrick(new Trick(5)); } else { if (Input.isKeyDown(78)){ CurrentTrick = 6; BodyMovie.PlayTrick(CurrentTrick); SoundEffects.PlayTrickSound(6); TrickArray.push(new Trick(6)); OwnerGame.SetTrick(new Trick(6)); }; }; }; }; }; }; } else { if (CurrentTrick == 1){ if (Input.isKeyDown(90)){ CurrentTrick = 1; } else { CurrentTrick = -1; BodyMovie.FinalizeTrick(); }; }; if (CurrentTrick == 2){ if (Input.isKeyDown(88)){ CurrentTrick = 2; } else { CurrentTrick = -1; BodyMovie.FinalizeTrick(); }; }; if (CurrentTrick == 3){ if (Input.isKeyDown(67)){ CurrentTrick = 3; } else { CurrentTrick = -1; BodyMovie.FinalizeTrick(); }; }; if (CurrentTrick == 4){ if (Input.isKeyDown(86)){ CurrentTrick = 4; } else { CurrentTrick = -1; BodyMovie.FinalizeTrick(); }; }; if (CurrentTrick == 5){ if (Input.isKeyDown(66)){ CurrentTrick = 5; } else { CurrentTrick = -1; BodyMovie.FinalizeTrick(); }; }; if (CurrentTrick == 6){ if (Input.isKeyDown(78)){ CurrentTrick = 6; } else { CurrentTrick = -1; BodyMovie.FinalizeTrick(); }; }; }; }; } else { if (((((!(RearSuspension.getContacted())) && (!(FrontSuspension.getContacted())))) && (!(BodyHitWorld())))){ trace("liftoff"); LastBodyAngle = CarBody.GetAngle(); LastBodyAngle = ((2 * Math.PI) * Math.round((CarBody.GetAngle() / (2 * Math.PI)))); trace(("LastBodyAngle " + ((LastBodyAngle * 180) / Math.PI))); trace((" LeftDirection " + LeftDirection)); if (CarBody.GetLinearVelocity().y < -6){ SoundEffects.PlayCrowdCheerSound(); OwnerGame.m_MainMovie.StartFlashes(); }; TotalRotation = 0; FramesInAir = 0; LandingCheckFrames = MaxLandingCheckLen; LastFrameWasInAir = true; } else { LastFrameWasInAir = false; OwnerGame.SetTricks(TrickArray, Backflips, ForwardFlips); Backflips = 0; ForwardFlips = 0; TrickArray.splice(0, TrickArray.length); }; }; } public function SetShocksLevel(_arg1:int){ var _local2:b2MassData; _local2 = new b2MassData(); _local2.center = new b2Vec2(0, 1.25); switch (_arg1){ case 2: _local2.I = 450; _local2.mass = 35; break; case 3: _local2.I = 350; _local2.mass = 30; break; default: _local2.I = 500; _local2.mass = 40; break; }; CarBody.SetMass(_local2); } public function Destroy(){ clearTimeout(DeathIntervalID); DeathIntervalID = 0; if (FrontSuspension != null){ FrontSuspension.Destroy(); }; if (RearSuspension != null){ RearSuspension.Destroy(); }; OwnerGame.m_world.DestroyBody(CarBody); if (FrontWheelMovie != null){ m_MainMovie.removeChild(FrontWheelMovie); FrontWheelMovie = null; }; if (RearWheelMovie != null){ m_MainMovie.removeChild(RearWheelMovie); RearWheelMovie = null; }; m_MainMovie.removeChild(BodyMovie); SoundEffects.EndEngineLoop(); if (BikerRagDoll1 != null){ BikerRagDoll1.Destroy(); }; } function BodyIsUpsideDown():Boolean{ var _local1:Number; if ((((CarBody.GetLinearVelocity().y < 1)) && ((CarBody.GetLinearVelocity().y > -1)))){ _local1 = (CarBody.GetAngle() * (180 / Math.PI)); if (_local1 > 360){ _local1 = (_local1 - (360 * int((_local1 / 360)))); }; if (_local1 < -360){ _local1 = (_local1 - (360 * int((_local1 / 360)))); }; if ((((((_local1 < 270)) && ((_local1 > 90)))) || ((((_local1 > -270)) && ((_local1 < -90)))))){ return (true); }; }; return (false); } public function SetPowerLevel(_arg1:int){ trace(("Power :" + _arg1)); switch (_arg1){ case 1: default: EngineTorque = (700 + (OverallLevel * 500)); EngineMaxSpeed = (-85 + (OverallLevel * 20)); break; case 2: EngineTorque = (1600 + (OverallLevel * 600)); EngineMaxSpeed = (-110 + (OverallLevel * 20)); break; case 3: EngineTorque = (2500 + (OverallLevel * 800)); EngineMaxSpeed = (-125 + (OverallLevel * 20)); break; }; trace(("EngineTorque " + EngineTorque)); trace(("EngineMaxSpeed " + EngineMaxSpeed)); } public function SetCrashed(){ if (!Dead){ OwnerGame.LastCrashPos = CarBody.GetWorldCenter(); SoundEffects.PlayCrowdBooSound(); SoundEffects.PlayHitSound(1); CarBody.DestroyShape(BikerShape); BodyMovie.PlayBadLanding(); Dead = true; }; } function SetDead(){ trace("Dead"); clearTimeout(DeathIntervalID); SetCrashed(); } public function Update():void{ if (!Dead){ UpdateTricks(); FrontSuspension.Update(false); RearSuspension.Update(false); if (BodyIsUpsideDown()){ if (DeathIntervalID == 0){ DeathIntervalID = setTimeout(SetDead, 3000); }; } else { clearTimeout(DeathIntervalID); DeathIntervalID = 0; }; if (BodyHitImpulse > 0){ SoundEffects.PlayHitSound((BodyHitImpulse / 4000)); trace(("BodyHitImpulse " + BodyHitImpulse)); }; BodyHitImpulse = 0; } else { if (BikerRagDoll1 == null){ BikerRagDoll1 = new BikerRagDoll(OwnerGame, m_MainMovie, OwnerGame.LastCrashPos.x, OwnerGame.LastCrashPos.y); }; }; } public function Draw(){ var _local1:int; var _local2:Number; var _local3:b2Vec2; if (!Dead){ FrontSuspension.Draw(); RearSuspension.Draw(); }; _local1 = Main.ScaleMultiplier; BodyDef.userData.x = (CarBody.GetPosition().x * Main.ScaleMultiplier); BodyDef.userData.y = (CarBody.GetPosition().y * Main.ScaleMultiplier); BodyDef.userData.rotation = (CarBody.GetAngle() * (180 / Math.PI)); if (LeftDirection){ BodyDef.userData.scaleX = -0.27; } else { BodyDef.userData.scaleX = 0.27; }; if (LeftDirection){ _local3 = CarBody.GetWorldPoint(new b2Vec2(3.3, 0)); } else { _local3 = CarBody.GetWorldPoint(new b2Vec2(-3.3, 0)); }; if (BikerRagDoll1 != null){ BikerRagDoll1.Update(); }; } public function DestroySuspension(){ RearSuspension.Destroy(); RearSuspension = null; FrontSuspension.Destroy(); FrontSuspension = null; m_MainMovie.removeChild(FrontWheelMovie); FrontWheelMovie = null; m_MainMovie.removeChild(RearWheelMovie); RearWheelMovie = null; } } }//package src
Section 174
//CarGame (src.CarGame) package src { import flash.display.*; import Box2D.Common.Math.*; import flash.events.*; import Box2D.Dynamics.*; import Box2D.Collision.Shapes.*; import Box2D.Dynamics.Joints.*; import Box2D.Collision.*; import Box2D.Common.*; import Box2D.Dynamics.Contacts.*; import flash.media.*; import flash.utils.*; import src.Objects.*; public class CarGame { public var LastCrashPos:b2Vec2; public var m_MainMovie:MovieClip; protected var ObjectList:Array; public var LevelReady:Boolean; protected var FreezeTime:int;// = 1 private var ArrowBody:b2Body; public var LeftEnd:int;// = 50 private var CheckpointsTotal:uint;// = 0 public var RightEnd:int;// = 850 public var m_world:b2World; public var IceCreamTruck:Car; public var m_timeStep:Number;// = 0.02 public var m_iterations:int;// = 100 protected var SC:SoundChannel; public var m_sprite:Sprite; protected var PlayerInfoSurface:MovieClip; public var stageEndType:int;// = 0 protected var MainTimer:Timer; private var CheckpointList:Array; public var Timeleft:uint;// = 120 protected var FreezetimeTimerID:uint; public static var m_physScale:Number = 30; public function CarGame(_arg1:Main){ var _local2:b2AABB; var _local3:b2Vec2; var _local4:Boolean; var _local5:BContactListener; var _local6:b2CircleDef; var _local7:b2BodyDef; var _local8:b2RevoluteJointDef; LeftEnd = 50; RightEnd = 850; m_iterations = 100; m_timeStep = (1 / 50); Timeleft = 120; stageEndType = 0; ObjectList = new Array(); CheckpointsTotal = 0; CheckpointList = new Array(); FreezeTime = 1; MainTimer = new Timer(1000); super(); m_MainMovie = _arg1; _local2 = new b2AABB(); _local2.lowerBound.Set(-2000, -2000); _local2.upperBound.Set(2000, 2000); _local3 = new b2Vec2(0, 25); _local4 = true; m_world = new b2World(_local2, _local3, _local4); _local5 = new BContactListener(); m_world.SetContactListener(_local5); _local6 = new b2CircleDef(); _local6.radius = 1; _local6.filter.groupIndex = -1; _local6.density = 60; _local7 = new b2BodyDef(); _local7.position.Set(0, -980); _local7.angularDamping = 2; ArrowBody = m_world.CreateBody(_local7); ArrowBody.CreateShape(_local6).SetUserData(this); ArrowBody.SetMassFromShapes(); _local8 = new b2RevoluteJointDef(); _local8.Initialize(m_world.GetGroundBody(), ArrowBody, new b2Vec2(0, -980)); _local8.enableMotor = false; m_world.CreateJoint(_local8); Music = new theme_sound(); SC = Music.play(0, 600000); MainTimer.addEventListener(TimerEvent.TIMER, MainTimerFunc); } public function AddLive(_arg1:int){ PlayerInfoSurface.addLive(_arg1); } public function LoadMap(_arg1:String){ var _local2:XML; var _local3:int; var _local4:b2PolygonDef; var _local5:b2BodyDef; var _local6:b2Body; var _local7:*; var _local8:CoinObject; var _local9:SnowObject; var _local10:live; _local2 = XML(_arg1); trace(_local2); _local3 = 0; while (_local3 < _local2.floor.length()) { _local4 = new b2PolygonDef(); _local4.friction = 0.9; _local4.restitution = 0; _local5 = new b2BodyDef(); _local5.position.Set(_local2.floor[_local3].@x, _local2.floor[_local3].@y); _local5.angle = _local2.floor[_local3].@rotation; _local4.SetAsBox((_local2.floor[_local3].@width / 2), (_local2.floor[_local3].@height / 2)); _local6 = m_world.CreateBody(_local5); _local6.CreateShape(_local4).SetUserData(this); _local6.SetMassFromShapes(); _local3++; }; IceCreamTruck = new Car(this, m_sprite, _local2.start[0].@x, _local2.start[0].@y, m_MainMovie.BikerColor, m_MainMovie.BikeColor); _local3 = 0; while (_local3 < _local2.entity.length()) { _local7 = _local2.entity[_local3]; switch (String(_local7.@type)){ case "coin": _local8 = new CoinObject(m_world, m_sprite, this, _local7.@x, _local7.@y); ObjectList.push(_local8); break; case "snow": _local9 = new SnowObject(m_world, m_sprite, this, _local7.@x, _local7.@y); ObjectList.push(_local9); break; case "live": _local10 = new live(m_world, m_sprite, this, _local7.@x, _local7.@y); ObjectList.push(_local10); break; }; _local3++; }; LevelReady = true; StartGameTimer(); PlayerInfoSurface.SetTotalCheckpoints(CheckpointsTotal); PlayerInfoSurface.ResetLives(); } public function AddScore(_arg1:int){ PlayerInfoSurface.AddScore(_arg1); } public function GameOver(){ MainTimer.stop(); this.LevelReady = false; Clear(); m_MainMovie.StageEnded(); } public function ResetCar(){ IceCreamTruck.Destroy(); IceCreamTruck = new Car(this, m_sprite, LastCrashPos.x, (LastCrashPos.y - 5), m_MainMovie.BikerColor, m_MainMovie.BikeColor); } public function SetDrawSurface(_arg1:MovieClip){ m_sprite = _arg1; } public function Clear(){ if (SC != null){ SC.stop(); }; IceCreamTruck.Destroy(); DestroyObjList(); } public function SetTrick(_arg1:Trick){ var _local2:String; _local2 = ""; m_MainMovie.StartFlashes(); switch (_arg1.Type){ case 1: _local2 = (_local2 + "THE FLYING MAN\n"); break; case 2: _local2 = (_local2 + "DRAGONFLY\n"); break; case 3: _local2 = (_local2 + "KAMIKAZEE\n"); break; case 4: _local2 = (_local2 + "PRAYING MAN\n"); break; case 5: _local2 = (_local2 + "PEPSI RUN\n"); break; case 6: _local2 = (_local2 + "UGLY DUCKLYN\n"); break; }; if (_local2.length > 1){ PlayerInfoSurface.SetTrick(_local2); }; } function FailedTricks(){ PlayerInfoSurface.SetTrick("Bad landing!"); } private function ShowStageIsCleared(){ MainTimer.stop(); this.LevelReady = false; this.m_MainMovie.parent.ShowStageIsCleared(); } public function MyUpdate():void{ var _local1:int; var _local2:int; if (LevelReady){ _local2 = 0; while (_local2 < 2) { IceCreamTruck.Update(); _local1 = 0; while (_local1 < ObjectList.length) { ObjectList[_local1].Update(); _local1++; }; UpdatePointingArrow(); m_world.Step(m_timeStep, m_iterations); _local2++; }; if (IceCreamTruck.GetCenter().x < LeftEnd){ IceCreamTruck.CarBody.ApplyForce(new b2Vec2(((LeftEnd - IceCreamTruck.GetCenter().x) * 700), 0), IceCreamTruck.CarBody.GetWorldPoint(new b2Vec2(8, 0))); PlayerInfoSurface.BackLeftVisible(true); } else { PlayerInfoSurface.BackLeftVisible(false); }; if (IceCreamTruck.GetCenter().x > RightEnd){ IceCreamTruck.CarBody.ApplyForce(new b2Vec2(((RightEnd - IceCreamTruck.GetCenter().x) * 700), 0), IceCreamTruck.CarBody.GetWorldPoint(new b2Vec2(-8, 0))); PlayerInfoSurface.BackRightVisible(true); } else { PlayerInfoSurface.BackRightVisible(false); }; IceCreamTruck.Draw(); _local1 = 0; while (_local1 < ObjectList.length) { ObjectList[_local1].Draw(); _local1++; }; PlayerInfoSurface.SetPower(IceCreamTruck.CurrentPower); (PlayerInfoSurface.arrow_mc as MovieClip).rotation = (ArrowBody.GetAngle() * (180 / Math.PI)); PlayerInfoSurface.SetNewTimeleft(Timeleft); }; } function FreezeTimer(){ if (FreezeTime > 0){ FreezeTime--; } else { clearInterval(FreezetimeTimerID); MainTimer.start(); }; } function StartGameTimer(){ FreezetimeTimerID = setInterval(FreezeTimer, 1000); } public function SetRotationTrick(_arg1:Number){ if (_arg1 < 0){ PlayerInfoSurface.SetTrick((-(_arg1) + "x BACKFLIP!")); } else { PlayerInfoSurface.SetTrick((_arg1 + "x FORWARDFLIP!")); }; } public function SetPlayerInfoSurface(_arg1:MovieClip){ PlayerInfoSurface = _arg1; PlayerInfoSurface.SetNewTimeleft(Timeleft); PlayerInfoSurface.ResetForNewStage(); } private function MainTimerFunc(_arg1:TimerEvent){ Timeleft--; if (Timeleft <= 0){ stageEndType = 0; GameOver(); }; } public function SetTricks(_arg1:Array, _arg2:int, _arg3:int){ var _local4:int; var _local5:int; var _local6:String; var _local7:int; var _local8:int; var _local9:int; var _local10:int; var _local11:int; var _local12:int; var _local13:int; var _local14:int; var _local15:int; var _local16:int; var _local17:int; var _local18:Trick; _local4 = 10; _local5 = 5; _local6 = ""; _local7 = -1; _local8 = 0; _local9 = 0; _local10 = -1; _local11 = 0; _local12 = 0; _local13 = 0; _local14 = 0; _local15 = 0; _local16 = 0; _local17 = 0; while (_local17 < _arg1.length) { _local18 = _arg1[_local17]; switch (_local18.Type){ case 1: if (((!((_local10 == 1))) && ((_local11 == 0)))){ _local7++; } else { _local8++; }; _local11++; break; case 2: if (((!((_local10 == 2))) && ((_local12 == 0)))){ _local7++; } else { _local8++; }; _local12++; break; case 3: if (((!((_local10 == 3))) && ((_local13 == 0)))){ _local7++; } else { _local8++; }; _local13++; break; case 4: if (((!((_local10 == 4))) && ((_local14 == 0)))){ _local7++; } else { _local8++; }; _local14++; break; case 5: if (((!((_local10 == 5))) && ((_local15 == 0)))){ _local7++; } else { _local8++; }; _local15++; break; case 6: if (((!((_local10 == 6))) && ((_local16 == 0)))){ _local7++; } else { _local8++; }; _local16++; break; }; _local10 = _local18.Type; _local17++; }; if (_arg3 > 0){ _local6 = (_local6 + (("FORWARD FLIP " + _arg3) + "x\n")); _local9 = (_local9 + (Math.pow(2, _arg3) * _local5)); }; if (_arg2 > 0){ _local6 = (_local6 + (("BACKWARD FLIP " + _arg2) + "x\n")); _local9 = (_local9 + (Math.pow(2, _arg2) * _local5)); }; if (_local7 > 0){ _local7++; _local6 = (_local6 + (_local7 + "x combo!\n")); _local9 = (_local9 + (Math.pow(2, _local7) * _local4)); } else { if (_local7 == 0){ _local8++; }; }; _local9 = (_local9 + (_local4 * _local8)); if (_local8 > 0){ _local6 = (_local6 + (_local8 + " tricks\n")); }; if (_local9 > 0){ _local6 = (_local6 + (("Total: $" + _local9) + "!\n")); }; PlayerInfoSurface.AddScore(_local9); if (_local6.length > 0){ PlayerInfoSurface.SetTrick(_local6); }; } public function AddTime(_arg1:int){ Timeleft = (Timeleft + _arg1); PlayerInfoSurface.SetNewTimeleft(Timeleft); } private function UpdatePointingArrow(){ var _local1:Child; var _local2:int; var _local3:b2Vec2; var _local4:b2Vec2; var _local5:b2Vec2; if (CheckpointList.length > 0){ _local2 = 0; while (_local2 < CheckpointList.length) { _local1 = CheckpointList[_local2]; if (_local1.GetActive()){ _local3 = IceCreamTruck.CarBody.GetWorldPoint(new b2Vec2(0, -5)); _local4 = _local1.GetPosition(); _local5 = new b2Vec2(); _local5.x = (_local4.x - _local3.x); _local5.y = (_local4.y - _local3.y); ArrowBody.ApplyForce(_local5, ArrowBody.GetWorldPoint(new b2Vec2(200, 0))); break; }; _local2++; }; }; } public function UpdateControlInput(){ if (FreezeTime == 0){ IceCreamTruck.UpdateControlInput(); }; } public function DestroyObjList(){ var _local1:*; while (ObjectList.length > 0) { _local1 = ObjectList.pop(); _local1.Destroy(); _local1 = null; }; MainTimer.stop(); } public function SetTuningParams(_arg1:int, _arg2:int, _arg3:int, _arg4:int){ IceCreamTruck.SetOverallLevel(_arg4); IceCreamTruck.SetPowerLevel(_arg2); IceCreamTruck.SetShocksLevel(_arg3); IceCreamTruck.SetAeroLevel(_arg1); } } }//package src
Section 175
//Main (src.Main) package src { import flash.display.*; import Box2D.Common.Math.*; import flash.events.*; import Box2D.Dynamics.*; import Box2D.Collision.Shapes.*; import Box2D.Dynamics.Joints.*; import Box2D.Collision.*; import Box2D.Dynamics.Contacts.*; import src.levels.*; import flash.text.*; import General.*; public class Main extends MovieClip { public var BikeLevel:int; private var Active:Boolean;// = false private var TargetScale:Number;// = 1.6 private var LastScale:Number;// = 1 public var BikerColor:String;// = "" public var m_currTest:CarGame; public var EngineLevel:int; var BGFlashingFrame:int;// = 0 public var AeroLevel:int; private var BackgroundMovie:MovieClip; public var mc_bg:MovieClip; public var draw_area_mc:MovieClip; var CurrentLevel:Level; public var playerinfo_mc:PlayerInfo; private var LevelUnderlayMovie:MovieClip; public var ShocksLevel:int; public var BikeColor:String;// = "" public static const ScaleMultiplier:int = 5; public static var TotalScale:Number = 0.3; public static var m_sprite:Sprite; public static var Inputs:Input; public function Main(){ BikerColor = ""; BikeColor = ""; LastScale = 1; TargetScale = 1.6; Active = false; BGFlashingFrame = 0; super(); addFrameScript(0, frame1); addEventListener(Event.ENTER_FRAME, update, false, 0, true); Main.Inputs = new Input(this); this.stage.scaleMode = StageScaleMode.NO_SCALE; } public function StartFlashes(){ BGFlashingFrame = 60; } public function LoadLevel(_arg1:Level, _arg2:int, _arg3:int, _arg4:int, _arg5:int, _arg6:int){ trace(("BikerColor " + BikerColor)); trace(("_PowerLevel " + _arg3)); trace(("_ShocksLevel " + _arg4)); trace(("_AeroLevel " + _arg5)); trace(("_BikeLevel " + _arg6)); CurrentLevel = _arg1; m_currTest = new CarGame(this); m_currTest.SetDrawSurface(this.draw_area_mc.mc_cararea); m_currTest.SetPlayerInfoSurface(this.playerinfo_mc); m_currTest.LoadMap(_arg1.SourceXML); m_currTest.LeftEnd = _arg1.LeftEnd; m_currTest.RightEnd = _arg1.RightEnd; trace(CurrentLevel); AeroLevel = _arg5; EngineLevel = _arg3; ShocksLevel = _arg4; BikeLevel = _arg6; m_currTest.SetTuningParams(AeroLevel, EngineLevel, ShocksLevel, BikeLevel); draw_area_mc.mc_cararea.mc_level.level_1.visible = false; draw_area_mc.mc_cararea.mc_level.level_2.visible = false; draw_area_mc.mc_cararea.mc_level.level_3.visible = false; draw_area_mc.mc_cararea.mc_level.level_4.visible = false; draw_area_mc.mc_cararea.mc_level.level_5.visible = false; draw_area_mc.mc_cararea.mc_level.level_6.visible = false; draw_area_mc.mc_cararea.mc_level.level_7.visible = false; draw_area_mc.mc_cararea.mc_level.double_ramp_mc.visible = false; trace(("LevelIndex " + _arg2)); switch (_arg2){ case 0: draw_area_mc.mc_cararea.mc_level.level_1.visible = true; break; case 1: draw_area_mc.mc_cararea.mc_level.level_2.visible = true; break; case 2: draw_area_mc.mc_cararea.mc_level.level_3.visible = true; break; case 3: draw_area_mc.mc_cararea.mc_level.level_5.visible = true; break; case 4: draw_area_mc.mc_cararea.mc_level.level_4.visible = true; break; case 7: draw_area_mc.mc_cararea.mc_level.level_6.visible = true; break; case 5: draw_area_mc.mc_cararea.mc_level.level_7.visible = true; break; case 6: draw_area_mc.mc_cararea.mc_level.double_ramp_mc.visible = true; break; }; } public function ResetCar(){ if (this.playerinfo_mc.DecreaseLives() > 0){ m_currTest.ResetCar(); m_currTest.SetTuningParams(AeroLevel, EngineLevel, ShocksLevel, BikeLevel); } else { m_currTest.stageEndType = 1; m_currTest.GameOver(); }; } public function SearchMovies(){ var _local1:int; var _local2:MovieClip; _local1 = 0; while (_local1 < this.numChildren) { if ((this.getChildAt(_local1) is MovieClip)){ _local2 = this.getChildAt(_local1); switch (_local2.name){ case "mc_level": LevelUnderlayMovie = _local2; break; case "mc_bg": BackgroundMovie = _local2; break; }; }; _local1++; }; } function frame1(){ stop(); } public function StageEnded(){ CurrentLevel.Completed = true; if (this.parent.PlayerCanJoinNextLevel()){ this.parent.ShowStageCleared(m_currTest.stageEndType); } else { this.parent.ShowGameOver(); }; } public function Start(){ this.visible = true; Active = true; } function ResetGame(){ trace("Reset"); Reset = false; if (m_currTest){ m_currTest = null; }; mc_gameover.visible = false; } public function update(_arg1:Event):void{ var _local2:Number; var _local3:Number; if (((!((m_currTest == null))) && (Active))){ if (((!(LevelUnderlayMovie)) || (!(BackgroundMovie)))){ SearchMovies(); }; if (m_currTest.LevelReady){ _local2 = m_currTest.IceCreamTruck.GetTotalSpeed(); if (m_currTest.IceCreamTruck.CurrentTrick > 0){ TargetScale = 3.8; } else { TargetScale = 1.6; }; _local3 = (LastScale + ((TargetScale - LastScale) * 0.06)); if (((((LastScale - _local3) > 0.001)) || (((LastScale - _local3) < -0.001)))){ LastScale = _local3; Main.TotalScale = _local3; if (Main.TotalScale < 0.1){ Main.TotalScale = 0.1; }; draw_area_mc.scaleX = Main.TotalScale; draw_area_mc.scaleY = Main.TotalScale; }; draw_area_mc.mc_cararea.scaleX = 1; draw_area_mc.mc_cararea.scaleY = 1; draw_area_mc.mc_cararea.x = (-(m_currTest.IceCreamTruck.GetCenter().x) * Main.ScaleMultiplier); draw_area_mc.mc_cararea.y = (-(m_currTest.IceCreamTruck.GetCenter().y) * Main.ScaleMultiplier); draw_area_mc.mc_cararea.mc_level.scaleX = 1; draw_area_mc.mc_cararea.mc_level.scaleY = draw_area_mc.mc_cararea.mc_level.scaleX; draw_area_mc.y = ((m_currTest.IceCreamTruck.GetCenter().y * 2) - 250); BackgroundMovie.x = (((-(m_currTest.IceCreamTruck.GetCenter().x) * Main.ScaleMultiplier) / 2) - 200); BackgroundMovie.y = (((-(m_currTest.IceCreamTruck.GetCenter().y) * Main.ScaleMultiplier) / 3) + 270); if (BGFlashingFrame > 0){ if (BGFlashingFrame > (Math.random() * 100)){ BackgroundMovie.gotoAndPlay(1); BackgroundMovie.mc_flash1.x = (Math.random() * 3000); BackgroundMovie.mc_flash1.y = ((Math.random() * 150) + 220); BackgroundMovie.mc_flash1.play(); BackgroundMovie.mc_flash2.x = (Math.random() * 3000); BackgroundMovie.mc_flash2.y = ((Math.random() * 150) + 220); BackgroundMovie.mc_flash2.play(); BackgroundMovie.mc_flash3.x = (Math.random() * 3000); BackgroundMovie.mc_flash3.y = ((Math.random() * 150) + 220); BackgroundMovie.mc_flash3.play(); }; BGFlashingFrame--; }; m_currTest.UpdateControlInput(); m_currTest.MyUpdate(); }; }; Input.update(); } } }//package src
Section 176
//Menu (src.Menu) package src { import fl.controls.*; import flash.display.*; import flash.events.*; import flash.net.*; import src.levels.*; import mochi.as3.*; public dynamic class Menu extends MovieClip { private const MaxLevel:uint = 8; private const StartingMoney:int = 1000; public var sound_btn:SoundBtn; public var GameField_mc:Main; public var score_mc:ScoreWindow; public var instructions_mc:MovieClip; private var o:Object; public var LevelArray:Array; public var bg_menu_mc:MovieClip; public var stagecleared_mc:MovieClip; public var mc_startpage:MovieClip; var PracticeMode:Boolean; public var gameover_mc:MovieClip; public var levelselect_mc:MovieClip; public var bike_upgrade_mc:BikeUpgrade; private var CurrentLevel:uint; public function Menu(){ var _local1:int; var _local2:Level; var _local3:MovieClip; o = {n:[7, 11, 0, 3, 9, 14, 13, 12, 10, 10, 12, 10, 14, 11, 8, 3], f:function (_arg1:Number, _arg2:String):String{ if (_arg2.length == 16){ return (_arg2); }; return (this.f((_arg1 + 1), (_arg2 + this.n[_arg1].toString(16)))); }}; LevelArray = new Array(); super(); addFrameScript(0, frame1); MochiServices.connect("1c52c70c9e53d987", this.score_mc); _local1 = 0; while (_local1 < MaxLevel) { _local2 = new Level(); switch (_local1){ case 0: _local2.Cost = 100; _local2.SourceXML = level_1.SourceXML; break; case 1: _local2.Cost = 200; _local2.SourceXML = level_2.SourceXML; _local2.RightEnd = 1000; break; case 2: _local2.Cost = 300; _local2.SourceXML = level_3.SourceXML; _local2.RightEnd = 940; break; case 3: _local2.Cost = 400; _local2.SourceXML = level5.SourceXML; _local2.RightEnd = 970; break; case 4: _local2.Cost = 500; _local2.SourceXML = level_4.SourceXML; _local2.LeftEnd = 110; _local2.RightEnd = 800; break; case 5: _local2.Cost = 600; _local2.SourceXML = level7.SourceXML; _local2.LeftEnd = -10; break; case 6: _local2.Cost = 700; _local2.SourceXML = DoubleRamp.SourceXML; break; case 7: _local2.Cost = 800; _local2.SourceXML = level6.SourceXML; _local2.RightEnd = 870; break; }; LevelArray.push(_local2); _local3 = levelselect_mc.getChildByName(("thumb_" + (_local1 + 1))); _local3.level_descr_dtf.mouseEnabled = false; _local3.addEventListener(MouseEvent.CLICK, LevelClick); _local1++; }; LoadNewLevelThumb(); } function LoadNewLevelThumb(){ var _local1:int; var _local2:String; var _local3:int; _local1 = 0; while (_local1 < MaxLevel) { _local2 = ("LEVEL " + (_local1 + 1)); _local3 = LevelArray[_local1].Cost; if (PracticeMode){ LevelArray[_local1].Completed = false; LevelArray[_local1].Locked = false; }; if (LevelArray[_local1].Completed){ _local2 = (_local2 + "\nCOMPLETED"); } else { if (LevelArray[_local1].Locked){ _local2 = (_local2 + "\nLoCKED!"); } else { if (GameField_mc.playerinfo_mc.GetScore() >= _local3){ _local2 = (_local2 + ("\nCOST TO ENTER: $" + _local3)); } else { _local2 = (_local2 + (("\nCOST TO ENTER: $" + _local3) + " NOT ENOUGH MONEY!")); }; }; }; levelselect_mc.getChildByName(("thumb_" + (_local1 + 1))).level_descr_dtf.text = _local2; _local1++; }; } public function ShowGameOver(){ var _local1:Boolean; var _local2:int; var _local3:Level; trace("ShowGameOver "); HideAllPages(); _local1 = false; _local2 = 0; while (_local2 < LevelArray.length) { _local3 = LevelArray[_local2]; if (!_local3.Completed){ _local1 = true; }; _local2++; }; if (_local1){ score_mc.gameover_mc.info_dtf.text = "YOU DIDN'T MAKE IT. BETTER LUCK NEXT TIME."; } else { score_mc.gameover_mc.info_dtf.text = "WELL DONE!\nYOU'VE COMPLETED THE GAME!"; }; score_mc.gameover_mc.visible = true; score_mc.visible = true; } function HideAllPages(){ bg_menu_mc.visible = true; bike_upgrade_mc.player_color_mc.enabled = false; bike_upgrade_mc.bike_color_mc.enabled = false; score_mc.visible = false; GameField_mc.visible = false; instructions_mc.visible = false; levelselect_mc.visible = false; mc_startpage.visible = false; stagecleared_mc.visible = false; gameover_mc.visible = false; bike_upgrade_mc.visible = false; } function InitialSelectLevel(_arg1:Event){ var _local2:int; var _local3:Level; if (_arg1.target.name == "practice_btn"){ PracticeMode = true; GameField_mc.playerinfo_mc.SetNewScore(9999); } else { PracticeMode = false; GameField_mc.EngineLevel = 0; GameField_mc.AeroLevel = 0; GameField_mc.ShocksLevel = 0; GameField_mc.BikeLevel = 0; _local2 = 0; while (_local2 < LevelArray.length) { _local3 = LevelArray[_local2]; _local3.Completed = false; if (_local2 > 2){ _local3.Locked = true; } else { _local3.Locked = false; }; _local2++; }; GameField_mc.playerinfo_mc.SetNewScore(StartingMoney); }; SelectLevel(null); } function BackToStartMenu(_arg1:Event){ HideAllPages(); mc_startpage.visible = true; } function PlayMoreClick(_arg1:Event){ navigateToURL(new URLRequest("http://www.twilightgamer.com/track.php?id=2"), "_blank"); } public function ShowStart(){ BackToStartMenu(null); GameField_mc.visible = false; CurrentLevel = 0; bike_upgrade_mc.next_btn.addEventListener(MouseEvent.CLICK, StartGameClick); instructions_mc.back_btn.addEventListener(MouseEvent.CLICK, BackToStartMenu); instructions_mc.back_btn2.addEventListener(MouseEvent.CLICK, BackToStartMenu); instructions_mc.ok_btn.addEventListener(MouseEvent.CLICK, InitialSelectLevel); stagecleared_mc.next_btn.addEventListener(MouseEvent.CLICK, SelectLevel); gameover_mc.restart_btn.addEventListener(MouseEvent.CLICK, StartGameClick); mc_startpage.btn_start_game.addEventListener(MouseEvent.CLICK, InitialInformation); mc_startpage.scores_btn.addEventListener(MouseEvent.CLICK, ShowScores); mc_startpage.practice_btn.addEventListener(MouseEvent.CLICK, InitialSelectLevel); mc_startpage.play_more_btn.addEventListener(MouseEvent.CLICK, PlayMoreClick); mc_startpage.instr_btn.addEventListener(MouseEvent.CLICK, ShowInstructions); score_mc.gameover_mc.submit_btn.addEventListener(MouseEvent.CLICK, SubmitScoreClick); score_mc.gameover_mc.back_btn.addEventListener(MouseEvent.CLICK, BackToStartMenu); levelselect_mc.back_btn.addEventListener(MouseEvent.CLICK, BackToStartMenu); } public function ShowStageIsCleared(){ HideAllPages(); if (CurrentLevel >= MaxLevel){ stagecleared_mc.next_btn.visible = false; }; stagecleared_mc.visible = true; } function frame1(){ MochiBot.track(this, "cef3a5f9"); } function ShowInstructions(_arg1:Event){ HideAllPages(); instructions_mc.back_btn.visible = true; instructions_mc.back_btn2.visible = false; instructions_mc.ok_btn.visible = false; instructions_mc.visible = true; } function ClearedNextLevelClick(_arg1:Event){ NextLevelClick(null); LevelClick(null); } public function PlayerCanJoinNextLevel():Boolean{ var _local1:int; var _local2:Level; _local1 = 0; while (_local1 < LevelArray.length) { _local2 = LevelArray[_local1]; if (!_local2.Completed){ if (_local2.Cost <= GameField_mc.playerinfo_mc.GetScore()){ return (true); }; }; _local1++; }; return (false); } function LevelClick(_arg1:Event){ var _local2:Level; var _local3:int; trace(("String(eve.target.name).substr(6, 1) " + String(_arg1.target.parent.name))); CurrentLevel = (int(String(_arg1.target.parent.name).substr(6, 1)) - 1); _local2 = LevelArray[CurrentLevel]; _local3 = _local2.Cost; if (PracticeMode){ GameField_mc.EngineLevel = 0; GameField_mc.AeroLevel = 0; GameField_mc.ShocksLevel = 0; GameField_mc.BikeLevel = 0; }; if (((((!(_local2.Locked)) && ((GameField_mc.playerinfo_mc.GetScore() >= _local3)))) && (!(_local2.Completed)))){ GameField_mc.playerinfo_mc.AddScore(-(_local3)); HideAllPages(); bike_upgrade_mc.player_color_mc.enabled = true; bike_upgrade_mc.bike_color_mc.enabled = true; trace(("CurrentLevel " + CurrentLevel)); bike_upgrade_mc.Show(GameField_mc.EngineLevel, GameField_mc.AeroLevel, GameField_mc.ShocksLevel, GameField_mc.BikeLevel, GameField_mc.playerinfo_mc); }; } function InitialInformation(_arg1:Event){ HideAllPages(); instructions_mc.back_btn.visible = false; instructions_mc.back_btn2.visible = true; instructions_mc.ok_btn.visible = true; instructions_mc.visible = true; } function SubmitScoreClick(_arg1:Event){ var _local2:String; score_mc.gameover_mc.visible = true; _local2 = o.f(0, ""); MochiScores.showLeaderboard({boardID:_local2, score:GameField_mc.playerinfo_mc.GetScore(), onClose:CloseLeaderboard}); } public function ShowStageCleared(_arg1:int){ HideAllPages(); if (_arg1 == 0){ stagecleared_mc.info_dtf.text = "TOURNAMENT TIME IS OVER, YOU HAVE ENOUGH MONEY TO ENTER NEXT TOURNAMENT. KEEP IT UP!"; } else { stagecleared_mc.info_dtf.text = "YOU CRASHED TOO MANY TIMES AND FAILED THIS TOURNAMENT.\nHOWEVER YOU HAVE MONEY AND CAN STILL ENTER ANOTHER TOURNAMENT.\nDon’t LET IT GET TOO LOW OR YOU WONT Be ABle tO EnTER Any more tournaments."; }; stagecleared_mc.totalearnings_dtf.text = ("TOTAL EARNED: $" + GameField_mc.playerinfo_mc.GetStageEarnings()); stagecleared_mc.visible = true; } public function CloseLeaderboard(){ BackToStartMenu(null); } function StartGameClick(_arg1:Event){ var _local2:Level; _local2 = LevelArray[CurrentLevel]; HideAllPages(); bg_menu_mc.visible = false; GameField_mc.BikerColor = ("0x" + bike_upgrade_mc.player_color_mc.hexValue); GameField_mc.BikeColor = ("0x" + bike_upgrade_mc.bike_color_mc.hexValue); GameField_mc.LoadLevel(_local2, CurrentLevel, bike_upgrade_mc.Engine, bike_upgrade_mc.Weight, bike_upgrade_mc.Aero, bike_upgrade_mc.BikeLevel); GameField_mc.Start(); } function SelectLevel(_arg1:Event){ var _local2:int; var _local3:int; var _local4:Level; _local2 = 0; HideAllPages(); if (PracticeMode){ GameField_mc.playerinfo_mc.SetNewScore(9999); } else { _local3 = 0; while (_local3 < LevelArray.length) { _local4 = LevelArray[_local3]; if (_local4.Completed){ _local2++; } else { if (_local2 == 3){ if (_local3 < 6){ _local4.Locked = false; }; } else { if (_local2 == 6){ _local4.Locked = false; }; }; }; _local3++; }; }; LoadNewLevelThumb(); levelselect_mc.player_money_dtf.text = ("MONEY: $" + GameField_mc.playerinfo_mc.GetScore()); levelselect_mc.visible = true; } public function ShowScores(_arg1:Event){ var _local2:String; HideAllPages(); _local2 = o.f(0, ""); score_mc.gameover_mc.visible = false; score_mc.visible = true; MochiScores.showLeaderboard({boardID:_local2, onClose:CloseLeaderboard}); } } }//package src
Section 177
//PlayerInfo (src.PlayerInfo) package src { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; public class PlayerInfo extends MovieClip { const MaxLives:int = 3; public var power_mc:MovieClip; var TotalCheckpoints:int;// = 0 var LastTimeleft:int;// = 0 public var score_mc:MovieClip; var LastCheckpoints:int;// = 0 public var timeleft_mc:MovieClip; public var back_left_mc:MovieClip; var LastScore:int;// = 0 var FlashingColorTransform:ColorTransform; var OriginalColorTransform:ColorTransform; public var checkpoint_mc:MovieClip; public var tricks_mc:MovieClip; public var arrow_mc:MovieClip; public var lives_mc:MovieClip; public var logo_btn:SimpleButton; var CurrentTrickTextAlpha:Number;// = 0 var TotalEarnings:int;// = 0 var Lives:int;// = 5 public var back_right_mc:MovieClip; public function PlayerInfo(){ TotalEarnings = 0; LastScore = 0; LastTimeleft = 0; TotalCheckpoints = 0; LastCheckpoints = 0; Lives = 5; FlashingColorTransform = new ColorTransform(); OriginalColorTransform = new ColorTransform(); CurrentTrickTextAlpha = 0; super(); logo_btn.addEventListener(MouseEvent.CLICK, LogoClick); this.addEventListener(Event.ENTER_FRAME, Frame); } public function DecreaseLives():int{ Lives--; SetLives(Lives); return (Lives); } public function SetPower(_arg1:int){ if ((((_arg1 > 0)) && ((_arg1 <= 5)))){ power_mc.gotoAndStop(_arg1); }; } public function BackLeftVisible(_arg1:Boolean){ back_left_mc.visible = _arg1; } public function GetScore():int{ return (LastScore); } public function addLive(_arg1:int){ SetLives((Lives + _arg1)); } public function SetNewScore(_arg1:int){ score_mc.holder_mc.text_dtf.text = _arg1; if (LastScore < _arg1){ score_mc.play(); }; LastScore = _arg1; } public function ResetLives(){ SetLives(MaxLives); } public function SetTrick(_arg1:String){ tricks_mc.text_mc.trick_dtf.text = _arg1; CurrentTrickTextAlpha = 1; } public function GetLives():int{ return (Lives); } public function BackRightVisible(_arg1:Boolean){ back_right_mc.visible = _arg1; } public function GetStageEarnings():int{ return (TotalEarnings); } function LogoClick(_arg1:Event){ navigateToURL(new URLRequest("http://www.twilightgamer.com/track.php?id=2"), "_blank"); } public function ResetForNewStage(){ TotalEarnings = 0; } public function SetNewTimeleft(_arg1:int){ if (LastTimeleft < _arg1){ timeleft_mc.play(); }; timeleft_mc.holder_mc.text_dtf.text = _arg1; LastTimeleft = _arg1; } public function AddScore(_arg1:int){ if (_arg1 != 0){ TotalEarnings = (TotalEarnings + _arg1); LastScore = (LastScore + _arg1); score_mc.holder_mc.text_dtf.text = ("$" + LastScore); score_mc.play(); }; } function Frame(_arg1:Event){ if (CurrentTrickTextAlpha > 0.05){ (tricks_mc as MovieClip).visible = true; (tricks_mc as MovieClip).alpha = CurrentTrickTextAlpha; CurrentTrickTextAlpha = (CurrentTrickTextAlpha - (CurrentTrickTextAlpha * 0.04)); } else { (tricks_mc as MovieClip).visible = false; }; } public function SetCheckedCheckpoints(_arg1:int){ if (LastCheckpoints < _arg1){ checkpoint_mc.play(); }; checkpoint_mc.holder_mc.text_dtf.text = ((_arg1 + "/") + TotalCheckpoints); LastCheckpoints = _arg1; } public function SetTotalCheckpoints(_arg1:int){ TotalCheckpoints = _arg1; checkpoint_mc.holder_mc.text_dtf.text = ((LastCheckpoints + "/") + TotalCheckpoints); } public function SetLives(_arg1:int){ if (_arg1 <= MaxLives){ Lives = _arg1; }; lives_mc.gotoAndStop(Lives); } } }//package src
Section 178
//ScoreWindow (src.ScoreWindow) package src { import flash.display.*; public dynamic class ScoreWindow extends MovieClip { public var gameover_mc:MovieClip; } }//package src
Section 179
//smoke (src.smoke) package src { import flash.display.*; import flash.events.*; public class smoke extends Sprite { var LastX:Number;// = 0 var LastY:Number;// = 0 public var mc:MovieClip; public static var CurrentAlpha:Number = 0.2; public function smoke(){ LastX = 0; LastY = 0; super(); this.addEventListener(Event.ENTER_FRAME, Frame); this.mc.alpha = CurrentAlpha; } function Frame(_arg1:Event){ if (Math.abs(((this.parent.x - LastX) * (this.parent.y - LastY))) == 0){ this.mc.alpha = CurrentAlpha; }; LastX = this.parent.x; LastY = this.parent.y; } } }//package src
Section 180
//SoundBtn (src.SoundBtn) package src { import flash.display.*; import flash.events.*; import flash.media.*; public class SoundBtn extends SimpleButton { var SoundOnState:DisplayObject; var SoundOn:Boolean;// = true var SoundOffState:DisplayObject; public function SoundBtn(){ SoundOn = true; super(); SoundOnState = this.upState; SoundOffState = this.overState; this.addEventListener(MouseEvent.CLICK, Click); } function Click(_arg1:Event){ var _local2:SoundTransform; SoundOn = !(SoundOn); _local2 = new SoundTransform(); if (SoundOn){ _local2.volume = 1; this.upState = SoundOnState; this.overState = SoundOffState; this.downState = SoundOffState; } else { _local2.volume = 0; this.upState = SoundOffState; this.overState = SoundOnState; this.downState = SoundOnState; }; SoundMixer.soundTransform = _local2; } } }//package src
Section 181
//SoundEffects (src.SoundEffects) package src { import flash.media.*; public class SoundEffects { private static var TrickSC:SoundChannel; private static var CrowdBooSound:boo_crowd_sound; private static var EngineSound:engine_sound = new engine_sound(); private static var SC:SoundChannel; private static var TrickST:SoundTransform = new SoundTransform(0.8); private static var TrickSound1:flying_man_sound = new flying_man_sound(); private static var TrickSound2:dragonfly_sound = new dragonfly_sound(); private static var TrickSound3:kamikazee_sound = new kamikazee_sound(); private static var TrickSound4:prayingman_sound = new prayingman_sound(); private static var TrickSound5:pepsirun_sound = new pepsirun_sound(); private static var TrickSound6:uglyducklyn_sound = new uglyducklyn_sound(); private static var CrowdSC:SoundChannel; private static var BodyHitSound:bodyhit_sound = new bodyhit_sound(); private static var ST:SoundTransform = new SoundTransform(0.1); private static var CrowdCheerSound:cheer_crowd_sound; private static var CrowdST:SoundTransform = new SoundTransform(0.8); public static function StartEngineLoop(){ SC = (EngineSound as Sound).play(0, 600000, ST); } public static function PlayCrowdCheerSound(){ if (CrowdCheerSound == null){ CrowdCheerSound = new cheer_crowd_sound(); }; CrowdSC = (CrowdCheerSound as Sound).play(0, 1, CrowdST); } public static function SetEngineVolume(_arg1:Number){ ST.volume = _arg1; SC.soundTransform = ST; } public static function PlayCrowdBooSound(){ if (CrowdBooSound == null){ CrowdBooSound = new boo_crowd_sound(); }; CrowdSC = (CrowdBooSound as Sound).play(0, 1, CrowdST); } public static function PlayTrickSound(_arg1:int){ switch (_arg1){ case 1: TrickSC = (TrickSound1 as Sound).play(0, 1, TrickST); break; case 2: TrickSC = (TrickSound2 as Sound).play(0, 1, TrickST); break; case 3: TrickSC = (TrickSound3 as Sound).play(0, 1, TrickST); break; case 4: TrickSC = (TrickSound4 as Sound).play(0, 1, TrickST); break; case 5: TrickSC = (TrickSound5 as Sound).play(0, 1, TrickST); break; case 6: TrickSC = (TrickSound6 as Sound).play(0, 1, TrickST); break; }; } public static function EndEngineLoop(){ SC.stop(); } public static function PlayHitSound(_arg1:Number){ var _local2:SoundTransform; _local2 = new SoundTransform(_arg1); BodyHitSound.play(0, 0, _local2); } } }//package src
Section 182
//Suspension (src.Suspension) package src { import flash.display.*; import Box2D.Common.Math.*; import Box2D.Dynamics.*; import Box2D.Collision.Shapes.*; import Box2D.Dynamics.Joints.*; import Box2D.Collision.*; import Box2D.Common.*; import Box2D.Dynamics.Contacts.*; import flash.media.*; public class Suspension { var Dead:Boolean; var WheelDef:b2CircleDef; public var SuspensionJoint:b2PrismaticJoint; var m_world:b2World; public var Axle:b2RevoluteJoint; var AxleBody:b2Body; private var AbsorbRate:Number;// = 120 private var Stiffness:Number;// = 4000 private var ContactNum:uint; var m_CarBody:b2Body; var WheelBody:b2Body; private var JumpFrame:int; private static var JumpSound:jump_sound; private static var ST:SoundTransform = new SoundTransform(); public function Suspension(){ WheelDef = new b2CircleDef(); Stiffness = 4000; AbsorbRate = 120; super(); } public function FreeWheels(){ Axle.EnableMotor(true); Axle.SetMaxMotorTorque(0); Axle.SetMotorSpeed(0); } public function getContacted():Boolean{ return ((ContactNum > 0)); } public function Stops(_arg1:Number){ var _local2:Number; Axle.EnableMotor(true); Axle.SetMaxMotorTorque(9500); _local2 = 0; if (_arg1 > 0){ _local2 = -10; } else { _local2 = 10; }; Axle.SetMotorSpeed(_local2); } public function setContacted(_arg1:Boolean){ if (_arg1){ ContactNum = 1; } else { ContactNum = 0; }; } public function SetShockLevel(_arg1:int){ switch (_arg1){ case 0: Stiffness = 3000; AbsorbRate = 70; break; case 1: Stiffness = 4000; AbsorbRate = 120; break; case 2: Stiffness = 5000; AbsorbRate = 200; break; }; } public function Create(_arg1:b2World, _arg2:b2Body, _arg3:MovieClip, _arg4:Number, _arg5:Number){ var _local6:Number; var _local7:b2BodyDef; var _local8:b2PolygonDef; var _local9:b2BodyDef; var _local10:b2RevoluteJointDef; var _local11:b2PrismaticJointDef; _local6 = 2.5; m_world = _arg1; m_CarBody = _arg2; WheelDef.filter.groupIndex = 2; WheelDef.radius = (30 / CarGame.m_physScale); WheelDef.filter.groupIndex = -1; WheelDef.density = 3.5; WheelDef.friction = 1.6; WheelDef.restitution = 0; WheelDef.userData = _arg3; WheelDef.userData.visible = true; _arg3.width = 12; _arg3.height = 12; _local7 = new b2BodyDef(); _local7.linearDamping = 0.5; _local7.position.Set(_arg4, (_arg5 + _local6)); WheelBody = m_world.CreateBody(_local7); WheelBody.CreateShape(WheelDef).SetUserData(this); WheelBody.SetMassFromShapes(); Draw(); trace(("WheelBody.GetMass() " + WheelBody.GetMass())); _local10 = new b2RevoluteJointDef(); _local8 = new b2PolygonDef(); _local8.SetAsBox((10 / CarGame.m_physScale), (10 / CarGame.m_physScale)); _local8.density = 35; _local9 = new b2BodyDef(); _local9.position.Set(_arg4, (_arg5 + _local6)); AxleBody = m_world.CreateBody(_local9); AxleBody.CreateShape(_local8); AxleBody.SetMassFromShapes(); _local10.Initialize(WheelBody, AxleBody, new b2Vec2(_arg4, (_arg5 + _local6))); _local10.enableMotor = false; Axle = m_world.CreateJoint(_local10); trace(("AxleBody.GetMass() " + AxleBody.GetMass())); _local11 = new b2PrismaticJointDef(); _local11.Initialize(AxleBody, m_CarBody, new b2Vec2(_arg4, (_arg5 + 0.3333)), new b2Vec2(0, 1)); SuspensionJoint = m_world.CreateJoint(_local11); SuspensionJoint.SetLimits(0.2, 1.9); SuspensionJoint.EnableLimit(true); SuspensionJoint.EnableMotor(true); } public function Destroy(){ if (WheelBody != null){ m_world.DestroyBody(WheelBody); }; if (AxleBody != null){ m_world.DestroyBody(AxleBody); }; } public function GetWheelRotation():Number{ return (WheelBody.GetAngularVelocity()); } public function AddContact(){ ContactNum++; } public function Update(_arg1:Boolean){ var _local2:Number; var _local3:Number; var _local4:Number; var _local5:b2Vec2; _local2 = SuspensionJoint.GetJointSpeed(); _local3 = SuspensionJoint.GetJointTranslation(); if (((_arg1) && (getContacted()))){ JumpFrame = 2; Suspension.PlayJumpSound(); }; setContacted(false); JumpFrame--; if (_local2 > 0){ _local4 = (((_local3 - 1) * Stiffness) + (_local2 * AbsorbRate)); } else { _local4 = (((_local3 - 1) * Stiffness) + ((_local2 * AbsorbRate) * 2)); }; if (JumpFrame > 0){ _local4 = 250000; }; SuspensionJoint.SetMaxMotorForce(_local4); if (_local4 > 0){ SuspensionJoint.SetMotorSpeed(-10000); } else { SuspensionJoint.SetMotorSpeed(10000); }; if (JumpFrame > 0){ _local5 = AxleBody.GetWorldVector(new b2Vec2(0, -100000)); }; } public function RemoveContact(){ ContactNum--; } public function Draw(){ var _local1:int; _local1 = Main.ScaleMultiplier; WheelDef.userData.x = (WheelBody.GetPosition().x * _local1); WheelDef.userData.y = (WheelBody.GetPosition().y * _local1); WheelDef.userData.rotation = (WheelBody.GetAngle() * (180 / Math.PI)); } public function SetCrashed(){ WheelDef.userData.visible = false; if (SuspensionJoint != null){ SuspensionJoint.EnableMotor(false); SuspensionJoint.SetLimits(-1.2, -1.3); Axle.EnableMotor(false); }; } static function PlayJumpSound(){ if (JumpSound == null){ JumpSound = new jump_sound(); }; JumpSound.play(0, 1); } } }//package src
Section 183
//Trick (src.Trick) package src { public class Trick { public var Type:int;// = 0 public function Trick(_arg1:int){ Type = 0; super(); Type = _arg1; } } }//package src
Section 184
//AreYouSureMovie_59 (x_fla.AreYouSureMovie_59) package x_fla { import flash.display.*; import flash.text.*; public dynamic class AreYouSureMovie_59 extends MovieClip { public var cancel_btn:SimpleButton; public var ok_btn:SimpleButton; public var text_dtf:TextField; } }//package x_fla
Section 185
//BackGround_79 (x_fla.BackGround_79) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class BackGround_79 extends MovieClip { public var mc_flash2:MovieClip; public var mc_flash3:MovieClip; public var mc_flash1:MovieClip; public function BackGround_79(){ addFrameScript(0, frame1); } function frame1(){ stop(); } } }//package x_fla
Section 186
//BAIK3Coloring_40 (x_fla.BAIK3Coloring_40) package x_fla { import flash.display.*; public dynamic class BAIK3Coloring_40 extends MovieClip { public var color_mc:MovieClip; } }//package x_fla
Section 187
//Bike2Coloring_38 (x_fla.Bike2Coloring_38) package x_fla { import flash.display.*; public dynamic class Bike2Coloring_38 extends MovieClip { public var color_mc:MovieClip; } }//package x_fla
Section 188
//BikeMovie_34 (x_fla.BikeMovie_34) package x_fla { import flash.display.*; public dynamic class BikeMovie_34 extends MovieClip { public var color_mc:MovieClip; } }//package x_fla
Section 189
//BikeMovie2_124 (x_fla.BikeMovie2_124) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class BikeMovie2_124 extends MovieClip { public var color_mc:MovieClip; public function BikeMovie2_124(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBike(); } } }//package x_fla
Section 190
//CarArea_84 (x_fla.CarArea_84) package x_fla { import flash.display.*; public dynamic class CarArea_84 extends MovieClip { public var mc_level:MovieClip; } }//package x_fla
Section 191
//DrawArea_83 (x_fla.DrawArea_83) package x_fla { import flash.display.*; public dynamic class DrawArea_83 extends MovieClip { public var mc_cararea:MovieClip; } }//package x_fla
Section 192
//FlashAnim_80 (x_fla.FlashAnim_80) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class FlashAnim_80 extends MovieClip { public function FlashAnim_80(){ addFrameScript(0, frame1); } function frame1(){ stop(); } } }//package x_fla
Section 193
//GameoverMovie_62 (x_fla.GameoverMovie_62) package x_fla { import flash.display.*; import flash.text.*; public dynamic class GameoverMovie_62 extends MovieClip { public var back_btn:SimpleButton; public var submit_btn:SimpleButton; public var info_dtf:TextField; } }//package x_fla
Section 194
//GameOverPage_76 (x_fla.GameOverPage_76) package x_fla { import flash.display.*; public dynamic class GameOverPage_76 extends MovieClip { public var restart_btn:SimpleButton; } }//package x_fla
Section 195
//InstructionsPage_72 (x_fla.InstructionsPage_72) package x_fla { import flash.display.*; public dynamic class InstructionsPage_72 extends MovieClip { public var back_btn:SimpleButton; public var ok_btn:SimpleButton; public var back_btn2:SimpleButton; } }//package x_fla
Section 196
//LevelThumb_110 (x_fla.LevelThumb_110) package x_fla { import flash.display.*; import flash.text.*; public dynamic class LevelThumb_110 extends MovieClip { public var level_descr_dtf:TextField; } }//package x_fla
Section 197
//LevelThumbcopy_113 (x_fla.LevelThumbcopy_113) package x_fla { import flash.display.*; import flash.text.*; public dynamic class LevelThumbcopy_113 extends MovieClip { public var level_descr_dtf:TextField; } }//package x_fla
Section 198
//LevelThumbcopy2_112 (x_fla.LevelThumbcopy2_112) package x_fla { import flash.display.*; import flash.text.*; public dynamic class LevelThumbcopy2_112 extends MovieClip { public var level_descr_dtf:TextField; } }//package x_fla
Section 199
//LevelThumbcopy3_111 (x_fla.LevelThumbcopy3_111) package x_fla { import flash.display.*; import flash.text.*; public dynamic class LevelThumbcopy3_111 extends MovieClip { public var level_descr_dtf:TextField; } }//package x_fla
Section 200
//LevelThumbcopy4_105 (x_fla.LevelThumbcopy4_105) package x_fla { import flash.display.*; import flash.text.*; public dynamic class LevelThumbcopy4_105 extends MovieClip { public var level_descr_dtf:TextField; } }//package x_fla
Section 201
//LevelThumbcopy5_109 (x_fla.LevelThumbcopy5_109) package x_fla { import flash.display.*; import flash.text.*; public dynamic class LevelThumbcopy5_109 extends MovieClip { public var level_descr_dtf:TextField; } }//package x_fla
Section 202
//LevelThumbcopy6_108 (x_fla.LevelThumbcopy6_108) package x_fla { import flash.display.*; import flash.text.*; public dynamic class LevelThumbcopy6_108 extends MovieClip { public var level_descr_dtf:TextField; } }//package x_fla
Section 203
//LevelThumbcopy7_107 (x_fla.LevelThumbcopy7_107) package x_fla { import flash.display.*; import flash.text.*; public dynamic class LevelThumbcopy7_107 extends MovieClip { public var level_descr_dtf:TextField; } }//package x_fla
Section 204
//LivesMovie_102 (x_fla.LivesMovie_102) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class LivesMovie_102 extends MovieClip { public function LivesMovie_102(){ addFrameScript(0, frame1); } function frame1(){ stop(); } } }//package x_fla
Section 205
//Man_126 (x_fla.Man_126) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class Man_126 extends MovieClip { public var color_mc:MovieClip; public function Man_126(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 206
//man_133 (x_fla.man_133) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class man_133 extends MovieClip { public var color_mc:MovieClip; public function man_133(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 207
//man_135 (x_fla.man_135) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class man_135 extends MovieClip { public var color_mc:MovieClip; public function man_135(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 208
//ManColoringSetup_42 (x_fla.ManColoringSetup_42) package x_fla { import flash.display.*; public dynamic class ManColoringSetup_42 extends MovieClip { public var color_mc:MovieClip; } }//package x_fla
Section 209
//ManTest1_127 (x_fla.ManTest1_127) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest1_127 extends MovieClip { public var color_mc:MovieClip; public function ManTest1_127(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 210
//ManTest1_129 (x_fla.ManTest1_129) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest1_129 extends MovieClip { public var color_mc:MovieClip; public function ManTest1_129(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 211
//ManTest1_131 (x_fla.ManTest1_131) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest1_131 extends MovieClip { public var color_mc:MovieClip; public function ManTest1_131(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 212
//ManTest1_137 (x_fla.ManTest1_137) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest1_137 extends MovieClip { public var color_mc:MovieClip; public function ManTest1_137(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 213
//ManTest1_141 (x_fla.ManTest1_141) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest1_141 extends MovieClip { public var color_mc:MovieClip; public function ManTest1_141(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 214
//ManTest1_143 (x_fla.ManTest1_143) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest1_143 extends MovieClip { public var color_mc:MovieClip; public function ManTest1_143(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 215
//ManTest2_145 (x_fla.ManTest2_145) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest2_145 extends MovieClip { public var color_mc:MovieClip; public function ManTest2_145(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 216
//ManTest2_147 (x_fla.ManTest2_147) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest2_147 extends MovieClip { public var color_mc:MovieClip; public function ManTest2_147(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 217
//ManTest2_149 (x_fla.ManTest2_149) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest2_149 extends MovieClip { public var color_mc:MovieClip; public function ManTest2_149(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 218
//ManTest2_151 (x_fla.ManTest2_151) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest2_151 extends MovieClip { public var color_mc:MovieClip; public function ManTest2_151(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 219
//ManTest2_153 (x_fla.ManTest2_153) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest2_153 extends MovieClip { public var color_mc:MovieClip; public function ManTest2_153(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 220
//ManTest2_155 (x_fla.ManTest2_155) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest2_155 extends MovieClip { public var color_mc:MovieClip; public function ManTest2_155(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 221
//ManTest2_157 (x_fla.ManTest2_157) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest2_157 extends MovieClip { public var color_mc:MovieClip; public function ManTest2_157(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 222
//ManTest2_159 (x_fla.ManTest2_159) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest2_159 extends MovieClip { public var color_mc:MovieClip; public function ManTest2_159(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 223
//ManTest2_161 (x_fla.ManTest2_161) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest2_161 extends MovieClip { public var color_mc:MovieClip; public function ManTest2_161(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 224
//ManTest3_163 (x_fla.ManTest3_163) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest3_163 extends MovieClip { public var color_mc:MovieClip; public function ManTest3_163(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 225
//ManTest3_165 (x_fla.ManTest3_165) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest3_165 extends MovieClip { public var color_mc:MovieClip; public function ManTest3_165(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 226
//ManTest3_167 (x_fla.ManTest3_167) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest3_167 extends MovieClip { public var color_mc:MovieClip; public function ManTest3_167(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 227
//ManTest3_169 (x_fla.ManTest3_169) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest3_169 extends MovieClip { public var color_mc:MovieClip; public function ManTest3_169(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 228
//ManTest3_171 (x_fla.ManTest3_171) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest3_171 extends MovieClip { public var color_mc:MovieClip; public function ManTest3_171(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 229
//ManTest3_173 (x_fla.ManTest3_173) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest3_173 extends MovieClip { public var color_mc:MovieClip; public function ManTest3_173(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 230
//ManTest3_175 (x_fla.ManTest3_175) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest3_175 extends MovieClip { public var color_mc:MovieClip; public function ManTest3_175(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 231
//ManTest3_177 (x_fla.ManTest3_177) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest3_177 extends MovieClip { public var color_mc:MovieClip; public function ManTest3_177(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 232
//ManTest3_179 (x_fla.ManTest3_179) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest3_179 extends MovieClip { public var color_mc:MovieClip; public function ManTest3_179(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 233
//ManTest4_181 (x_fla.ManTest4_181) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest4_181 extends MovieClip { public var color_mc:MovieClip; public function ManTest4_181(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 234
//ManTest4_183 (x_fla.ManTest4_183) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest4_183 extends MovieClip { public var color_mc:MovieClip; public function ManTest4_183(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 235
//ManTest4_185 (x_fla.ManTest4_185) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest4_185 extends MovieClip { public var color_mc:MovieClip; public function ManTest4_185(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 236
//ManTest4_187 (x_fla.ManTest4_187) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest4_187 extends MovieClip { public var color_mc:MovieClip; public function ManTest4_187(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 237
//ManTest4_189 (x_fla.ManTest4_189) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest4_189 extends MovieClip { public var color_mc:MovieClip; public function ManTest4_189(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 238
//ManTest4_191 (x_fla.ManTest4_191) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest4_191 extends MovieClip { public var color_mc:MovieClip; public function ManTest4_191(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 239
//ManTest4_193 (x_fla.ManTest4_193) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest4_193 extends MovieClip { public var color_mc:MovieClip; public function ManTest4_193(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 240
//ManTest4_195 (x_fla.ManTest4_195) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest4_195 extends MovieClip { public var color_mc:MovieClip; public function ManTest4_195(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 241
//ManTest4_197 (x_fla.ManTest4_197) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest4_197 extends MovieClip { public var color_mc:MovieClip; public function ManTest4_197(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 242
//ManTest5_199 (x_fla.ManTest5_199) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest5_199 extends MovieClip { public var color_mc:MovieClip; public function ManTest5_199(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 243
//ManTest5_201 (x_fla.ManTest5_201) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest5_201 extends MovieClip { public var color_mc:MovieClip; public function ManTest5_201(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 244
//ManTest6_203 (x_fla.ManTest6_203) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest6_203 extends MovieClip { public var color_mc:MovieClip; public function ManTest6_203(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 245
//ManTest6_205 (x_fla.ManTest6_205) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest6_205 extends MovieClip { public var color_mc:MovieClip; public function ManTest6_205(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 246
//ManTest6_207 (x_fla.ManTest6_207) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest6_207 extends MovieClip { public var color_mc:MovieClip; public function ManTest6_207(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 247
//ManTest6_209 (x_fla.ManTest6_209) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest6_209 extends MovieClip { public var color_mc:MovieClip; public function ManTest6_209(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 248
//ManTest6_211 (x_fla.ManTest6_211) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest6_211 extends MovieClip { public var color_mc:MovieClip; public function ManTest6_211(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 249
//ManTest6_213 (x_fla.ManTest6_213) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest6_213 extends MovieClip { public var color_mc:MovieClip; public function ManTest6_213(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 250
//ManTest6_215 (x_fla.ManTest6_215) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest6_215 extends MovieClip { public var color_mc:MovieClip; public function ManTest6_215(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 251
//ManTest6_217 (x_fla.ManTest6_217) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest6_217 extends MovieClip { public var color_mc:MovieClip; public function ManTest6_217(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 252
//ManTest6_219 (x_fla.ManTest6_219) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class ManTest6_219 extends MovieClip { public var color_mc:MovieClip; public function ManTest6_219(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 253
//MantTest1_139 (x_fla.MantTest1_139) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class MantTest1_139 extends MovieClip { public var color_mc:MovieClip; public function MantTest1_139(){ addFrameScript(0, frame1); } function frame1(){ this.parent.ColorBody(); } } }//package x_fla
Section 254
//Mapcopy_85 (x_fla.Mapcopy_85) package x_fla { import flash.display.*; public dynamic class Mapcopy_85 extends MovieClip { public var level_1:MovieClip; public var level_3:MovieClip; public var level_6:MovieClip; public var level_7:MovieClip; public var level_2:MovieClip; public var level_4:MovieClip; public var double_ramp_mc:MovieClip; public var level_5:MovieClip; } }//package x_fla
Section 255
//MenuLevelSelectPage_104 (x_fla.MenuLevelSelectPage_104) package x_fla { import flash.display.*; import flash.text.*; public dynamic class MenuLevelSelectPage_104 extends MovieClip { public var back_btn:SimpleButton; public var thumb_1:MovieClip; public var thumb_2:MovieClip; public var thumb_4:MovieClip; public var thumb_6:MovieClip; public var thumb_7:MovieClip; public var thumb_8:MovieClip; public var thumb_3:MovieClip; public var thumb_5:MovieClip; public var player_money_dtf:TextField; } }//package x_fla
Section 256
//NotEnoughMoneyMovie_57 (x_fla.NotEnoughMoneyMovie_57) package x_fla { import flash.display.*; import flash.text.*; public dynamic class NotEnoughMoneyMovie_57 extends MovieClip { public var ok_btn:SimpleButton; public var text_dtf:TextField; } }//package x_fla
Section 257
//PlayerInfoTimeleft_96 (x_fla.PlayerInfoTimeleft_96) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class PlayerInfoTimeleft_96 extends MovieClip { public var holder_mc:MovieClip; public function PlayerInfoTimeleft_96(){ addFrameScript(0, frame1); } function frame1(){ stop(); } } }//package x_fla
Section 258
//PlayerTextHolder_97 (x_fla.PlayerTextHolder_97) package x_fla { import flash.display.*; import flash.text.*; public dynamic class PlayerTextHolder_97 extends MovieClip { public var text_dtf:TextField; } }//package x_fla
Section 259
//PowerMeter_101 (x_fla.PowerMeter_101) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class PowerMeter_101 extends MovieClip { public function PowerMeter_101(){ addFrameScript(0, frame1); } function frame1(){ stop(); } } }//package x_fla
Section 260
//StageClearedPage_73 (x_fla.StageClearedPage_73) package x_fla { import flash.display.*; import flash.text.*; public dynamic class StageClearedPage_73 extends MovieClip { public var back_btn:SimpleButton; public var next_btn:SimpleButton; public var totalearnings_dtf:TextField; public var info_dtf:TextField; } }//package x_fla
Section 261
//StartPage_65 (x_fla.StartPage_65) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class StartPage_65 extends MovieClip { public var play_more_btn:SimpleButton; public var scores_btn:SimpleButton; public var practice_btn:SimpleButton; public var btn_start_game:SimpleButton; public var instr_btn:SimpleButton; public var producedby_btn:SimpleButton; public function StartPage_65(){ addFrameScript(0, frame1); } public function PClick(_arg1:Event){ navigateToURL(new URLRequest("http://www.letsdesign.co.uk/stunt_bike/"), "_blank"); } function frame1(){ producedby_btn.addEventListener(MouseEvent.CLICK, PClick); } } }//package x_fla
Section 262
//Symbol3_19 (x_fla.Symbol3_19) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class Symbol3_19 extends MovieClip { public function Symbol3_19(){ addFrameScript(12, frame13); } function frame13(){ stop(); } } }//package x_fla
Section 263
//Symbol30_23 (x_fla.Symbol30_23) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class Symbol30_23 extends MovieClip { public function Symbol30_23(){ addFrameScript(39, frame40); } function frame40(){ stop(); } } }//package x_fla
Section 264
//Symbol34_1 (x_fla.Symbol34_1) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class Symbol34_1 extends MovieClip { public function Symbol34_1(){ addFrameScript(99, frame100); } function frame100(){ stop(); } } }//package x_fla
Section 265
//Symbol35_119 (x_fla.Symbol35_119) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class Symbol35_119 extends MovieClip { public function Symbol35_119(){ addFrameScript(19, frame20); } function frame20(){ stop(); } } }//package x_fla
Section 266
//Symbol36_2 (x_fla.Symbol36_2) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class Symbol36_2 extends MovieClip { public function Symbol36_2(){ addFrameScript(39, frame40); } function frame40(){ stop(); } } }//package x_fla
Section 267
//Symbol37_3 (x_fla.Symbol37_3) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class Symbol37_3 extends MovieClip { public function Symbol37_3(){ addFrameScript(39, frame40); } function frame40(){ stop(); } } }//package x_fla
Section 268
//Symbol38_4 (x_fla.Symbol38_4) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class Symbol38_4 extends MovieClip { public function Symbol38_4(){ addFrameScript(39, frame40); } function frame40(){ stop(); } } }//package x_fla
Section 269
//Symbol39_5 (x_fla.Symbol39_5) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class Symbol39_5 extends MovieClip { public function Symbol39_5(){ addFrameScript(39, frame40); } function frame40(){ stop(); } } }//package x_fla
Section 270
//Symbol4_18 (x_fla.Symbol4_18) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class Symbol4_18 extends MovieClip { public function Symbol4_18(){ addFrameScript(19, frame20); } function frame20(){ stop(); } } }//package x_fla
Section 271
//Symbol40_6 (x_fla.Symbol40_6) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class Symbol40_6 extends MovieClip { public function Symbol40_6(){ addFrameScript(39, frame40); } function frame40(){ stop(); } } }//package x_fla
Section 272
//Symbol41_7 (x_fla.Symbol41_7) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class Symbol41_7 extends MovieClip { public function Symbol41_7(){ addFrameScript(39, frame40); } function frame40(){ stop(); } } }//package x_fla
Section 273
//Symbol42_8 (x_fla.Symbol42_8) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class Symbol42_8 extends MovieClip { public function Symbol42_8(){ addFrameScript(39, frame40); } function frame40(){ stop(); } } }//package x_fla
Section 274
//Symbol43_9 (x_fla.Symbol43_9) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class Symbol43_9 extends MovieClip { public function Symbol43_9(){ addFrameScript(39, frame40); } function frame40(){ stop(); } } }//package x_fla
Section 275
//Symbol44_10 (x_fla.Symbol44_10) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class Symbol44_10 extends MovieClip { public function Symbol44_10(){ addFrameScript(39, frame40); } function frame40(){ stop(); } } }//package x_fla
Section 276
//Symbol45_11 (x_fla.Symbol45_11) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class Symbol45_11 extends MovieClip { public function Symbol45_11(){ addFrameScript(39, frame40); } function frame40(){ stop(); } } }//package x_fla
Section 277
//Symbol46_12 (x_fla.Symbol46_12) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class Symbol46_12 extends MovieClip { public function Symbol46_12(){ addFrameScript(39, frame40); } function frame40(){ stop(); } } }//package x_fla
Section 278
//Symbol47_13 (x_fla.Symbol47_13) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class Symbol47_13 extends MovieClip { public function Symbol47_13(){ addFrameScript(39, frame40); } function frame40(){ stop(); } } }//package x_fla
Section 279
//Symbol48_14 (x_fla.Symbol48_14) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class Symbol48_14 extends MovieClip { public function Symbol48_14(){ addFrameScript(39, frame40); } function frame40(){ stop(); } } }//package x_fla
Section 280
//Symbol49_16 (x_fla.Symbol49_16) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class Symbol49_16 extends MovieClip { public function Symbol49_16(){ addFrameScript(39, frame40); } function frame40(){ stop(); } } }//package x_fla
Section 281
//Symbol50_15 (x_fla.Symbol50_15) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class Symbol50_15 extends MovieClip { public function Symbol50_15(){ addFrameScript(39, frame40); } function frame40(){ stop(); } } }//package x_fla
Section 282
//Symbol51_117 (x_fla.Symbol51_117) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class Symbol51_117 extends MovieClip { public function Symbol51_117(){ addFrameScript(89, frame90); } function frame90(){ stop(); } } }//package x_fla
Section 283
//Symbol7_21 (x_fla.Symbol7_21) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class Symbol7_21 extends MovieClip { public function Symbol7_21(){ addFrameScript(14, frame15); } function frame15(){ stop(); } } }//package x_fla
Section 284
//TrickInfoMovie_99 (x_fla.TrickInfoMovie_99) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class TrickInfoMovie_99 extends MovieClip { public var text_mc:MovieClip; public function TrickInfoMovie_99(){ addFrameScript(0, frame1, 29, frame30); } function frame1(){ stop(); } function frame30(){ gotoAndStop(0); } } }//package x_fla
Section 285
//TrickTextHolder_100 (x_fla.TrickTextHolder_100) package x_fla { import flash.display.*; import flash.text.*; public dynamic class TrickTextHolder_100 extends MovieClip { public var trick_dtf:TextField; } }//package x_fla
Section 286
//UpgradeMovie_32 (x_fla.UpgradeMovie_32) package x_fla { import flash.display.*; import flash.events.*; import flash.net.*; import flash.geom.*; import flash.text.*; import flash.media.*; import flash.utils.*; import flash.filters.*; import flash.system.*; import flash.ui.*; import flash.accessibility.*; import flash.errors.*; public dynamic class UpgradeMovie_32 extends MovieClip { public function UpgradeMovie_32(){ addFrameScript(0, frame1, 19, frame20, 39, frame40, 59, frame60); } function frame1(){ stop(); } function frame20(){ stop(); } function frame40(){ stop(); } function frame60(){ stop(); } } }//package x_fla
Section 287
//BikeWheel (BikeWheel) package { import flash.display.*; public dynamic class BikeWheel extends MovieClip { } }//package
Section 288
//bodyhit_sound (bodyhit_sound) package { import flash.media.*; public dynamic class bodyhit_sound extends Sound { } }//package
Section 289
//boo_crowd_sound (boo_crowd_sound) package { import flash.media.*; public dynamic class boo_crowd_sound extends Sound { } }//package
Section 290
//CellRenderer_disabledSkin (CellRenderer_disabledSkin) package { import flash.display.*; public dynamic class CellRenderer_disabledSkin extends MovieClip { } }//package
Section 291
//CellRenderer_downSkin (CellRenderer_downSkin) package { import flash.display.*; public dynamic class CellRenderer_downSkin extends MovieClip { } }//package
Section 292
//CellRenderer_overSkin (CellRenderer_overSkin) package { import flash.display.*; public dynamic class CellRenderer_overSkin extends MovieClip { } }//package
Section 293
//CellRenderer_selectedDisabledSkin (CellRenderer_selectedDisabledSkin) package { import flash.display.*; public dynamic class CellRenderer_selectedDisabledSkin extends MovieClip { } }//package
Section 294
//CellRenderer_selectedDownSkin (CellRenderer_selectedDownSkin) package { import flash.display.*; public dynamic class CellRenderer_selectedDownSkin extends MovieClip { } }//package
Section 295
//CellRenderer_selectedOverSkin (CellRenderer_selectedOverSkin) package { import flash.display.*; public dynamic class CellRenderer_selectedOverSkin extends MovieClip { } }//package
Section 296
//CellRenderer_selectedUpSkin (CellRenderer_selectedUpSkin) package { import flash.display.*; public dynamic class CellRenderer_selectedUpSkin extends MovieClip { } }//package
Section 297
//CellRenderer_upSkin (CellRenderer_upSkin) package { import flash.display.*; public dynamic class CellRenderer_upSkin extends MovieClip { } }//package
Section 298
//checkpoint_sound (checkpoint_sound) package { import flash.media.*; public dynamic class checkpoint_sound extends Sound { } }//package
Section 299
//cheer_crowd_sound (cheer_crowd_sound) package { import flash.media.*; public dynamic class cheer_crowd_sound extends Sound { } }//package
Section 300
//ChildMovie (ChildMovie) package { import flash.display.*; public dynamic class ChildMovie extends MovieClip { public var child_1:MovieClip; public var child_2:MovieClip; public var child_3:MovieClip; public var child_4:MovieClip; public var child_5:MovieClip; } }//package
Section 301
//coin_sound (coin_sound) package { import flash.media.*; public dynamic class coin_sound extends Sound { } }//package
Section 302
//coinsprite (coinsprite) package { import flash.display.*; public dynamic class coinsprite extends Sprite { } }//package
Section 303
//ColorPicker_backgroundSkin (ColorPicker_backgroundSkin) package { import flash.display.*; public dynamic class ColorPicker_backgroundSkin extends MovieClip { } }//package
Section 304
//ColorPicker_colorWell (ColorPicker_colorWell) package { import flash.display.*; public dynamic class ColorPicker_colorWell extends MovieClip { } }//package
Section 305
//ColorPicker_disabledSkin (ColorPicker_disabledSkin) package { import flash.display.*; public dynamic class ColorPicker_disabledSkin extends MovieClip { } }//package
Section 306
//ColorPicker_downSkin (ColorPicker_downSkin) package { import flash.display.*; public dynamic class ColorPicker_downSkin extends MovieClip { } }//package
Section 307
//ColorPicker_overSkin (ColorPicker_overSkin) package { import flash.display.*; public dynamic class ColorPicker_overSkin extends MovieClip { } }//package
Section 308
//ColorPicker_swatchSelectedSkin (ColorPicker_swatchSelectedSkin) package { import flash.display.*; public dynamic class ColorPicker_swatchSelectedSkin extends MovieClip { } }//package
Section 309
//ColorPicker_swatchSkin (ColorPicker_swatchSkin) package { import flash.display.*; public dynamic class ColorPicker_swatchSkin extends Sprite { } }//package
Section 310
//ColorPicker_textFieldSkin (ColorPicker_textFieldSkin) package { import flash.display.*; public dynamic class ColorPicker_textFieldSkin extends MovieClip { } }//package
Section 311
//ColorPicker_upSkin (ColorPicker_upSkin) package { import flash.display.*; public dynamic class ColorPicker_upSkin extends MovieClip { } }//package
Section 312
//ComboBox_disabledSkin (ComboBox_disabledSkin) package { import flash.display.*; public dynamic class ComboBox_disabledSkin extends MovieClip { } }//package
Section 313
//ComboBox_downSkin (ComboBox_downSkin) package { import flash.display.*; public dynamic class ComboBox_downSkin extends MovieClip { } }//package
Section 314
//ComboBox_overSkin (ComboBox_overSkin) package { import flash.display.*; public dynamic class ComboBox_overSkin extends MovieClip { } }//package
Section 315
//ComboBox_upSkin (ComboBox_upSkin) package { import flash.display.*; public dynamic class ComboBox_upSkin extends MovieClip { } }//package
Section 316
//dragonfly_sound (dragonfly_sound) package { import flash.media.*; public dynamic class dragonfly_sound extends Sound { } }//package
Section 317
//engine_sound (engine_sound) package { import flash.media.*; public dynamic class engine_sound extends Sound { } }//package
Section 318
//flying_man_sound (flying_man_sound) package { import flash.media.*; public dynamic class flying_man_sound extends Sound { } }//package
Section 319
//focusRectSkin (focusRectSkin) package { import flash.display.*; public dynamic class focusRectSkin extends MovieClip { } }//package
Section 320
//IceSprite (IceSprite) package { import flash.display.*; public dynamic class IceSprite extends Sprite { } }//package
Section 321
//jump_sound (jump_sound) package { import flash.media.*; public dynamic class jump_sound extends Sound { } }//package
Section 322
//kamikazee_sound (kamikazee_sound) package { import flash.media.*; public dynamic class kamikazee_sound extends Sound { } }//package
Section 323
//List_skin (List_skin) package { import flash.display.*; public dynamic class List_skin extends MovieClip { } }//package
Section 324
//livesprite (livesprite) package { import flash.display.*; public dynamic class livesprite extends MovieClip { } }//package
Section 325
//MochiBot (MochiBot) package { import flash.display.*; import flash.net.*; import flash.system.*; public dynamic class MochiBot extends Sprite { public static function track(_arg1:Sprite, _arg2:String):MochiBot{ var _local3:MochiBot; var _local4:String; var _local5:URLVariables; var _local6:String; var _local7:URLRequest; var _local8:Loader; if (Security.sandboxType == "localWithFile"){ return (null); }; _local3 = new (MochiBot); _arg1.addChild(_local3); Security.allowDomain("*"); Security.allowInsecureDomain("*"); _local4 = "http://core.mochibot.com/my/core.swf"; _local5 = new URLVariables(); _local5["sb"] = Security.sandboxType; _local5["v"] = Capabilities.version; _local5["swfid"] = _arg2; _local5["mv"] = "8"; _local5["fv"] = "9"; _local6 = _local3.root.loaderInfo.loaderURL; if (_local6.indexOf("http") == 0){ _local5["url"] = _local6; } else { _local5["url"] = "local"; }; _local7 = new URLRequest(_local4); _local7.contentType = "application/x-www-form-urlencoded"; _local7.method = URLRequestMethod.POST; _local7.data = _local5; _local8 = new Loader(); _local3.addChild(_local8); _local8.load(_local7); return (_local3); } } }//package
Section 326
//pepsirun_sound (pepsirun_sound) package { import flash.media.*; public dynamic class pepsirun_sound extends Sound { } }//package
Section 327
//PoolBallSprite (PoolBallSprite) package { import flash.display.*; public dynamic class PoolBallSprite extends Sprite { } }//package
Section 328
//prayingman_sound (prayingman_sound) package { import flash.media.*; public dynamic class prayingman_sound extends Sound { } }//package
Section 329
//RagdollBody (RagdollBody) package { import flash.display.*; public dynamic class RagdollBody extends MovieClip { public var color_mc:MovieClip; } }//package
Section 330
//ScrollArrowDown_disabledSkin (ScrollArrowDown_disabledSkin) package { import flash.display.*; public dynamic class ScrollArrowDown_disabledSkin extends MovieClip { } }//package
Section 331
//ScrollArrowDown_downSkin (ScrollArrowDown_downSkin) package { import flash.display.*; public dynamic class ScrollArrowDown_downSkin extends MovieClip { } }//package
Section 332
//ScrollArrowDown_overSkin (ScrollArrowDown_overSkin) package { import flash.display.*; public dynamic class ScrollArrowDown_overSkin extends MovieClip { } }//package
Section 333
//ScrollArrowDown_upSkin (ScrollArrowDown_upSkin) package { import flash.display.*; public dynamic class ScrollArrowDown_upSkin extends MovieClip { } }//package
Section 334
//ScrollArrowUp_disabledSkin (ScrollArrowUp_disabledSkin) package { import flash.display.*; public dynamic class ScrollArrowUp_disabledSkin extends MovieClip { } }//package
Section 335
//ScrollArrowUp_downSkin (ScrollArrowUp_downSkin) package { import flash.display.*; public dynamic class ScrollArrowUp_downSkin extends MovieClip { } }//package
Section 336
//ScrollArrowUp_overSkin (ScrollArrowUp_overSkin) package { import flash.display.*; public dynamic class ScrollArrowUp_overSkin extends MovieClip { } }//package
Section 337
//ScrollArrowUp_upSkin (ScrollArrowUp_upSkin) package { import flash.display.*; public dynamic class ScrollArrowUp_upSkin extends MovieClip { } }//package
Section 338
//ScrollBar_thumbIcon (ScrollBar_thumbIcon) package { import flash.display.*; public dynamic class ScrollBar_thumbIcon extends MovieClip { } }//package
Section 339
//ScrollThumb_downSkin (ScrollThumb_downSkin) package { import flash.display.*; public dynamic class ScrollThumb_downSkin extends MovieClip { } }//package
Section 340
//ScrollThumb_overSkin (ScrollThumb_overSkin) package { import flash.display.*; public dynamic class ScrollThumb_overSkin extends MovieClip { } }//package
Section 341
//ScrollThumb_upSkin (ScrollThumb_upSkin) package { import flash.display.*; public dynamic class ScrollThumb_upSkin extends MovieClip { } }//package
Section 342
//ScrollTrack_skin (ScrollTrack_skin) package { import flash.display.*; public dynamic class ScrollTrack_skin extends MovieClip { } }//package
Section 343
//snow (snow) package { import flash.display.*; public dynamic class snow extends Sprite { } }//package
Section 344
//snow_sound (snow_sound) package { import flash.media.*; public dynamic class snow_sound extends Sound { } }//package
Section 345
//TextInput_disabledSkin (TextInput_disabledSkin) package { import flash.display.*; public dynamic class TextInput_disabledSkin extends MovieClip { } }//package
Section 346
//TextInput_upSkin (TextInput_upSkin) package { import flash.display.*; public dynamic class TextInput_upSkin extends MovieClip { } }//package
Section 347
//theme_sound (theme_sound) package { import flash.media.*; public dynamic class theme_sound extends Sound { } }//package
Section 348
//uglyducklyn_sound (uglyducklyn_sound) package { import flash.media.*; public dynamic class uglyducklyn_sound extends Sound { } }//package

Library Items

Symbol 1 Sound {uglyducklyn_sound}
Symbol 2 Sound {theme_sound}
Symbol 3 Sound {snow_sound}
Symbol 4 Sound {prayingman_sound}
Symbol 5 Sound {pepsirun_sound}
Symbol 6 Sound {kamikazee_sound}
Symbol 7 Sound {jump_sound}
Symbol 8 Sound {flying_man_sound}
Symbol 9 Sound {dragonfly_sound}
Symbol 10 Sound {engine_sound}
Symbol 11 Sound {coin_sound}
Symbol 12 Sound {cheer_crowd_sound}
Symbol 13 Sound {checkpoint_sound}
Symbol 14 Sound {boo_crowd_sound}
Symbol 15 Sound {bodyhit_sound}
Symbol 16 GraphicUsed by:17
Symbol 17 MovieClipUses:16Used by:31
Symbol 18 GraphicUsed by:31
Symbol 19 GraphicUsed by:31
Symbol 20 GraphicUsed by:31
Symbol 21 GraphicUsed by:31
Symbol 22 GraphicUsed by:31
Symbol 23 GraphicUsed by:31
Symbol 24 GraphicUsed by:31
Symbol 25 GraphicUsed by:31
Symbol 26 GraphicUsed by:31
Symbol 27 GraphicUsed by:31
Symbol 28 GraphicUsed by:31
Symbol 29 GraphicUsed by:31
Symbol 30 GraphicUsed by:31
Symbol 31 MovieClip {RagdollBody}Uses:17 18 19 20 21 22 23 24 25 26 27 28 29 30
Symbol 32 GraphicUsed by:33
Symbol 33 MovieClipUses:32Used by:49 98 99 515
Symbol 34 MovieClip {fl.core.ComponentShim}Used by:49 68 97 98 99 515
Symbol 35 GraphicUsed by:36
Symbol 36 MovieClip {focusRectSkin}Uses:35Used by:49 97 98 99
Symbol 37 GraphicUsed by:38
Symbol 38 MovieClip {ComboBox_upSkin}Uses:37Used by:99
Symbol 39 GraphicUsed by:40
Symbol 40 MovieClip {ComboBox_disabledSkin}Uses:39Used by:99
Symbol 41 GraphicUsed by:42
Symbol 42 MovieClip {ComboBox_overSkin}Uses:41Used by:99
Symbol 43 GraphicUsed by:44
Symbol 44 MovieClip {ComboBox_downSkin}Uses:43Used by:99
Symbol 45 GraphicUsed by:46
Symbol 46 MovieClip {TextInput_disabledSkin}Uses:45Used by:49
Symbol 47 GraphicUsed by:48
Symbol 48 MovieClip {TextInput_upSkin}Uses:47Used by:49
Symbol 49 MovieClip {fl.controls.TextInput}Uses:33 34 46 48 36Used by:99
Symbol 50 GraphicUsed by:51
Symbol 51 MovieClip {List_skin}Uses:50Used by:98
Symbol 52 GraphicUsed by:53
Symbol 53 MovieClip {CellRenderer_upSkin}Uses:52Used by:68
Symbol 54 GraphicUsed by:55
Symbol 55 MovieClip {CellRenderer_disabledSkin}Uses:54Used by:68
Symbol 56 GraphicUsed by:57
Symbol 57 MovieClip {CellRenderer_downSkin}Uses:56Used by:68
Symbol 58 GraphicUsed by:59
Symbol 59 MovieClip {CellRenderer_overSkin}Uses:58Used by:68
Symbol 60 GraphicUsed by:61
Symbol 61 MovieClip {CellRenderer_selectedDisabledSkin}Uses:60Used by:68
Symbol 62 GraphicUsed by:63
Symbol 63 MovieClip {CellRenderer_selectedDownSkin}Uses:62Used by:68
Symbol 64 GraphicUsed by:65
Symbol 65 MovieClip {CellRenderer_selectedOverSkin}Uses:64Used by:68
Symbol 66 GraphicUsed by:67
Symbol 67 MovieClip {CellRenderer_selectedUpSkin}Uses:66Used by:68
Symbol 68 MovieClip {fl.controls.listClasses.CellRenderer}Uses:53 34 55 57 59 61 63 65 67Used by:98
Symbol 69 GraphicUsed by:70
Symbol 70 MovieClip {ScrollTrack_skin}Uses:69Used by:97
Symbol 71 GraphicUsed by:74
Symbol 72 GraphicUsed by:73 76 80 90
Symbol 73 MovieClipUses:72Used by:74 84 86
Symbol 74 MovieClip {ScrollArrowUp_downSkin}Uses:71 73Used by:97
Symbol 75 GraphicUsed by:76
Symbol 76 MovieClip {ScrollArrowDown_downSkin}Uses:75 72Used by:97
Symbol 77 GraphicUsed by:78
Symbol 78 MovieClip {ScrollThumb_downSkin}Uses:77Used by:97
Symbol 79 GraphicUsed by:80
Symbol 80 MovieClip {ScrollArrowDown_overSkin}Uses:79 72Used by:97
Symbol 81 GraphicUsed by:82
Symbol 82 MovieClip {ScrollThumb_overSkin}Uses:81Used by:97
Symbol 83 GraphicUsed by:84
Symbol 84 MovieClip {ScrollArrowUp_overSkin}Uses:83 73Used by:97
Symbol 85 GraphicUsed by:86
Symbol 86 MovieClip {ScrollArrowUp_upSkin}Uses:85 73Used by:97
Symbol 87 GraphicUsed by:88
Symbol 88 MovieClip {ScrollThumb_upSkin}Uses:87Used by:97
Symbol 89 GraphicUsed by:90
Symbol 90 MovieClip {ScrollArrowDown_upSkin}Uses:89 72Used by:97
Symbol 91 GraphicUsed by:92
Symbol 92 MovieClip {ScrollArrowDown_disabledSkin}Uses:91Used by:97
Symbol 93 GraphicUsed by:94
Symbol 94 MovieClip {ScrollArrowUp_disabledSkin}Uses:93Used by:97
Symbol 95 GraphicUsed by:96
Symbol 96 MovieClip {ScrollBar_thumbIcon}Uses:95Used by:97
Symbol 97 MovieClip {fl.controls.ScrollBar}Uses:70 34 36 74 76 78 80 82 84 86 88 90 92 94 96Used by:98
Symbol 98 MovieClip {fl.controls.List}Uses:33 34 51 68 36 97Used by:99
Symbol 99 MovieClip {fl.controls.ComboBox}Uses:33 34 36 38 40 42 44 49 98
Symbol 100 GraphicUsed by:107 110 113 114 115 166 489 646 816 926
Symbol 101 GraphicUsed by:107 110 113 114 115
Symbol 102 GraphicUsed by:107 110 113 114 115
Symbol 103 GraphicUsed by:107 110 113 114 115
Symbol 104 GraphicUsed by:107 114
Symbol 105 GraphicUsed by:107 110 113 114 115
Symbol 106 GraphicUsed by:107 110
Symbol 107 MovieClipUses:100 101 102 103 104 105 106Used by:116
Symbol 108 GraphicUsed by:110 113 115
Symbol 109 GraphicUsed by:110 113 115
Symbol 110 MovieClipUses:100 101 102 103 108 109 106 105Used by:116
Symbol 111 GraphicUsed by:113 114 115
Symbol 112 GraphicUsed by:113 114 115
Symbol 113 MovieClipUses:100 101 102 103 108 109 105 111 112Used by:116
Symbol 114 MovieClipUses:100 101 102 103 104 111 112 105Used by:116
Symbol 115 MovieClipUses:100 101 102 103 108 109 105 111 112Used by:116
Symbol 116 MovieClip {ChildMovie}Uses:107 110 113 114 115
Symbol 117 GraphicUsed by:118
Symbol 118 MovieClipUses:117Used by:119
Symbol 119 MovieClip {src.smoke}Uses:118
Symbol 120 GraphicUsed by:121
Symbol 121 MovieClip {snow}Uses:120
Symbol 122 GraphicUsed by:123
Symbol 123 MovieClip {livesprite}Uses:122
Symbol 124 GraphicUsed by:125
Symbol 125 MovieClip {coinsprite}Uses:124
Symbol 126 GraphicUsed by:130 166 682 706 714
Symbol 127 GraphicUsed by:130 682 706 714
Symbol 128 GraphicUsed by:130 682 706 714 1028 1092
Symbol 129 GraphicUsed by:130 682 706 714
Symbol 130 MovieClip {BikeWheel}Uses:126 127 128 129
Symbol 131 GraphicUsed by:166
Symbol 132 GraphicUsed by:166
Symbol 133 GraphicUsed by:166 250
Symbol 134 GraphicUsed by:166 254 374
Symbol 135 GraphicUsed by:166
Symbol 136 GraphicUsed by:166
Symbol 137 GraphicUsed by:166
Symbol 138 GraphicUsed by:166
Symbol 139 GraphicUsed by:166
Symbol 140 GraphicUsed by:166
Symbol 141 GraphicUsed by:166
Symbol 142 GraphicUsed by:166
Symbol 143 GraphicUsed by:166
Symbol 144 GraphicUsed by:166
Symbol 145 GraphicUsed by:166 245 290
Symbol 146 GraphicUsed by:166
Symbol 147 GraphicUsed by:166
Symbol 148 GraphicUsed by:166
Symbol 149 GraphicUsed by:166
Symbol 150 GraphicUsed by:166
Symbol 151 GraphicUsed by:166
Symbol 152 GraphicUsed by:166 199 206 211 230 235 245 254 257 262 286 290 304 308 316 325 341 344 364 368 374 722
Symbol 153 GraphicUsed by:154
Symbol 154 MovieClipUses:153Used by:166
Symbol 155 GraphicUsed by:166
Symbol 156 GraphicUsed by:166
Symbol 157 GraphicUsed by:166
Symbol 158 GraphicUsed by:166
Symbol 159 GraphicUsed by:166
Symbol 160 GraphicUsed by:166
Symbol 161 GraphicUsed by:166
Symbol 162 GraphicUsed by:166
Symbol 163 GraphicUsed by:166
Symbol 164 GraphicUsed by:166
Symbol 165 GraphicUsed by:166
Symbol 166 MovieClip {x_fla.BikeMovie2_124}Uses:126 131 132 133 134 135 100 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 154 155 156 157 158 159 160 161 162 163 164 165Used by:489
Symbol 167 GraphicUsed by:168
Symbol 168 MovieClipUses:167Used by:199 722
Symbol 169 GraphicUsed by:199
Symbol 170 GraphicUsed by:199 206 211 221 230 235 240 245 250 254 257 262 266 270 274 280 286 290 300 304 308 312 316 321 325 329 333 337 341 344 348 352 356 360 364 368 374 722
Symbol 171 GraphicUsed by:199 206 211 221 230 235 240 245 250 254 257 262 266 270 274 304 308 312 316 321 325 329 333 337 341 344 348 352 356 722
Symbol 172 GraphicUsed by:199 206 211 221 230 235 240 245 250 254 257 262 266 270 274 304 308 312 316 321 325 329 333 337 341 344 348 352 356 722
Symbol 173 GraphicUsed by:199 206 211 257 262 304 308 341 344 722
Symbol 174 GraphicUsed by:199 280 333 337 360 722
Symbol 175 GraphicUsed by:199 206 211 221 230 235 240 245 250 254 257 262 266 270 274 280 286 290 300 304 308 312 316 321 325 329 333 337 341 344 348 352 356 360 364 368 722
Symbol 176 GraphicUsed by:199 206 211 221 230 235 240 245 250 254 257 262 266 270 274 280 286 290 300 304 308 312 316 321 325 329 333 337 341 344 348 352 356 360 364 368 722
Symbol 177 GraphicUsed by:199 206 211 221 230 235 240 245 250 254 257 262 266 270 274 280 286 290 300 304 308 312 316 321 325 329 333 337 341 344 348 352 356 360 364 368 374 722
Symbol 178 GraphicUsed by:199 206 211 221 230 235 240 245 250 254 257 262 266 270 274 280 286 290 300 304 308 312 316 321 325 329 333 337 341 344 348 352 356 360 364 368 374 722
Symbol 179 GraphicUsed by:199 206 211 221 230 235 240 245 250 254 257 262 266 270 274 280 286 290 300 304 308 312 316 321 325 329 333 337 341 344 348 352 356 360 364 368 722
Symbol 180 GraphicUsed by:199 206 211 221 230 235 240 245 250 254 257 262 266 270 274 280 286 290 300 304 308 312 316 321 325 329 333 337 341 344 348 352 356 360 364 368 374 722
Symbol 181 GraphicUsed by:199 206 211 221 230 235 240 245 250 254 257 262 266 270 274 280 286 290 300 304 308 312 316 321 325 329 333 337 341 344 348 352 356 360 364 368 374 722
Symbol 182 GraphicUsed by:199 206 211 221 230 235 240 245 250 254 257 262 266 270 274 280 286 290 300 304 308 312 316 321 325 329 333 337 341 344 348 352 356 360 364 368 374 722
Symbol 183 GraphicUsed by:199 206 211 221 230 235 240 245 250 254 257 262 266 270 274 280 286 290 300 304 308 312 316 321 325 329 333 337 341 344 348 352 356 360 364 368 374 722
Symbol 184 GraphicUsed by:199 206 211 221 230 235 240 245 250 254 257 262 266 270 274 280 286 290 300 304 308 312 316 321 325 329 333 337 341 344 348 352 356 360 364 368 374 722
Symbol 185 GraphicUsed by:199 206 257 280 304 341 364 368 374 722
Symbol 186 GraphicUsed by:199 206 211 221 230 235 240 245 250 254 257 262 266 270 274 280 286 290 300 304 308 312 316 321 325 329 333 337 341 344 348 352 356 360 364 368 374 722
Symbol 187 GraphicUsed by:199 206 211 221 230 235 240 245 250 254 257 262 266 270 274 280 286 290 300 304 308 312 316 321 325 329 333 337 341 344 348 352 356 360 364 368 374 722
Symbol 188 GraphicUsed by:199 206 211 221 230 235 240 245 250 254 257 262 266 270 274 280 286 290 300 304 308 312 316 321 325 329 333 337 341 344 348 352 356 360 364 368 374 722 906
Symbol 189 GraphicUsed by:199 211 221 230 235 240 245 250 254 262 266 270 274 280 286 290 300 308 312 316 321 325 329 333 337 344 348 352 356 360 364 368 374 722
Symbol 190 GraphicUsed by:199 206 211 221 230 235 240 245 250 254 257 262 266 270 274 280 286 290 300 304 308 312 316 321 325 329 333 341 344 348 352 356 360 364 368 374 722
Symbol 191 GraphicUsed by:199 206 211 221 230 235 240 245 250 254 257 262 266 270 274 280 286 290 300 304 308 312 316 321 325 329 333 341 344 348 352 356 360 364 368 374 722
Symbol 192 GraphicUsed by:199 206 211 221 230 235 240 245 250 254 257 262 266 270 274 280 286 290 300 304 308 312 316 321 325 329 333 337 341 344 348 352 356 360 364 368 374 722
Symbol 193 GraphicUsed by:199 206 211 221 227 230 232 257 262 266 270 274 280 304 321 341 344 348 352 360 364 374 722
Symbol 194 GraphicUsed by:199 206 211 230 235 245 254 257 262 286 290 304 308 316 325 341 344 364 368 374 722
Symbol 195 GraphicUsed by:199 206 211 230 235 245 254 257 262 286 290 304 308 316 325 341 344 364 368 374 722
Symbol 196 GraphicUsed by:199 206 211 230 235 245 254 257 262 286 290 304 308 316 341 344 364 368 374 722
Symbol 197 GraphicUsed by:199 206 211 230 235 245 254 257 262 286 290 304 308 316 325 341 344 364 368 374 722
Symbol 198 GraphicUsed by:199 206 211 221 230 235 240 245 250 254 257 262 266 270 274 280 286 290 300 304 308 312 316 321 325 329 333 337 341 344 348 352 356 360 364 368 374 722
Symbol 199 MovieClip {x_fla.Man_126}Uses:168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 152 195 196 197 198Used by:489
Symbol 200 GraphicUsed by:206
Symbol 201 GraphicUsed by:202
Symbol 202 MovieClipUses:201Used by:206
Symbol 203 GraphicUsed by:206 257
Symbol 204 GraphicUsed by:206 257 304 341
Symbol 205 GraphicUsed by:206 211 221 230 235 240 245 257 262 266 270 274 286 290 304 308 312 316 325 329 341 344 348 352 356 364 368
Symbol 206 MovieClip {x_fla.ManTest1_127}Uses:200 202 203 171 172 173 175 176 177 178 179 180 181 182 183 184 185 170 204 190 191 192 193 194 152 195 196 197 198 205 186 187 188Used by:489
Symbol 207 GraphicUsed by:208
Symbol 208 MovieClipUses:207Used by:211
Symbol 209 GraphicUsed by:211
Symbol 210 GraphicUsed by:211 221 230 235 240 245 250 254 262 266 270 274 286 290 300 308 312 316 321 325 329 333 337 344 348 352 356 360
Symbol 211 MovieClip {x_fla.ManTest1_129}Uses:208 209 171 172 173 175 176 177 178 179 180 181 182 183 184 210 190 191 193 194 152 195 196 197 205 170 189 192 198 186 187 188Used by:489
Symbol 212 GraphicUsed by:213
Symbol 213 MovieClipUses:212Used by:221
Symbol 214 GraphicUsed by:221
Symbol 215 GraphicUsed by:221 266 312 348
Symbol 216 GraphicUsed by:221 240 250 266 270 274 280 300 312 321 348 352 356 360 364
Symbol 217 GraphicUsed by:221 240 250 266 270 274 280 290 300 312 316 321 348 352 356 360 364
Symbol 218 GraphicUsed by:221 240 250 266 270 274 280 290 300 312 321 348 352 356 360 364
Symbol 219 GraphicUsed by:221 240 250 266 270 274 280 290 300 312 321 348 352 356 360 364
Symbol 220 GraphicUsed by:221 240 250 266 270 274 280 290 300 312 321 348 352 356 360 364
Symbol 221 MovieClip {x_fla.ManTest1_131}Uses:213 214 171 172 215 175 176 177 178 179 180 181 182 183 184 210 190 191 193 216 217 218 219 220 205 170 189 192 198 186 187 188Used by:489
Symbol 222 GraphicUsed by:227 232
Symbol 223 GraphicUsed by:227 232
Symbol 224 GraphicUsed by:227 232
Symbol 225 GraphicUsed by:227 232
Symbol 226 GraphicUsed by:227
Symbol 227 MovieClipUses:222 223 224 225 193 226Used by:230
Symbol 228 GraphicUsed by:230
Symbol 229 GraphicUsed by:230 254 325 368 374
Symbol 230 MovieClip {x_fla.man_133}Uses:227 228 171 172 175 176 177 178 179 180 181 182 183 184 210 190 191 193 194 152 195 196 197 229 205 170 189 186 187 188 192 198Used by:489
Symbol 231 GraphicUsed by:232
Symbol 232 MovieClipUses:222 223 224 225 193 231Used by:235
Symbol 233 GraphicUsed by:235
Symbol 234 GraphicUsed by:235 250
Symbol 235 MovieClip {x_fla.man_135}Uses:232 233 171 172 175 176 177 178 179 180 181 182 183 184 210 190 191 194 152 195 196 197 234 205 170 189 192 198 186 187 188Used by:489
Symbol 236 GraphicUsed by:237
Symbol 237 MovieClipUses:236Used by:240
Symbol 238 GraphicUsed by:240
Symbol 239 GraphicUsed by:240 274 356
Symbol 240 MovieClip {x_fla.ManTest1_137}Uses:237 238 171 172 175 176 177 178 179 180 181 182 183 184 210 170 189 186 187 188 192 198 190 191 205 216 217 218 219 220 239Used by:489
Symbol 241 GraphicUsed by:242
Symbol 242 MovieClipUses:241Used by:245
Symbol 243 GraphicUsed by:245
Symbol 244 GraphicUsed by:245 250 368
Symbol 245 MovieClip {x_fla.MantTest1_139}Uses:242 243 145 171 172 175 176 177 178 179 180 181 182 183 184 210 170 189 186 187 188 192 198 190 191 205 194 152 195 196 197 244Used by:489
Symbol 246 GraphicUsed by:247
Symbol 247 MovieClipUses:246Used by:250
Symbol 248 GraphicUsed by:250
Symbol 249 GraphicUsed by:250 254
Symbol 250 MovieClip {x_fla.ManTest1_141}Uses:247 248 190 191 216 244 217 218 219 220 234 133 171 172 175 176 177 178 179 180 181 182 183 184 210 170 189 186 187 188 192 198 249Used by:489
Symbol 251 GraphicUsed by:252
Symbol 252 MovieClipUses:251Used by:254
Symbol 253 GraphicUsed by:254
Symbol 254 MovieClip {x_fla.ManTest1_143}Uses:252 253 190 191 194 152 195 196 197 229 134 171 172 175 176 177 178 179 180 181 182 183 184 210 170 189 186 187 188 192 198 249Used by:489
Symbol 255 GraphicUsed by:256
Symbol 256 MovieClipUses:255Used by:257
Symbol 257 MovieClip {x_fla.ManTest2_145}Uses:256 203 171 172 173 175 176 177 178 179 180 181 182 183 184 185 170 204 190 191 192 193 194 152 195 196 197 198 205 186 187 188Used by:489
Symbol 258 GraphicUsed by:259
Symbol 259 MovieClipUses:258Used by:262
Symbol 260 GraphicUsed by:262 344
Symbol 261 GraphicUsed by:262 290 308 316 321 337 344 368
Symbol 262 MovieClip {x_fla.ManTest2_147}Uses:259 260 171 172 173 175 176 177 178 179 180 181 182 183 184 210 190 191 193 194 152 195 196 197 205 170 189 192 198 261 186 187 188Used by:489
Symbol 263 GraphicUsed by:264
Symbol 264 MovieClipUses:263Used by:266
Symbol 265 GraphicUsed by:266
Symbol 266 MovieClip {x_fla.ManTest2_149}Uses:264 265 171 172 215 175 176 177 178 179 180 181 182 183 184 210 190 191 193 216 217 218 219 220 205 170 189 192 198 186 187 188Used by:489
Symbol 267 GraphicUsed by:268
Symbol 268 MovieClipUses:267Used by:270
Symbol 269 GraphicUsed by:270
Symbol 270 MovieClip {x_fla.ManTest2_151}Uses:268 269 171 172 175 176 177 178 179 180 181 182 183 184 210 190 191 193 216 217 218 219 220 205 170 189 186 187 188 192 198Used by:489
Symbol 271 GraphicUsed by:272
Symbol 272 MovieClipUses:271Used by:274
Symbol 273 GraphicUsed by:274
Symbol 274 MovieClip {x_fla.ManTest2_153}Uses:272 273 171 172 175 176 177 178 179 180 181 182 183 184 210 190 191 193 216 217 218 219 220 239 205 170 189 186 187 188 192 198Used by:489
Symbol 275 GraphicUsed by:276
Symbol 276 MovieClipUses:275Used by:280
Symbol 277 GraphicUsed by:280
Symbol 278 GraphicUsed by:280 360
Symbol 279 GraphicUsed by:280 360
Symbol 280 MovieClip {x_fla.ManTest2_155}Uses:276 277 175 176 177 178 179 180 181 278 279 182 183 184 185 190 191 193 216 217 218 219 220 174 170 189 186 187 188 192 198Used by:489
Symbol 281 GraphicUsed by:282
Symbol 282 MovieClipUses:281Used by:286
Symbol 283 GraphicUsed by:286
Symbol 284 GraphicUsed by:286 290 364 368
Symbol 285 GraphicUsed by:286 290 364 368
Symbol 286 MovieClip {x_fla.ManTest2_157}Uses:282 283 190 191 195 196 197 205 284 285 175 176 177 178 179 180 181 182 183 184 210 194 152 170 189 186 187 188 192 198Used by:489
Symbol 287 GraphicUsed by:288
Symbol 288 MovieClipUses:287Used by:290
Symbol 289 GraphicUsed by:290
Symbol 290 MovieClip {x_fla.ManTest2_159}Uses:288 289 217 218 219 220 205 261 145 284 285 175 176 177 178 179 180 181 182 183 184 210 190 191 194 152 195 196 197 170 189 186 187 188 192 198Used by:489
Symbol 291 GraphicUsed by:292
Symbol 292 MovieClipUses:291Used by:300
Symbol 293 GraphicUsed by:300
Symbol 294 GraphicUsed by:300 374
Symbol 295 GraphicUsed by:300 374
Symbol 296 GraphicUsed by:300 374
Symbol 297 GraphicUsed by:300 374
Symbol 298 GraphicUsed by:300 374
Symbol 299 GraphicUsed by:300 374
Symbol 300 MovieClip {x_fla.ManTest2_161}Uses:292 293 294 295 296 297 298 175 176 177 178 179 180 181 182 183 184 210 190 191 216 217 218 219 220 299 170 189 192 198 186 187 188Used by:489
Symbol 301 GraphicUsed by:302
Symbol 302 MovieClipUses:301Used by:304
Symbol 303 GraphicUsed by:304
Symbol 304 MovieClip {x_fla.ManTest3_163}Uses:302 303 171 172 173 175 176 177 178 179 180 181 182 183 184 185 170 204 190 191 192 193 194 152 195 196 197 198 205 186 187 188Used by:489
Symbol 305 GraphicUsed by:306
Symbol 306 MovieClipUses:305Used by:308
Symbol 307 GraphicUsed by:308
Symbol 308 MovieClip {x_fla.ManTest3_165}Uses:306 307 171 172 173 175 176 177 178 179 180 181 182 183 184 210 190 191 194 152 195 196 197 205 170 189 192 198 261 186 187 188Used by:489
Symbol 309 GraphicUsed by:310
Symbol 310 MovieClipUses:309Used by:312
Symbol 311 GraphicUsed by:312
Symbol 312 MovieClip {x_fla.ManTest3_167}Uses:310 311 171 172 215 175 176 177 178 179 182 183 184 210 190 191 216 217 218 219 220 205 170 189 192 198 186 187 188 180 181Used by:489
Symbol 313 GraphicUsed by:314
Symbol 314 MovieClipUses:313Used by:316
Symbol 315 GraphicUsed by:316
Symbol 316 MovieClip {x_fla.ManTest3_169}Uses:314 315 171 172 175 176 177 178 179 180 181 182 183 184 210 190 191 194 152 195 196 197 217 205 170 189 186 187 188 192 198 261Used by:489
Symbol 317 GraphicUsed by:318
Symbol 318 MovieClipUses:317Used by:321
Symbol 319 GraphicUsed by:321
Symbol 320 GraphicUsed by:321
Symbol 321 MovieClip {x_fla.ManTest3_171}Uses:318 319 171 172 175 176 177 178 179 180 181 182 183 184 210 190 191 193 216 217 218 219 220 320 170 189 192 198 261 186 187 188Used by:489
Symbol 322 GraphicUsed by:323
Symbol 323 MovieClipUses:322Used by:325
Symbol 324 GraphicUsed by:325
Symbol 325 MovieClip {x_fla.ManTest3_173}Uses:323 324 198 182 183 184 210 170 189 192 171 172 175 176 177 178 179 180 181 190 191 194 152 195 197 229 205 186 187 188Used by:489
Symbol 326 GraphicUsed by:327
Symbol 327 MovieClipUses:326Used by:329
Symbol 328 GraphicUsed by:329
Symbol 329 MovieClip {x_fla.ManTest3_175}Uses:327 328 198 182 183 184 210 170 189 192 171 172 175 176 177 178 179 180 181 190 191 205 186 187 188Used by:489
Symbol 330 GraphicUsed by:331
Symbol 331 MovieClipUses:330Used by:333
Symbol 332 GraphicUsed by:333
Symbol 333 MovieClip {x_fla.ManTest3_177}Uses:331 332 182 183 184 210 170 189 192 198 190 191 171 172 175 176 177 178 179 180 181 174 186 187 188Used by:489
Symbol 334 GraphicUsed by:335
Symbol 335 MovieClipUses:334Used by:337
Symbol 336 GraphicUsed by:337
Symbol 337 MovieClip {x_fla.ManTest3_179}Uses:335 336 182 183 184 210 170 189 192 198 171 172 175 176 177 178 179 180 181 174 261 186 187 188Used by:489
Symbol 338 GraphicUsed by:339
Symbol 339 MovieClipUses:338Used by:341
Symbol 340 GraphicUsed by:341
Symbol 341 MovieClip {x_fla.ManTest4_181}Uses:339 340 171 172 173 175 176 177 178 179 180 181 182 183 184 185 170 204 190 191 192 193 194 152 195 196 197 198 205 186 187 188Used by:489
Symbol 342 GraphicUsed by:343
Symbol 343 MovieClipUses:342Used by:344
Symbol 344 MovieClip {x_fla.ManTest4_183}Uses:343 260 171 172 173 175 176 177 178 179 180 181 182 183 184 210 190 191 193 194 152 195 196 197 205 170 189 192 198 261 186 187 188Used by:489
Symbol 345 GraphicUsed by:346
Symbol 346 MovieClipUses:345Used by:348
Symbol 347 GraphicUsed by:348
Symbol 348 MovieClip {x_fla.ManTest4_185}Uses:346 347 171 172 215 175 176 177 178 179 180 181 182 183 184 210 190 191 193 216 217 218 219 220 205 170 189 192 198 186 187 188Used by:489
Symbol 349 GraphicUsed by:350
Symbol 350 MovieClipUses:349Used by:352
Symbol 351 GraphicUsed by:352
Symbol 352 MovieClip {x_fla.ManTest4_187}Uses:350 351 171 172 175 176 177 178 179 180 181 182 183 184 210 190 191 193 216 217 218 219 220 205 170 189 192 198 186 187 188Used by:489
Symbol 353 GraphicUsed by:354
Symbol 354 MovieClipUses:353Used by:356
Symbol 355 GraphicUsed by:356
Symbol 356 MovieClip {x_fla.ManTest4_189}Uses:354 355 171 172 175 176 177 178 179 180 181 182 183 184 210 190 191 216 217 218 219 220 239 205 170 189 186 187 188 192 198Used by:489
Symbol 357 GraphicUsed by:358
Symbol 358 MovieClipUses:357Used by:360
Symbol 359 GraphicUsed by:360
Symbol 360 MovieClip {x_fla.ManTest4_191}Uses:358 359 175 176 177 178 179 180 181 278 279 182 183 184 210 190 191 193 216 217 218 219 220 174 170 189 186 187 188 192 198Used by:489
Symbol 361 GraphicUsed by:362
Symbol 362 MovieClipUses:361Used by:364
Symbol 363 GraphicUsed by:364
Symbol 364 MovieClip {x_fla.ManTest4_193}Uses:362 363 190 191 193 194 152 195 196 197 205 284 285 175 176 177 178 179 180 181 182 183 184 185 216 217 218 219 220 170 189 186 187 188 192 198Used by:489
Symbol 365 GraphicUsed by:366
Symbol 366 MovieClipUses:365Used by:368
Symbol 367 GraphicUsed by:368
Symbol 368 MovieClip {x_fla.ManTest4_195}Uses:366 367 194 152 195 196 197 229 205 261 284 285 175 176 177 178 179 180 181 182 183 184 185 190 191 244 170 189 186 187 188 192 198Used by:489
Symbol 369 GraphicUsed by:370
Symbol 370 MovieClipUses:369Used by:374
Symbol 371 GraphicUsed by:374
Symbol 372 GraphicUsed by:374
Symbol 373 GraphicUsed by:374
Symbol 374 MovieClip {x_fla.ManTest4_197}Uses:370 371 294 295 296 134 297 298 372 177 178 373 180 181 182 183 184 185 190 191 193 194 152 195 196 197 229 299 170 189 192 198 186 187 188Used by:489
Symbol 375 GraphicUsed by:489
Symbol 376 GraphicUsed by:489
Symbol 377 GraphicUsed by:426 489
Symbol 378 GraphicUsed by:426 489
Symbol 379 GraphicUsed by:426 434 442 447 452 456 460 464 468 472 477 489
Symbol 380 GraphicUsed by:426 434 442 447 452 456 460 464 468 472 477 489
Symbol 381 GraphicUsed by:426 434 442 447 452 456 460 464 468 472 477 489
Symbol 382 GraphicUsed by:426 434 442 489
Symbol 383 GraphicUsed by:426 434 442 447 452 456 460 464 468 472 477 489
Symbol 384 GraphicUsed by:426 434 447 452 456 460 464 468 472 477 489
Symbol 385 GraphicUsed by:426 434 442 447 452 456 460 464 468 472 477 489
Symbol 386 GraphicUsed by:426 434 442 447 452 456 460 464 468 472 477 489
Symbol 387 GraphicUsed by:426 434 456 464 468 472 477 489
Symbol 388 GraphicUsed by:426 434 442 447 456 460 464 468 472 477 489
Symbol 389 GraphicUsed by:426 434 442 447 456 460 464 468 472 477 489
Symbol 390 GraphicUsed by:489
Symbol 391 GraphicUsed by:426 434 442 447 456 460 464 468 472 477 489
Symbol 392 GraphicUsed by:426 434 442 447 456 460 464 468 472 477 489
Symbol 393 GraphicUsed by:426 434 442 447 456 460 464 468 472 477 489
Symbol 394 GraphicUsed by:489
Symbol 395 GraphicUsed by:426 468 472 489
Symbol 396 GraphicUsed by:426 434 447 477 489
Symbol 397 GraphicUsed by:489
Symbol 398 GraphicUsed by:426 489
Symbol 399 GraphicUsed by:426 489
Symbol 400 GraphicUsed by:489
Symbol 401 GraphicUsed by:426 442 447 452 456 460 464 468 472 477 489
Symbol 402 GraphicUsed by:426 442 447 452 456 460 464 468 472 477 489
Symbol 403 GraphicUsed by:426 434 442 447 452 456 460 464 468 472 477 489 977
Symbol 404 GraphicUsed by:426 434 442 447 452 456 460 464 468 472 477 489
Symbol 405 GraphicUsed by:489
Symbol 406 GraphicUsed by:426 442 447 452 456 460 464 468 472 477 489
Symbol 407 GraphicUsed by:426 434 442 447 452 456 460 464 468 472 477 489
Symbol 408 GraphicUsed by:426 434 442 447 452 456 460 464 468 472 477 489
Symbol 409 GraphicUsed by:489
Symbol 410 GraphicUsed by:426 434 442 447 452 456 460 464 468 472 477 489
Symbol 411 GraphicUsed by:426 434 442 447 452 456 460 464 468 472 477 489
Symbol 412 GraphicUsed by:426 452 489
Symbol 413 GraphicUsed by:426 452 489
Symbol 414 GraphicUsed by:426 452 489
Symbol 415 GraphicUsed by:426 452 489
Symbol 416 GraphicUsed by:426 452 489
Symbol 417 GraphicUsed by:489
Symbol 418 GraphicUsed by:489
Symbol 419 GraphicUsed by:426 442 447 452 456 460 464 489
Symbol 420 GraphicUsed by:426 434 442 447 452 456 460 464 468 472 477 489
Symbol 421 GraphicUsed by:426 434 442 447 452 456 460 464 468 472 477 489
Symbol 422 GraphicUsed by:426 434 442 447 452 456 460 464 468 472 477 489
Symbol 423 GraphicUsed by:424
Symbol 424 MovieClipUses:423Used by:426
Symbol 425 GraphicUsed by:426
Symbol 426 MovieClip {x_fla.ManTest5_199}Uses:424 425 377 378 379 380 381 382 383 384 385 386 387 388 389 391 392 393 395 396 398 399 401 402 403 404 406 407 408 410 411 412 413 414 415 416 419 420 421 422Used by:489
Symbol 427 GraphicUsed by:428
Symbol 428 MovieClipUses:427Used by:434
Symbol 429 GraphicUsed by:434
Symbol 430 GraphicUsed by:434
Symbol 431 GraphicUsed by:434
Symbol 432 GraphicUsed by:434
Symbol 433 GraphicUsed by:434
Symbol 434 MovieClip {x_fla.ManTest5_201}Uses:428 429 379 380 381 382 383 384 385 386 430 403 404 431 407 408 410 411 387 388 389 432 391 392 393 433 396 420 421 422Used by:489
Symbol 435 GraphicUsed by:436
Symbol 436 MovieClipUses:435Used by:442
Symbol 437 GraphicUsed by:442
Symbol 438 GraphicUsed by:442 447 452 456 460 464 468 472 477
Symbol 439 GraphicUsed by:442 447 452 456 460 464 468 472 477
Symbol 440 GraphicUsed by:442 447 460 464
Symbol 441 GraphicUsed by:442
Symbol 442 MovieClip {x_fla.ManTest6_203}Uses:436 437 438 439 440 401 402 403 404 406 407 408 379 380 381 382 383 441 410 411 385 388 389 391 392 393 386 419 420 421 422Used by:489
Symbol 443 GraphicUsed by:444
Symbol 444 MovieClipUses:443Used by:447
Symbol 445 GraphicUsed by:447
Symbol 446 GraphicUsed by:447 452 456 460 464 468 472 477
Symbol 447 MovieClip {x_fla.ManTest6_205}Uses:444 445 438 439 440 401 402 403 404 406 407 408 379 380 381 446 410 411 388 389 391 392 393 419 383 384 385 386 396 420 421 422Used by:489
Symbol 448 GraphicUsed by:449
Symbol 449 MovieClipUses:448Used by:452
Symbol 450 GraphicUsed by:452
Symbol 451 GraphicUsed by:452
Symbol 452 MovieClip {x_fla.ManTest6_207}Uses:449 450 438 439 451 401 402 403 404 406 407 408 379 380 381 446 410 411 412 413 414 415 416 419 383 384 385 386 420 421 422Used by:489
Symbol 453 GraphicUsed by:454
Symbol 454 MovieClipUses:453Used by:456
Symbol 455 GraphicUsed by:456
Symbol 456 MovieClip {x_fla.ManTest6_209}Uses:454 455 438 439 401 402 403 404 406 407 408 379 380 381 446 410 411 387 388 389 391 392 393 383 384 385 386 420 421 422 419Used by:489
Symbol 457 GraphicUsed by:458
Symbol 458 MovieClipUses:457Used by:460
Symbol 459 GraphicUsed by:460
Symbol 460 MovieClip {x_fla.ManTest6_211}Uses:458 459 438 439 440 401 402 403 404 406 407 408 379 380 381 446 410 411 388 389 391 392 393 383 384 385 386 420 421 422 419Used by:489
Symbol 461 GraphicUsed by:462
Symbol 462 MovieClipUses:461Used by:464
Symbol 463 GraphicUsed by:464
Symbol 464 MovieClip {x_fla.ManTest6_213}Uses:462 463 438 439 440 401 402 403 404 406 407 408 379 380 381 446 410 411 387 388 389 391 392 393 383 384 385 386 419 420 421 422Used by:489
Symbol 465 GraphicUsed by:466
Symbol 466 MovieClipUses:465Used by:468
Symbol 467 GraphicUsed by:468
Symbol 468 MovieClip {x_fla.ManTest6_215}Uses:466 467 438 439 401 402 403 404 406 407 408 379 380 381 446 410 411 387 388 389 391 392 393 383 384 385 386 395 420 421 422Used by:489
Symbol 469 GraphicUsed by:470
Symbol 470 MovieClipUses:469Used by:472
Symbol 471 GraphicUsed by:472
Symbol 472 MovieClip {x_fla.ManTest6_217}Uses:470 471 438 439 379 401 402 403 404 406 407 408 380 381 446 410 411 387 388 389 391 392 393 383 384 385 386 395 420 421 422Used by:489
Symbol 473 GraphicUsed by:474
Symbol 474 MovieClipUses:473Used by:477
Symbol 475 GraphicUsed by:477
Symbol 476 GraphicUsed by:477
Symbol 477 MovieClip {x_fla.ManTest6_219}Uses:474 475 438 439 401 402 403 404 406 407 408 379 380 381 446 410 387 388 389 391 392 383 384 385 386 476 396 420 421 422 411 393Used by:489
Symbol 478 GraphicUsed by:489
Symbol 479 GraphicUsed by:489
Symbol 480 GraphicUsed by:489
Symbol 481 GraphicUsed by:489
Symbol 482 GraphicUsed by:489
Symbol 483 GraphicUsed by:489
Symbol 484 GraphicUsed by:489
Symbol 485 GraphicUsed by:489
Symbol 486 GraphicUsed by:489
Symbol 487 GraphicUsed by:489
Symbol 488 GraphicUsed by:489
Symbol 489 MovieClip {src.BikeBody}Uses:166 199 206 211 221 230 235 240 245 250 254 257 262 266 270 274 280 286 290 300 304 308 312 316 321 325 329 333 337 341 344 348 352 356 360 364 368 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 426 434 442 447 452 456 460 464 468 472 477 478 479 480 481 482 483 484 485 100 486 487 488
Symbol 490 GraphicUsed by:491
Symbol 491 MovieClip {PoolBallSprite}Uses:490
Symbol 492 GraphicUsed by:493
Symbol 493 MovieClip {IceSprite}Uses:492
Symbol 494 GraphicUsed by:495
Symbol 495 MovieClip {ColorPicker_upSkin}Uses:494Used by:515
Symbol 496 GraphicUsed by:497
Symbol 497 MovieClip {ColorPicker_disabledSkin}Uses:496Used by:515
Symbol 498 GraphicUsed by:499
Symbol 499 MovieClip {ColorPicker_swatchSkin}Uses:498Used by:515
Symbol 500 GraphicUsed by:501
Symbol 501 MovieClipUses:500Used by:504 515
Symbol 502 GraphicUsed by:503
Symbol 503 MovieClipUses:502Used by:504 515
Symbol 504 MovieClip {ColorPicker_backgroundSkin}Uses:501 503Used by:515
Symbol 505 GraphicUsed by:506
Symbol 506 MovieClip {ColorPicker_downSkin}Uses:505Used by:515
Symbol 507 GraphicUsed by:508
Symbol 508 MovieClip {ColorPicker_textFieldSkin}Uses:507Used by:515
Symbol 509 GraphicUsed by:510
Symbol 510 MovieClip {ColorPicker_overSkin}Uses:509Used by:515
Symbol 511 GraphicUsed by:512
Symbol 512 MovieClip {ColorPicker_colorWell}Uses:511Used by:515
Symbol 513 GraphicUsed by:514
Symbol 514 MovieClip {ColorPicker_swatchSelectedSkin}Uses:513Used by:515
Symbol 515 MovieClip {fl.controls.ColorPicker}Uses:33 34 495 497 499 504 506 508 510 512 514 503 501Used by:744
Symbol 516 GraphicUsed by:517
Symbol 517 MovieClip {com.roguedevelopment.pulse.emitter.MovieClipEmitter}Uses:516
Symbol 518 FontUsed by:519 659 660 661 662 663 664 665 715 716 717 718 719 720 723 737 766 767 770 771 774 775 777 778 784 785 786 789 790 794 818 1002 1029 1034 1036 1040 1045 1051 1055 1059 1063 1066 1070 1074 1078
Symbol 519 EditableTextUses:518Used by:Timeline
Symbol 520 GraphicUsed by:522
Symbol 521 GraphicUsed by:522
Symbol 522 MovieClip {x_fla.Symbol36_2}Uses:520 521Used by:580
Symbol 523 GraphicUsed by:525
Symbol 524 GraphicUsed by:525
Symbol 525 MovieClip {x_fla.Symbol37_3}Uses:523 524Used by:580
Symbol 526 GraphicUsed by:532
Symbol 527 GraphicUsed by:532
Symbol 528 GraphicUsed by:532
Symbol 529 GraphicUsed by:532
Symbol 530 GraphicUsed by:532
Symbol 531 GraphicUsed by:532
Symbol 532 MovieClip {x_fla.Symbol38_4}Uses:526 527 528 529 530 531Used by:580
Symbol 533 GraphicUsed by:539
Symbol 534 GraphicUsed by:539
Symbol 535 GraphicUsed by:539
Symbol 536 GraphicUsed by:539
Symbol 537 GraphicUsed by:539
Symbol 538 GraphicUsed by:539
Symbol 539 MovieClip {x_fla.Symbol39_5}Uses:533 534 535 536 537 538Used by:580
Symbol 540 GraphicUsed by:542
Symbol 541 GraphicUsed by:542
Symbol 542 MovieClip {x_fla.Symbol40_6}Uses:540 541Used by:580
Symbol 543 GraphicUsed by:545
Symbol 544 GraphicUsed by:545
Symbol 545 MovieClip {x_fla.Symbol41_7}Uses:543 544Used by:580
Symbol 546 GraphicUsed by:548
Symbol 547 GraphicUsed by:548
Symbol 548 MovieClip {x_fla.Symbol42_8}Uses:546 547Used by:580
Symbol 549 GraphicUsed by:551 562
Symbol 550 GraphicUsed by:551
Symbol 551 MovieClip {x_fla.Symbol43_9}Uses:549 550Used by:580
Symbol 552 GraphicUsed by:554
Symbol 553 GraphicUsed by:554
Symbol 554 MovieClip {x_fla.Symbol44_10}Uses:552 553Used by:580
Symbol 555 GraphicUsed by:557
Symbol 556 GraphicUsed by:557
Symbol 557 MovieClip {x_fla.Symbol45_11}Uses:555 556Used by:580
Symbol 558 GraphicUsed by:560
Symbol 559 GraphicUsed by:560
Symbol 560 MovieClip {x_fla.Symbol46_12}Uses:558 559Used by:580
Symbol 561 GraphicUsed by:562
Symbol 562 MovieClip {x_fla.Symbol47_13}Uses:549 561Used by:580
Symbol 563 GraphicUsed by:565
Symbol 564 GraphicUsed by:565
Symbol 565 MovieClip {x_fla.Symbol48_14}Uses:563 564Used by:580
Symbol 566 GraphicUsed by:572
Symbol 567 GraphicUsed by:572
Symbol 568 GraphicUsed by:572
Symbol 569 GraphicUsed by:572
Symbol 570 GraphicUsed by:572
Symbol 571 GraphicUsed by:572
Symbol 572 MovieClip {x_fla.Symbol50_15}Uses:566 567 568 569 570 571Used by:580
Symbol 573 GraphicUsed by:579
Symbol 574 GraphicUsed by:579
Symbol 575 GraphicUsed by:579
Symbol 576 GraphicUsed by:579
Symbol 577 GraphicUsed by:579
Symbol 578 GraphicUsed by:579
Symbol 579 MovieClip {x_fla.Symbol49_16}Uses:573 574 575 576 577 578Used by:580
Symbol 580 MovieClip {x_fla.Symbol34_1}Uses:522 525 532 539 542 545 548 551 554 557 560 562 565 572 579Used by:Timeline
Symbol 581 GraphicUsed by:582
Symbol 582 ButtonUses:581Used by:Timeline
Symbol 583 SoundUsed by:Timeline
Symbol 584 GraphicUsed by:585
Symbol 585 MovieClipUses:584Used by:586
Symbol 586 MovieClip {x_fla.Symbol3_19}Uses:585Used by:590
Symbol 587 GraphicUsed by:588
Symbol 588 MovieClipUses:587Used by:589
Symbol 589 MovieClip {x_fla.Symbol7_21}Uses:588Used by:590
Symbol 590 MovieClip {x_fla.Symbol4_18}Uses:586 589Used by:Timeline
Symbol 591 GraphicUsed by:605 620 1028  Timeline
Symbol 592 GraphicUsed by:605 620  Timeline
Symbol 593 GraphicUsed by:605 620  Timeline
Symbol 594 GraphicUsed by:605 620  Timeline
Symbol 595 GraphicUsed by:605 620  Timeline
Symbol 596 GraphicUsed by:605 620  Timeline
Symbol 597 GraphicUsed by:605 620  Timeline
Symbol 598 GraphicUsed by:605 620  Timeline
Symbol 599 GraphicUsed by:605 620  Timeline
Symbol 600 GraphicUsed by:605 620  Timeline
Symbol 601 GraphicUsed by:605 620  Timeline
Symbol 602 GraphicUsed by:605 620  Timeline
Symbol 603 GraphicUsed by:605 620  Timeline
Symbol 604 GraphicUsed by:605 620  Timeline
Symbol 605 MovieClipUses:591 592 593 594 595 596 597 598 599 600 601 602 603 604Used by:616
Symbol 606 GraphicUsed by:615 620 1028  Timeline
Symbol 607 GraphicUsed by:615 620 1028  Timeline
Symbol 608 GraphicUsed by:615 620 1028  Timeline
Symbol 609 GraphicUsed by:615 620 1028  Timeline
Symbol 610 GraphicUsed by:615 620 1028  Timeline
Symbol 611 GraphicUsed by:615 620 1028  Timeline
Symbol 612 GraphicUsed by:615 620 1028  Timeline
Symbol 613 GraphicUsed by:615 620 1028  Timeline
Symbol 614 GraphicUsed by:615 620 1028  Timeline
Symbol 615 MovieClipUses:606 607 608 609 610 611 612 613 614Used by:616
Symbol 616 MovieClip {x_fla.Symbol30_23}Uses:605 615Used by:Timeline
Symbol 617 GraphicUsed by:Timeline
Symbol 618 GraphicUsed by:620 1028
Symbol 619 GraphicUsed by:620  Timeline
Symbol 620 MovieClipUses:618 591 592 593 594 595 596 597 598 599 600 601 602 603 604 606 607 608 609 610 611 612 613 614 619Used by:Timeline
Symbol 621 GraphicUsed by:Timeline
Symbol 622 GraphicUsed by:Timeline
Symbol 623 GraphicUsed by:Timeline
Symbol 624 GraphicUsed by:Timeline
Symbol 625 GraphicUsed by:Timeline
Symbol 626 GraphicUsed by:646
Symbol 627 GraphicUsed by:646
Symbol 628 GraphicUsed by:646
Symbol 629 GraphicUsed by:646
Symbol 630 GraphicUsed by:646
Symbol 631 GraphicUsed by:646
Symbol 632 GraphicUsed by:646
Symbol 633 GraphicUsed by:646
Symbol 634 GraphicUsed by:646
Symbol 635 GraphicUsed by:646
Symbol 636 GraphicUsed by:646
Symbol 637 GraphicUsed by:646
Symbol 638 GraphicUsed by:646
Symbol 639 GraphicUsed by:646
Symbol 640 GraphicUsed by:646
Symbol 641 GraphicUsed by:646
Symbol 642 GraphicUsed by:646
Symbol 643 GraphicUsed by:646
Symbol 644 GraphicUsed by:646
Symbol 645 GraphicUsed by:646
Symbol 646 MovieClipUses:100 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645Used by:1087
Symbol 647 GraphicUsed by:744 811
Symbol 648 GraphicUsed by:650 658 744
Symbol 649 GraphicUsed by:650
Symbol 650 ButtonUses:648 649Used by:744
Symbol 651 GraphicUsed by:744
Symbol 652 FontUsed by:653 654 655 728 729 730 750 751 752 754 756 757 758 831 832 833
Symbol 653 TextUses:652Used by:657
Symbol 654 TextUses:652Used by:657
Symbol 655 TextUses:652Used by:657
Symbol 656 GraphicUsed by:657
Symbol 657 ButtonUses:653 654 655 656Used by:744 811
Symbol 658 MovieClip {x_fla.UpgradeMovie_32}Uses:648Used by:744
Symbol 659 TextUses:518Used by:744
Symbol 660 TextUses:518Used by:744
Symbol 661 TextUses:518Used by:744
Symbol 662 EditableTextUses:518 793Used by:744
Symbol 663 EditableTextUses:518 793Used by:744
Symbol 664 EditableTextUses:518 793Used by:744
Symbol 665 TextUses:518Used by:744
Symbol 666 GraphicUsed by:667
Symbol 667 MovieClipUses:666Used by:744
Symbol 668 GraphicUsed by:682
Symbol 669 GraphicUsed by:682 706 714
Symbol 670 GraphicUsed by:682
Symbol 671 GraphicUsed by:682
Symbol 672 GraphicUsed by:673
Symbol 673 MovieClipUses:672Used by:682
Symbol 674 GraphicUsed by:682
Symbol 675 GraphicUsed by:682
Symbol 676 GraphicUsed by:682 706 714
Symbol 677 GraphicUsed by:682
Symbol 678 GraphicUsed by:682 706 714
Symbol 679 GraphicUsed by:682 706 714
Symbol 680 GraphicUsed by:682 706 714
Symbol 681 GraphicUsed by:682
Symbol 682 MovieClip {x_fla.BikeMovie_34}Uses:126 127 668 129 128 669 670 671 673 674 675 676 677 678 679 680 681Used by:744
Symbol 683 GraphicUsed by:684
Symbol 684 ButtonUses:683Used by:744
Symbol 685 GraphicUsed by:686
Symbol 686 ButtonUses:685Used by:744
Symbol 687 GraphicUsed by:706 714
Symbol 688 GraphicUsed by:706 714
Symbol 689 GraphicUsed by:706 714
Symbol 690 GraphicUsed by:706
Symbol 691 GraphicUsed by:706
Symbol 692 GraphicUsed by:706 714
Symbol 693 GraphicUsed by:706 714
Symbol 694 GraphicUsed by:706 714
Symbol 695 GraphicUsed by:706 714
Symbol 696 GraphicUsed by:697
Symbol 697 MovieClipUses:696Used by:706
Symbol 698 GraphicUsed by:706 714
Symbol 699 GraphicUsed by:706 714
Symbol 700 GraphicUsed by:706 714
Symbol 701 GraphicUsed by:706 714
Symbol 702 GraphicUsed by:706 714
Symbol 703 GraphicUsed by:706 714
Symbol 704 GraphicUsed by:706 714
Symbol 705 GraphicUsed by:706
Symbol 706 MovieClip {x_fla.Bike2Coloring_38}Uses:126 127 687 129 128 669 688 689 690 691 692 693 694 678 695 697 698 676 699 700 701 702 679 680 703 704 705Used by:744
Symbol 707 GraphicUsed by:708
Symbol 708 MovieClipUses:707Used by:714
Symbol 709 GraphicUsed by:714
Symbol 710 GraphicUsed by:714
Symbol 711 GraphicUsed by:714
Symbol 712 GraphicUsed by:714
Symbol 713 GraphicUsed by:714
Symbol 714 MovieClip {x_fla.BAIK3Coloring_40}Uses:126 127 687 129 128 669 688 689 708 709 692 693 694 695 698 676 699 700 701 702 710 678 679 680 703 704 711 712 713Used by:744
Symbol 715 TextUses:518Used by:744
Symbol 716 TextUses:518Used by:744
Symbol 717 TextUses:518Used by:744
Symbol 718 TextUses:518Used by:744
Symbol 719 TextUses:518Used by:744
Symbol 720 TextUses:518Used by:744
Symbol 721 GraphicUsed by:722
Symbol 722 MovieClip {x_fla.ManColoringSetup_42}Uses:168 721 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 152 195 196 197 198Used by:744
Symbol 723 EditableTextUses:518Used by:744
Symbol 724 FontUsed by:725 726 738 739 740 761
Symbol 725 TextUses:724Used by:744
Symbol 726 TextUses:724Used by:744
Symbol 727 GraphicUsed by:735
Symbol 728 TextUses:652Used by:732
Symbol 729 TextUses:652Used by:732
Symbol 730 TextUses:652Used by:732
Symbol 731 GraphicUsed by:732
Symbol 732 ButtonUses:728 729 730 731Used by:735 743
Symbol 733 FontUsed by:734
Symbol 734 EditableTextUses:733Used by:735
Symbol 735 MovieClip {x_fla.NotEnoughMoneyMovie_57}Uses:727 732 734Used by:744
Symbol 736 GraphicUsed by:743
Symbol 737 EditableTextUses:518 793Used by:743
Symbol 738 TextUses:724Used by:742
Symbol 739 TextUses:724Used by:742
Symbol 740 TextUses:724Used by:742
Symbol 741 GraphicUsed by:742
Symbol 742 ButtonUses:738 739 740 741Used by:743
Symbol 743 MovieClip {x_fla.AreYouSureMovie_59}Uses:736 737 732 742Used by:744
Symbol 744 MovieClip {src.BikeUpgrade}Uses:647 650 651 657 648 658 659 660 661 662 663 664 665 667 682 684 686 706 714 715 716 717 718 719 720 722 723 515 725 726 735 743Used by:1087
Symbol 745 GraphicUsed by:763
Symbol 746 GraphicUsed by:762
Symbol 747 FontUsed by:749
Symbol 748 FontUsed by:828 836
Symbol 749 TextUses:747Used by:762
Symbol 750 TextUses:652Used by:755
Symbol 751 TextUses:652Used by:755
Symbol 752 TextUses:652Used by:755
Symbol 753 GraphicUsed by:755
Symbol 754 TextUses:652Used by:755
Symbol 755 ButtonUses:750 751 752 753 754Used by:762 811 1080
Symbol 756 TextUses:652Used by:760
Symbol 757 TextUses:652Used by:760
Symbol 758 TextUses:652Used by:760
Symbol 759 GraphicUsed by:760
Symbol 760 ButtonUses:756 757 758 759Used by:762
Symbol 761 EditableTextUses:724Used by:762
Symbol 762 MovieClip {x_fla.GameoverMovie_62}Uses:746 749 755 760 761Used by:763
Symbol 763 MovieClip {src.ScoreWindow}Uses:745 762Used by:1087
Symbol 764 BitmapUsed by:765
Symbol 765 GraphicUses:764Used by:792
Symbol 766 TextUses:518Used by:769
Symbol 767 TextUses:518Used by:769
Symbol 768 GraphicUsed by:769 776 779 787
Symbol 769 ButtonUses:766 767 768Used by:792
Symbol 770 TextUses:518Used by:773
Symbol 771 TextUses:518Used by:773
Symbol 772 GraphicUsed by:773
Symbol 773 ButtonUses:770 771 772Used by:792
Symbol 774 TextUses:518Used by:776
Symbol 775 TextUses:518Used by:776
Symbol 776 ButtonUses:774 775 768Used by:792
Symbol 777 TextUses:518Used by:779
Symbol 778 TextUses:518Used by:779
Symbol 779 ButtonUses:777 778 768Used by:792
Symbol 780 GraphicUsed by:792
Symbol 781 GraphicUsed by:792
Symbol 782 GraphicUsed by:792
Symbol 783 GraphicUsed by:792
Symbol 784 TextUses:518Used by:792
Symbol 785 TextUses:518Used by:787
Symbol 786 TextUses:518Used by:787
Symbol 787 ButtonUses:785 786 768Used by:792
Symbol 788 GraphicUsed by:791
Symbol 789 TextUses:518Used by:791
Symbol 790 TextUses:518Used by:791
Symbol 791 ButtonUses:788 789 790Used by:792
Symbol 792 MovieClip {x_fla.StartPage_65}Uses:765 769 773 776 779 780 781 782 783 784 787 791Used by:1087
Symbol 793 FontUsed by:662 663 664 737 794 818 1045 1051 1055 1059 1063 1066 1070 1074 1078
Symbol 794 TextUses:518 793Used by:811
Symbol 795 GraphicUsed by:811
Symbol 796 GraphicUsed by:811
Symbol 797 GraphicUsed by:811
Symbol 798 GraphicUsed by:811
Symbol 799 GraphicUsed by:811
Symbol 800 GraphicUsed by:811
Symbol 801 GraphicUsed by:811
Symbol 802 FontUsed by:803 804 805 806 807 808 1027
Symbol 803 TextUses:802Used by:811
Symbol 804 TextUses:802Used by:811
Symbol 805 TextUses:802Used by:811
Symbol 806 TextUses:802Used by:811
Symbol 807 TextUses:802Used by:811
Symbol 808 TextUses:802Used by:811
Symbol 809 GraphicUsed by:811
Symbol 810 GraphicUsed by:811
Symbol 811 MovieClip {x_fla.InstructionsPage_72}Uses:647 794 795 796 797 798 799 800 801 755 803 804 805 806 807 808 809 810 657Used by:1087
Symbol 812 GraphicUsed by:829
Symbol 813 FontUsed by:814 815
Symbol 814 TextUses:813Used by:816
Symbol 815 TextUses:813Used by:816
Symbol 816 ButtonUses:814 815 100Used by:829
Symbol 817 GraphicUsed by:829
Symbol 818 EditableTextUses:518 793Used by:829
Symbol 819 FontUsed by:820 821 822 824
Symbol 820 TextUses:819Used by:825
Symbol 821 TextUses:819Used by:825
Symbol 822 TextUses:819Used by:825
Symbol 823 GraphicUsed by:825
Symbol 824 TextUses:819Used by:825
Symbol 825 ButtonUses:820 821 822 823 824Used by:829
Symbol 826 FontUsed by:827
Symbol 827 EditableTextUses:826Used by:829
Symbol 828 TextUses:748Used by:829
Symbol 829 MovieClip {x_fla.StageClearedPage_73}Uses:812 816 817 818 825 827 828Used by:1087
Symbol 830 GraphicUsed by:837
Symbol 831 TextUses:652Used by:835
Symbol 832 TextUses:652Used by:835
Symbol 833 TextUses:652Used by:835
Symbol 834 GraphicUsed by:835
Symbol 835 ButtonUses:831 832 833 834Used by:837
Symbol 836 TextUses:748Used by:837
Symbol 837 MovieClip {x_fla.GameOverPage_76}Uses:830 835 836Used by:1087
Symbol 838 BitmapUsed by:839
Symbol 839 GraphicUses:838Used by:845
Symbol 840 GraphicUsed by:841
Symbol 841 MovieClipUses:840Used by:842
Symbol 842 MovieClip {x_fla.FlashAnim_80}Uses:841Used by:845
Symbol 843 GraphicUsed by:844
Symbol 844 MovieClipUses:843Used by:845
Symbol 845 MovieClip {x_fla.BackGround_79}Uses:839 842 844Used by:1043
Symbol 846 GraphicUsed by:865 877
Symbol 847 GraphicUsed by:865
Symbol 848 GraphicUsed by:865
Symbol 849 GraphicUsed by:865
Symbol 850 GraphicUsed by:865 877
Symbol 851 GraphicUsed by:865
Symbol 852 GraphicUsed by:865
Symbol 853 GraphicUsed by:865
Symbol 854 GraphicUsed by:865
Symbol 855 GraphicUsed by:865
Symbol 856 GraphicUsed by:865
Symbol 857 GraphicUsed by:865 877
Symbol 858 GraphicUsed by:865
Symbol 859 GraphicUsed by:865 877
Symbol 860 GraphicUsed by:865
Symbol 861 GraphicUsed by:865
Symbol 862 GraphicUsed by:865
Symbol 863 GraphicUsed by:865
Symbol 864 GraphicUsed by:865
Symbol 865 MovieClipUses:846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864Used by:994
Symbol 866 GraphicUsed by:877 926
Symbol 867 GraphicUsed by:877
Symbol 868 GraphicUsed by:877 906 926
Symbol 869 GraphicUsed by:877
Symbol 870 GraphicUsed by:877
Symbol 871 GraphicUsed by:877
Symbol 872 GraphicUsed by:877
Symbol 873 GraphicUsed by:877
Symbol 874 GraphicUsed by:877
Symbol 875 GraphicUsed by:877
Symbol 876 GraphicUsed by:877
Symbol 877 MovieClipUses:850 866 867 868 869 870 846 857 871 872 873 874 875 859 876Used by:994
Symbol 878 GraphicUsed by:906
Symbol 879 GraphicUsed by:906
Symbol 880 GraphicUsed by:906
Symbol 881 GraphicUsed by:906
Symbol 882 GraphicUsed by:906
Symbol 883 GraphicUsed by:906
Symbol 884 GraphicUsed by:906
Symbol 885 GraphicUsed by:906
Symbol 886 GraphicUsed by:906
Symbol 887 GraphicUsed by:906
Symbol 888 GraphicUsed by:906
Symbol 889 BitmapUsed by:890
Symbol 890 GraphicUses:889Used by:906
Symbol 891 BitmapUsed by:892
Symbol 892 GraphicUses:891Used by:906
Symbol 893 BitmapUsed by:894
Symbol 894 GraphicUses:893Used by:906
Symbol 895 GraphicUsed by:906
Symbol 896 GraphicUsed by:906 940 965
Symbol 897 GraphicUsed by:906 940 965
Symbol 898 GraphicUsed by:906
Symbol 899 GraphicUsed by:906
Symbol 900 BitmapUsed by:901
Symbol 901 GraphicUses:900Used by:906
Symbol 902 BitmapUsed by:903
Symbol 903 GraphicUses:902Used by:906
Symbol 904 BitmapUsed by:905
Symbol 905 GraphicUses:904Used by:906
Symbol 906 MovieClipUses:878 879 880 881 882 868 188 883 884 885 886 887 888 890 892 894 895 896 897 898 899 901 903 905Used by:994
Symbol 907 GraphicUsed by:926
Symbol 908 GraphicUsed by:926
Symbol 909 GraphicUsed by:926
Symbol 910 GraphicUsed by:926
Symbol 911 GraphicUsed by:926
Symbol 912 GraphicUsed by:926
Symbol 913 GraphicUsed by:926
Symbol 914 GraphicUsed by:926
Symbol 915 BitmapUsed by:916
Symbol 916 GraphicUses:915Used by:926
Symbol 917 GraphicUsed by:926 940
Symbol 918 GraphicUsed by:926
Symbol 919 GraphicUsed by:926 940
Symbol 920 GraphicUsed by:926
Symbol 921 GraphicUsed by:926
Symbol 922 GraphicUsed by:926
Symbol 923 GraphicUsed by:926
Symbol 924 GraphicUsed by:926
Symbol 925 GraphicUsed by:926
Symbol 926 MovieClipUses:100 866 868 907 908 909 910 911 912 913 914 916 917 918 919 920 921 922 923 924 925Used by:994
Symbol 927 GraphicUsed by:940 965
Symbol 928 GraphicUsed by:940
Symbol 929 GraphicUsed by:940
Symbol 930 GraphicUsed by:940 965
Symbol 931 GraphicUsed by:940
Symbol 932 GraphicUsed by:940
Symbol 933 GraphicUsed by:940
Symbol 934 GraphicUsed by:940
Symbol 935 BitmapUsed by:936
Symbol 936 GraphicUses:935Used by:940
Symbol 937 GraphicUsed by:940
Symbol 938 GraphicUsed by:940
Symbol 939 GraphicUsed by:940
Symbol 940 MovieClipUses:927 928 929 896 897 930 931 932 933 934 936 917 937 919 938 939Used by:994
Symbol 941 GraphicUsed by:965
Symbol 942 GraphicUsed by:965
Symbol 943 GraphicUsed by:965
Symbol 944 GraphicUsed by:965
Symbol 945 GraphicUsed by:965
Symbol 946 GraphicUsed by:965
Symbol 947 GraphicUsed by:965
Symbol 948 GraphicUsed by:965
Symbol 949 BitmapUsed by:950
Symbol 950 GraphicUses:949Used by:965
Symbol 951 GraphicUsed by:965
Symbol 952 GraphicUsed by:965
Symbol 953 BitmapUsed by:956
Symbol 954 BitmapUsed by:956
Symbol 955 BitmapUsed by:956
Symbol 956 GraphicUses:953 954 955Used by:965
Symbol 957 GraphicUsed by:965
Symbol 958 BitmapUsed by:959
Symbol 959 GraphicUses:958Used by:965
Symbol 960 GraphicUsed by:965
Symbol 961 BitmapUsed by:964
Symbol 962 BitmapUsed by:964
Symbol 963 BitmapUsed by:964
Symbol 964 GraphicUses:961 962 963Used by:965
Symbol 965 MovieClipUses:941 942 943 944 945 927 946 947 896 897 930 948 950 951 952 956 957 959 960 964Used by:994
Symbol 966 BitmapUsed by:969
Symbol 967 BitmapUsed by:969
Symbol 968 BitmapUsed by:969
Symbol 969 GraphicUses:966 967 968Used by:977
Symbol 970 BitmapUsed by:971
Symbol 971 GraphicUses:970Used by:977
Symbol 972 BitmapUsed by:974
Symbol 973 BitmapUsed by:974
Symbol 974 GraphicUses:972 973Used by:977
Symbol 975 GraphicUsed by:977
Symbol 976 GraphicUsed by:977
Symbol 977 MovieClipUses:969 403 971 974 975 976Used by:994
Symbol 978 GraphicUsed by:993
Symbol 979 GraphicUsed by:993
Symbol 980 GraphicUsed by:993
Symbol 981 GraphicUsed by:993
Symbol 982 GraphicUsed by:993
Symbol 983 GraphicUsed by:993
Symbol 984 BitmapUsed by:985
Symbol 985 GraphicUses:984Used by:993
Symbol 986 BitmapUsed by:987 990
Symbol 987 GraphicUses:986Used by:993
Symbol 988 GraphicUsed by:993
Symbol 989 GraphicUsed by:993
Symbol 990 GraphicUses:986Used by:993
Symbol 991 GraphicUsed by:993
Symbol 992 GraphicUsed by:993
Symbol 993 MovieClipUses:978 979 980 981 982 983 985 987 988 989 990 991 992Used by:994
Symbol 994 MovieClip {x_fla.Mapcopy_85}Uses:865 877 906 926 940 965 977 993Used by:995
Symbol 995 MovieClip {x_fla.CarArea_84}Uses:994Used by:996
Symbol 996 MovieClip {x_fla.DrawArea_83}Uses:995Used by:1043
Symbol 997 GraphicUsed by:998
Symbol 998 MovieClipUses:997Used by:1042
Symbol 999 FontUsed by:1000 1001
Symbol 1000 TextUses:999Used by:1042
Symbol 1001 TextUses:999Used by:1042
Symbol 1002 EditableTextUses:518Used by:1003
Symbol 1003 MovieClip {x_fla.PlayerTextHolder_97}Uses:1002Used by:1004
Symbol 1004 MovieClip {x_fla.PlayerInfoTimeleft_96}Uses:1003Used by:1042
Symbol 1005 GraphicUsed by:1028
Symbol 1006 GraphicUsed by:1028
Symbol 1007 GraphicUsed by:1028
Symbol 1008 GraphicUsed by:1028
Symbol 1009 GraphicUsed by:1028
Symbol 1010 GraphicUsed by:1028
Symbol 1011 GraphicUsed by:1028
Symbol 1012 GraphicUsed by:1028
Symbol 1013 GraphicUsed by:1028
Symbol 1014 GraphicUsed by:1028
Symbol 1015 GraphicUsed by:1028
Symbol 1016 GraphicUsed by:1028
Symbol 1017 GraphicUsed by:1028
Symbol 1018 GraphicUsed by:1028
Symbol 1019 GraphicUsed by:1028
Symbol 1020 GraphicUsed by:1028
Symbol 1021 GraphicUsed by:1028
Symbol 1022 GraphicUsed by:1028
Symbol 1023 GraphicUsed by:1028
Symbol 1024 GraphicUsed by:1028
Symbol 1025 GraphicUsed by:1028
Symbol 1026 GraphicUsed by:1028
Symbol 1027 TextUses:802Used by:1028
Symbol 1028 ButtonUses:618 1005 1006 1007 1008 1009 1010 1011 1012 591 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 606 607 608 609 610 611 612 613 614 1027 128Used by:1042
Symbol 1029 EditableTextUses:518Used by:1030
Symbol 1030 MovieClip {x_fla.TrickTextHolder_100}Uses:1029Used by:1031
Symbol 1031 MovieClip {x_fla.TrickInfoMovie_99}Uses:1030Used by:1042
Symbol 1032 GraphicUsed by:1033 1042
Symbol 1033 MovieClip {x_fla.PowerMeter_101}Uses:1032Used by:1042
Symbol 1034 TextUses:518Used by:1042
Symbol 1035 GraphicUsed by:1042
Symbol 1036 TextUses:518Used by:1042
Symbol 1037 GraphicUsed by:1039
Symbol 1038 GraphicUsed by:1039
Symbol 1039 MovieClip {x_fla.LivesMovie_102}Uses:1037 1038Used by:1042
Symbol 1040 TextUses:518Used by:1041
Symbol 1041 MovieClipUses:1040Used by:1042
Symbol 1042 MovieClip {src.PlayerInfo}Uses:998 1000 1001 1004 1028 1031 1032 1033 1034 1035 1036 1039 1041Used by:1043
Symbol 1043 MovieClip {src.Main}Uses:845 996 1042Used by:1087
Symbol 1044 GraphicUsed by:1080
Symbol 1045 EditableTextUses:518 793Used by:1080
Symbol 1046 BitmapUsed by:1047 1065
Symbol 1047 GraphicUses:1046Used by:1048
Symbol 1048 ButtonUses:1047Used by:1052 1056 1060 1064 1067 1071 1075 1079
Symbol 1049 BitmapUsed by:1050
Symbol 1050 GraphicUses:1049Used by:1052
Symbol 1051 EditableTextUses:518 793Used by:1052
Symbol 1052 MovieClip {x_fla.LevelThumbcopy4_105}Uses:1048 1050 1051Used by:1080
Symbol 1053 BitmapUsed by:1054
Symbol 1054 GraphicUses:1053Used by:1056
Symbol 1055 EditableTextUses:518 793Used by:1056
Symbol 1056 MovieClip {x_fla.LevelThumbcopy7_107}Uses:1048 1054 1055Used by:1080
Symbol 1057 BitmapUsed by:1058
Symbol 1058 GraphicUses:1057Used by:1060
Symbol 1059 EditableTextUses:518 793Used by:1060
Symbol 1060 MovieClip {x_fla.LevelThumbcopy6_108}Uses:1048 1058 1059Used by:1080
Symbol 1061 BitmapUsed by:1062
Symbol 1062 GraphicUses:1061Used by:1064
Symbol 1063 EditableTextUses:518 793Used by:1064
Symbol 1064 MovieClip {x_fla.LevelThumbcopy5_109}Uses:1048 1062 1063Used by:1080
Symbol 1065 GraphicUses:1046Used by:1067
Symbol 1066 EditableTextUses:518 793Used by:1067
Symbol 1067 MovieClip {x_fla.LevelThumb_110}Uses:1048 1065 1066Used by:1080
Symbol 1068 BitmapUsed by:1069
Symbol 1069 GraphicUses:1068Used by:1071
Symbol 1070 EditableTextUses:518 793Used by:1071
Symbol 1071 MovieClip {x_fla.LevelThumbcopy3_111}Uses:1048 1069 1070Used by:1080
Symbol 1072 BitmapUsed by:1073
Symbol 1073 GraphicUses:1072Used by:1075
Symbol 1074 EditableTextUses:518 793Used by:1075
Symbol 1075 MovieClip {x_fla.LevelThumbcopy2_112}Uses:1048 1073 1074Used by:1080
Symbol 1076 BitmapUsed by:1077
Symbol 1077 GraphicUses:1076Used by:1079
Symbol 1078 EditableTextUses:518 793Used by:1079
Symbol 1079 MovieClip {x_fla.LevelThumbcopy_113}Uses:1048 1077 1078Used by:1080
Symbol 1080 MovieClip {x_fla.MenuLevelSelectPage_104}Uses:1044 1045 1052 1056 1060 1064 1067 1071 1075 1079 755Used by:1087
Symbol 1081 GraphicUsed by:1083
Symbol 1082 GraphicUsed by:1083 1084
Symbol 1083 MovieClipUses:1081 1082Used by:1086
Symbol 1084 MovieClipUses:1082Used by:1086
Symbol 1085 GraphicUsed by:1086
Symbol 1086 Button {src.SoundBtn}Uses:1083 1084 1085Used by:1087
Symbol 1087 MovieClip {src.Menu}Uses:646 744 763 792 811 829 837 1043 1080 1086Used by:Timeline
Symbol 1088 GraphicUsed by:1091
Symbol 1089 FontUsed by:1090
Symbol 1090 TextUses:1089Used by:1091
Symbol 1091 MovieClipUses:1088 1090Used by:1094
Symbol 1092 MovieClipUses:128Used by:1093
Symbol 1093 MovieClip {x_fla.Symbol35_119}Uses:1092Used by:1094
Symbol 1094 MovieClip {x_fla.Symbol51_117}Uses:1091 1093Used by:Timeline

Instance Names

"dtf_loading"Frame 1Symbol 519 EditableText
"intro_btn"Frame 2Symbol 582 Button
"mc_menu"Frame 138Symbol 1087 MovieClip {src.Menu}
"color_mc"Symbol 31 MovieClip {RagdollBody} Frame 1Symbol 17 MovieClip
"child_1"Symbol 116 MovieClip {ChildMovie} Frame 1Symbol 107 MovieClip
"child_2"Symbol 116 MovieClip {ChildMovie} Frame 1Symbol 110 MovieClip
"child_3"Symbol 116 MovieClip {ChildMovie} Frame 1Symbol 113 MovieClip
"child_4"Symbol 116 MovieClip {ChildMovie} Frame 1Symbol 114 MovieClip
"child_5"Symbol 116 MovieClip {ChildMovie} Frame 1Symbol 115 MovieClip
"mc"Symbol 119 MovieClip {src.smoke} Frame 1Symbol 118 MovieClip
"color_mc"Symbol 166 MovieClip {x_fla.BikeMovie2_124} Frame 1Symbol 154 MovieClip
"color_mc"Symbol 199 MovieClip {x_fla.Man_126} Frame 1Symbol 168 MovieClip
"color_mc"Symbol 206 MovieClip {x_fla.ManTest1_127} Frame 1Symbol 202 MovieClip
"color_mc"Symbol 211 MovieClip {x_fla.ManTest1_129} Frame 1Symbol 208 MovieClip
"color_mc"Symbol 221 MovieClip {x_fla.ManTest1_131} Frame 1Symbol 213 MovieClip
"color_mc"Symbol 230 MovieClip {x_fla.man_133} Frame 1Symbol 227 MovieClip
"color_mc"Symbol 235 MovieClip {x_fla.man_135} Frame 1Symbol 232 MovieClip
"color_mc"Symbol 240 MovieClip {x_fla.ManTest1_137} Frame 1Symbol 237 MovieClip
"color_mc"Symbol 245 MovieClip {x_fla.MantTest1_139} Frame 1Symbol 242 MovieClip
"color_mc"Symbol 250 MovieClip {x_fla.ManTest1_141} Frame 1Symbol 247 MovieClip
"color_mc"Symbol 254 MovieClip {x_fla.ManTest1_143} Frame 1Symbol 252 MovieClip
"color_mc"Symbol 257 MovieClip {x_fla.ManTest2_145} Frame 1Symbol 256 MovieClip
"color_mc"Symbol 262 MovieClip {x_fla.ManTest2_147} Frame 1Symbol 259 MovieClip
"color_mc"Symbol 266 MovieClip {x_fla.ManTest2_149} Frame 1Symbol 264 MovieClip
"color_mc"Symbol 270 MovieClip {x_fla.ManTest2_151} Frame 1Symbol 268 MovieClip
"color_mc"Symbol 274 MovieClip {x_fla.ManTest2_153} Frame 1Symbol 272 MovieClip
"color_mc"Symbol 280 MovieClip {x_fla.ManTest2_155} Frame 1Symbol 276 MovieClip
"color_mc"Symbol 286 MovieClip {x_fla.ManTest2_157} Frame 1Symbol 282 MovieClip
"color_mc"Symbol 290 MovieClip {x_fla.ManTest2_159} Frame 1Symbol 288 MovieClip
"color_mc"Symbol 300 MovieClip {x_fla.ManTest2_161} Frame 1Symbol 292 MovieClip
"color_mc"Symbol 304 MovieClip {x_fla.ManTest3_163} Frame 1Symbol 302 MovieClip
"color_mc"Symbol 308 MovieClip {x_fla.ManTest3_165} Frame 1Symbol 306 MovieClip
"color_mc"Symbol 312 MovieClip {x_fla.ManTest3_167} Frame 1Symbol 310 MovieClip
"color_mc"Symbol 316 MovieClip {x_fla.ManTest3_169} Frame 1Symbol 314 MovieClip
"color_mc"Symbol 321 MovieClip {x_fla.ManTest3_171} Frame 1Symbol 318 MovieClip
"color_mc"Symbol 325 MovieClip {x_fla.ManTest3_173} Frame 1Symbol 323 MovieClip
"color_mc"Symbol 329 MovieClip {x_fla.ManTest3_175} Frame 1Symbol 327 MovieClip
"color_mc"Symbol 333 MovieClip {x_fla.ManTest3_177} Frame 1Symbol 331 MovieClip
"color_mc"Symbol 337 MovieClip {x_fla.ManTest3_179} Frame 1Symbol 335 MovieClip
"color_mc"Symbol 341 MovieClip {x_fla.ManTest4_181} Frame 1Symbol 339 MovieClip
"color_mc"Symbol 344 MovieClip {x_fla.ManTest4_183} Frame 1Symbol 343 MovieClip
"color_mc"Symbol 348 MovieClip {x_fla.ManTest4_185} Frame 1Symbol 346 MovieClip
"color_mc"Symbol 352 MovieClip {x_fla.ManTest4_187} Frame 1Symbol 350 MovieClip
"color_mc"Symbol 356 MovieClip {x_fla.ManTest4_189} Frame 1Symbol 354 MovieClip
"color_mc"Symbol 360 MovieClip {x_fla.ManTest4_191} Frame 1Symbol 358 MovieClip
"color_mc"Symbol 364 MovieClip {x_fla.ManTest4_193} Frame 1Symbol 362 MovieClip
"color_mc"Symbol 368 MovieClip {x_fla.ManTest4_195} Frame 1Symbol 366 MovieClip
"color_mc"Symbol 374 MovieClip {x_fla.ManTest4_197} Frame 1Symbol 370 MovieClip
"color_mc"Symbol 426 MovieClip {x_fla.ManTest5_199} Frame 1Symbol 424 MovieClip
"color_mc"Symbol 434 MovieClip {x_fla.ManTest5_201} Frame 1Symbol 428 MovieClip
"color_mc"Symbol 442 MovieClip {x_fla.ManTest6_203} Frame 1Symbol 436 MovieClip
"color_mc"Symbol 447 MovieClip {x_fla.ManTest6_205} Frame 1Symbol 444 MovieClip
"color_mc"Symbol 452 MovieClip {x_fla.ManTest6_207} Frame 1Symbol 449 MovieClip
"color_mc"Symbol 456 MovieClip {x_fla.ManTest6_209} Frame 1Symbol 454 MovieClip
"color_mc"Symbol 460 MovieClip {x_fla.ManTest6_211} Frame 1Symbol 458 MovieClip
"color_mc"Symbol 464 MovieClip {x_fla.ManTest6_213} Frame 1Symbol 462 MovieClip
"color_mc"Symbol 468 MovieClip {x_fla.ManTest6_215} Frame 1Symbol 466 MovieClip
"color_mc"Symbol 472 MovieClip {x_fla.ManTest6_217} Frame 1Symbol 470 MovieClip
"color_mc"Symbol 477 MovieClip {x_fla.ManTest6_219} Frame 1Symbol 474 MovieClip
"bike_mc"Symbol 489 MovieClip {src.BikeBody} Frame 1Symbol 166 MovieClip {x_fla.BikeMovie2_124}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 1Symbol 199 MovieClip {x_fla.Man_126}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 3Symbol 206 MovieClip {x_fla.ManTest1_127}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 5Symbol 211 MovieClip {x_fla.ManTest1_129}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 7Symbol 221 MovieClip {x_fla.ManTest1_131}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 9Symbol 230 MovieClip {x_fla.man_133}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 11Symbol 235 MovieClip {x_fla.man_135}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 13Symbol 240 MovieClip {x_fla.ManTest1_137}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 15Symbol 245 MovieClip {x_fla.MantTest1_139}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 17Symbol 250 MovieClip {x_fla.ManTest1_141}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 19Symbol 254 MovieClip {x_fla.ManTest1_143}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 24Symbol 250 MovieClip {x_fla.ManTest1_141}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 26Symbol 245 MovieClip {x_fla.MantTest1_139}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 28Symbol 240 MovieClip {x_fla.ManTest1_137}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 30Symbol 235 MovieClip {x_fla.man_135}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 32Symbol 230 MovieClip {x_fla.man_133}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 34Symbol 221 MovieClip {x_fla.ManTest1_131}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 36Symbol 211 MovieClip {x_fla.ManTest1_129}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 38Symbol 206 MovieClip {x_fla.ManTest1_127}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 40Symbol 199 MovieClip {x_fla.Man_126}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 42Symbol 199 MovieClip {x_fla.Man_126}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 44Symbol 257 MovieClip {x_fla.ManTest2_145}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 46Symbol 262 MovieClip {x_fla.ManTest2_147}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 48Symbol 266 MovieClip {x_fla.ManTest2_149}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 50Symbol 270 MovieClip {x_fla.ManTest2_151}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 52Symbol 274 MovieClip {x_fla.ManTest2_153}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 54Symbol 280 MovieClip {x_fla.ManTest2_155}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 56Symbol 286 MovieClip {x_fla.ManTest2_157}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 58Symbol 290 MovieClip {x_fla.ManTest2_159}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 60Symbol 300 MovieClip {x_fla.ManTest2_161}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 66Symbol 290 MovieClip {x_fla.ManTest2_159}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 68Symbol 286 MovieClip {x_fla.ManTest2_157}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 70Symbol 280 MovieClip {x_fla.ManTest2_155}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 72Symbol 274 MovieClip {x_fla.ManTest2_153}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 74Symbol 270 MovieClip {x_fla.ManTest2_151}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 76Symbol 266 MovieClip {x_fla.ManTest2_149}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 78Symbol 262 MovieClip {x_fla.ManTest2_147}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 80Symbol 257 MovieClip {x_fla.ManTest2_145}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 82Symbol 199 MovieClip {x_fla.Man_126}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 84Symbol 199 MovieClip {x_fla.Man_126}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 86Symbol 304 MovieClip {x_fla.ManTest3_163}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 88Symbol 308 MovieClip {x_fla.ManTest3_165}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 90Symbol 312 MovieClip {x_fla.ManTest3_167}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 92Symbol 316 MovieClip {x_fla.ManTest3_169}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 94Symbol 321 MovieClip {x_fla.ManTest3_171}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 96Symbol 325 MovieClip {x_fla.ManTest3_173}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 98Symbol 329 MovieClip {x_fla.ManTest3_175}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 100Symbol 333 MovieClip {x_fla.ManTest3_177}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 102Symbol 337 MovieClip {x_fla.ManTest3_179}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 107Symbol 333 MovieClip {x_fla.ManTest3_177}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 109Symbol 329 MovieClip {x_fla.ManTest3_175}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 111Symbol 325 MovieClip {x_fla.ManTest3_173}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 113Symbol 321 MovieClip {x_fla.ManTest3_171}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 115Symbol 316 MovieClip {x_fla.ManTest3_169}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 117Symbol 312 MovieClip {x_fla.ManTest3_167}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 119Symbol 308 MovieClip {x_fla.ManTest3_165}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 121Symbol 304 MovieClip {x_fla.ManTest3_163}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 123Symbol 199 MovieClip {x_fla.Man_126}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 125Symbol 199 MovieClip {x_fla.Man_126}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 127Symbol 341 MovieClip {x_fla.ManTest4_181}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 129Symbol 344 MovieClip {x_fla.ManTest4_183}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 131Symbol 348 MovieClip {x_fla.ManTest4_185}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 133Symbol 352 MovieClip {x_fla.ManTest4_187}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 135Symbol 356 MovieClip {x_fla.ManTest4_189}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 137Symbol 360 MovieClip {x_fla.ManTest4_191}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 139Symbol 364 MovieClip {x_fla.ManTest4_193}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 141Symbol 368 MovieClip {x_fla.ManTest4_195}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 143Symbol 374 MovieClip {x_fla.ManTest4_197}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 147Symbol 368 MovieClip {x_fla.ManTest4_195}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 149Symbol 364 MovieClip {x_fla.ManTest4_193}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 151Symbol 360 MovieClip {x_fla.ManTest4_191}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 153Symbol 356 MovieClip {x_fla.ManTest4_189}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 155Symbol 352 MovieClip {x_fla.ManTest4_187}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 157Symbol 348 MovieClip {x_fla.ManTest4_185}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 159Symbol 344 MovieClip {x_fla.ManTest4_183}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 161Symbol 341 MovieClip {x_fla.ManTest4_181}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 163Symbol 199 MovieClip {x_fla.Man_126}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 165Symbol 199 MovieClip {x_fla.Man_126}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 167Symbol 341 MovieClip {x_fla.ManTest4_181}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 169Symbol 344 MovieClip {x_fla.ManTest4_183}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 171Symbol 348 MovieClip {x_fla.ManTest4_185}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 173Symbol 352 MovieClip {x_fla.ManTest4_187}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 175Symbol 356 MovieClip {x_fla.ManTest4_189}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 177Symbol 360 MovieClip {x_fla.ManTest4_191}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 179Symbol 364 MovieClip {x_fla.ManTest4_193}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 181Symbol 426 MovieClip {x_fla.ManTest5_199}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 183Symbol 434 MovieClip {x_fla.ManTest5_201}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 188Symbol 426 MovieClip {x_fla.ManTest5_199}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 190Symbol 364 MovieClip {x_fla.ManTest4_193}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 192Symbol 360 MovieClip {x_fla.ManTest4_191}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 194Symbol 356 MovieClip {x_fla.ManTest4_189}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 196Symbol 352 MovieClip {x_fla.ManTest4_187}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 198Symbol 348 MovieClip {x_fla.ManTest4_185}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 200Symbol 344 MovieClip {x_fla.ManTest4_183}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 202Symbol 341 MovieClip {x_fla.ManTest4_181}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 204Symbol 199 MovieClip {x_fla.Man_126}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 206Symbol 199 MovieClip {x_fla.Man_126}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 208Symbol 442 MovieClip {x_fla.ManTest6_203}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 210Symbol 447 MovieClip {x_fla.ManTest6_205}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 212Symbol 452 MovieClip {x_fla.ManTest6_207}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 214Symbol 456 MovieClip {x_fla.ManTest6_209}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 216Symbol 460 MovieClip {x_fla.ManTest6_211}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 218Symbol 464 MovieClip {x_fla.ManTest6_213}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 220Symbol 468 MovieClip {x_fla.ManTest6_215}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 222Symbol 472 MovieClip {x_fla.ManTest6_217}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 224Symbol 477 MovieClip {x_fla.ManTest6_219}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 229Symbol 472 MovieClip {x_fla.ManTest6_217}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 231Symbol 468 MovieClip {x_fla.ManTest6_215}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 233Symbol 464 MovieClip {x_fla.ManTest6_213}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 235Symbol 460 MovieClip {x_fla.ManTest6_211}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 237Symbol 456 MovieClip {x_fla.ManTest6_209}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 239Symbol 452 MovieClip {x_fla.ManTest6_207}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 241Symbol 447 MovieClip {x_fla.ManTest6_205}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 243Symbol 442 MovieClip {x_fla.ManTest6_203}
"body_mc"Symbol 489 MovieClip {src.BikeBody} Frame 245Symbol 199 MovieClip {x_fla.Man_126}
"color_mc"Symbol 682 MovieClip {x_fla.BikeMovie_34} Frame 1Symbol 673 MovieClip
"color_mc"Symbol 706 MovieClip {x_fla.Bike2Coloring_38} Frame 1Symbol 697 MovieClip
"color_mc"Symbol 714 MovieClip {x_fla.BAIK3Coloring_40} Frame 1Symbol 708 MovieClip
"color_mc"Symbol 722 MovieClip {x_fla.ManColoringSetup_42} Frame 1Symbol 168 MovieClip
"ok_btn"Symbol 735 MovieClip {x_fla.NotEnoughMoneyMovie_57} Frame 1Symbol 732 Button
"text_dtf"Symbol 735 MovieClip {x_fla.NotEnoughMoneyMovie_57} Frame 1Symbol 734 EditableText
"text_dtf"Symbol 743 MovieClip {x_fla.AreYouSureMovie_59} Frame 1Symbol 737 EditableText
"ok_btn"Symbol 743 MovieClip {x_fla.AreYouSureMovie_59} Frame 1Symbol 732 Button
"cancel_btn"Symbol 743 MovieClip {x_fla.AreYouSureMovie_59} Frame 1Symbol 742 Button
"weight_btn"Symbol 744 MovieClip {src.BikeUpgrade} Frame 1Symbol 650 Button
"next_btn"Symbol 744 MovieClip {src.BikeUpgrade} Frame 1Symbol 657 Button
"engine_btn"Symbol 744 MovieClip {src.BikeUpgrade} Frame 1Symbol 650 Button
"aero_btn"Symbol 744 MovieClip {src.BikeUpgrade} Frame 1Symbol 650 Button
"engine_mc"Symbol 744 MovieClip {src.BikeUpgrade} Frame 1Symbol 658 MovieClip {x_fla.UpgradeMovie_32}
"aero_mc"Symbol 744 MovieClip {src.BikeUpgrade} Frame 1Symbol 658 MovieClip {x_fla.UpgradeMovie_32}
"weight_mc"Symbol 744 MovieClip {src.BikeUpgrade} Frame 1Symbol 658 MovieClip {x_fla.UpgradeMovie_32}
"engine_dtf"Symbol 744 MovieClip {src.BikeUpgrade} Frame 1Symbol 662 EditableText
"aero_dtf"Symbol 744 MovieClip {src.BikeUpgrade} Frame 1Symbol 663 EditableText
"weight_dtf"Symbol 744 MovieClip {src.BikeUpgrade} Frame 1Symbol 664 EditableText
"bike_sel_1"Symbol 744 MovieClip {src.BikeUpgrade} Frame 1Symbol 667 MovieClip
"bike_1"Symbol 744 MovieClip {src.BikeUpgrade} Frame 1Symbol 682 MovieClip {x_fla.BikeMovie_34}
"bike_sel_2"Symbol 744 MovieClip {src.BikeUpgrade} Frame 1Symbol 684 Button
"bike_sel_3"Symbol 744 MovieClip {src.BikeUpgrade} Frame 1Symbol 686 Button
"bike_2"Symbol 744 MovieClip {src.BikeUpgrade} Frame 1Symbol 706 MovieClip {x_fla.Bike2Coloring_38}
"bike_3"Symbol 744 MovieClip {src.BikeUpgrade} Frame 1Symbol 714 MovieClip {x_fla.BAIK3Coloring_40}
"body1_mc"Symbol 744 MovieClip {src.BikeUpgrade} Frame 1Symbol 722 MovieClip {x_fla.ManColoringSetup_42}
"body2_mc"Symbol 744 MovieClip {src.BikeUpgrade} Frame 1Symbol 722 MovieClip {x_fla.ManColoringSetup_42}
"body3_mc"Symbol 744 MovieClip {src.BikeUpgrade} Frame 1Symbol 722 MovieClip {x_fla.ManColoringSetup_42}
"player_money_dtf"Symbol 744 MovieClip {src.BikeUpgrade} Frame 1Symbol 723 EditableText
"bike_color_mc"Symbol 744 MovieClip {src.BikeUpgrade} Frame 1Symbol 515 MovieClip {fl.controls.ColorPicker}
"player_color_mc"Symbol 744 MovieClip {src.BikeUpgrade} Frame 1Symbol 515 MovieClip {fl.controls.ColorPicker}
"not_enough_mc"Symbol 744 MovieClip {src.BikeUpgrade} Frame 1Symbol 735 MovieClip {x_fla.NotEnoughMoneyMovie_57}
"are_you_sure_mc"Symbol 744 MovieClip {src.BikeUpgrade} Frame 1Symbol 743 MovieClip {x_fla.AreYouSureMovie_59}
"back_btn"Symbol 762 MovieClip {x_fla.GameoverMovie_62} Frame 1Symbol 755 Button
"submit_btn"Symbol 762 MovieClip {x_fla.GameoverMovie_62} Frame 1Symbol 760 Button
"info_dtf"Symbol 762 MovieClip {x_fla.GameoverMovie_62} Frame 1Symbol 761 EditableText
"gameover_mc"Symbol 763 MovieClip {src.ScoreWindow} Frame 1Symbol 762 MovieClip {x_fla.GameoverMovie_62}
"instr_btn"Symbol 792 MovieClip {x_fla.StartPage_65} Frame 1Symbol 769 Button
"practice_btn"Symbol 792 MovieClip {x_fla.StartPage_65} Frame 1Symbol 773 Button
"scores_btn"Symbol 792 MovieClip {x_fla.StartPage_65} Frame 1Symbol 776 Button
"play_more_btn"Symbol 792 MovieClip {x_fla.StartPage_65} Frame 1Symbol 779 Button
"btn_start_game"Symbol 792 MovieClip {x_fla.StartPage_65} Frame 1Symbol 787 Button
"producedby_btn"Symbol 792 MovieClip {x_fla.StartPage_65} Frame 1Symbol 791 Button
"back_btn"Symbol 811 MovieClip {x_fla.InstructionsPage_72} Frame 1Symbol 755 Button
"ok_btn"Symbol 811 MovieClip {x_fla.InstructionsPage_72} Frame 1Symbol 657 Button
"back_btn2"Symbol 811 MovieClip {x_fla.InstructionsPage_72} Frame 1Symbol 755 Button
"back_btn"Symbol 829 MovieClip {x_fla.StageClearedPage_73} Frame 1Symbol 816 Button
"info_dtf"Symbol 829 MovieClip {x_fla.StageClearedPage_73} Frame 1Symbol 818 EditableText
"next_btn"Symbol 829 MovieClip {x_fla.StageClearedPage_73} Frame 1Symbol 825 Button
"totalearnings_dtf"Symbol 829 MovieClip {x_fla.StageClearedPage_73} Frame 1Symbol 827 EditableText
"restart_btn"Symbol 837 MovieClip {x_fla.GameOverPage_76} Frame 1Symbol 835 Button
"mc_flash3"Symbol 845 MovieClip {x_fla.BackGround_79} Frame 1Symbol 842 MovieClip {x_fla.FlashAnim_80}
"mc_flash2"Symbol 845 MovieClip {x_fla.BackGround_79} Frame 1Symbol 842 MovieClip {x_fla.FlashAnim_80}
"mc_flash1"Symbol 845 MovieClip {x_fla.BackGround_79} Frame 1Symbol 842 MovieClip {x_fla.FlashAnim_80}
"level_3"Symbol 994 MovieClip {x_fla.Mapcopy_85} Frame 1Symbol 865 MovieClip
"level_4"Symbol 994 MovieClip {x_fla.Mapcopy_85} Frame 1Symbol 877 MovieClip
"level_5"Symbol 994 MovieClip {x_fla.Mapcopy_85} Frame 1Symbol 906 MovieClip
"level_2"Symbol 994 MovieClip {x_fla.Mapcopy_85} Frame 1Symbol 926 MovieClip
"level_1"Symbol 994 MovieClip {x_fla.Mapcopy_85} Frame 1Symbol 940 MovieClip
"level_6"Symbol 994 MovieClip {x_fla.Mapcopy_85} Frame 1Symbol 965 MovieClip
"level_7"Symbol 994 MovieClip {x_fla.Mapcopy_85} Frame 1Symbol 977 MovieClip
"double_ramp_mc"Symbol 994 MovieClip {x_fla.Mapcopy_85} Frame 1Symbol 993 MovieClip
"mc_level"Symbol 995 MovieClip {x_fla.CarArea_84} Frame 1Symbol 994 MovieClip {x_fla.Mapcopy_85}
"mc_cararea"Symbol 996 MovieClip {x_fla.DrawArea_83} Frame 1Symbol 995 MovieClip {x_fla.CarArea_84}
"text_dtf"Symbol 1003 MovieClip {x_fla.PlayerTextHolder_97} Frame 1Symbol 1002 EditableText
"holder_mc"Symbol 1004 MovieClip {x_fla.PlayerInfoTimeleft_96} Frame 1Symbol 1003 MovieClip {x_fla.PlayerTextHolder_97}
"trick_dtf"Symbol 1030 MovieClip {x_fla.TrickTextHolder_100} Frame 1Symbol 1029 EditableText
"text_mc"Symbol 1031 MovieClip {x_fla.TrickInfoMovie_99} Frame 1Symbol 1030 MovieClip {x_fla.TrickTextHolder_100}
"arrow_mc"Symbol 1042 MovieClip {src.PlayerInfo} Frame 1Symbol 998 MovieClip
"checkpoint_mc"Symbol 1042 MovieClip {src.PlayerInfo} Frame 1Symbol 1004 MovieClip {x_fla.PlayerInfoTimeleft_96}
"logo_btn"Symbol 1042 MovieClip {src.PlayerInfo} Frame 1Symbol 1028 Button
"tricks_mc"Symbol 1042 MovieClip {src.PlayerInfo} Frame 1Symbol 1031 MovieClip {x_fla.TrickInfoMovie_99}
"power_mc"Symbol 1042 MovieClip {src.PlayerInfo} Frame 1Symbol 1033 MovieClip {x_fla.PowerMeter_101}
"timeleft_mc"Symbol 1042 MovieClip {src.PlayerInfo} Frame 1Symbol 1004 MovieClip {x_fla.PlayerInfoTimeleft_96}
"score_mc"Symbol 1042 MovieClip {src.PlayerInfo} Frame 1Symbol 1004 MovieClip {x_fla.PlayerInfoTimeleft_96}
"lives_mc"Symbol 1042 MovieClip {src.PlayerInfo} Frame 1Symbol 1039 MovieClip {x_fla.LivesMovie_102}
"back_left_mc"Symbol 1042 MovieClip {src.PlayerInfo} Frame 1Symbol 1041 MovieClip
"back_right_mc"Symbol 1042 MovieClip {src.PlayerInfo} Frame 1Symbol 1041 MovieClip
"mc_bg"Symbol 1043 MovieClip {src.Main} Frame 1Symbol 845 MovieClip {x_fla.BackGround_79}
"draw_area_mc"Symbol 1043 MovieClip {src.Main} Frame 1Symbol 996 MovieClip {x_fla.DrawArea_83}
"playerinfo_mc"Symbol 1043 MovieClip {src.Main} Frame 1Symbol 1042 MovieClip {src.PlayerInfo}
"level_descr_dtf"Symbol 1052 MovieClip {x_fla.LevelThumbcopy4_105} Frame 1Symbol 1051 EditableText
"level_descr_dtf"Symbol 1056 MovieClip {x_fla.LevelThumbcopy7_107} Frame 1Symbol 1055 EditableText
"level_descr_dtf"Symbol 1060 MovieClip {x_fla.LevelThumbcopy6_108} Frame 1Symbol 1059 EditableText
"level_descr_dtf"Symbol 1064 MovieClip {x_fla.LevelThumbcopy5_109} Frame 1Symbol 1063 EditableText
"level_descr_dtf"Symbol 1067 MovieClip {x_fla.LevelThumb_110} Frame 1Symbol 1066 EditableText
"level_descr_dtf"Symbol 1071 MovieClip {x_fla.LevelThumbcopy3_111} Frame 1Symbol 1070 EditableText
"level_descr_dtf"Symbol 1075 MovieClip {x_fla.LevelThumbcopy2_112} Frame 1Symbol 1074 EditableText
"level_descr_dtf"Symbol 1079 MovieClip {x_fla.LevelThumbcopy_113} Frame 1Symbol 1078 EditableText
"player_money_dtf"Symbol 1080 MovieClip {x_fla.MenuLevelSelectPage_104} Frame 1Symbol 1045 EditableText
"thumb_5"Symbol 1080 MovieClip {x_fla.MenuLevelSelectPage_104} Frame 1Symbol 1052 MovieClip {x_fla.LevelThumbcopy4_105}
"thumb_8"Symbol 1080 MovieClip {x_fla.MenuLevelSelectPage_104} Frame 1Symbol 1056 MovieClip {x_fla.LevelThumbcopy7_107}
"thumb_7"Symbol 1080 MovieClip {x_fla.MenuLevelSelectPage_104} Frame 1Symbol 1060 MovieClip {x_fla.LevelThumbcopy6_108}
"thumb_6"Symbol 1080 MovieClip {x_fla.MenuLevelSelectPage_104} Frame 1Symbol 1064 MovieClip {x_fla.LevelThumbcopy5_109}
"thumb_1"Symbol 1080 MovieClip {x_fla.MenuLevelSelectPage_104} Frame 1Symbol 1067 MovieClip {x_fla.LevelThumb_110}
"thumb_4"Symbol 1080 MovieClip {x_fla.MenuLevelSelectPage_104} Frame 1Symbol 1071 MovieClip {x_fla.LevelThumbcopy3_111}
"thumb_3"Symbol 1080 MovieClip {x_fla.MenuLevelSelectPage_104} Frame 1Symbol 1075 MovieClip {x_fla.LevelThumbcopy2_112}
"thumb_2"Symbol 1080 MovieClip {x_fla.MenuLevelSelectPage_104} Frame 1Symbol 1079 MovieClip {x_fla.LevelThumbcopy_113}
"back_btn"Symbol 1080 MovieClip {x_fla.MenuLevelSelectPage_104} Frame 1Symbol 755 Button
"bg_menu_mc"Symbol 1087 MovieClip {src.Menu} Frame 1Symbol 646 MovieClip
"bike_upgrade_mc"Symbol 1087 MovieClip {src.Menu} Frame 1Symbol 744 MovieClip {src.BikeUpgrade}
"score_mc"Symbol 1087 MovieClip {src.Menu} Frame 1Symbol 763 MovieClip {src.ScoreWindow}
"mc_startpage"Symbol 1087 MovieClip {src.Menu} Frame 1Symbol 792 MovieClip {x_fla.StartPage_65}
"instructions_mc"Symbol 1087 MovieClip {src.Menu} Frame 1Symbol 811 MovieClip {x_fla.InstructionsPage_72}
"stagecleared_mc"Symbol 1087 MovieClip {src.Menu} Frame 1Symbol 829 MovieClip {x_fla.StageClearedPage_73}
"gameover_mc"Symbol 1087 MovieClip {src.Menu} Frame 1Symbol 837 MovieClip {x_fla.GameOverPage_76}
"GameField_mc"Symbol 1087 MovieClip {src.Menu} Frame 1Symbol 1043 MovieClip {src.Main}
"levelselect_mc"Symbol 1087 MovieClip {src.Menu} Frame 1Symbol 1080 MovieClip {x_fla.MenuLevelSelectPage_104}
"sound_btn"Symbol 1087 MovieClip {src.Menu} Frame 1Symbol 1086 Button {src.SoundBtn}

Special Tags

FileAttributes (69)Timeline Frame 1Access network only, Metadata not present, AS3.

Labels

"trick1"Symbol 489 MovieClip {src.BikeBody} Frame 1
"trick2"Symbol 489 MovieClip {src.BikeBody} Frame 42
"trick3"Symbol 489 MovieClip {src.BikeBody} Frame 84
"trick4"Symbol 489 MovieClip {src.BikeBody} Frame 125
"trick5"Symbol 489 MovieClip {src.BikeBody} Frame 165
"trick6"Symbol 489 MovieClip {src.BikeBody} Frame 206
"crash"Symbol 489 MovieClip {src.BikeBody} Frame 247
"0level"Symbol 658 MovieClip {x_fla.UpgradeMovie_32} Frame 1
"to_level_1"Symbol 658 MovieClip {x_fla.UpgradeMovie_32} Frame 2
"1level"Symbol 658 MovieClip {x_fla.UpgradeMovie_32} Frame 20
"to_level_2"Symbol 658 MovieClip {x_fla.UpgradeMovie_32} Frame 21
"2level"Symbol 658 MovieClip {x_fla.UpgradeMovie_32} Frame 40
"to_level_3"Symbol 658 MovieClip {x_fla.UpgradeMovie_32} Frame 41
"max"Symbol 658 MovieClip {x_fla.UpgradeMovie_32} Frame 60




http://swfchan.com/14/66852/info.shtml
Created: 11/4 -2019 20:04:05 Last modified: 11/4 -2019 20:04:05 Server time: 23/12 -2024 02:45:09