PackageBox2DAS.Dynamics
Classpublic class b2Body
Inheritanceb2Body Inheritance b2Base Inheritance Object



Public Properties
 PropertyDefined By
 Inheritedbytes : ByteArray
[static]
b2Base
  groupID : int
b2Body
 Inheritedinitialized : Boolean = false
[static]
b2Base
 Inheritedlib : Object
[static]
b2Base
 Inheritedloader : CLibInit
[static]
b2Base
  m_angularDamping : Number
b2Body
  m_angularVelocity : Number
b2Body
  m_controllers : Dictionary
b2Body
 Inheritedmem : MemUser
[static]
b2Base
  m_fixtureCount : int
b2Body
  m_fixtureList : b2Fixture
b2Body
  m_flags : int
b2Body
  m_force : b2Vec2
b2Body
  m_I : Number
b2Body
  m_invI : Number
b2Body
  m_invMass : Number
b2Body
  m_islandIndex : int
b2Body
  m_linearDamping : Number
b2Body
  m_linearVelocity : b2Vec2
b2Body
  m_mass : Number
b2Body
  m_next : b2Body
b2Body
  m_prev : b2Body
b2Body
  m_sleepTime : Number
b2Body
  m_sweep : b2Sweep
b2Body
  m_torque : Number
b2Body
  m_type : int
b2Body
  m_userData : *
b2Body
  m_world : b2World
b2Body
  m_xf : b2Transform
b2Body
 Inherited_ptr : Number
b2Base
 Inheritedvalid : Boolean
[read-only] Does the object point to a C++ equivalent (i.e.
b2Base
Public Methods
 MethodDefined By
  
b2Body(w:b2World, d:b2BodyDef = null)
b2Body
  
ApplyForce(force:V2, point:V2):void
b2Body
  
ApplyImpulse(impulse:V2, point:V2):void
b2Body
  
ApplyTorque(torque:Number):void
b2Body
  
b2Body
  
CreateFixtureShape(shape:b2Shape, density:Number):b2Fixture
b2Body
 Inherited
deref(adr:int):*
[static] dereference a C++ pointer or AS3_Val that is pointing to an AS3 object.
b2Base
  
destroy():void
[override]
b2Body
  
b2Body
  
GetAngle():Number
b2Body
  
b2Body
  
b2Body
 Inherited
getArr():Array
[static]
b2Base
  
b2Body
  
b2Body
  
GetInertia():Number
b2Body
  
b2Body
  
b2Body
  
b2Body
  
b2Body
  
b2Body
  
b2Body
  
GetLocalPoint(worldPoint:V2):V2
b2Body
  
GetLocalVector(worldVector:V2):V2
b2Body
  
GetMass():Number
b2Body
  
b2Body
  
b2Body
  
b2Body
  
b2Body
  
GetType():int
b2Body
  
b2Body
  
b2Body
  
b2Body
  
GetWorldPoint(localPoint:V2):V2
b2Body
  
GetWorldVector(localVector:V2):V2
b2Body
 Inherited
initialize(defs:Boolean = true):void
[static] Initialize the C++ module.
b2Base
  
IsActive():Boolean
b2Body
  
IsAlwaysActive():Boolean
b2Body
  
IsAwake():Boolean
b2Body
  
IsBullet():Boolean
b2Body
  
IsDynamic():Boolean
b2Body
  
IsFixedRotation():Boolean
b2Body
  
b2Body
  
IsKinematic():Boolean
b2Body
  
b2Body
  
IsStatic():Boolean
b2Body
 Inherited
readVertices(adr:int, num:int):Vector.<V2>
Read C++ memory and convert it into a vertex array.
b2Base
  
b2Body
  
SetActive(flag:Boolean):void
b2Body
  
SetAlwaysActive(flag:Boolean):void
b2Body
  
SetAngle(angle:Number):void
b2Body
  
SetAngularDamping(angularDamping:Number):void
b2Body
  
SetAngularVelocity(omega:Number):void
b2Body
  
SetAwake(flag:Boolean):void
b2Body
  
SetBounciness(bounciness:Number):void
b2Body
  
SetBullet(flag:Boolean):void
b2Body
  
SetFixedRotation(flag:Boolean):void
b2Body
  
SetFriction(friction:Number):void
b2Body
  
SetIgnoreGravity(flag:Boolean):void
b2Body
  
SetLinearDamping(linearDamping:Number):void
b2Body
  
b2Body
  
b2Body
  
SetPosition(position:V2):void
b2Body
  
SetSleepingAllowed(flag:Boolean):void
b2Body
  
SetTransform(position:V2, angle:Number):void
b2Body
  
SetType(type:int):void
b2Body
  
SetUserData(data:*):void
b2Body
 Inherited
writeVertices(adr:int, v:Vector.<V2>):void
Write a vertex array of the format [new V2(x,y), new V2(x,y), ...] to C++ memory.
b2Base
Public Constants
 ConstantDefined By
  b2_dynamicBody : int = 2
[static]
b2Body
  b2_kinematicBody : int = 1
[static]
b2Body
  b2_staticBody : int = 0
[static]
b2Body
  e_activeFlag : int = 0x0020
[static]
b2Body
  e_alwaysActiveFlag : int = 0x0100
[static]
b2Body
  e_autoSleepFlag : int = 0x0004
[static]
b2Body
  e_awakeFlag : int = 0x0002
[static]
b2Body
  e_bulletFlag : int = 0x0008
[static]
b2Body
  e_fixedRotationFlag : int = 0x0010
[static]
b2Body
  e_ignoreGravityFlag : int = 0x0080
[static]
b2Body
  e_islandFlag : int = 0x0001
[static]
b2Body
Property Detail
groupIDproperty
groupID:int


Implementation
    public function get groupID():int
    public function set groupID(value:int):void
m_angularDampingproperty 
m_angularDamping:Number


Implementation
    public function get m_angularDamping():Number
    public function set m_angularDamping(value:Number):void
m_angularVelocityproperty 
m_angularVelocity:Number


Implementation
    public function get m_angularVelocity():Number
    public function set m_angularVelocity(value:Number):void
m_controllersproperty 
public var m_controllers:Dictionary

m_fixtureCountproperty 
m_fixtureCount:int


Implementation
    public function get m_fixtureCount():int
    public function set m_fixtureCount(value:int):void
m_fixtureListproperty 
public var m_fixtureList:b2Fixture

m_flagsproperty 
m_flags:int


Implementation
    public function get m_flags():int
    public function set m_flags(value:int):void
m_forceproperty 
public var m_force:b2Vec2

m_Iproperty 
m_I:Number


Implementation
    public function get m_I():Number
    public function set m_I(value:Number):void
m_invIproperty 
m_invI:Number


Implementation
    public function get m_invI():Number
    public function set m_invI(value:Number):void
m_invMassproperty 
m_invMass:Number


Implementation
    public function get m_invMass():Number
    public function set m_invMass(value:Number):void
m_islandIndexproperty 
m_islandIndex:int


Implementation
    public function get m_islandIndex():int
    public function set m_islandIndex(value:int):void
m_linearDampingproperty 
m_linearDamping:Number


Implementation
    public function get m_linearDamping():Number
    public function set m_linearDamping(value:Number):void
m_linearVelocityproperty 
public var m_linearVelocity:b2Vec2

m_massproperty 
m_mass:Number


Implementation
    public function get m_mass():Number
    public function set m_mass(value:Number):void
m_nextproperty 
public var m_next:b2Body

m_prevproperty 
public var m_prev:b2Body

m_sleepTimeproperty 
m_sleepTime:Number


Implementation
    public function get m_sleepTime():Number
    public function set m_sleepTime(value:Number):void
m_sweepproperty 
public var m_sweep:b2Sweep

m_torqueproperty 
m_torque:Number


Implementation
    public function get m_torque():Number
    public function set m_torque(value:Number):void
m_typeproperty 
m_type:int


Implementation
    public function get m_type():int
    public function set m_type(value:int):void
m_userDataproperty 
public var m_userData:*

m_worldproperty 
public var m_world:b2World

m_xfproperty 
public var m_xf:b2Transform

Constructor Detail
b2Body()Constructor
public function b2Body(w:b2World, d:b2BodyDef = null)



Parameters
w:b2World
 
d:b2BodyDef (default = null)
Method Detail
ApplyForce()method
public function ApplyForce(force:V2, point:V2):void

Parameters

force:V2
 
point:V2

ApplyImpulse()method 
public function ApplyImpulse(impulse:V2, point:V2):void

Parameters

impulse:V2
 
point:V2

ApplyTorque()method 
public function ApplyTorque(torque:Number):void

Parameters

torque:Number

CreateFixture()method 
public function CreateFixture(def:b2FixtureDef):b2Fixture

Parameters

def:b2FixtureDef

Returns
b2Fixture
CreateFixtureShape()method 
public function CreateFixtureShape(shape:b2Shape, density:Number):b2Fixture

Parameters

shape:b2Shape
 
density:Number

Returns
b2Fixture
destroy()method 
override public function destroy():void

DestroyFixture()method 
public function DestroyFixture(fixture:b2Fixture):void

Parameters

fixture:b2Fixture

GetAngle()method 
public function GetAngle():Number

Returns
Number
GetAngularDamping()method 
public function GetAngularDamping():Number

Returns
Number
GetAngularVelocity()method 
public function GetAngularVelocity():Number

Returns
Number
GetContactList()method 
public function GetContactList():b2ContactEdge

Returns
b2ContactEdge
GetFixtureList()method 
public function GetFixtureList():b2Fixture

Returns
b2Fixture
GetInertia()method 
public function GetInertia():Number

Returns
Number
GetJointList()method 
public function GetJointList():b2JointEdge

Returns
b2JointEdge
GetLinearDamping()method 
public function GetLinearDamping():Number

Returns
Number
GetLinearVelocity()method 
public function GetLinearVelocity():V2

Returns
V2
GetLinearVelocityFromLocalPoint()method 
public function GetLinearVelocityFromLocalPoint(localPoint:V2):V2

Parameters

localPoint:V2

Returns
V2
GetLinearVelocityFromWorldPoint()method 
public function GetLinearVelocityFromWorldPoint(worldPoint:V2):V2

Parameters

worldPoint:V2

Returns
V2
GetLocalCenter()method 
public function GetLocalCenter():V2

Returns
V2
GetLocalPoint()method 
public function GetLocalPoint(worldPoint:V2):V2

Parameters

worldPoint:V2

Returns
V2
GetLocalVector()method 
public function GetLocalVector(worldVector:V2):V2

Parameters

worldVector:V2

Returns
V2
GetMass()method 
public function GetMass():Number

Returns
Number
GetMassData()method 
public function GetMassData(data:b2MassData):void

Parameters

data:b2MassData

GetNext()method 
public function GetNext():b2Body

Returns
b2Body
GetPosition()method 
public function GetPosition():V2

Returns
V2
GetTransform()method 
public function GetTransform():XF

Returns
XF
GetType()method 
public function GetType():int

Returns
int
GetUserData()method 
public function GetUserData():*

Returns
*
GetWorld()method 
public function GetWorld():b2World

Returns
b2World
GetWorldCenter()method 
public function GetWorldCenter():V2

Returns
V2
GetWorldPoint()method 
public function GetWorldPoint(localPoint:V2):V2

Parameters

localPoint:V2

Returns
V2
GetWorldVector()method 
public function GetWorldVector(localVector:V2):V2

Parameters

localVector:V2

Returns
V2
IsActive()method 
public function IsActive():Boolean

Returns
Boolean
IsAlwaysActive()method 
public function IsAlwaysActive():Boolean

Returns
Boolean
IsAwake()method 
public function IsAwake():Boolean

Returns
Boolean
IsBullet()method 
public function IsBullet():Boolean

Returns
Boolean
IsDynamic()method 
public function IsDynamic():Boolean

Returns
Boolean
IsFixedRotation()method 
public function IsFixedRotation():Boolean

Returns
Boolean
IsIgnoringGravity()method 
public function IsIgnoringGravity():Boolean

Returns
Boolean
IsKinematic()method 
public function IsKinematic():Boolean

Returns
Boolean
IsSleepingAllowed()method 
public function IsSleepingAllowed():Boolean

Returns
Boolean
IsStatic()method 
public function IsStatic():Boolean

Returns
Boolean
ResetMassData()method 
public function ResetMassData():void

SetActive()method 
public function SetActive(flag:Boolean):void

Parameters

flag:Boolean

SetAlwaysActive()method 
public function SetAlwaysActive(flag:Boolean):void

Parameters

flag:Boolean

SetAngle()method 
public function SetAngle(angle:Number):void

Parameters

angle:Number

SetAngularDamping()method 
public function SetAngularDamping(angularDamping:Number):void

Parameters

angularDamping:Number

SetAngularVelocity()method 
public function SetAngularVelocity(omega:Number):void

Parameters

omega:Number

SetAwake()method 
public function SetAwake(flag:Boolean):void

Parameters

flag:Boolean

SetBounciness()method 
public function SetBounciness(bounciness:Number):void

Parameters

bounciness:Number

SetBullet()method 
public function SetBullet(flag:Boolean):void

Parameters

flag:Boolean

SetFixedRotation()method 
public function SetFixedRotation(flag:Boolean):void

Parameters

flag:Boolean

SetFriction()method 
public function SetFriction(friction:Number):void

Parameters

friction:Number

SetIgnoreGravity()method 
public function SetIgnoreGravity(flag:Boolean):void

Parameters

flag:Boolean

SetLinearDamping()method 
public function SetLinearDamping(linearDamping:Number):void

Parameters

linearDamping:Number

SetLinearVelocity()method 
public function SetLinearVelocity(v:V2):void

Parameters

v:V2

SetMassData()method 
public function SetMassData(data:b2MassData):void

Parameters

data:b2MassData

SetPosition()method 
public function SetPosition(position:V2):void

Parameters

position:V2

SetSleepingAllowed()method 
public function SetSleepingAllowed(flag:Boolean):void

Parameters

flag:Boolean

SetTransform()method 
public function SetTransform(position:V2, angle:Number):void

Parameters

position:V2
 
angle:Number

SetType()method 
public function SetType(type:int):void

Parameters

type:int

SetUserData()method 
public function SetUserData(data:*):void

Parameters

data:*

Constant Detail
b2_dynamicBodyConstant
public static const b2_dynamicBody:int = 2

b2_kinematicBodyConstant 
public static const b2_kinematicBody:int = 1

b2_staticBodyConstant 
public static const b2_staticBody:int = 0

e_activeFlagConstant 
public static const e_activeFlag:int = 0x0020

e_alwaysActiveFlagConstant 
public static const e_alwaysActiveFlag:int = 0x0100

e_autoSleepFlagConstant 
public static const e_autoSleepFlag:int = 0x0004

e_awakeFlagConstant 
public static const e_awakeFlag:int = 0x0002

e_bulletFlagConstant 
public static const e_bulletFlag:int = 0x0008

e_fixedRotationFlagConstant 
public static const e_fixedRotationFlag:int = 0x0010

e_ignoreGravityFlagConstant 
public static const e_ignoreGravityFlag:int = 0x0080

e_islandFlagConstant 
public static const e_islandFlag:int = 0x0001