Why does WCK replace Box2D's Gravity with it's own?

Post about the Flash World Construction Kit and the Alchemy port of Box2D.
SmartArtsGames
Posts: 2
Joined: Tue Feb 04, 2014 9:26 am

Why does WCK replace Box2D's Gravity with it's own?

Postby SmartArtsGames » Wed Oct 01, 2014 10:10 pm

Hello,

Is there a critical reason WCK applies its own Gravity (feeding Box2D zero gravity vector) ?
Does it solve some kind of Box2D limitation? (i.e. can Box2D not handle WCKs custom gravities/bodies?)
If I do use Box2D's built in gravity, are there edge cases that I may not discover immediately?

Thankyou

mayobutter
Posts: 915
Joined: Fri Dec 14, 2007 8:07 pm
Contact:

Re: Why does WCK replace Box2D's Gravity with it's own?

Postby mayobutter » Wed Oct 08, 2014 2:45 pm

Using the WCK framework, it's possible to apply different gravity vectors to different bodies (the first demo, for example, gives each body its own gravity to create the radial gravity effect). In pure Box2D, one gravity vector is applied to everything. So if you've got uniform gravity (like most games) you don't really have to worry about it and can just use the pure Box2D implementation.

SmartArtsGames
Posts: 2
Joined: Tue Feb 04, 2014 9:26 am

Re: Why does WCK replace Box2D's Gravity with it's own?

Postby SmartArtsGames » Tue Oct 14, 2014 6:48 pm

I really appreciate you taking the time to confirm Mayobutter,
I realise this is quite an old project for you.

I'd also like to thank you so much for your time put into WCK and sharing it
openly. It was actually this project that first lead me into reading my first source code
which triggered me to see programming from a whole different perspective,
inspiring me to start studying programming properly.

While the learning curve has proven very frustrating at times (which I do not thank
you for :) When things do finally click, I do find it very rewarding (which I do thank you
for.)

Thanks again for your time and effort.


Return to “WCK”



Who is online

Users browsing this forum: No registered users and 1 guest