PDA

View Full Version : Can you build a wall with bullet dynamics?



digitalimagery
05-03-2016, 11:03 AM
IS bullet only for knocking things apart or could you build a stone (like granite blocks) wall with bullet dynamics? I have a project where the speaker is talking about building your defenses and wants to use a castle with a wall being built around it as a metaphor.

Can bullet build a block wall.

Thanks!
DI

prometheus
05-03-2016, 11:13 AM
why would need to you use bullet for that?
keyframing in pieces would probably better, ...Unless you need bullet broken pieces that in the beggining is exploded and in dynamic chaos ..which then forms to a wall, in such case you would simply have to reverse the animation of a bullet destruction...if you want more sequenctial build ups, you would have to knock down wall blocks one by one with kinematic forces, or use animated images or procedurals to break the pieces up, then reverse animation...

But otherwise, keyframe it or use part move displacement..but itīs a bit hard to figure out exactly how you want the building of the wall to be?

So yes I would say you can build a wall with bullet if you reverse the animation, but I wouldnīt try and build it with dynamic forces and let them fall to place etc..that would probably be extremly difficult, you would have to make a container where the block falls in to and settles, without jumping jittering pieces.
There may be a way of using negative forces, but I havenīt looked in to that yet.

The question is..why would you need bullet dynamics for it, is it because of the way the motion of the pieces should behave..before, during the animation?

there are ways to either simply manually keyframing it..wich may be a bit time consuming, you can use instances, you kan use part move, and you can use particles, if you assign a point per object in the block center and then blow the particles away with some forces..then fx link blocks to those particles, then reverse the whole animation.
or is it becuase you think it would be easier to build it?


Michael

digitalimagery
05-03-2016, 11:32 AM
why would need to you use bullet for that?
keyframing in pieces would probably better, ...Unless you need bullet broken pieces that in the beggining is exploded and in dynamic chaos ..which then forms to a wall, in such case you would simply have to reverse the animation of a bullet destruction...if you want more sequenctial build ups, you would have to knock down wall blocks one by one with kinematic forces, or use animated images or procedurals to break the pieces up, then reverse animation...

But otherwise, keyframe it or use part move displacement..but itīs a bit hard to figure out exactly how you want the building of the wall to be?

So yes I would say you can build a wall with bullet if you reverse the animation, but I wouldnīt try and build it with dynamic forces and let them fall to place etc..that would probably be extremly difficult, you would have to make a container where the block falls in to and settles, without jumping jittering pieces.
There may be a way of using negative forces, but I havenīt looked in to that yet.

The question is..why would you need bullet dynamics for it, is it because of the way the motion of the pieces should behave..before, during the animation?

there are ways to either simply manually keyframing it..wich may be a bit time consuming, you can use instances, you kan use part move, and you can use particles, if you assign a point per object in the block center and then blow the particles away with some forces..then fx link blocks to those particles, then reverse the whole animation.
or is it becuase you think it would be easier to build it?


Michael

Thanks Michael,

I'm not advanced enough to have an opinion on the best way to handle this. I just hate the thought of doing it block by block and "then" discover there was an easier way. I thought of particles but I think I'll be creating walls in different stages and dissolving them in to suggest it being built over time. As is frequently the case, time and budget dictate production.

Thanks,
DI

prometheus
05-03-2016, 12:28 PM
Thanks Michael,

I'm not advanced enough to have an opinion on the best way to handle this. I just hate the thought of doing it block by block and "then" discover there was an easier way. I thought of particles but I think I'll be creating walls in different stages and dissolving them in to suggest it being built over time. As is frequently the case, time and budget dictate production.

Thanks,
DI

How advanced is the wall? is it curved,has it angles, sharp corners et?
and are the block parts quite simple and straight in itīs form?

Even it you do not know the best way to handle it, you may consider provide info on how the walls are coming together? if we shoud be able to advice correctly, that you should know regardless if you donīt know the best way to do it I think...so if itīs suppose to just move in linear, sequently?..or if each block is suppose to fly in with advanced motion and settle where it should be?

you can also either user fertilizer and weightmaps, or use the shifter plugin, thought that may be a bit more advanced if you do not know how to use it.
even more advanced stuff if you look in to bryphi77 and his node motion stuff.

but itīs hard to say what may be the fastest simplest way if we do not know how the block pieces making up the wall is supposed to build the wall in terms of incoming motion and in terms of how the final wall shoudl look like
shifter and fertilizer is more about growing in the parts, but you have to work with weightmaps, or be careful about the point amount and how you create your original initial block piece.
spline instancing may also be a way to offset pieces on a curve or even edges, though that would be more advances if you use edges and use particles on the edges, then instances on the particles, so depending on birthrate the particles will popup along the edges, and so will the blocks that are instanced.



https://www.youtube.com/watch?v=3-n2oTGiIOY

ernpchan
05-03-2016, 01:33 PM
You could key the start and end positions then use my ShiftKeysPlus script to stagger the animation.

MonroePoteet
05-03-2016, 04:39 PM
You could use Bullet by setting Gravity to 0, set Glue Strength on the Parts Convex-object wall to 100%, then use proximity to a Null to reduce the glue and apply a Forcefield to break the wall apart. Then, render the animation backwards by setting the Start Frame to 600 (or whatever), the Last Frame to 1, and the Frame Step to -1 in the Camera General Properties tab.

Attached is a sample scene. The Forcefield strength has a Gradient with Distance to Object (the Null), and I had to add another Forcefield to avoid having the bricks float away even before their glue was loosened and the RotatorNull Forcefield applied. I didn't fine-tune this latter Forcefield, so the first blocks to be unloosened start to fall toward the ground.

May not be what you're looking for, but kinda cool anyway.

mTp

prometheus
05-03-2016, 05:42 PM
You could use Bullet by setting Gravity to 0, set Glue Strength on the Parts Convex-object wall to 100%, then use proximity to a Null to reduce the glue and apply a Forcefield to break the wall apart. Then, render the animation backwards by setting the Start Frame to 600 (or whatever), the Last Frame to 1, and the Frame Step to -1 in the Camera General Properties tab.

Attached is a sample scene. The Forcefield strength has a Gradient with Distance to Object (the Null), and I had to add another Forcefield to avoid having the bricks float away even before their glue was loosened and the RotatorNull Forcefield applied. I didn't fine-tune this latter Forcefield, so the first blocks to be unloosened start to fall toward the ground.

May not be what you're looking for, but kinda cool anyway.

mTp

Yes..that is cool, and thanks for sharing, but is it not a bit heavy? It took a while to load, and the pieces comes together randomly a bit, I think part move would be easier on the system, and if you do not need bullet interaction why use it?
Great to have samples though, so thanks for that.

I tested with particles, and you can draw an edge in a straight line if it is a straight walls, or else you would need more segments, but adding particle and birth rate to object line, and you can have particles evenly distributed on the edges, then instance boxes and then use collision event to trigger the blocks, you could adust blocks or particle amount as needed, but the animation will by that pop the blocks in by birth, when the collision event triggers it.

But it is a bit in vain to advice if we do not know how the wall is looking like, curved, straight etc, and how the blocks are suppose to animate in...Grow? pop in?, fly in?

Kevbarnes
05-03-2016, 06:22 PM
133711 133712




Here another Bullet solution - just wanted to see if it could be done - scene_02 has a gradient on Mass but I don't think its doing anything
I couldn't include the Dynamic Cash files (over 5MB limit) - so you will need to run simulation again.

133713
scene files LW2015.3

Kevbarnes
05-03-2016, 06:35 PM
but kinda cool anyway.

Yep - I like your solution, would also work for irregular Stone blocks as well - a bit more control over end result.

Kev

MonroePoteet
05-03-2016, 07:31 PM
Quick note: rendering backwards is irrelevant, since LW still names the files in ascending order. The sequence has to be reversed in an NLE.

mTp