API Documentation for:
Show:

File:addBox2D\Dynamics\Joints\b2JointDef.js

//################################################################################################//
//################################################################################################//
//                                                                                                //
//                         ██       ██        ██   █████         ████                             //
//                         ██                 ██   ██  ██        ██                               //
//                         ██ █████ ██ █████ █████ ██  ██ █████  ██                               //
//                         ██ ██ ██ ██ ██ ██  ██   ██  ██ ██ ██ █████                             //
//                         ██ ██ ██ ██ ██ ██  ██   ██  ██ █████  ██                               //
//                         ██ ██ ██ ██ ██ ██  ██   ██  ██ ██     ██                               //
//                      █████ █████ ██ ██ ██  ████ █████  █████  ██                               //
//                                                                                                //
//################################################################################################//
//################################################################################################//

 // CLASS CONSTRUCTOR

    /**
     * Joint definitions are used to construct joints.
     *
     * @class b2JointDef
     * @constructor
     * @param   {int=} [type=b2Joint.e_unknownJoint]
     * @module  Joints
     */
    function b2JointDef( type ) {

////////////////////////////////////////////////////////////////////////////////////////////////////
//                                                                                                //
//                  ██████                              ██   ██                                   //
//                  ██  ██                              ██                                        //
//                  ██  ██ ████ █████ █████ █████ ████ █████ ██ █████ █████                       //
//                  ██████ ██   ██ ██ ██ ██ ██ ██ ██    ██   ██ ██ ██ ██                          //
//                  ██     ██   ██ ██ ██ ██ █████ ██    ██   ██ █████ █████                       //
//                  ██     ██   ██ ██ ██ ██ ██    ██    ██   ██ ██       ██                       //
//                  ██     ██   █████ █████ █████ ██    ████ ██ █████ █████                       //
//                                    ██                                                          //
//                                    ██                                                          //
//                                                                                                //
////////////////////////////////////////////////////////////////////////////////////////////////////

     // property INITIALISATIONS

        /**
         * The joint type is set automatically for native joint types.
         *
         * @public
         * @property  type
         * @type      {int}
         */
        this.type = type || b2Joint.e_unknownJoint;

        /**
         * Application specific data.</br></br>
         *
         * NOTE: Using the
         *       <a href=https://github.com/SmartArtsStudio/addPhysicsJS>addPhysicsJS framework</a>
         *       m_userData is managed for you extending either a
         *       <a href=http://www.createjs.com/docs/easeljs/classes/Container.html>createjs.container</a>
         *       or
         *       <a href=http://www.createjs.com/docs/easeljs/classes/MovieClip.html>createjs.movieClip</a>
         *       class.
         *
         * @public
         * @property  userData
         * @type      {*|null}
         * @default   null
         */
        this.userData = null;

        /**
         * The first attached body.
         *
         * @public
         * @property   bodyA
         * @type       {b2Body|null}
         * @default    null
         */
        this.bodyA = null;

        /**
         * The second attached body.
         *
         * @public
         * @property  bodyB
         * @type      {b2Body|null}
         * @default   null
         */
        this.bodyB = null;

        /**
         * Set this flag to true if the attached bodies should collide.
         *
         * @public
         * @property  collideConnected
         * @type      {boolean}
         * @default   false
         */
        this.collideConnected = false;


    } Box2D.b2JointDef = b2JointDef;