Collision of attached actor does not work correctly
For example, add 3 static mesh actors in scene, make their collision preset BlockAllDynamic.
Actor 1 is to be the wall, actor 2 is the parent, actor 3 is the child.
Add some input control in level blueprint, so that you can move parent and child freely.
When child and parent are not attached together, moving both parent and child (I used AddActorWorldOffset with Sweep = true in this example), their collision work correctly and they are blocked by the wall.
Whenever I attach the child to the parent, and try to move the parent, the collision of the child is not working anymore, the child just intersect with the wall.
A test project is included, open the level blueprint and see what keys to use; open the only one map in Content folder first, then just press Play and move your default pawn to a location that you can see the 3 actors and try.
I asked this question in the comment here, but I think it's better to ask it as a standalone question.
Below are some screenshots.
Add Offset with "Sweep" function WON'T check the children, just root component.
I think it's better way that If you press P, make a bool such as "is together?" to true
And if this bool set to true, when press U,H,J,K , the Sphere and Cube will move together.
answered Nov 02 '15 at 02:24 PM
I'm using 4.9 as we'll. I've been trying to attach skeletal and static meshes to a vehicle, so they can be torn off via damage. Maybe I can do it with 1 skeleton, but if a part isn't always going to be attached, it should be a seperate asset, no?
Anyways, if I attach a mesh to a socket on my vehicle, I can collide with it as a player walking against it, and also shoot projectiles and collide. But when driving the car, the collision is ignored like you guys said. That is, until I turn on simulation I think, then I believed it worked. Need to double check. Not at my PC now.
But, I tried attaching a collision box as well, same deal. But I attached via the editor and not in blue print code and not from a level asset that is placed.
How else would I do this then? Can we enable/ disable or delete parts of a physics mesh at runtime? So in my base vehicle I add the bumper collision, then when damaged, remove it?
This does seem like a bug though? I'd think people would want this functionality?
Edit: I forgot. It DID work, to a extent, when my attached physics box was using the root bone/node. But then my vehicle physics was basically removed / screwed up. The car was tipping forward and kinda floating in the air. But the bumper physics box worked.
Follow this question
Once you sign in you will be able to subscribe for any updates here