Mesh Flicker when Follow Mouse

I am working on making/learning an RTS style game. I am at the point now (early on still) where I can select a “building” from the hud/widget, follow the mouse cursor, then place it into the world.

The problem I am having is as I move the mouse around the screen with the “building” attached, there are areas of the screen that cause the “building” to leave the mouse position and go to another area of the map causing a type of flicker effect. Regardless of where I am in the world/map, when the flicker occurs, the mesh goes to the exact same location on the map, which is slightly off-center from the start location.

Here are the images I captured, first one is the blueprint I am using and the other 2 are images of what I’m referring too. While the “flicker” is difficult/impossible to realize from a still image, you will get the idea. You can’t see the mouse cursor in the screenshots but in the first image you’ll see the area of the building. The second image I moved the mouse just slightly north of the image 1 position and the mesh jumps to the location you see in image 2. As mentioned, there are several locations in the viewport that causes this flicker effect.

If needed, I can make a quick video demonstrating what I am referring too but I think you can get the idea of what I’m talking about from the images; if not, let me know.

One last weird caveat is that if/when I change the angle of my camera to be less inclined, the flickering does not occur. I don’t know if the angle of the camera is what’s causing this or not but I’m not quite sure how it would be the culprit. I followed a general tutorial on building placement on YouTube and his buildings do not have this anomaly.

Any help would be appreciated!

This is probably the hit test returning a null hit so the hit returns 0,0,0 (which is where the mesh is going). Add a branch before the set location to verify the HitActor output of the BreakHitResult is valid before doing the setter.

That is beautiful and simplistic! Added a null check to the hit actor into a branch and it works awesome now! Can’t even see any sort of “hiccup” when it hits a null spot. Thank you soooo much for the help! And in case anyone in the future wants to check the differences of what I did, here is the blueprint as it looks and works now.

Thanks again for your help RimmyD!