If you add and weld a component as a child to another component and the parent component has simulate physics enable and the child component has block all, the interaction physics interaction is translated to the component that is simulating physics. However, if you do the same, except that the child component is a InstancedStaticMeshComponent, the interaction with an instance collision isn’t translated to the parent component that is simulating physics. Is this a bug?
I confirm physics behaving differently in 4.26.1
A static mesh component behaves differently to an instanced mesh component when it comes to physics.
It also behaves differently then to a child actor component (with a static mesh).
Haven’t figured out why yet.
Having this issue in 5.0.2, and similar other issues with Instanced Static Meshes.
I’m trying to make a drone with adjustable parts so I’m using Instanced Static Meshes for the arms.
Previously I was using regular static meshes and it worked fine. When I attached them, they did not collide with the drone’s body and could collide with the environment without issues.
With ISM, the arms collide with the drone’s body and the drone flips around violently. I setup a quick test by making a BP of a cube with a regular Static Mesh and an Instanced Static Mesh as children. With just the regular mesh it attaches as expected, but with the Instanced Mesh the cube spins around and flies off.
I tried disabling collision on just the drone 's body which fixed them clipping, but then the whole drone acts like it has no collision and can fly through everything. However, it can push other physics objects around with the arms, so it definitely has collision. It does seem like the collision forces aren’t being replicated to what it’s attached to, only whatever it’s colliding with. I can ram full speed into a physics cube and it sends it flying but the drone behaves as if it hit nothing.
I looked into the source code a little for the InstancedStaticMeshComponent and saw that it is coded to always force physics simulation off. I don’t know if that has something to do with it, but it stops me from testing it’s physics without it being attached to something.
I am very confused by what I see when I use the command ‘show COLLISION’. The arms don’t have any collision box around the actual meshes, but there is one collision box at the center of the actor, unrotated and untranslated. From what I’ve tested, it seems to just be a visual bug with it not moving the collision debug, as I can walk through the out of place collision box, despite colliding with the arms that don’t show a collision box around them.
I have the same problem I am adding an ISM for every item in a stack of items using a spline to place them correctly parented to a main item, but when the main item has simulated physics turned on the ISM’s just fall through the floor.
I then just tried using just the ISM but I can’t turn on simulated physics so that’s a bust.
Any way I can fix this?