I have used the Physic basic example to create Physic for Crates and that they land on Solids,but how make a dynamic pushing for this crates by player ?
The player should have physics behaviour also.
Apply force on the player and when the player touches the crates the crates should be pushed.
If not it could be the settings for density/friction etcetera could be off, so adjust these to your needs.
A far better way would probably be to skip the whole physics behaviour and fake it with other behaviours, but well..
I try every Settings but my Player can push the crate only 1 pixel forward. I use Polygon collision for my Player.
Does this help? I added Solid and Platform behaviors to the block I wanted to move and did this:
<img src="http://imageshack.com/a/img513/7662/of4d.jpg" border="0" />
You might have better luck with the Platform behavior or 8-direction movement for both the player and the crate. The physics behavior can be kind of wonky, so I would avoid it if possible.
Develop games in your browser. Powerful, performant & highly capable.
I wouldn't use platform behaviour for the blocks.
Using your example, instead of simulating pressing right for the block, try set position to: Block.X + Player.Platform.Speed
Sorry to make this more confusing for you than it already is but:
If you are making a grid based game then IMO you will be better using bullet behaviour for both player and block.
You also need to check that the block is movable which usually means spawning a collision detector on the far side of the block to see if the space you want to move it into is empty.
Thank you for this but it don't work, I mean its the same that i can only move the Crate 1 pixel every second. It's very very very hard to move. I try to make a Platform Game. Do someone have a other Idea maybe ?
Oh yes thank you very much :)