import Box2D. Collision . Shapes . * ; import Box2D. Common . Math . * ; import Box2D. Dynamics . * ; import Box2D. Dynamics . Joints . * ; import Box2D. Collision . * ; import Box2D. Common . * ; import com. actionsnippet . qbox . * ;
import Box2D. Collision . Shapes . * ; import Box2D. Common . Math . * ; import Box2D. Dynamics . * ; import Box2D. Dynamics . Joints . * ; import Box2D. Collision . * ; import Box2D. Common . * ; import com. actionsnippet . qbox . * ;
import Box2D. Collision . Shapes . * ; import Box2D. Common . Math . * ; import Box2D. Dynamics . * ; import Box2D. Dynamics . Joints . * ; import Box2D. Collision . * ; import Box2D. Common . * ; import com. actionsnippet . qbox . * ;
import Box2D. Collision . Shapes . * ; import Box2D. Common . Math . * ; import Box2D. Dynamics . * ; import Box2D. Dynamics . Joints . * ; import Box2D. Collision . * ; import Box2D. Common . * ; import com. actionsnippet . qbox . * ;
import Box2D. Collision . Shapes . * ; import Box2D. Common . Math . * ; import Box2D. Dynamics . * ; import Box2D. Dynamics . Joints . * ; import Box2D. Collision . * ; import Box2D. Common . * ; import com. actionsnippet . qbox . * ;
import Box2D. Collision . Shapes . * ; import Box2D. Common . Math . * ; import Box2D. Dynamics . * ; import Box2D. Dynamics . Joints . * ; import Box2D. Collision . * ; import Box2D. Common . * ; import com. actionsnippet . qbox . * ;
import Box2D. Collision . Shapes . * ; import Box2D. Common . Math . * ; import Box2D. Dynamics . * ; import Box2D. Dynamics . Joints . * ; import Box2D. Collision . * ; import Box2D. Common . * ; import com. actionsnippet . qbox . * ;
var world:QuickBox2D = new QuickBox2D ( this , { debug: false , frim: true } ) ; world. gravity = new b2Vec2 ( 0 , 0 ) ; // world. start ( ) ; // world. createStageWalls ( ) ; // QuickBox'a - 4 stage world. mouseDrag ( ) ; //
var world:QuickBox2D = new QuickBox2D ( this , { debug: false , frim: true } ) ; world. gravity = new b2Vec2 ( 0 , 0 ) ; // world. start ( ) ; // world. createStageWalls ( ) ; // QuickBox'a - 4 stage world. mouseDrag ( ) ; //
var world:QuickBox2D = new QuickBox2D ( this , { debug: false , frim: true } ) ; world. gravity = new b2Vec2 ( 0 , 0 ) ; // world. start ( ) ; // world. createStageWalls ( ) ; // QuickBox'a - 4 stage world. mouseDrag ( ) ; //
var world:QuickBox2D = new QuickBox2D ( this , { debug: false , frim: true } ) ; world. gravity = new b2Vec2 ( 0 , 0 ) ; // world. start ( ) ; // world. createStageWalls ( ) ; // QuickBox'a - 4 stage world. mouseDrag ( ) ; //
var world:QuickBox2D = new QuickBox2D ( this , { debug: false , frim: true } ) ; world. gravity = new b2Vec2 ( 0 , 0 ) ; // world. start ( ) ; // world. createStageWalls ( ) ; // QuickBox'a - 4 stage world. mouseDrag ( ) ; //
// : private const FWD= 1 ; // private const AWD= 2 ; // private const RWD= 3 ; // private var _privod: Number ; // , private var _maxTurnAngle: Number ; // private var _width : Number ; // private var _height : Number ; // private var _axisOffset: Number ; // , private const _angularDamping = 7 ; // private const _angularDampingReverse = 3 ; // , private const _linearDamping = 0.25 ; // , - private const _linearDampingReverse = 0.5 ; // public var _carBody:QuickObject; // private var _frontAxisBodyLeft:QuickObject; // private var _frontAxisBodyRight:QuickObject; private var _rearAxisBodyLeft:QuickObject; private var _rearAxisBodyRight:QuickObject; private var _frontLeftJoint:QuickObject; // private var _frontRightJoint:QuickObject; private var _rearLeftJoint:QuickObject; // private var _rearRightJoint:QuickObject; protected var axisHeight: Number = 4 ; // protected var axisWidth: Number = 7 ; // public var drive: int = 0 ; // public var steer: int = 0 ; //drive = 1 - //drive = 0 - , //drive = -1 - // //steer = -1 - //steer = 0 - //steer = 1 -
// : private const FWD= 1 ; // private const AWD= 2 ; // private const RWD= 3 ; // private var _privod: Number ; // , private var _maxTurnAngle: Number ; // private var _width : Number ; // private var _height : Number ; // private var _axisOffset: Number ; // , private const _angularDamping = 7 ; // private const _angularDampingReverse = 3 ; // , private const _linearDamping = 0.25 ; // , - private const _linearDampingReverse = 0.5 ; // public var _carBody:QuickObject; // private var _frontAxisBodyLeft:QuickObject; // private var _frontAxisBodyRight:QuickObject; private var _rearAxisBodyLeft:QuickObject; private var _rearAxisBodyRight:QuickObject; private var _frontLeftJoint:QuickObject; // private var _frontRightJoint:QuickObject; private var _rearLeftJoint:QuickObject; // private var _rearRightJoint:QuickObject; protected var axisHeight: Number = 4 ; // protected var axisWidth: Number = 7 ; // public var drive: int = 0 ; // public var steer: int = 0 ; //drive = 1 - //drive = 0 - , //drive = -1 - // //steer = -1 - //steer = 0 - //steer = 1 -
// : private const FWD= 1 ; // private const AWD= 2 ; // private const RWD= 3 ; // private var _privod: Number ; // , private var _maxTurnAngle: Number ; // private var _width : Number ; // private var _height : Number ; // private var _axisOffset: Number ; // , private const _angularDamping = 7 ; // private const _angularDampingReverse = 3 ; // , private const _linearDamping = 0.25 ; // , - private const _linearDampingReverse = 0.5 ; // public var _carBody:QuickObject; // private var _frontAxisBodyLeft:QuickObject; // private var _frontAxisBodyRight:QuickObject; private var _rearAxisBodyLeft:QuickObject; private var _rearAxisBodyRight:QuickObject; private var _frontLeftJoint:QuickObject; // private var _frontRightJoint:QuickObject; private var _rearLeftJoint:QuickObject; // private var _rearRightJoint:QuickObject; protected var axisHeight: Number = 4 ; // protected var axisWidth: Number = 7 ; // public var drive: int = 0 ; // public var steer: int = 0 ; //drive = 1 - //drive = 0 - , //drive = -1 - // //steer = -1 - //steer = 0 - //steer = 1 -
// : private const FWD= 1 ; // private const AWD= 2 ; // private const RWD= 3 ; // private var _privod: Number ; // , private var _maxTurnAngle: Number ; // private var _width : Number ; // private var _height : Number ; // private var _axisOffset: Number ; // , private const _angularDamping = 7 ; // private const _angularDampingReverse = 3 ; // , private const _linearDamping = 0.25 ; // , - private const _linearDampingReverse = 0.5 ; // public var _carBody:QuickObject; // private var _frontAxisBodyLeft:QuickObject; // private var _frontAxisBodyRight:QuickObject; private var _rearAxisBodyLeft:QuickObject; private var _rearAxisBodyRight:QuickObject; private var _frontLeftJoint:QuickObject; // private var _frontRightJoint:QuickObject; private var _rearLeftJoint:QuickObject; // private var _rearRightJoint:QuickObject; protected var axisHeight: Number = 4 ; // protected var axisWidth: Number = 7 ; // public var drive: int = 0 ; // public var steer: int = 0 ; //drive = 1 - //drive = 0 - , //drive = -1 - // //steer = -1 - //steer = 0 - //steer = 1 -
// : private const FWD= 1 ; // private const AWD= 2 ; // private const RWD= 3 ; // private var _privod: Number ; // , private var _maxTurnAngle: Number ; // private var _width : Number ; // private var _height : Number ; // private var _axisOffset: Number ; // , private const _angularDamping = 7 ; // private const _angularDampingReverse = 3 ; // , private const _linearDamping = 0.25 ; // , - private const _linearDampingReverse = 0.5 ; // public var _carBody:QuickObject; // private var _frontAxisBodyLeft:QuickObject; // private var _frontAxisBodyRight:QuickObject; private var _rearAxisBodyLeft:QuickObject; private var _rearAxisBodyRight:QuickObject; private var _frontLeftJoint:QuickObject; // private var _frontRightJoint:QuickObject; private var _rearLeftJoint:QuickObject; // private var _rearRightJoint:QuickObject; protected var axisHeight: Number = 4 ; // protected var axisWidth: Number = 7 ; // public var drive: int = 0 ; // public var steer: int = 0 ; //drive = 1 - //drive = 0 - , //drive = -1 - // //steer = -1 - //steer = 0 - //steer = 1 -
// : private const FWD= 1 ; // private const AWD= 2 ; // private const RWD= 3 ; // private var _privod: Number ; // , private var _maxTurnAngle: Number ; // private var _width : Number ; // private var _height : Number ; // private var _axisOffset: Number ; // , private const _angularDamping = 7 ; // private const _angularDampingReverse = 3 ; // , private const _linearDamping = 0.25 ; // , - private const _linearDampingReverse = 0.5 ; // public var _carBody:QuickObject; // private var _frontAxisBodyLeft:QuickObject; // private var _frontAxisBodyRight:QuickObject; private var _rearAxisBodyLeft:QuickObject; private var _rearAxisBodyRight:QuickObject; private var _frontLeftJoint:QuickObject; // private var _frontRightJoint:QuickObject; private var _rearLeftJoint:QuickObject; // private var _rearRightJoint:QuickObject; protected var axisHeight: Number = 4 ; // protected var axisWidth: Number = 7 ; // public var drive: int = 0 ; // public var steer: int = 0 ; //drive = 1 - //drive = 0 - , //drive = -1 - // //steer = -1 - //steer = 0 - //steer = 1 -
// : private const FWD= 1 ; // private const AWD= 2 ; // private const RWD= 3 ; // private var _privod: Number ; // , private var _maxTurnAngle: Number ; // private var _width : Number ; // private var _height : Number ; // private var _axisOffset: Number ; // , private const _angularDamping = 7 ; // private const _angularDampingReverse = 3 ; // , private const _linearDamping = 0.25 ; // , - private const _linearDampingReverse = 0.5 ; // public var _carBody:QuickObject; // private var _frontAxisBodyLeft:QuickObject; // private var _frontAxisBodyRight:QuickObject; private var _rearAxisBodyLeft:QuickObject; private var _rearAxisBodyRight:QuickObject; private var _frontLeftJoint:QuickObject; // private var _frontRightJoint:QuickObject; private var _rearLeftJoint:QuickObject; // private var _rearRightJoint:QuickObject; protected var axisHeight: Number = 4 ; // protected var axisWidth: Number = 7 ; // public var drive: int = 0 ; // public var steer: int = 0 ; //drive = 1 - //drive = 0 - , //drive = -1 - // //steer = -1 - //steer = 0 - //steer = 1 -
// : private const FWD= 1 ; // private const AWD= 2 ; // private const RWD= 3 ; // private var _privod: Number ; // , private var _maxTurnAngle: Number ; // private var _width : Number ; // private var _height : Number ; // private var _axisOffset: Number ; // , private const _angularDamping = 7 ; // private const _angularDampingReverse = 3 ; // , private const _linearDamping = 0.25 ; // , - private const _linearDampingReverse = 0.5 ; // public var _carBody:QuickObject; // private var _frontAxisBodyLeft:QuickObject; // private var _frontAxisBodyRight:QuickObject; private var _rearAxisBodyLeft:QuickObject; private var _rearAxisBodyRight:QuickObject; private var _frontLeftJoint:QuickObject; // private var _frontRightJoint:QuickObject; private var _rearLeftJoint:QuickObject; // private var _rearRightJoint:QuickObject; protected var axisHeight: Number = 4 ; // protected var axisWidth: Number = 7 ; // public var drive: int = 0 ; // public var steer: int = 0 ; //drive = 1 - //drive = 0 - , //drive = -1 - // //steer = -1 - //steer = 0 - //steer = 1 -
// : private const FWD= 1 ; // private const AWD= 2 ; // private const RWD= 3 ; // private var _privod: Number ; // , private var _maxTurnAngle: Number ; // private var _width : Number ; // private var _height : Number ; // private var _axisOffset: Number ; // , private const _angularDamping = 7 ; // private const _angularDampingReverse = 3 ; // , private const _linearDamping = 0.25 ; // , - private const _linearDampingReverse = 0.5 ; // public var _carBody:QuickObject; // private var _frontAxisBodyLeft:QuickObject; // private var _frontAxisBodyRight:QuickObject; private var _rearAxisBodyLeft:QuickObject; private var _rearAxisBodyRight:QuickObject; private var _frontLeftJoint:QuickObject; // private var _frontRightJoint:QuickObject; private var _rearLeftJoint:QuickObject; // private var _rearRightJoint:QuickObject; protected var axisHeight: Number = 4 ; // protected var axisWidth: Number = 7 ; // public var drive: int = 0 ; // public var steer: int = 0 ; //drive = 1 - //drive = 0 - , //drive = -1 - // //steer = -1 - //steer = 0 - //steer = 1 -
// : private const FWD= 1 ; // private const AWD= 2 ; // private const RWD= 3 ; // private var _privod: Number ; // , private var _maxTurnAngle: Number ; // private var _width : Number ; // private var _height : Number ; // private var _axisOffset: Number ; // , private const _angularDamping = 7 ; // private const _angularDampingReverse = 3 ; // , private const _linearDamping = 0.25 ; // , - private const _linearDampingReverse = 0.5 ; // public var _carBody:QuickObject; // private var _frontAxisBodyLeft:QuickObject; // private var _frontAxisBodyRight:QuickObject; private var _rearAxisBodyLeft:QuickObject; private var _rearAxisBodyRight:QuickObject; private var _frontLeftJoint:QuickObject; // private var _frontRightJoint:QuickObject; private var _rearLeftJoint:QuickObject; // private var _rearRightJoint:QuickObject; protected var axisHeight: Number = 4 ; // protected var axisWidth: Number = 7 ; // public var drive: int = 0 ; // public var steer: int = 0 ; //drive = 1 - //drive = 0 - , //drive = -1 - // //steer = -1 - //steer = 0 - //steer = 1 -
// : private const FWD= 1 ; // private const AWD= 2 ; // private const RWD= 3 ; // private var _privod: Number ; // , private var _maxTurnAngle: Number ; // private var _width : Number ; // private var _height : Number ; // private var _axisOffset: Number ; // , private const _angularDamping = 7 ; // private const _angularDampingReverse = 3 ; // , private const _linearDamping = 0.25 ; // , - private const _linearDampingReverse = 0.5 ; // public var _carBody:QuickObject; // private var _frontAxisBodyLeft:QuickObject; // private var _frontAxisBodyRight:QuickObject; private var _rearAxisBodyLeft:QuickObject; private var _rearAxisBodyRight:QuickObject; private var _frontLeftJoint:QuickObject; // private var _frontRightJoint:QuickObject; private var _rearLeftJoint:QuickObject; // private var _rearRightJoint:QuickObject; protected var axisHeight: Number = 4 ; // protected var axisWidth: Number = 7 ; // public var drive: int = 0 ; // public var steer: int = 0 ; //drive = 1 - //drive = 0 - , //drive = -1 - // //steer = -1 - //steer = 0 - //steer = 1 -
// : private const FWD= 1 ; // private const AWD= 2 ; // private const RWD= 3 ; // private var _privod: Number ; // , private var _maxTurnAngle: Number ; // private var _width : Number ; // private var _height : Number ; // private var _axisOffset: Number ; // , private const _angularDamping = 7 ; // private const _angularDampingReverse = 3 ; // , private const _linearDamping = 0.25 ; // , - private const _linearDampingReverse = 0.5 ; // public var _carBody:QuickObject; // private var _frontAxisBodyLeft:QuickObject; // private var _frontAxisBodyRight:QuickObject; private var _rearAxisBodyLeft:QuickObject; private var _rearAxisBodyRight:QuickObject; private var _frontLeftJoint:QuickObject; // private var _frontRightJoint:QuickObject; private var _rearLeftJoint:QuickObject; // private var _rearRightJoint:QuickObject; protected var axisHeight: Number = 4 ; // protected var axisWidth: Number = 7 ; // public var drive: int = 0 ; // public var steer: int = 0 ; //drive = 1 - //drive = 0 - , //drive = -1 - // //steer = -1 - //steer = 0 - //steer = 1 -
// : private const FWD= 1 ; // private const AWD= 2 ; // private const RWD= 3 ; // private var _privod: Number ; // , private var _maxTurnAngle: Number ; // private var _width : Number ; // private var _height : Number ; // private var _axisOffset: Number ; // , private const _angularDamping = 7 ; // private const _angularDampingReverse = 3 ; // , private const _linearDamping = 0.25 ; // , - private const _linearDampingReverse = 0.5 ; // public var _carBody:QuickObject; // private var _frontAxisBodyLeft:QuickObject; // private var _frontAxisBodyRight:QuickObject; private var _rearAxisBodyLeft:QuickObject; private var _rearAxisBodyRight:QuickObject; private var _frontLeftJoint:QuickObject; // private var _frontRightJoint:QuickObject; private var _rearLeftJoint:QuickObject; // private var _rearRightJoint:QuickObject; protected var axisHeight: Number = 4 ; // protected var axisWidth: Number = 7 ; // public var drive: int = 0 ; // public var steer: int = 0 ; //drive = 1 - //drive = 0 - , //drive = -1 - // //steer = -1 - //steer = 0 - //steer = 1 -
// : private const FWD= 1 ; // private const AWD= 2 ; // private const RWD= 3 ; // private var _privod: Number ; // , private var _maxTurnAngle: Number ; // private var _width : Number ; // private var _height : Number ; // private var _axisOffset: Number ; // , private const _angularDamping = 7 ; // private const _angularDampingReverse = 3 ; // , private const _linearDamping = 0.25 ; // , - private const _linearDampingReverse = 0.5 ; // public var _carBody:QuickObject; // private var _frontAxisBodyLeft:QuickObject; // private var _frontAxisBodyRight:QuickObject; private var _rearAxisBodyLeft:QuickObject; private var _rearAxisBodyRight:QuickObject; private var _frontLeftJoint:QuickObject; // private var _frontRightJoint:QuickObject; private var _rearLeftJoint:QuickObject; // private var _rearRightJoint:QuickObject; protected var axisHeight: Number = 4 ; // protected var axisWidth: Number = 7 ; // public var drive: int = 0 ; // public var steer: int = 0 ; //drive = 1 - //drive = 0 - , //drive = -1 - // //steer = -1 - //steer = 0 - //steer = 1 -
// : private const FWD= 1 ; // private const AWD= 2 ; // private const RWD= 3 ; // private var _privod: Number ; // , private var _maxTurnAngle: Number ; // private var _width : Number ; // private var _height : Number ; // private var _axisOffset: Number ; // , private const _angularDamping = 7 ; // private const _angularDampingReverse = 3 ; // , private const _linearDamping = 0.25 ; // , - private const _linearDampingReverse = 0.5 ; // public var _carBody:QuickObject; // private var _frontAxisBodyLeft:QuickObject; // private var _frontAxisBodyRight:QuickObject; private var _rearAxisBodyLeft:QuickObject; private var _rearAxisBodyRight:QuickObject; private var _frontLeftJoint:QuickObject; // private var _frontRightJoint:QuickObject; private var _rearLeftJoint:QuickObject; // private var _rearRightJoint:QuickObject; protected var axisHeight: Number = 4 ; // protected var axisWidth: Number = 7 ; // public var drive: int = 0 ; // public var steer: int = 0 ; //drive = 1 - //drive = 0 - , //drive = -1 - // //steer = -1 - //steer = 0 - //steer = 1 -
// : private const FWD= 1 ; // private const AWD= 2 ; // private const RWD= 3 ; // private var _privod: Number ; // , private var _maxTurnAngle: Number ; // private var _width : Number ; // private var _height : Number ; // private var _axisOffset: Number ; // , private const _angularDamping = 7 ; // private const _angularDampingReverse = 3 ; // , private const _linearDamping = 0.25 ; // , - private const _linearDampingReverse = 0.5 ; // public var _carBody:QuickObject; // private var _frontAxisBodyLeft:QuickObject; // private var _frontAxisBodyRight:QuickObject; private var _rearAxisBodyLeft:QuickObject; private var _rearAxisBodyRight:QuickObject; private var _frontLeftJoint:QuickObject; // private var _frontRightJoint:QuickObject; private var _rearLeftJoint:QuickObject; // private var _rearRightJoint:QuickObject; protected var axisHeight: Number = 4 ; // protected var axisWidth: Number = 7 ; // public var drive: int = 0 ; // public var steer: int = 0 ; //drive = 1 - //drive = 0 - , //drive = -1 - // //steer = -1 - //steer = 0 - //steer = 1 -
// : private const FWD= 1 ; // private const AWD= 2 ; // private const RWD= 3 ; // private var _privod: Number ; // , private var _maxTurnAngle: Number ; // private var _width : Number ; // private var _height : Number ; // private var _axisOffset: Number ; // , private const _angularDamping = 7 ; // private const _angularDampingReverse = 3 ; // , private const _linearDamping = 0.25 ; // , - private const _linearDampingReverse = 0.5 ; // public var _carBody:QuickObject; // private var _frontAxisBodyLeft:QuickObject; // private var _frontAxisBodyRight:QuickObject; private var _rearAxisBodyLeft:QuickObject; private var _rearAxisBodyRight:QuickObject; private var _frontLeftJoint:QuickObject; // private var _frontRightJoint:QuickObject; private var _rearLeftJoint:QuickObject; // private var _rearRightJoint:QuickObject; protected var axisHeight: Number = 4 ; // protected var axisWidth: Number = 7 ; // public var drive: int = 0 ; // public var steer: int = 0 ; //drive = 1 - //drive = 0 - , //drive = -1 - // //steer = -1 - //steer = 0 - //steer = 1 -
// : private const FWD= 1 ; // private const AWD= 2 ; // private const RWD= 3 ; // private var _privod: Number ; // , private var _maxTurnAngle: Number ; // private var _width : Number ; // private var _height : Number ; // private var _axisOffset: Number ; // , private const _angularDamping = 7 ; // private const _angularDampingReverse = 3 ; // , private const _linearDamping = 0.25 ; // , - private const _linearDampingReverse = 0.5 ; // public var _carBody:QuickObject; // private var _frontAxisBodyLeft:QuickObject; // private var _frontAxisBodyRight:QuickObject; private var _rearAxisBodyLeft:QuickObject; private var _rearAxisBodyRight:QuickObject; private var _frontLeftJoint:QuickObject; // private var _frontRightJoint:QuickObject; private var _rearLeftJoint:QuickObject; // private var _rearRightJoint:QuickObject; protected var axisHeight: Number = 4 ; // protected var axisWidth: Number = 7 ; // public var drive: int = 0 ; // public var steer: int = 0 ; //drive = 1 - //drive = 0 - , //drive = -1 - // //steer = -1 - //steer = 0 - //steer = 1 -
// : private const FWD= 1 ; // private const AWD= 2 ; // private const RWD= 3 ; // private var _privod: Number ; // , private var _maxTurnAngle: Number ; // private var _width : Number ; // private var _height : Number ; // private var _axisOffset: Number ; // , private const _angularDamping = 7 ; // private const _angularDampingReverse = 3 ; // , private const _linearDamping = 0.25 ; // , - private const _linearDampingReverse = 0.5 ; // public var _carBody:QuickObject; // private var _frontAxisBodyLeft:QuickObject; // private var _frontAxisBodyRight:QuickObject; private var _rearAxisBodyLeft:QuickObject; private var _rearAxisBodyRight:QuickObject; private var _frontLeftJoint:QuickObject; // private var _frontRightJoint:QuickObject; private var _rearLeftJoint:QuickObject; // private var _rearRightJoint:QuickObject; protected var axisHeight: Number = 4 ; // protected var axisWidth: Number = 7 ; // public var drive: int = 0 ; // public var steer: int = 0 ; //drive = 1 - //drive = 0 - , //drive = -1 - // //steer = -1 - //steer = 0 - //steer = 1 -
// : private const FWD= 1 ; // private const AWD= 2 ; // private const RWD= 3 ; // private var _privod: Number ; // , private var _maxTurnAngle: Number ; // private var _width : Number ; // private var _height : Number ; // private var _axisOffset: Number ; // , private const _angularDamping = 7 ; // private const _angularDampingReverse = 3 ; // , private const _linearDamping = 0.25 ; // , - private const _linearDampingReverse = 0.5 ; // public var _carBody:QuickObject; // private var _frontAxisBodyLeft:QuickObject; // private var _frontAxisBodyRight:QuickObject; private var _rearAxisBodyLeft:QuickObject; private var _rearAxisBodyRight:QuickObject; private var _frontLeftJoint:QuickObject; // private var _frontRightJoint:QuickObject; private var _rearLeftJoint:QuickObject; // private var _rearRightJoint:QuickObject; protected var axisHeight: Number = 4 ; // protected var axisWidth: Number = 7 ; // public var drive: int = 0 ; // public var steer: int = 0 ; //drive = 1 - //drive = 0 - , //drive = -1 - // //steer = -1 - //steer = 0 - //steer = 1 -
// : private const FWD= 1 ; // private const AWD= 2 ; // private const RWD= 3 ; // private var _privod: Number ; // , private var _maxTurnAngle: Number ; // private var _width : Number ; // private var _height : Number ; // private var _axisOffset: Number ; // , private const _angularDamping = 7 ; // private const _angularDampingReverse = 3 ; // , private const _linearDamping = 0.25 ; // , - private const _linearDampingReverse = 0.5 ; // public var _carBody:QuickObject; // private var _frontAxisBodyLeft:QuickObject; // private var _frontAxisBodyRight:QuickObject; private var _rearAxisBodyLeft:QuickObject; private var _rearAxisBodyRight:QuickObject; private var _frontLeftJoint:QuickObject; // private var _frontRightJoint:QuickObject; private var _rearLeftJoint:QuickObject; // private var _rearRightJoint:QuickObject; protected var axisHeight: Number = 4 ; // protected var axisWidth: Number = 7 ; // public var drive: int = 0 ; // public var steer: int = 0 ; //drive = 1 - //drive = 0 - , //drive = -1 - // //steer = -1 - //steer = 0 - //steer = 1 -
// : private const FWD= 1 ; // private const AWD= 2 ; // private const RWD= 3 ; // private var _privod: Number ; // , private var _maxTurnAngle: Number ; // private var _width : Number ; // private var _height : Number ; // private var _axisOffset: Number ; // , private const _angularDamping = 7 ; // private const _angularDampingReverse = 3 ; // , private const _linearDamping = 0.25 ; // , - private const _linearDampingReverse = 0.5 ; // public var _carBody:QuickObject; // private var _frontAxisBodyLeft:QuickObject; // private var _frontAxisBodyRight:QuickObject; private var _rearAxisBodyLeft:QuickObject; private var _rearAxisBodyRight:QuickObject; private var _frontLeftJoint:QuickObject; // private var _frontRightJoint:QuickObject; private var _rearLeftJoint:QuickObject; // private var _rearRightJoint:QuickObject; protected var axisHeight: Number = 4 ; // protected var axisWidth: Number = 7 ; // public var drive: int = 0 ; // public var steer: int = 0 ; //drive = 1 - //drive = 0 - , //drive = -1 - // //steer = -1 - //steer = 0 - //steer = 1 -
// : private const FWD= 1 ; // private const AWD= 2 ; // private const RWD= 3 ; // private var _privod: Number ; // , private var _maxTurnAngle: Number ; // private var _width : Number ; // private var _height : Number ; // private var _axisOffset: Number ; // , private const _angularDamping = 7 ; // private const _angularDampingReverse = 3 ; // , private const _linearDamping = 0.25 ; // , - private const _linearDampingReverse = 0.5 ; // public var _carBody:QuickObject; // private var _frontAxisBodyLeft:QuickObject; // private var _frontAxisBodyRight:QuickObject; private var _rearAxisBodyLeft:QuickObject; private var _rearAxisBodyRight:QuickObject; private var _frontLeftJoint:QuickObject; // private var _frontRightJoint:QuickObject; private var _rearLeftJoint:QuickObject; // private var _rearRightJoint:QuickObject; protected var axisHeight: Number = 4 ; // protected var axisWidth: Number = 7 ; // public var drive: int = 0 ; // public var steer: int = 0 ; //drive = 1 - //drive = 0 - , //drive = -1 - // //steer = -1 - //steer = 0 - //steer = 1 -
// : private const FWD= 1 ; // private const AWD= 2 ; // private const RWD= 3 ; // private var _privod: Number ; // , private var _maxTurnAngle: Number ; // private var _width : Number ; // private var _height : Number ; // private var _axisOffset: Number ; // , private const _angularDamping = 7 ; // private const _angularDampingReverse = 3 ; // , private const _linearDamping = 0.25 ; // , - private const _linearDampingReverse = 0.5 ; // public var _carBody:QuickObject; // private var _frontAxisBodyLeft:QuickObject; // private var _frontAxisBodyRight:QuickObject; private var _rearAxisBodyLeft:QuickObject; private var _rearAxisBodyRight:QuickObject; private var _frontLeftJoint:QuickObject; // private var _frontRightJoint:QuickObject; private var _rearLeftJoint:QuickObject; // private var _rearRightJoint:QuickObject; protected var axisHeight: Number = 4 ; // protected var axisWidth: Number = 7 ; // public var drive: int = 0 ; // public var steer: int = 0 ; //drive = 1 - //drive = 0 - , //drive = -1 - // //steer = -1 - //steer = 0 - //steer = 1 -
// : private const FWD= 1 ; // private const AWD= 2 ; // private const RWD= 3 ; // private var _privod: Number ; // , private var _maxTurnAngle: Number ; // private var _width : Number ; // private var _height : Number ; // private var _axisOffset: Number ; // , private const _angularDamping = 7 ; // private const _angularDampingReverse = 3 ; // , private const _linearDamping = 0.25 ; // , - private const _linearDampingReverse = 0.5 ; // public var _carBody:QuickObject; // private var _frontAxisBodyLeft:QuickObject; // private var _frontAxisBodyRight:QuickObject; private var _rearAxisBodyLeft:QuickObject; private var _rearAxisBodyRight:QuickObject; private var _frontLeftJoint:QuickObject; // private var _frontRightJoint:QuickObject; private var _rearLeftJoint:QuickObject; // private var _rearRightJoint:QuickObject; protected var axisHeight: Number = 4 ; // protected var axisWidth: Number = 7 ; // public var drive: int = 0 ; // public var steer: int = 0 ; //drive = 1 - //drive = 0 - , //drive = -1 - // //steer = -1 - //steer = 0 - //steer = 1 -
// : private const FWD= 1 ; // private const AWD= 2 ; // private const RWD= 3 ; // private var _privod: Number ; // , private var _maxTurnAngle: Number ; // private var _width : Number ; // private var _height : Number ; // private var _axisOffset: Number ; // , private const _angularDamping = 7 ; // private const _angularDampingReverse = 3 ; // , private const _linearDamping = 0.25 ; // , - private const _linearDampingReverse = 0.5 ; // public var _carBody:QuickObject; // private var _frontAxisBodyLeft:QuickObject; // private var _frontAxisBodyRight:QuickObject; private var _rearAxisBodyLeft:QuickObject; private var _rearAxisBodyRight:QuickObject; private var _frontLeftJoint:QuickObject; // private var _frontRightJoint:QuickObject; private var _rearLeftJoint:QuickObject; // private var _rearRightJoint:QuickObject; protected var axisHeight: Number = 4 ; // protected var axisWidth: Number = 7 ; // public var drive: int = 0 ; // public var steer: int = 0 ; //drive = 1 - //drive = 0 - , //drive = -1 - // //steer = -1 - //steer = 0 - //steer = 1 -
// : private const FWD= 1 ; // private const AWD= 2 ; // private const RWD= 3 ; // private var _privod: Number ; // , private var _maxTurnAngle: Number ; // private var _width : Number ; // private var _height : Number ; // private var _axisOffset: Number ; // , private const _angularDamping = 7 ; // private const _angularDampingReverse = 3 ; // , private const _linearDamping = 0.25 ; // , - private const _linearDampingReverse = 0.5 ; // public var _carBody:QuickObject; // private var _frontAxisBodyLeft:QuickObject; // private var _frontAxisBodyRight:QuickObject; private var _rearAxisBodyLeft:QuickObject; private var _rearAxisBodyRight:QuickObject; private var _frontLeftJoint:QuickObject; // private var _frontRightJoint:QuickObject; private var _rearLeftJoint:QuickObject; // private var _rearRightJoint:QuickObject; protected var axisHeight: Number = 4 ; // protected var axisWidth: Number = 7 ; // public var drive: int = 0 ; // public var steer: int = 0 ; //drive = 1 - //drive = 0 - , //drive = -1 - // //steer = -1 - //steer = 0 - //steer = 1 -
// : private const FWD= 1 ; // private const AWD= 2 ; // private const RWD= 3 ; // private var _privod: Number ; // , private var _maxTurnAngle: Number ; // private var _width : Number ; // private var _height : Number ; // private var _axisOffset: Number ; // , private const _angularDamping = 7 ; // private const _angularDampingReverse = 3 ; // , private const _linearDamping = 0.25 ; // , - private const _linearDampingReverse = 0.5 ; // public var _carBody:QuickObject; // private var _frontAxisBodyLeft:QuickObject; // private var _frontAxisBodyRight:QuickObject; private var _rearAxisBodyLeft:QuickObject; private var _rearAxisBodyRight:QuickObject; private var _frontLeftJoint:QuickObject; // private var _frontRightJoint:QuickObject; private var _rearLeftJoint:QuickObject; // private var _rearRightJoint:QuickObject; protected var axisHeight: Number = 4 ; // protected var axisWidth: Number = 7 ; // public var drive: int = 0 ; // public var steer: int = 0 ; //drive = 1 - //drive = 0 - , //drive = -1 - // //steer = -1 - //steer = 0 - //steer = 1 -
// : private const FWD= 1 ; // private const AWD= 2 ; // private const RWD= 3 ; // private var _privod: Number ; // , private var _maxTurnAngle: Number ; // private var _width : Number ; // private var _height : Number ; // private var _axisOffset: Number ; // , private const _angularDamping = 7 ; // private const _angularDampingReverse = 3 ; // , private const _linearDamping = 0.25 ; // , - private const _linearDampingReverse = 0.5 ; // public var _carBody:QuickObject; // private var _frontAxisBodyLeft:QuickObject; // private var _frontAxisBodyRight:QuickObject; private var _rearAxisBodyLeft:QuickObject; private var _rearAxisBodyRight:QuickObject; private var _frontLeftJoint:QuickObject; // private var _frontRightJoint:QuickObject; private var _rearLeftJoint:QuickObject; // private var _rearRightJoint:QuickObject; protected var axisHeight: Number = 4 ; // protected var axisWidth: Number = 7 ; // public var drive: int = 0 ; // public var steer: int = 0 ; //drive = 1 - //drive = 0 - , //drive = -1 - // //steer = -1 - //steer = 0 - //steer = 1 -
// : private const FWD= 1 ; // private const AWD= 2 ; // private const RWD= 3 ; // private var _privod: Number ; // , private var _maxTurnAngle: Number ; // private var _width : Number ; // private var _height : Number ; // private var _axisOffset: Number ; // , private const _angularDamping = 7 ; // private const _angularDampingReverse = 3 ; // , private const _linearDamping = 0.25 ; // , - private const _linearDampingReverse = 0.5 ; // public var _carBody:QuickObject; // private var _frontAxisBodyLeft:QuickObject; // private var _frontAxisBodyRight:QuickObject; private var _rearAxisBodyLeft:QuickObject; private var _rearAxisBodyRight:QuickObject; private var _frontLeftJoint:QuickObject; // private var _frontRightJoint:QuickObject; private var _rearLeftJoint:QuickObject; // private var _rearRightJoint:QuickObject; protected var axisHeight: Number = 4 ; // protected var axisWidth: Number = 7 ; // public var drive: int = 0 ; // public var steer: int = 0 ; //drive = 1 - //drive = 0 - , //drive = -1 - // //steer = -1 - //steer = 0 - //steer = 1 -
// : private const FWD= 1 ; // private const AWD= 2 ; // private const RWD= 3 ; // private var _privod: Number ; // , private var _maxTurnAngle: Number ; // private var _width : Number ; // private var _height : Number ; // private var _axisOffset: Number ; // , private const _angularDamping = 7 ; // private const _angularDampingReverse = 3 ; // , private const _linearDamping = 0.25 ; // , - private const _linearDampingReverse = 0.5 ; // public var _carBody:QuickObject; // private var _frontAxisBodyLeft:QuickObject; // private var _frontAxisBodyRight:QuickObject; private var _rearAxisBodyLeft:QuickObject; private var _rearAxisBodyRight:QuickObject; private var _frontLeftJoint:QuickObject; // private var _frontRightJoint:QuickObject; private var _rearLeftJoint:QuickObject; // private var _rearRightJoint:QuickObject; protected var axisHeight: Number = 4 ; // protected var axisWidth: Number = 7 ; // public var drive: int = 0 ; // public var steer: int = 0 ; //drive = 1 - //drive = 0 - , //drive = -1 - // //steer = -1 - //steer = 0 - //steer = 1 -
// : private const FWD= 1 ; // private const AWD= 2 ; // private const RWD= 3 ; // private var _privod: Number ; // , private var _maxTurnAngle: Number ; // private var _width : Number ; // private var _height : Number ; // private var _axisOffset: Number ; // , private const _angularDamping = 7 ; // private const _angularDampingReverse = 3 ; // , private const _linearDamping = 0.25 ; // , - private const _linearDampingReverse = 0.5 ; // public var _carBody:QuickObject; // private var _frontAxisBodyLeft:QuickObject; // private var _frontAxisBodyRight:QuickObject; private var _rearAxisBodyLeft:QuickObject; private var _rearAxisBodyRight:QuickObject; private var _frontLeftJoint:QuickObject; // private var _frontRightJoint:QuickObject; private var _rearLeftJoint:QuickObject; // private var _rearRightJoint:QuickObject; protected var axisHeight: Number = 4 ; // protected var axisWidth: Number = 7 ; // public var drive: int = 0 ; // public var steer: int = 0 ; //drive = 1 - //drive = 0 - , //drive = -1 - // //steer = -1 - //steer = 0 - //steer = 1 -
// : private const FWD= 1 ; // private const AWD= 2 ; // private const RWD= 3 ; // private var _privod: Number ; // , private var _maxTurnAngle: Number ; // private var _width : Number ; // private var _height : Number ; // private var _axisOffset: Number ; // , private const _angularDamping = 7 ; // private const _angularDampingReverse = 3 ; // , private const _linearDamping = 0.25 ; // , - private const _linearDampingReverse = 0.5 ; // public var _carBody:QuickObject; // private var _frontAxisBodyLeft:QuickObject; // private var _frontAxisBodyRight:QuickObject; private var _rearAxisBodyLeft:QuickObject; private var _rearAxisBodyRight:QuickObject; private var _frontLeftJoint:QuickObject; // private var _frontRightJoint:QuickObject; private var _rearLeftJoint:QuickObject; // private var _rearRightJoint:QuickObject; protected var axisHeight: Number = 4 ; // protected var axisWidth: Number = 7 ; // public var drive: int = 0 ; // public var steer: int = 0 ; //drive = 1 - //drive = 0 - , //drive = -1 - // //steer = -1 - //steer = 0 - //steer = 1 -
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
// _width = 76 ; _height = 40 ; _maxTurnAngle = 15 * Globals. DEG_TO_RAD ; // _axisOffset: Number = ( _width / 4 - axisWidth ) / Globals. RATIO // _privod = FWD; // , _carBody = world. addBox ( { width : this . _width / 2 / Globals. RATIO , height : this . _height / 2 / Globals. RATIO , x : ( this . x + this . _width / 2 ) / Globals. RATIO , y : ( this . y + this . _height / 2 ) / Globals. RATIO , density: 0.48 , driction: 0.3 , restitution: 0.4 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true , skin: null , scaleSkin: true } ) ; this ._frontAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. body . GetWorldCenter ( ) . x + this ._axisOffset, y :_carBody. body . GetWorldCenter ( ) . y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 } ) ; this ._frontLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyLeft. body , x1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyLeft. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._frontRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._frontAxisBodyRight. body , x1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y1: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , x2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . x , y2: this ._frontAxisBodyRight. body . GetWorldCenter ( ) . y , enableLimit: true , enableMotor: true , collideConnected: true , lowerAngle:- this ._maxTurnAngle, upperAngle: this ._maxTurnAngle } ) ; this ._rearAxisBodyLeft = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y - this . _height / 4 / Globals. RATIO + 1 / Globals. RATIO , // + (this.axisHeight/2) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearAxisBodyRight = this . world . addBox ( { width : this . axisWidth / Globals. RATIO , height : ( this . axisHeight ) / Globals. RATIO , x :_carBody. x - this ._axisOffset, //-this.frontPivotOffset, y :_carBody. y + this . _height / 4 / Globals. RATIO - 1 / Globals. RATIO , // - (this.axisHeight) / Globals.RATIO, density: 0.48 , friction: 0.3 , restitution: 0.5 , linearDamping: this ._linearDamping, angularDamping: this ._angularDamping, groupIndex:- 1 , isSleeping: true } ) ; this ._rearLeftJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyLeft. body , x1: this ._rearAxisBodyLeft. x , y1: this ._rearAxisBodyLeft. y , x2: this ._rearAxisBodyLeft. x , y2: this ._rearAxisBodyLeft. y , enableLimit: true , enableMotor: false , collideConnected: false , lowerAngle: 0 , upperAngle: 0 } ) ; this ._rearRightJoint = this . world . addJoint ( { type :QuickBox2D. REVOLUTE , a: this ._carBody. body , b: this ._rearAxisBodyRight. body , x1: this ._rearAxisBodyRight. x , y1: this ._rearAxisBodyRight. y , x2: this ._rearAxisBodyRight. x , y2: this ._rearAxisBodyRight. y , enableLimit: true , enableMotor: false , lowerAngle: 0 , upperAngle: 0 } ) ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
stage . addEventListener ( KeyboardEvent. KEY_DOWN , keyDownList ) ; stage . addEventListener ( KeyboardEvent. KEY_UP , keyUpList ) ; world. addEventListener ( QuickBox2D. STEP ,onStep ) ; ... var bup: Boolean ; var bdown: Boolean ; var bleft: Boolean ; var bright: Boolean ; function keyDownList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = true ; } if ( e . keyCode == Keyboard. LEFT ) { bleft = true ; } if ( e . keyCode == Keyboard. DOWN ) { bdown = true ; } if ( e . keyCode == Keyboard. RIGHT ) { bright = true ; } } ; function keyUpList ( e :KeyboardEvent ) : void { if ( e . keyCode == Keyboard. UP ) { bup = false ; } ; if ( e . keyCode == Keyboard. LEFT ) { bleft = false ; } ; if ( e . keyCode == Keyboard. DOWN ) { bdown = false ; } ; if ( e . keyCode == Keyboard. RIGHT ) { bright = false ; } ; } ; function onStep ( evt:Event ) : void { car. accelerate ( ) ; if ( bup ) { car. drive = 1 } ; if ( bdown ) { car. drive =- 1 } ; if ( ! bup && ! bdown ) ( car. drive = 0 ) ; if ( bleft ) { car. steer =- 1 } ; if ( bright ) { car. steer = 1 } ; if ( ! bleft && ! bright ) { car. steer = 0 } ; } ;
this ._carBody. body . WakeUp ( ) ; this ._frontAxisBodyLeft. body . WakeUp ( ) ; this ._frontAxisBodyRight. body . WakeUp ( ) ;
this ._carBody. body . WakeUp ( ) ; this ._frontAxisBodyLeft. body . WakeUp ( ) ; this ._frontAxisBodyRight. body . WakeUp ( ) ;
this ._carBody. body . WakeUp ( ) ; this ._frontAxisBodyLeft. body . WakeUp ( ) ; this ._frontAxisBodyRight. body . WakeUp ( ) ;
if ( this . drive > 0 ) { // this ._acceleration = this ._accelerationForward; this . setLinearDamping ( this ._linearDamping ) ; this . setAngularDamping ( this ._angularDamping ) ; } else { // this ._acceleration = this ._accelerationBackwards; this . setLinearDamping ( this ._linearDamping ) ; this . setAngularDamping ( this ._angularDamping ) ; } this . addFriction ( this ._rearAxisBodyLeft. body , 0 ) ; this . addFriction ( this ._rearAxisBodyRight. body , 0 ) ; this . addFriction ( this ._frontAxisBodyLeft. body , 1 ) ; this . addFriction ( this ._frontAxisBodyRight. body , 1 ) ;
if ( this . drive > 0 ) { // this ._acceleration = this ._accelerationForward; this . setLinearDamping ( this ._linearDamping ) ; this . setAngularDamping ( this ._angularDamping ) ; } else { // this ._acceleration = this ._accelerationBackwards; this . setLinearDamping ( this ._linearDamping ) ; this . setAngularDamping ( this ._angularDamping ) ; } this . addFriction ( this ._rearAxisBodyLeft. body , 0 ) ; this . addFriction ( this ._rearAxisBodyRight. body , 0 ) ; this . addFriction ( this ._frontAxisBodyLeft. body , 1 ) ; this . addFriction ( this ._frontAxisBodyRight. body , 1 ) ;
if ( this . drive > 0 ) { // this ._acceleration = this ._accelerationForward; this . setLinearDamping ( this ._linearDamping ) ; this . setAngularDamping ( this ._angularDamping ) ; } else { // this ._acceleration = this ._accelerationBackwards; this . setLinearDamping ( this ._linearDamping ) ; this . setAngularDamping ( this ._angularDamping ) ; } this . addFriction ( this ._rearAxisBodyLeft. body , 0 ) ; this . addFriction ( this ._rearAxisBodyRight. body , 0 ) ; this . addFriction ( this ._frontAxisBodyLeft. body , 1 ) ; this . addFriction ( this ._frontAxisBodyRight. body , 1 ) ;
if ( this . drive > 0 ) { // this ._acceleration = this ._accelerationForward; this . setLinearDamping ( this ._linearDamping ) ; this . setAngularDamping ( this ._angularDamping ) ; } else { // this ._acceleration = this ._accelerationBackwards; this . setLinearDamping ( this ._linearDamping ) ; this . setAngularDamping ( this ._angularDamping ) ; } this . addFriction ( this ._rearAxisBodyLeft. body , 0 ) ; this . addFriction ( this ._rearAxisBodyRight. body , 0 ) ; this . addFriction ( this ._frontAxisBodyLeft. body , 1 ) ; this . addFriction ( this ._frontAxisBodyRight. body , 1 ) ;
if ( this . drive > 0 ) { // this ._acceleration = this ._accelerationForward; this . setLinearDamping ( this ._linearDamping ) ; this . setAngularDamping ( this ._angularDamping ) ; } else { // this ._acceleration = this ._accelerationBackwards; this . setLinearDamping ( this ._linearDamping ) ; this . setAngularDamping ( this ._angularDamping ) ; } this . addFriction ( this ._rearAxisBodyLeft. body , 0 ) ; this . addFriction ( this ._rearAxisBodyRight. body , 0 ) ; this . addFriction ( this ._frontAxisBodyLeft. body , 1 ) ; this . addFriction ( this ._frontAxisBodyRight. body , 1 ) ;
if ( this . drive > 0 ) { // this ._acceleration = this ._accelerationForward; this . setLinearDamping ( this ._linearDamping ) ; this . setAngularDamping ( this ._angularDamping ) ; } else { // this ._acceleration = this ._accelerationBackwards; this . setLinearDamping ( this ._linearDamping ) ; this . setAngularDamping ( this ._angularDamping ) ; } this . addFriction ( this ._rearAxisBodyLeft. body , 0 ) ; this . addFriction ( this ._rearAxisBodyRight. body , 0 ) ; this . addFriction ( this ._frontAxisBodyLeft. body , 1 ) ; this . addFriction ( this ._frontAxisBodyRight. body , 1 ) ;
if ( this . drive > 0 ) { // this ._acceleration = this ._accelerationForward; this . setLinearDamping ( this ._linearDamping ) ; this . setAngularDamping ( this ._angularDamping ) ; } else { // this ._acceleration = this ._accelerationBackwards; this . setLinearDamping ( this ._linearDamping ) ; this . setAngularDamping ( this ._angularDamping ) ; } this . addFriction ( this ._rearAxisBodyLeft. body , 0 ) ; this . addFriction ( this ._rearAxisBodyRight. body , 0 ) ; this . addFriction ( this ._frontAxisBodyLeft. body , 1 ) ; this . addFriction ( this ._frontAxisBodyRight. body , 1 ) ;
if ( this . drive > 0 ) { // this ._acceleration = this ._accelerationForward; this . setLinearDamping ( this ._linearDamping ) ; this . setAngularDamping ( this ._angularDamping ) ; } else { // this ._acceleration = this ._accelerationBackwards; this . setLinearDamping ( this ._linearDamping ) ; this . setAngularDamping ( this ._angularDamping ) ; } this . addFriction ( this ._rearAxisBodyLeft. body , 0 ) ; this . addFriction ( this ._rearAxisBodyRight. body , 0 ) ; this . addFriction ( this ._frontAxisBodyLeft. body , 1 ) ; this . addFriction ( this ._frontAxisBodyRight. body , 1 ) ;
if ( this . drive > 0 ) { // this ._acceleration = this ._accelerationForward; this . setLinearDamping ( this ._linearDamping ) ; this . setAngularDamping ( this ._angularDamping ) ; } else { // this ._acceleration = this ._accelerationBackwards; this . setLinearDamping ( this ._linearDamping ) ; this . setAngularDamping ( this ._angularDamping ) ; } this . addFriction ( this ._rearAxisBodyLeft. body , 0 ) ; this . addFriction ( this ._rearAxisBodyRight. body , 0 ) ; this . addFriction ( this ._frontAxisBodyLeft. body , 1 ) ; this . addFriction ( this ._frontAxisBodyRight. body , 1 ) ;
if ( this . drive > 0 ) { // this ._acceleration = this ._accelerationForward; this . setLinearDamping ( this ._linearDamping ) ; this . setAngularDamping ( this ._angularDamping ) ; } else { // this ._acceleration = this ._accelerationBackwards; this . setLinearDamping ( this ._linearDamping ) ; this . setAngularDamping ( this ._angularDamping ) ; } this . addFriction ( this ._rearAxisBodyLeft. body , 0 ) ; this . addFriction ( this ._rearAxisBodyRight. body , 0 ) ; this . addFriction ( this ._frontAxisBodyLeft. body , 1 ) ; this . addFriction ( this ._frontAxisBodyRight. body , 1 ) ;
if ( this . drive > 0 ) { // this ._acceleration = this ._accelerationForward; this . setLinearDamping ( this ._linearDamping ) ; this . setAngularDamping ( this ._angularDamping ) ; } else { // this ._acceleration = this ._accelerationBackwards; this . setLinearDamping ( this ._linearDamping ) ; this . setAngularDamping ( this ._angularDamping ) ; } this . addFriction ( this ._rearAxisBodyLeft. body , 0 ) ; this . addFriction ( this ._rearAxisBodyRight. body , 0 ) ; this . addFriction ( this ._frontAxisBodyLeft. body , 1 ) ; this . addFriction ( this ._frontAxisBodyRight. body , 1 ) ;
if ( this . drive > 0 ) { // this ._acceleration = this ._accelerationForward; this . setLinearDamping ( this ._linearDamping ) ; this . setAngularDamping ( this ._angularDamping ) ; } else { // this ._acceleration = this ._accelerationBackwards; this . setLinearDamping ( this ._linearDamping ) ; this . setAngularDamping ( this ._angularDamping ) ; } this . addFriction ( this ._rearAxisBodyLeft. body , 0 ) ; this . addFriction ( this ._rearAxisBodyRight. body , 0 ) ; this . addFriction ( this ._frontAxisBodyLeft. body , 1 ) ; this . addFriction ( this ._frontAxisBodyRight. body , 1 ) ;
if ( this . drive > 0 ) { // this ._acceleration = this ._accelerationForward; this . setLinearDamping ( this ._linearDamping ) ; this . setAngularDamping ( this ._angularDamping ) ; } else { // this ._acceleration = this ._accelerationBackwards; this . setLinearDamping ( this ._linearDamping ) ; this . setAngularDamping ( this ._angularDamping ) ; } this . addFriction ( this ._rearAxisBodyLeft. body , 0 ) ; this . addFriction ( this ._rearAxisBodyRight. body , 0 ) ; this . addFriction ( this ._frontAxisBodyLeft. body , 1 ) ; this . addFriction ( this ._frontAxisBodyRight. body , 1 ) ;
if ( this . drive > 0 ) { // this ._acceleration = this ._accelerationForward; this . setLinearDamping ( this ._linearDamping ) ; this . setAngularDamping ( this ._angularDamping ) ; } else { // this ._acceleration = this ._accelerationBackwards; this . setLinearDamping ( this ._linearDamping ) ; this . setAngularDamping ( this ._angularDamping ) ; } this . addFriction ( this ._rearAxisBodyLeft. body , 0 ) ; this . addFriction ( this ._rearAxisBodyRight. body , 0 ) ; this . addFriction ( this ._frontAxisBodyLeft. body , 1 ) ; this . addFriction ( this ._frontAxisBodyRight. body , 1 ) ;
private function setLinearDamping ( linDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_linearDamping = linDamp; this ._frontAxisBodyRight. body . m_linearDamping = linDamp; this ._rearAxisBodyLeft. body . m_linearDamping = linDamp; this ._rearAxisBodyRight. body . m_linearDamping = linDamp; this ._carBody. body . m_linearDamping = linDamp; return ; } private function setAngularDamping ( angDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_angularDamping = angDamp; this ._frontAxisBodyRight. body . m_angularDamping = angDamp; this ._rearAxisBodyLeft. body . m_angularDamping = angDamp; this ._rearAxisBodyRight. body . m_angularDamping = angDamp; this ._carBody. body . m_angularDamping = angDamp; return ; }
private function setLinearDamping ( linDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_linearDamping = linDamp; this ._frontAxisBodyRight. body . m_linearDamping = linDamp; this ._rearAxisBodyLeft. body . m_linearDamping = linDamp; this ._rearAxisBodyRight. body . m_linearDamping = linDamp; this ._carBody. body . m_linearDamping = linDamp; return ; } private function setAngularDamping ( angDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_angularDamping = angDamp; this ._frontAxisBodyRight. body . m_angularDamping = angDamp; this ._rearAxisBodyLeft. body . m_angularDamping = angDamp; this ._rearAxisBodyRight. body . m_angularDamping = angDamp; this ._carBody. body . m_angularDamping = angDamp; return ; }
private function setLinearDamping ( linDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_linearDamping = linDamp; this ._frontAxisBodyRight. body . m_linearDamping = linDamp; this ._rearAxisBodyLeft. body . m_linearDamping = linDamp; this ._rearAxisBodyRight. body . m_linearDamping = linDamp; this ._carBody. body . m_linearDamping = linDamp; return ; } private function setAngularDamping ( angDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_angularDamping = angDamp; this ._frontAxisBodyRight. body . m_angularDamping = angDamp; this ._rearAxisBodyLeft. body . m_angularDamping = angDamp; this ._rearAxisBodyRight. body . m_angularDamping = angDamp; this ._carBody. body . m_angularDamping = angDamp; return ; }
private function setLinearDamping ( linDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_linearDamping = linDamp; this ._frontAxisBodyRight. body . m_linearDamping = linDamp; this ._rearAxisBodyLeft. body . m_linearDamping = linDamp; this ._rearAxisBodyRight. body . m_linearDamping = linDamp; this ._carBody. body . m_linearDamping = linDamp; return ; } private function setAngularDamping ( angDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_angularDamping = angDamp; this ._frontAxisBodyRight. body . m_angularDamping = angDamp; this ._rearAxisBodyLeft. body . m_angularDamping = angDamp; this ._rearAxisBodyRight. body . m_angularDamping = angDamp; this ._carBody. body . m_angularDamping = angDamp; return ; }
private function setLinearDamping ( linDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_linearDamping = linDamp; this ._frontAxisBodyRight. body . m_linearDamping = linDamp; this ._rearAxisBodyLeft. body . m_linearDamping = linDamp; this ._rearAxisBodyRight. body . m_linearDamping = linDamp; this ._carBody. body . m_linearDamping = linDamp; return ; } private function setAngularDamping ( angDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_angularDamping = angDamp; this ._frontAxisBodyRight. body . m_angularDamping = angDamp; this ._rearAxisBodyLeft. body . m_angularDamping = angDamp; this ._rearAxisBodyRight. body . m_angularDamping = angDamp; this ._carBody. body . m_angularDamping = angDamp; return ; }
private function setLinearDamping ( linDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_linearDamping = linDamp; this ._frontAxisBodyRight. body . m_linearDamping = linDamp; this ._rearAxisBodyLeft. body . m_linearDamping = linDamp; this ._rearAxisBodyRight. body . m_linearDamping = linDamp; this ._carBody. body . m_linearDamping = linDamp; return ; } private function setAngularDamping ( angDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_angularDamping = angDamp; this ._frontAxisBodyRight. body . m_angularDamping = angDamp; this ._rearAxisBodyLeft. body . m_angularDamping = angDamp; this ._rearAxisBodyRight. body . m_angularDamping = angDamp; this ._carBody. body . m_angularDamping = angDamp; return ; }
private function setLinearDamping ( linDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_linearDamping = linDamp; this ._frontAxisBodyRight. body . m_linearDamping = linDamp; this ._rearAxisBodyLeft. body . m_linearDamping = linDamp; this ._rearAxisBodyRight. body . m_linearDamping = linDamp; this ._carBody. body . m_linearDamping = linDamp; return ; } private function setAngularDamping ( angDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_angularDamping = angDamp; this ._frontAxisBodyRight. body . m_angularDamping = angDamp; this ._rearAxisBodyLeft. body . m_angularDamping = angDamp; this ._rearAxisBodyRight. body . m_angularDamping = angDamp; this ._carBody. body . m_angularDamping = angDamp; return ; }
private function setLinearDamping ( linDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_linearDamping = linDamp; this ._frontAxisBodyRight. body . m_linearDamping = linDamp; this ._rearAxisBodyLeft. body . m_linearDamping = linDamp; this ._rearAxisBodyRight. body . m_linearDamping = linDamp; this ._carBody. body . m_linearDamping = linDamp; return ; } private function setAngularDamping ( angDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_angularDamping = angDamp; this ._frontAxisBodyRight. body . m_angularDamping = angDamp; this ._rearAxisBodyLeft. body . m_angularDamping = angDamp; this ._rearAxisBodyRight. body . m_angularDamping = angDamp; this ._carBody. body . m_angularDamping = angDamp; return ; }
private function setLinearDamping ( linDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_linearDamping = linDamp; this ._frontAxisBodyRight. body . m_linearDamping = linDamp; this ._rearAxisBodyLeft. body . m_linearDamping = linDamp; this ._rearAxisBodyRight. body . m_linearDamping = linDamp; this ._carBody. body . m_linearDamping = linDamp; return ; } private function setAngularDamping ( angDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_angularDamping = angDamp; this ._frontAxisBodyRight. body . m_angularDamping = angDamp; this ._rearAxisBodyLeft. body . m_angularDamping = angDamp; this ._rearAxisBodyRight. body . m_angularDamping = angDamp; this ._carBody. body . m_angularDamping = angDamp; return ; }
private function setLinearDamping ( linDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_linearDamping = linDamp; this ._frontAxisBodyRight. body . m_linearDamping = linDamp; this ._rearAxisBodyLeft. body . m_linearDamping = linDamp; this ._rearAxisBodyRight. body . m_linearDamping = linDamp; this ._carBody. body . m_linearDamping = linDamp; return ; } private function setAngularDamping ( angDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_angularDamping = angDamp; this ._frontAxisBodyRight. body . m_angularDamping = angDamp; this ._rearAxisBodyLeft. body . m_angularDamping = angDamp; this ._rearAxisBodyRight. body . m_angularDamping = angDamp; this ._carBody. body . m_angularDamping = angDamp; return ; }
private function setLinearDamping ( linDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_linearDamping = linDamp; this ._frontAxisBodyRight. body . m_linearDamping = linDamp; this ._rearAxisBodyLeft. body . m_linearDamping = linDamp; this ._rearAxisBodyRight. body . m_linearDamping = linDamp; this ._carBody. body . m_linearDamping = linDamp; return ; } private function setAngularDamping ( angDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_angularDamping = angDamp; this ._frontAxisBodyRight. body . m_angularDamping = angDamp; this ._rearAxisBodyLeft. body . m_angularDamping = angDamp; this ._rearAxisBodyRight. body . m_angularDamping = angDamp; this ._carBody. body . m_angularDamping = angDamp; return ; }
private function setLinearDamping ( linDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_linearDamping = linDamp; this ._frontAxisBodyRight. body . m_linearDamping = linDamp; this ._rearAxisBodyLeft. body . m_linearDamping = linDamp; this ._rearAxisBodyRight. body . m_linearDamping = linDamp; this ._carBody. body . m_linearDamping = linDamp; return ; } private function setAngularDamping ( angDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_angularDamping = angDamp; this ._frontAxisBodyRight. body . m_angularDamping = angDamp; this ._rearAxisBodyLeft. body . m_angularDamping = angDamp; this ._rearAxisBodyRight. body . m_angularDamping = angDamp; this ._carBody. body . m_angularDamping = angDamp; return ; }
private function setLinearDamping ( linDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_linearDamping = linDamp; this ._frontAxisBodyRight. body . m_linearDamping = linDamp; this ._rearAxisBodyLeft. body . m_linearDamping = linDamp; this ._rearAxisBodyRight. body . m_linearDamping = linDamp; this ._carBody. body . m_linearDamping = linDamp; return ; } private function setAngularDamping ( angDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_angularDamping = angDamp; this ._frontAxisBodyRight. body . m_angularDamping = angDamp; this ._rearAxisBodyLeft. body . m_angularDamping = angDamp; this ._rearAxisBodyRight. body . m_angularDamping = angDamp; this ._carBody. body . m_angularDamping = angDamp; return ; }
private function setLinearDamping ( linDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_linearDamping = linDamp; this ._frontAxisBodyRight. body . m_linearDamping = linDamp; this ._rearAxisBodyLeft. body . m_linearDamping = linDamp; this ._rearAxisBodyRight. body . m_linearDamping = linDamp; this ._carBody. body . m_linearDamping = linDamp; return ; } private function setAngularDamping ( angDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_angularDamping = angDamp; this ._frontAxisBodyRight. body . m_angularDamping = angDamp; this ._rearAxisBodyLeft. body . m_angularDamping = angDamp; this ._rearAxisBodyRight. body . m_angularDamping = angDamp; this ._carBody. body . m_angularDamping = angDamp; return ; }
private function setLinearDamping ( linDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_linearDamping = linDamp; this ._frontAxisBodyRight. body . m_linearDamping = linDamp; this ._rearAxisBodyLeft. body . m_linearDamping = linDamp; this ._rearAxisBodyRight. body . m_linearDamping = linDamp; this ._carBody. body . m_linearDamping = linDamp; return ; } private function setAngularDamping ( angDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_angularDamping = angDamp; this ._frontAxisBodyRight. body . m_angularDamping = angDamp; this ._rearAxisBodyLeft. body . m_angularDamping = angDamp; this ._rearAxisBodyRight. body . m_angularDamping = angDamp; this ._carBody. body . m_angularDamping = angDamp; return ; }
private function setLinearDamping ( linDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_linearDamping = linDamp; this ._frontAxisBodyRight. body . m_linearDamping = linDamp; this ._rearAxisBodyLeft. body . m_linearDamping = linDamp; this ._rearAxisBodyRight. body . m_linearDamping = linDamp; this ._carBody. body . m_linearDamping = linDamp; return ; } private function setAngularDamping ( angDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_angularDamping = angDamp; this ._frontAxisBodyRight. body . m_angularDamping = angDamp; this ._rearAxisBodyLeft. body . m_angularDamping = angDamp; this ._rearAxisBodyRight. body . m_angularDamping = angDamp; this ._carBody. body . m_angularDamping = angDamp; return ; }
private function setLinearDamping ( linDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_linearDamping = linDamp; this ._frontAxisBodyRight. body . m_linearDamping = linDamp; this ._rearAxisBodyLeft. body . m_linearDamping = linDamp; this ._rearAxisBodyRight. body . m_linearDamping = linDamp; this ._carBody. body . m_linearDamping = linDamp; return ; } private function setAngularDamping ( angDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_angularDamping = angDamp; this ._frontAxisBodyRight. body . m_angularDamping = angDamp; this ._rearAxisBodyLeft. body . m_angularDamping = angDamp; this ._rearAxisBodyRight. body . m_angularDamping = angDamp; this ._carBody. body . m_angularDamping = angDamp; return ; }
private function setLinearDamping ( linDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_linearDamping = linDamp; this ._frontAxisBodyRight. body . m_linearDamping = linDamp; this ._rearAxisBodyLeft. body . m_linearDamping = linDamp; this ._rearAxisBodyRight. body . m_linearDamping = linDamp; this ._carBody. body . m_linearDamping = linDamp; return ; } private function setAngularDamping ( angDamp: Number ) : void { this ._frontAxisBodyLeft. body . m_angularDamping = angDamp; this ._frontAxisBodyRight. body . m_angularDamping = angDamp; this ._rearAxisBodyLeft. body . m_angularDamping = angDamp; this ._rearAxisBodyRight. body . m_angularDamping = angDamp; this ._carBody. body . m_angularDamping = angDamp; return ; }
- function addFriction ( targetBody: b2Body, isFront: Number )
- {
- var spd, spd2: b2Vec2;
- spd = targetBody. GetLinearVelocity ( ) ;
- spd2 = targetBody. GetLocalVector ( spd ) ;
- if ( this ._privod == FWD ) { // front-wheel drive
- if ( isFront == 1 ) {
- spd2. y = spd2. y * 0.5 ;
- }
- else {
- spd2. y = spd2. y > 2.5 ? spd2. y * 0.45 : 0 ;
- }
- spd = targetBody. GetWorldVector ( spd2 ) ;
- targetBody. SetLinearVelocity ( spd ) ;
- }
- if ( this ._privod == RWD ) {
- if ( isFront == 1 ) {
- spd2. y = 0 ;
- spd2. x = spd2. x * .9;
- spd = targetBody. GetWorldVector ( spd2 ) ;
- targetBody. SetLinearVelocity ( spd ) ;
- }
- else {
- spd2. y = spd2. y > 2.5 ? spd2. y * 0.25 : 0 ;
- spd = targetBody. GetWorldVector ( spd2 ) ;
- targetBody. SetLinearVelocity ( spd ) ;
- }
- }
- }
- var carAngle: Number = this ._carBody. body GetAngle ( ) ;
- if ( this . steer ! = 0 ) { // when driving forward
- this ._steerAngle = this ._steerAngle + this . steer * this ._steeringAcceleration;
- }
- if ( this ._steerAngle > carAngle + this ._steeringRange ) {
- this ._steerAngle = carAngle + this ._steeringRange;
- }
- else if ( this ._steerAngle < carAngle - this ._steeringRange ) {
- this ._steerAngle = carAngle - this ._steeringRange;
- }
- if ( this . drive < 0 ) { // when driving back
- if ( this . steer == 0 ) {
- this ._steerAngle = carAngle;
- }
- else if ( this . steer == - 1 ) {
- this ._steerAngle = carAngle - this ._steeringRange;
- }
- else if ( this . steer == 1 ) {
- this ._steerAngle = carAngle + this ._steeringRange;
- }
- }
- if ( this . steer == 0 ) {
- this ._steerAngle = carAngle;
- }
- this ._frontAxisBodyLeft. body SetXForm ( _frontAxisBodyLeft. Body . GetXForm ( ) . Position , this ._steerAngle ) ;
- this ._frontAxisBodyRight. body SetXForm ( _frontAxisBodyRight. Body . GetXForm ( ) . Position , this ._steerAngle ) ;
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
var carspeedX, carspeedY, carRearX,carRearY: Number ; if ( this ._privod == FWD ) { // carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; } if ( this ._privod == AWD ) { carspeedX = this . drive * Math . cos ( this ._steerAngle ) * ( this ._acceleration ) ; carspeedY = this . drive * Math . sin ( this ._steerAngle ) * ( this ._acceleration ) ; carRearX = this . drive * Math . cos ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; carRearY = this . drive * Math . sin ( this ._rearAxisBodyRight. angle ) * ( this ._acceleration ) ; } if ( this . drive ! = 0 ) { if ( this ._privod == FWD ) { // , ( ) this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) // , ( ) { this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carRearX, carRearY ) ) ; } } else { // spd = this . speed ; if ( spd > this ._friction ) { spd = spd - this ._friction / 1.3 ; } else { spd = 0 ; } if ( this ._privod == FWD ) // , ( ) { carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } if ( this ._privod == AWD ) { // , ( ) carspeedX = Math . cos ( this ._steerAngle ) * spd; carspeedY = Math . sin ( this ._steerAngle ) * spd; this ._frontAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._frontAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; carspeedX = Math . cos ( this ._carBody. angle ) * spd; carspeedY = Math . sin ( this ._carBody. angle ) * spd; this ._rearAxisBodyLeft. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; this ._rearAxisBodyRight. body . SetLinearVelocity ( new b2Vec2 ( carspeedX, carspeedY ) ) ; } }
- public function get speed ( ) : Number {
- return this ._carBody. body GetLinearVelocity ( ) . Length ( ) ;
- }
Source: https://habr.com/ru/post/124704/
All Articles