My player character’s first attack is a fairly slow projectile which bounces around and despawns OnProjectileStop. This mostly works fine, but I noticed something very odd when testing a new environmental asset.
If they never bounce on anything except for the ground, then their velocity remains non-zero… when they’re stationary. It’s usually something just around 100, and very slowly decreases, like, by something around .1 per second, until it finally reaches zero and they despawn. They just sit there, taunting me and generating hit events every tick.
To debug, I set up On Event Hit: Get Actor Velocity → Get Vector Length → PrintStr.
A demonstration: Projectile Velocity Issue - YouTube
I did manage to find a spot where I could bounce a projectile off of a static mesh once and then have it come to a stop and sit on the ground while printing velocity, but this is rare.
It occurred to me while uploading the video to demonstrate this weirdness that the ground I’m testing on is a BSP, so I tried testing on a floor plane made of a static mesh, and that did not generate the bug; velocity was appropriately reported and the projectiles despawned. So in a sense this is solved in that it doesn’t appear to be about to cause me any serious issues, but it’s still ■■■■ mysterious and I’d still like to hear wiser minds’ ideas about how a stationary projectile could be reporting ~100 velocity, and whether this could be symptomatic of something I should be afraid of!
BONUS BUG I’ve also noticed that my projectiles can cause multiple hit events in a tick when hitting a character. This was resulting in some fairly awesome bonus damage, as you might expect… and some other hilarious events too since they add an impulse when they hit a character. I’m sure you can imagine I’ve “solved” this for now by preventing any of my Event Hit logic from firing more often than .05s apart, but is this normal?