Greetings everyone. I’ve ran into some strange behaviors for my custom aircraft class. For my own development purposes, I use a vector variable to set all physics linear velocity for each frame. It all worked well, until I tested how the aircraft would behave when crashing into some large objects.
So the weird behavior is, the aircraft actor keeps drifting after the collision, as if it’s receiving the impulse from the collision every frame afterwards, regardless of the linear velocity input or the linear damping variable. Even if I kept setting all physics linear velocity to (0,0,0) at the start of the tick event, it’s still drifting. The drifting won’t stop until it collides with something again, in my case, it only stops after the aircraft hits the ground.
Some possible solutions I have tried but failed & haven’t tried:
- Setting the damping variable. It’a useless, even if I set the linear damping to a very large value, the drifting effect is still the same.
- Apply an “air-resistant force”, get the velocity and applying a reversed force. The most weird thing about it is that, even if the aircraft is drifting, the “get velocity” node for the actor still returns (0,0,0). Which means I cannot even get the drifting velocity of the aircraft, despite it’s constantly changing the position. I haven’t tried using the delta position though.
- Disable physics simulation when flying the aircraft, manually handles the collision behavior when overlapping. This would be so much pain for me to implement, and I don’t really want to use it unless all other methods fail.
Does anybody have the same issue as I am running into? Or can somebody help me with this bug? Sorry if I didn’t describe the bug clearly, I am literally dying after hours of debugging lol