I’ve written some code to do a line trace from one location (0,0,0) to wherever a linetrace ends. However, my implementation if it is a little wonky for a couple of reasons:
While the projectile spawns file, it works by using a bad workaround. It deletes the old instance every 1/60th of a second, and remakes another. Because it is only marked for deletion and isn’t actually deleted at every frame, it doesn’t actually follow player movement. My laser actually works in real time, too, so I don’t see why I couldn’t just use one laser and have it constantly on, but only render it at specific points. My issue is getting the laser to actually attach to the physical gun.
The constant addition and deletion is really taxing on the system; I wanted to ask about an implementation on my gun blueprint that doesn’t require constant creation and deletion of the linetrace, but for a way to just have it be constantly on?