physics object does not match pre-scaled display object (ZoomIn/ZoomOut for a physics game not possible)

Hi Greg,

I think your main questions were:

  1. Can you rotate a physics object? Absolutely yes… the older docs were vague/misleading on that specific point. I have fixed that, and I plan to update the collision guide considerably as soon as I get past some pressing tasks.

  2. You can scale up (or down) the entire physics world, and it will work. You just can’t scale individual bodies independently of the world and expect the collision bounds to work. That being said, it would probably be fairly easy to write a little scaling algorithm that would work on any given shape, and output the new coordinates. I did something like that just this past weekend for flipping physics shapes (and flipping is, in effect, scaling negatively across an axis). This took me about 30 minutes and it works nicely on all physics shapes… so, it could likely be enhanced to scale bodies up and down and dynamically apply a body based on the “scaled coordinate points”.

Take care,

Brent

ok thanks Brent - and whilst you’re there can you confirm the Corona visualization debug aspect for physics - is what we were saying true in terms of this no currently working for scaled physics?   (i.e. physics.setDrawMode( “hybrid” ))  

Any work arounds you could suggest beyond HardBoiledIndustries re debugging physics in a scaled game?

Hi Greg,

When scaling the game, you will need to contend with debug tracings that don’t quite match. I believe the engineers investigated fixing this, but it was placed at lower priority than several other things. So, for now, you’ll need to debug the best you can.

Take care,

Brent