away3d / awayphysics-core-fp11

Away Physics - 3D physics library for the Away3D Engine in Flash Player 11
http://www.awayphysics.com
112 stars 47 forks source link

Hi Li :) #26

Open LucaEstiva opened 11 years ago

LucaEstiva commented 11 years ago

The constraint ( hinge ) can be succesfully moved ( initially the constrained object moves a bit away from the constraint but... ) . So the constraint can now be placed at the right pinball palette position ! ( I have spent some times for work with the program interface, materials, material methods, Lua scripts, lights, camera, ecc but the phisycs remain a priority in Game Maker ! ) so, for now, thanks Li ! Some Games Maker images here: https://www.facebook.com/pages/Estiva-Community/248102938603578?ref=hl awaygamesmakerhingetest

muzerly commented 11 years ago

looks good, keek up the work.

LucaEstiva commented 11 years ago

Hey Li, sry, but i can’t change the constraint axis …. Can u make something ( please )? Thanks … J

         public function get pivotInA():Vector3D{

                return m_rbAFrame.position;

         }

         public function set pivotInA(v:Vector3D):void{

                m_rbAFrame.position = v;

         }

         public function get pivotInB():Vector3D{

                return m_rbBFrame.position;

         }

         public function set pivotInB(v:Vector3D):void{

                m_rbBFrame.position = v;

         }

         public function get axisInA():Vector3D{

                return m_rbAFrame.basis.column3;

         }

         public function get axisInB():Vector3D{

                return m_rbBFrame.basis.column3;

         }

This is because graphically …

Da: Yang Li [mailto:notifications@github.com] Inviato: mercoledì 6 novembre 2013 12:31 A: away3d/awayphysics-core-fp11 Cc: Luca Filippini Oggetto: Re: [awayphysics-core-fp11] Hi Li :) (#26)

looks good, keek up the work.

— Reply to this email directly or view it on GitHub https://github.com/away3d/awayphysics-core-fp11/issues/26#issuecomment-27865202 . https://github.com/notifications/beacon/VjXDoZXMK-OPt0FoHQI7ZXNHjSRXPZx9p062G6RNMfN9ynAZjUJ6BK9CJ7KY8SrZ.gif

muzerly commented 11 years ago

sorry, I'm not understand, how you set constraint axis? It's should be ok set pivotInA.

在 2013年11月6日,下午8:19,Luca Filippini notifications@github.com 写道:

Hey Li, sry, but i can’t change the constraint axis …. Can u make something ( please )? Thanks … J

public function get pivotInA():Vector3D{

return m_rbAFrame.position;

}

public function set pivotInA(v:Vector3D):void{

m_rbAFrame.position = v;

}

public function get pivotInB():Vector3D{

return m_rbBFrame.position;

}

public function set pivotInB(v:Vector3D):void{

m_rbBFrame.position = v;

}

public function get axisInA():Vector3D{

return m_rbAFrame.basis.column3;

}

public function get axisInB():Vector3D{

return m_rbBFrame.basis.column3;

}

This is because graphically …

Da: Yang Li [mailto:notifications@github.com] Inviato: mercoledì 6 novembre 2013 12:31 A: away3d/awayphysics-core-fp11 Cc: Luca Filippini Oggetto: Re: [awayphysics-core-fp11] Hi Li :) (#26)

looks good, keek up the work.

— Reply to this email directly or view it on GitHub https://github.com/away3d/awayphysics-core-fp11/issues/26#issuecomment-27865202 . https://github.com/notifications/beacon/VjXDoZXMK-OPt0FoHQI7ZXNHjSRXPZx9p062G6RNMfN9ynAZjUJ6BK9CJ7KY8SrZ.gif — Reply to this email directly or view it on GitHub.

LucaEstiva commented 11 years ago

I think i need a panel or a window to edit physics material properties like restitution for example ( simulate a soft ball ) the mass which is set to 0 make the object static and not dynamic.

A panel or a window to manage the physics world properties.

A panel or a window to manage the physics vehicle properties ( wheel, collision shape, and so on ).

A panel or a window to manage soft bodies properties. J

The hinge constraint need one or more axis as parameter to limit the constrained object rotations only to that axis, right ?

This is the LUA script for the pinball palette:

GStage = nil

FlipperLeft = nil

-- Add stage and objects references

function setupObjects( _GameStage, _Objects )

   GStage = _GameStage

  FlipperLeft = _Objects

   LuaFlashPrint( "Message from Object1Script" )

   LuaFlashPrint( FlipperLeft.name )

   -- assert (v [, message])

   assert( LeftPaletteUpdate )

   objects[fIndex] = {p = LeftPaletteUpdate}

   fIndex = fIndex + 1

   v = tostring(fIndex)

   LuaFlashPrint( v )

   -- Add keyboard event listener

   flash.call( GameStage, "addEventListener", "keyDown", KeyDownEvent )

   -- Limit constraint rotations - Min, Max

   -- HingeConstraint.setLimit( -Math.PI / 4, Math.PI / 4 );

   -- Add spring force

   -- HingeConstraint.setAngularMotor( true, 0, 100 );

   TVector = flash.new("flash.geom.Vector3D")

   FlipperLeft.extra.physicsProperties.mass = 1

-- RightPalette.extra.physicsProperties.linearFactor.x = 1;

-- RightPalette.extra.physicsProperties.linearFactor.y = 0;

-- RightPalette.extra.physicsProperties.linearFactor.z = 1;

   FlipperLeft.extra.physicsProperties.angularFactor.x = 0;

   FlipperLeft.extra.physicsProperties.angularFactor.y = 1;

   FlipperLeft.extra.physicsProperties.angularFactor.z = 0;

   constraint = FlipperLeft.extra:GetConstraint( 0 );

// CONSTRAINED OBJECT AXIS OF ROTATIONS

   constraint.axisInA.x = 0;

   constraint.axisInA.y = 1;

   constraint.axisInA.z = 0;

   -- constraint.physicsConstraint:angularFactor( TVector )

   -- constraint.physicsConstraint.angularOnly = true

   -- AWPHingeConstraint.setLimit(low:Number, high:Number, _softness:Number=0.9, _biasFactor:Number=0.3, _relaxationFactor:Number=1.0):void

-- _softness used by obsolete version of solver and left for compatibility;

-- _biasFactor applied as a factor to constraint error

-- _relaxationFactor controls bounce (0.0 == no bounce)

   -- ( -Math.PI / 4, Math.PI / 4 );

   -- Radians to dgrees

   -- 180.0 / Math.PI;

   -- Degrees to radians

   maxrot = ( math.pi / 180 ) * 20;

   minrot = ( math.pi / 180 ) * 60;

   constraint.physicsConstraint:setLimit( -maxrot, minrot, 0.9, 0.8, 0.5 );

-- -- constraint.physicsConstraint:setLimit( -math.pi / 6, math.pi / 6 )

-- -- AWPHingeConstraint.setAngularMotor(_enableMotor:Boolean, _targetVelocity:Number, _maxMotorImpulse:Number):void

// THE SIMULATED SPRING FORCE ( THE PALETTE RETURN A THE ORIGINAL POSITION

   constraint.physicsConstraint:setAngularMotor( true, -50, 1 );

end

function LeftPaletteUpdate()

   -- Get NUMBER - Object, property

   --opx = flash.getnumber( RightPalette, "rotationY" )

   --opx = opx + 1

   --RightPalette.rotationY = opx

end

-- AWPRigidBody.applyCentralForce(force:Vector3D):void

-- add force to the rigidbody's mass center

-- AWPRigidBody.applyCentralImpulse(impulse:Vector3D):void

-- add impulse to the rigidbody's mass center

-- AWPRigidBody.applyForce(force:Vector3D, rel_pos:Vector3D):void

-- add force to the rigidbody, rel_pos is the position in body's local coordinates

-- AWPRigidBody.applyImpulse(impulse:Vector3D, rel_pos:Vector3D):void

-- add a impulse to the rigidbody, rel_pos is the position in body's local coordinates

-- AWPRigidBody.applyTorque(torque:Vector3D):void

-- add torque to the rigidbody

-- AWPRigidBody.applyTorqueImpulse(torque:Vector3D):void

-- add a torque impulse to the rigidbody

function KeyDownEvent( event )

   if( IsKeyboardEventHandlerAnabled == 1 ) then

   -- If the object are Physics use:

         -- applyCentralForce

         -- applyCentralImpulse;

         -- applyForce;

         -- applyImpulse

         -- applyTorque;

         -- applyTorqueImpulse

         Force = flash.new("flash.geom.Vector3D")

         Impulse = flash.new("flash.geom.Vector3D")

         Position = flash.new("flash.geom.Vector3D")

         k = flash.getnumber( event, "keyCode" )

         if( k == 37 ) then         --RIGHT

                Force.x = 0

                Force.y = 60

                Force.z = 0

                Impulse.x = 0

                Impulse.y = 10

                Impulse.z = 0

                Position.x = 0

                Position.y = 0

                Position.z = 0

         end

         -- FlipperLeft.extra.physicsProperties:applyCentralForce( Force )

         -- FlipperLeft.extra.physicsProperties:applyCentralImpulse( Force )

         -- FlipperLeft.extra.physicsProperties:applyForce( Force, Position )

         -- FlipperLeft.extra.physicsProperties:applyImpulse( Force, Position )

-- FlipperLeft.extra.physicsProperties.angularVelocity.x = 0

-- FlipperLeft.extra.physicsProperties.angularVelocity.y = 1

-- FlipperLeft.extra.physicsProperties.angularVelocity.z = 0

         -- FlipperLeft.extra.physicsProperties:applyTorque( Force )

         FlipperLeft.extra.physicsProperties:applyTorqueImpulse( Impulse )

   end

end

Da: Yang Li [mailto:notifications@github.com] Inviato: mercoledì 6 novembre 2013 13:56 A: away3d/awayphysics-core-fp11 Cc: Luca Filippini Oggetto: Re: [awayphysics-core-fp11] Hi Li :) (#26)

sorry, I'm not understand, how you set constraint axis? It's should be ok set pivotInA.

在 2013年11月6日,下午8:19,Luca Filippini < mailto:notifications@github.com notifications@github.com> 写道:

Hey Li, sry, but i can’t change the constraint axis …. Can u make something ( please )? Thanks … J

public function get pivotInA():Vector3D{

return m_rbAFrame.position;

}

public function set pivotInA(v:Vector3D):void{

m_rbAFrame.position = v;

}

public function get pivotInB():Vector3D{

return m_rbBFrame.position;

}

public function set pivotInB(v:Vector3D):void{

m_rbBFrame.position = v;

}

public function get axisInA():Vector3D{

return m_rbAFrame.basis.column3;

}

public function get axisInB():Vector3D{

return m_rbBFrame.basis.column3;

}

This is because graphically …

Da: Yang Li [ mailto:notifications@github.com mailto:notifications@github.com] Inviato: mercoledì 6 novembre 2013 12:31 A: away3d/awayphysics-core-fp11 Cc: Luca Filippini Oggetto: Re: [awayphysics-core-fp11] Hi Li :) (#26)

looks good, keek up the work.

— Reply to this email directly or view it on GitHub < https://github.com/away3d/awayphysics-core-fp11/issues/26#issuecomment-27865202 https://github.com/away3d/awayphysics-core-fp11/issues/26#issuecomment-27865202> . < https://github.com/notifications/beacon/VjXDoZXMK-OPt0FoHQI7ZXNHjSRXPZx9p062G6RNMfN9ynAZjUJ6BK9CJ7KY8SrZ.gif https://github.com/notifications/beacon/VjXDoZXMK-OPt0FoHQI7ZXNHjSRXPZx9p062G6RNMfN9ynAZjUJ6BK9CJ7KY8SrZ.gif> — Reply to this email directly or view it on GitHub.

— Reply to this email directly or view it on GitHub https://github.com/away3d/awayphysics-core-fp11/issues/26#issuecomment-27870945 . https://github.com/notifications/beacon/VjXDoZXMK-OPt0FoHQI7ZXNHjSRXPZx9p062G6RNMfN9ynAZjUJ6BK9CJ7KY8SrZ.gif

muzerly commented 11 years ago

Do you mean need set axisInA and axisInB property? I will take a look.

在 2013年11月6日,下午10:16,Luca Filippini notifications@github.com 写道:

I think i need a panel or a window to edit physics material properties like restitution for example ( simulate a soft ball ) the mass which is set to 0 make the object static and not dynamic.

A panel or a window to manage the physics world properties.

A panel or a window to manage the physics vehicle properties ( wheel, collision shape, and so on ).

A panel or a window to manage soft bodies properties. J

The hinge constraint need one or more axis as parameter to limit the constrained object rotations only to that axis, right ?

This is the LUA script for the pinball palette:

GStage = nil

FlipperLeft = nil

-- Add stage and objects references

function setupObjects( _GameStage, _Objects )

GStage = _GameStage

FlipperLeft = _Objects

LuaFlashPrint( "Message from Object1Script" )

LuaFlashPrint( FlipperLeft.name )

-- assert (v [, message])

assert( LeftPaletteUpdate )

objects[fIndex] = {p = LeftPaletteUpdate}

fIndex = fIndex + 1

v = tostring(fIndex)

LuaFlashPrint( v )

-- Add keyboard event listener

flash.call( GameStage, "addEventListener", "keyDown", KeyDownEvent )

-- Limit constraint rotations - Min, Max

-- HingeConstraint.setLimit( -Math.PI / 4, Math.PI / 4 );

-- Add spring force

-- HingeConstraint.setAngularMotor( true, 0, 100 );

TVector = flash.new("flash.geom.Vector3D")

FlipperLeft.extra.physicsProperties.mass = 1

-- RightPalette.extra.physicsProperties.linearFactor.x = 1;

-- RightPalette.extra.physicsProperties.linearFactor.y = 0;

-- RightPalette.extra.physicsProperties.linearFactor.z = 1;

FlipperLeft.extra.physicsProperties.angularFactor.x = 0;

FlipperLeft.extra.physicsProperties.angularFactor.y = 1;

FlipperLeft.extra.physicsProperties.angularFactor.z = 0;

constraint = FlipperLeft.extra:GetConstraint( 0 );

// CONSTRAINED OBJECT AXIS OF ROTATIONS

constraint.axisInA.x = 0;

constraint.axisInA.y = 1;

constraint.axisInA.z = 0;

-- constraint.physicsConstraint:angularFactor( TVector )

-- constraint.physicsConstraint.angularOnly = true

-- AWPHingeConstraint.setLimit(low:Number, high:Number, _softness:Number=0.9, _biasFactor:Number=0.3, _relaxationFactor:Number=1.0):void

-- _softness used by obsolete version of solver and left for compatibility;

-- _biasFactor applied as a factor to constraint error

-- _relaxationFactor controls bounce (0.0 == no bounce)

-- ( -Math.PI / 4, Math.PI / 4 );

-- Radians to dgrees

-- 180.0 / Math.PI;

-- Degrees to radians

maxrot = ( math.pi / 180 ) * 20;

minrot = ( math.pi / 180 ) * 60;

constraint.physicsConstraint:setLimit( -maxrot, minrot, 0.9, 0.8, 0.5 );

-- -- constraint.physicsConstraint:setLimit( -math.pi / 6, math.pi / 6 )

-- -- AWPHingeConstraint.setAngularMotor(_enableMotor:Boolean, _targetVelocity:Number, _maxMotorImpulse:Number):void

// THE SIMULATED SPRING FORCE ( THE PALETTE RETURN A THE ORIGINAL POSITION

constraint.physicsConstraint:setAngularMotor( true, -50, 1 );

end

function LeftPaletteUpdate()

-- Get NUMBER - Object, property

--opx = flash.getnumber( RightPalette, "rotationY" )

--opx = opx + 1

--RightPalette.rotationY = opx

end

-- AWPRigidBody.applyCentralForce(force:Vector3D):void

-- add force to the rigidbody's mass center

-- AWPRigidBody.applyCentralImpulse(impulse:Vector3D):void

-- add impulse to the rigidbody's mass center

-- AWPRigidBody.applyForce(force:Vector3D, rel_pos:Vector3D):void

-- add force to the rigidbody, rel_pos is the position in body's local coordinates

-- AWPRigidBody.applyImpulse(impulse:Vector3D, rel_pos:Vector3D):void

-- add a impulse to the rigidbody, rel_pos is the position in body's local coordinates

-- AWPRigidBody.applyTorque(torque:Vector3D):void

-- add torque to the rigidbody

-- AWPRigidBody.applyTorqueImpulse(torque:Vector3D):void

-- add a torque impulse to the rigidbody

function KeyDownEvent( event )

if( IsKeyboardEventHandlerAnabled == 1 ) then

-- If the object are Physics use:

-- applyCentralForce

-- applyCentralImpulse;

-- applyForce;

-- applyImpulse

-- applyTorque;

-- applyTorqueImpulse

Force = flash.new("flash.geom.Vector3D")

Impulse = flash.new("flash.geom.Vector3D")

Position = flash.new("flash.geom.Vector3D")

k = flash.getnumber( event, "keyCode" )

if( k == 37 ) then --RIGHT

Force.x = 0

Force.y = 60

Force.z = 0

Impulse.x = 0

Impulse.y = 10

Impulse.z = 0

Position.x = 0

Position.y = 0

Position.z = 0

end

-- FlipperLeft.extra.physicsProperties:applyCentralForce( Force )

-- FlipperLeft.extra.physicsProperties:applyCentralImpulse( Force )

-- FlipperLeft.extra.physicsProperties:applyForce( Force, Position )

-- FlipperLeft.extra.physicsProperties:applyImpulse( Force, Position )

-- FlipperLeft.extra.physicsProperties.angularVelocity.x = 0

-- FlipperLeft.extra.physicsProperties.angularVelocity.y = 1

-- FlipperLeft.extra.physicsProperties.angularVelocity.z = 0

-- FlipperLeft.extra.physicsProperties:applyTorque( Force )

FlipperLeft.extra.physicsProperties:applyTorqueImpulse( Impulse )

end

end

Da: Yang Li [mailto:notifications@github.com] Inviato: mercoledì 6 novembre 2013 13:56 A: away3d/awayphysics-core-fp11 Cc: Luca Filippini Oggetto: Re: [awayphysics-core-fp11] Hi Li :) (#26)

sorry, I'm not understand, how you set constraint axis? It's should be ok set pivotInA.

在 2013年11月6日,下午8:19,Luca Filippini < mailto:notifications@github.com notifications@github.com> 写道:

Hey Li, sry, but i can’t change the constraint axis …. Can u make something ( please )? Thanks … J

public function get pivotInA():Vector3D{

return m_rbAFrame.position;

}

public function set pivotInA(v:Vector3D):void{

m_rbAFrame.position = v;

}

public function get pivotInB():Vector3D{

return m_rbBFrame.position;

}

public function set pivotInB(v:Vector3D):void{

m_rbBFrame.position = v;

}

public function get axisInA():Vector3D{

return m_rbAFrame.basis.column3;

}

public function get axisInB():Vector3D{

return m_rbBFrame.basis.column3;

}

This is because graphically …

Da: Yang Li [ mailto:notifications@github.com mailto:notifications@github.com] Inviato: mercoledì 6 novembre 2013 12:31 A: away3d/awayphysics-core-fp11 Cc: Luca Filippini Oggetto: Re: [awayphysics-core-fp11] Hi Li :) (#26)

looks good, keek up the work.

— Reply to this email directly or view it on GitHub < https://github.com/away3d/awayphysics-core-fp11/issues/26#issuecomment-27865202 https://github.com/away3d/awayphysics-core-fp11/issues/26#issuecomment-27865202> . < https://github.com/notifications/beacon/VjXDoZXMK-OPt0FoHQI7ZXNHjSRXPZx9p062G6RNMfN9ynAZjUJ6BK9CJ7KY8SrZ.gif https://github.com/notifications/beacon/VjXDoZXMK-OPt0FoHQI7ZXNHjSRXPZx9p062G6RNMfN9ynAZjUJ6BK9CJ7KY8SrZ.gif> — Reply to this email directly or view it on GitHub.

— Reply to this email directly or view it on GitHub https://github.com/away3d/awayphysics-core-fp11/issues/26#issuecomment-27870945 . https://github.com/notifications/beacon/VjXDoZXMK-OPt0FoHQI7ZXNHjSRXPZx9p062G6RNMfN9ynAZjUJ6BK9CJ7KY8SrZ.gif — Reply to this email directly or view it on GitHub.

LucaEstiva commented 11 years ago

Thanks Li ! Hey i can also add physics to point lights :) I'm excited !!! physicslight

muzerly commented 11 years ago

Hi, I have added setAxis function in hinge joint, update it in dev branch

LucaEstiva commented 11 years ago

Hi Li, really thanks !

What I need to do, is a software that is like MAX or MAYA or BLENDER or Unity. And for now Game Maker promising … ;)

So after i have composed all my scenes ( video, HUD or menu, 3DScene ( means all, animation, physics, particles systems, effects ( light, post process, ecc ), ecc ecc ) I need I way to thake all this

and make it playable. ( switch scenes can be caused by Time, Events, User action, ecc )

Games Maker use a pieces of software ( engine ) that can be used as “interpreter” so I think I need a “player” like Unity….

For example I can add a camera to one scene object and switch the camera if Games Maker enter “play”, or i must see, “simulation” mode… ( These are different… )

Now I need to manage all the “object” that Away 3D expose, this means Games Maker must be able to Add, Clone, Array, Delete, Modify all the properties, Moves, Align, Edit mesh by using “modifiers” simply access the vertex data… ecc ecc ecc

Add modeling, mesh animations ( bones graphically this is not to hard J I think a container “local transform” and Meshes or Line segments ;) ), texture painting features

I need to see if access and/or manage mesh faces can be made… For example by using segments to highlights these faces…

Add vertex to these mesh and so on..

And others type of modifiers like cut plane, melt, explode, shell ecc. Away already have some of this kind of “modifiers”…

This means that the object management must go in deep…

Obviously I can import objects from max for example… and for now this is the only way ( for now ) to have animated mesh, for example…

Manage all this is not simple, and I need to start with the basic and go in deep…

And because I have more than one method to implement at all, Games Maker are stable and instable ….

As you certainly know MAX use reactor first, MassFX now (NVidia PhysX) or Bullets in Blender J. Now, I need to manage all Physics properties by using the graphic interface so in this way I can make Games, Simulation, Simple scenes ecc ecc simply by using Games Maker, Away3D, and Away Physics...

I’m working on !!! J Thanks !

Da: Yang Li [mailto:notifications@github.com] Inviato: giovedì 7 novembre 2013 03:28 A: away3d/awayphysics-core-fp11 Cc: Luca Filippini Oggetto: Re: [awayphysics-core-fp11] Hi Li :) (#26)

Hi, I have added setAxis function in hinge joint, update it in dev branch

— Reply to this email directly or view it on GitHub https://github.com/away3d/awayphysics-core-fp11/issues/26#issuecomment-27933421 . https://github.com/notifications/beacon/VjXDoZXMK-OPt0FoHQI7ZXNHjSRXPZx9p062G6RNMfN9ynAZjUJ6BK9CJ7KY8SrZ.gif

LucaEstiva commented 11 years ago

The video i have promised you: :)

http://www.youtube.com/watch?v=X-NWJNfEDns

LucaEstiva commented 11 years ago

Now I'm in trouble... I know that i C(C++ a pointer is a memory address. The pointer math is clear, If i have a pointer to a byte ( char for example ) the next momery address ( suppose the first address is 1, and suppose the mem align is byte... not padded ) the Pointer++ incremet the pointer ( the pointed memory address ) , so the new memory address is 2 :) To thake the value store at this address i can use th & operator... I can use pointer to "reference" a struct, a class ( a struct basicly ) or a functions and i can access it's members by using the -> operator, Not the . operator this is another case...

http://www.geeksforgeeks.org/structure-member-alignment-padding-and-data-packing/

Now, Getters and Setters are available in Visual basic for example. This is because, the Hinge constraint can be used to link two objects ;)

hingeconstraint1 hingeconstraint2 hingeconstraint3

The hinge constraint need to know the constraint parameters for two reference point...

public function setAxis(axis:Vector3D):void { setHingeConstraintAxisInC(pointer, axis.x, axis.y, axis.z); }

What is the reference point here A or B :) ? Can i specify the axis for the reference point A or B ?

I can add setters ( AWPHingeConstraint ): public function set axisInA( axisInA:Vector3D ):void { // m_rbAFrame.basis.column3 = axisInA; } public function set axisInB( axisInB:Vector3D ):void { // m_rbBFrame.basis.column3 = axisInB; } and ( AWPMatrix3x3 ):

    public function set column3( column3:Vector3D ):void {
        _row1.z = column3.x;
        _row2.z = column3.y;
        _row3.z = column3.z;
    }

but i have only z here... what this means... ?

Help me Li ... :)

LucaEstiva commented 11 years ago

This are the position of the constraint relative to the object ( object space ):

New constraint position: Vector3D(-7.000000029802322, 0, 0) New constraint position: Vector3D(-9.000000357627869, 0, 0) New constraint position: Vector3D(-15.999999642372131, 0, 0) New constraint position: Vector3D(-20.999999344348907, 0, 0) New constraint position: Vector3D(-27.99999713897705, 0, 0) New constraint position: Vector3D(-31.999996304512024, 0, 0) New constraint position: Vector3D(-32.99999535083771, 0, 0) New constraint position: Vector3D(-36.99999749660492, 0, 0) New constraint position: Vector3D(-48.99999499320984, 0, 0) New constraint position: Vector3D(-50.999999046325684, 0, 0) New constraint position: Vector3D(-60.999995470047, 0, 0) New constraint position: Vector3D(-68.99999976158142, 0, 0) New constraint position: Vector3D(-70.99999785423279, 0, 0) New constraint position: Vector3D(-82.99999833106995, 0, 0) New constraint position: Vector3D(-85.00000238418579, 0, 0) New constraint position: Vector3D(-93.00000071525574, 0, 0) New constraint position: Vector3D(-107.00000524520874, 0, 0) New constraint position: Vector3D(-109.00000333786011, 0, 0)

Another question... :) The others constraint can be managed by Games Maker ... ??? I don't know ... :)

LucaEstiva commented 11 years ago

Hey Li where are you from... Can i take a look to your country in some way ? I'm here: https://www.facebook.com/luca.filippini.902

LucaEstiva commented 11 years ago

The last thing for today. Sorry Li but i'm really interested to make Games Maker works :). I don't know if you use blender or not, and/or if you have a GREAT DOCUMENTATION, about bullets but i have this:

http://79.0.174.91:8086/Bounce,%20Tumble,%20and%20Splash!%20Simulating%20the%20Physical%20World%20with%20Blender%203D.pdf

You can take a look in to the main folder. I have more and more but, as you know...

muzerly commented 11 years ago

hinge constraint is a fixed axis constraint, in bullet engine there is no a function to set axis in pivotA and pivotB separately. In other constraints you can set pivot and axis separately.

I'm from China. I can't visit the facebook link bacause the great firewall.

muzerly commented 11 years ago

yea, I use blender and unity3d. thanks for the link.

LucaEstiva commented 11 years ago

This means i must set the axis when i create the constraint and after i can’t change that axis. I’m confused:

http://bulletphysics.org/mediawiki-1.5.8/index.php/Constraints

Normally two axis in hinge-connected objects should align and point to the same direction, such as a door. But you can set two axis as different vectors.

btHingeConstraint( btRigidBody& rbA,

              btRigidBody& rbB,

              const btTransform& rbAFrame,

              const btTransform& rbBFrame,

              bool useReferenceFrameA = false )

Yes I can impose that…

Anyway for now i “can try to implements” ;) the others constraint…

Thanks to you Li …

( about the firewall Proxy server ? ;) )

Da: Yang Li [mailto:notifications@github.com] Inviato: venerdì 8 novembre 2013 11:54 A: away3d/awayphysics-core-fp11 Cc: Luca Filippini Oggetto: Re: [awayphysics-core-fp11] Hi Li :) (#26)

yea, I use blender and unity3d. thanks for the link.

— Reply to this email directly or view it on GitHub https://github.com/away3d/awayphysics-core-fp11/issues/26#issuecomment-28054857 . https://github.com/notifications/beacon/VjXDoZXMK-OPt0FoHQI7ZXNHjSRXPZx9p062G6RNMfN9ynAZjUJ6BK9CJ7KY8SrZ.gif

muzerly commented 11 years ago

no, you can use setAxis function change the axis realtime. but the axisInA and axisInB should be always equality.

LucaEstiva commented 11 years ago

Sry Li, i have two objects, and two matrix…

Or may be I have a “container” and in this case I can multiply the matrix of the object1 by the container matrix and the matrix of the object2 by the container matrix, in that way I have the final transformation that refer to the container transformation.

Like normal World, View, Projection or:

finalTransform.identity();

finalTransform.append(world);

finalTransform.append(camera);

finalTransform.append(projection);

It’s right for you ?

Da: Yang Li [mailto:notifications@github.com] Inviato: venerdì 8 novembre 2013 13:38 A: away3d/awayphysics-core-fp11 Cc: Luca Filippini Oggetto: Re: [awayphysics-core-fp11] Hi Li :) (#26)

no, you can use setAxis function change the axis realtime. but the axisInA and axisInB should be always equality.

— Reply to this email directly or view it on GitHub https://github.com/away3d/awayphysics-core-fp11/issues/26#issuecomment-28059726 . https://github.com/notifications/beacon/VjXDoZXMK-OPt0FoHQI7ZXNHjSRXPZx9p062G6RNMfN9ynAZjUJ6BK9CJ7KY8SrZ.gif

LucaEstiva commented 11 years ago

Thinking about this, as a real case, seems to be ok …

Da: Yang Li [mailto:notifications@github.com] Inviato: venerdì 8 novembre 2013 13:38 A: away3d/awayphysics-core-fp11 Cc: Luca Filippini Oggetto: Re: [awayphysics-core-fp11] Hi Li :) (#26)

no, you can use setAxis function change the axis realtime. but the axisInA and axisInB should be always equality.

— Reply to this email directly or view it on GitHub https://github.com/away3d/awayphysics-core-fp11/issues/26#issuecomment-28059726 . https://github.com/notifications/beacon/VjXDoZXMK-OPt0FoHQI7ZXNHjSRXPZx9p062G6RNMfN9ynAZjUJ6BK9CJ7KY8SrZ.gif

LucaEstiva commented 11 years ago

Not now but i want try to use PhysX:

https://www.youtube.com/watch?v=zhRPU1WyrBI J J J

( I must see the hardware/software compatibility list but i if remember right … there are no problems… )

http://79.0.174.91:8086/AwayGamesMaker/PhysX-3.2.4_LINUX_SDK_Core/Documentation/PhysXGuide/Manual/Joints.html

http://79.0.174.91:8086/AwayGamesMaker/PhysX-3.2.4_LINUX_SDK_Core/

Firefox and

https://addons.mozilla.org/it/firefox/addon/downthemall/

I think is the function declaration proto that confuse me… , but anyway as usual thank for your help Li

Da: Yang Li [mailto:notifications@github.com] Inviato: venerdì 8 novembre 2013 13:38 A: away3d/awayphysics-core-fp11 Cc: Luca Filippini Oggetto: Re: [awayphysics-core-fp11] Hi Li :) (#26)

no, you can use setAxis function change the axis realtime. but the axisInA and axisInB should be always equality.

— Reply to this email directly or view it on GitHub https://github.com/away3d/awayphysics-core-fp11/issues/26#issuecomment-28059726 . https://github.com/notifications/beacon/VjXDoZXMK-OPt0FoHQI7ZXNHjSRXPZx9p062G6RNMfN9ynAZjUJ6BK9CJ7KY8SrZ.gif

LucaEstiva commented 11 years ago

And… i have this comment on my Hinge constraint creation function … J

         * Hinge constraint, or revolute joint, restricts two additional angular degrees of freedom, so the

         * body can only rotate around one axis, the hinge axis.

Sry Li :P ( I’m lost )

Da: Yang Li [mailto:notifications@github.com] Inviato: venerdì 8 novembre 2013 13:38 A: away3d/awayphysics-core-fp11 Cc: Luca Filippini Oggetto: Re: [awayphysics-core-fp11] Hi Li :) (#26)

no, you can use setAxis function change the axis realtime. but the axisInA and axisInB should be always equality.

— Reply to this email directly or view it on GitHub https://github.com/away3d/awayphysics-core-fp11/issues/26#issuecomment-28059726 . https://github.com/notifications/beacon/VjXDoZXMK-OPt0FoHQI7ZXNHjSRXPZx9p062G6RNMfN9ynAZjUJ6BK9CJ7KY8SrZ.gif