Arc sweep in front of player (Useful for melee attacks)

Basically, you define the number of steps for the loop and define the number of degrees that you want to sweep across. It takes the current step that you’re on and uses that as a multiplier that gets added to make the offset. As the current step of the loop increases, the offset increase and causes it to sweep. Using a sphere trace, you can do things like up the radius of the trace and lower the number of steps; to reduce the overall number of traces performed. As the distance gets further out, you’ll start reaching the point where you’ll need to increase the number of steps to get enough coverage.


Thanks IronicParadox! This post is a big help!