Break up a large physical body into several small

I want to create something like a billboard. He will be a physical body. Draw a picture on it as a texture.

I want that when an object collides with a billboard, it will fly apart into small cubes. Can this be done? If so, can these cubes save part of the picture?

1 Like

Something like that: https://www.babylonjs-playground.com/#ML2LR9#0

Yes, I saw this example. But can particles be physical objects?

PG: https://www.babylonjs-playground.com/#Q6LPEN#1

I tried to immediately place the physical cubes next to each other, but I can’t put them in. They fly away right away

Pinging @jerome who masters the SPS

I don’t know anything about how the physics engine works.
As solid particles have, like other meshes, the properties position, rotation and velocity, I think it’s possible to set easily their values from ones computed by a physics engine.
I remember that @RaananW and @adam did once some PG examples with the SPS and physics. Maybe they keep the links to them …?

PG: https://www.babylonjs-playground.com/#Q6LPEN#1

I made physical cubes and drew a piece of the picture on them. But under the influence of gravity my wall collapses. Can I somehow make it collapse under the influence of any force other than gravity?

It would be cool to do if their gravity remained but the wall didn’t collapse at the same time

PG: https://www.babylonjs-playground.com/#Q6LPEN#3

It seems that I solved my problem, I turn to the experts of Babylon … is not my solution a crutch?

Physics wall in this PG https://www.babylonjs-playground.com/#480ZBN#8

2 Likes

As I understand it, my mistake was that all the cubes were the same size and were located on top of each other?

2 Likes