In: General
14 Apr 2009Hi all:
There have been a few edits and additions made to the library lately:
Radians vs Degrees
One major change is how rotation is handled. We made a few changes to the RigidBody class and the JConfig class. You as a developer now have the option to use either degrees or radians to set and get RigidBody rotations. All you have to do is specify which type you want to use by setting the JConfig.rotationType to either DEGREES or RADIANS. At the moment the JConfig.rotationType value is defaulted to DEGREES
The engine level calculations are still done with radians though (may or may not change, TBD), never the less the conversion to radians and degrees and vice versa is done at the RigidBody level. Additionally, we have added “yaw”, “pitch” and “roll” properties to the RigidBody class which also use either radians or degrees based on the JConfig.rotationType value.
New class: MouseConstraint
There has been a new class to the Papervision3D plug-in called MouseConstraint and a new example to the Papervision3D examples folder. The class basically allows you to attach a world constraint to an object and simulate dragging.
Other News
You can now also access the the PhysicsSystem directly from your instance of the plugin by accessing the “engine’ property.
What used to be:
can now be accessed as
considering that you names your instance of the plugin “physics”.
You can now also add constraints directly from your plugin instance as so:
where as before you had to get an instance of the PhysicsSystem and add it to that.
There are also new examples on how to set up constraints and a really cool example by Muzerly on how to set up a car using the vehicles package!
Stay tuned!!
JiglibFlash is a open source Actionscript 3D Physics Engine.
5 Responses to Radians vs Degress, New Class and Other News
Tiago Diaz
April 23rd, 2009 at 2:31 pm
Well i dont have too much words to descrive the enhancements, only that, they are great, i used the old version, and now this one, i am upgrading my project to this version, less code, better quality, more faster and cappable.
In the older version i was thinking to test the WOW Engine when he publish the new version… But now…
Thanks peopple.
Rossman
June 18th, 2009 at 6:31 pm
Hey,
I was checking out the library, great stuff. I am trying to make my own car in 3DS Max and I can’t figure out how you guys set up the front right/left wheel PIVOT’s in 3DS?
I followed this tutorial and have a car with “discs” for pivoting the front wheels…
http://professionalpapervision.wordpress.com/2009/03/31/building-the-flintstones-car-for-papervision3d/
Any advice appreciated!
Michael
July 31st, 2009 at 11:05 pm
Dont look at the tutorial of Mike Lively because his aproach there is totally different :he creates the car without using any physics engine
. I can tell you one thing . I am developing a racing game now and I was braking my head for 2 weeks in order to understand how to recreate the car which would behave similar to the car in the example . I am working in 3ds max and I found that there is an issue of coordinate system matching . You have to try changing local coordinate gizmos of each wheel and eventually (after a 2-4 hours of hard work) i think you will manage to match your car’s parts to the physics of JigLib
Ringo
August 2nd, 2009 at 10:45 pm
Hi Michael,
Yeah i saw that problem aswell, but didnt had enough time to fix that yet. If you come up with a solution contact me, i’ll make sure the fix will be committed. Thanks letting us know.
Michael Iv
August 23rd, 2009 at 7:55 am
Ok The problem is the Coordinate System in 3ds Max . I am saying it in connection to PV3D . Before exporting Collada one must play around with flipping local Z Y coords of each part of the car . Once again it depends on the 3ds max Version . The best id to use 3ds Max 9 as it s most matching for Collada Output . If you will not flip the axis Y Z properly you will have such anomalies as Wheels rotating around Y instead of rolling and so on. With Away3d there us a bigger problem . In the new Version of JiglIb the JCar asks for skin that is mesh and in away 3d mesh ca not nest objects so you cant assign the wheels to the JCar as it shown in the Jig|Lib Car example . In away 3d you when you get Collada file the Object that has nested wheels is ObjectContainer3d so it is not mesh and therefor you cannot assign it to the JCar . Shortly I tried different ways to overcome this barrier but found nothing . I believe that only the Guy who wrote the JigLib knows how to build an Away3d based car with JigLib.