Need create a fracture animation help

Hi there I create a blood splatter animation(scene) for head shot of zombie when he in near distance 5.0.Works good but i wish add other animation for show parts of brain go in to the ground.How can i do fracture object for that? how can use bake physic animation and if possible?
thanks in advance

simply have the head model be parented to a head bone

when shot swap out the head for parts,

recast rays from previous hit and apply impulse along vectors if the rays hit.

give me example please you tell for i explode head of zombie? but i wish just the parts of brain simulation going to ground lol.can made with cell fracture using rigid body? for performance how can bake this physic animation if made with cell fracture plugin did you know?
thanks in advance

Make the normal head an independent object, and when you need to pop it out, spawn a group instance that regroups a buch of brain parts that you modeled, and where you can give a bit of velocity in random direction.

This way when you want to pop the head, you can do something like:

def popHead(controller):
    head = controller.owner
    scene = head.scene
    scene.addObject('brainPartsGroupInstance', head, 0)

And the velocities can be applied from the brain parts themselves inside the group. Should be simple enough.

right in this case the original body stay just add parts of brain(the group instance) or cell fracture head object and add to empty in center of midle bone of original head of zombie?

1 Like

That’s the idea :slight_smile:

  • Why use animation when there is an imitation of physics? You can do this through a series of fractures You can do this through a cell fracture and group: - cell_fracture01.blend (603.9 KB)
    At the expense of performance, I do not think that there will be a large load when simulating.
1 Like

This is exactly what we were talking about ! It looks fantastic, Nick !

  • no problem, man! If necessary, I can make the appearance of different objects, depending on the distance - the script.
  • Hi. So I practiced a little in Python with a distance and destruction - link

Thank you for attention.

yeah i just can scaled the head cell fracure but i used bullet hit with ray will need made a X torque or impulse?
i not used real bullet that is for my rocket laucher future project lol
thanks in advance

without real bullets, shoot a ray, get distance to hitNormal, think about the speed you want to shoot a ‘fake’ bullet, then calculate time by doing distance/speed, and use that time as a timer, so you shoot, timer waits then bullet explodes at ray.hitNormal/position

I wouldn’t do that because on moving entities this is weird. I would have a ghost bullet without collisions but that cast a ray to a certain distance, and move where the ray stopped if it did not hit. If the ray hit something, consider this your collision. At this point you have the hit normal so you can do pretty much anything (ricochet, apply forces, emit particles, place decals, etc…)

cast ray to where bullet will be next frame using obj.worldPosition+(object.worldLinearVelocity*multi)

bullet itself can be dynamic/ghost

can give a blend file example?

I’ll just post this:

from bge import logic

def bulletRaycasting(controller):
    bullet = controller.owner

    # get the distance traveled in one frame
    velocity = bullet.getLinearVelocity()
    delta = velocity * 1 / logic.getPhysicsTicRate()

    # casting the ray
    object, position, normal = bullet.rayCast(
        bullet.worldPosition + delta, None, delta.magnitude)

    if object:
        bullet.endObject() # maybe ?
        # the bullet hit something, add your code here ?

Then all you have to do is to give some velocity to your bullets, the rayCast will adapt itself to the direction of the movement. It has to be “true” velocity though.

friend can give a small blend example?

I will need a Y an Z linearvelocity i think the Z if for fracure object go to the ground right?

I find small solution create a few particles like dynamic and put Y and Z linearVelocity and destroy few times ago working good.Booth images have a splatter wall efect too.

THE ZOMBIE gone to ground i,m playng at 130-160FPS very fast

image 3 and 4 is a splatter blood camera