How to Projectile reacting to 2D Wind

Hello, hope all is well

I’m trying to affect my arrow in flight with a 2D wind effect on a 3D arrow, I’m not worrying too much about up and down just how much the wind affects or pushes on the actor in flight (projectile).

My wind is global and is based on two values materials handle the rest for foliage. Arrows I can’t seem to wrap my head around how to accomplish this. I need to translate 0-360 to a vector -1 left +1 right x wind speed. But I’m not quite sure how to move forward I’m kind of stuck.

Thank you.

Many ways to do it, here’s one:

  • below, the character fires arrows in a pretty standard way
  • if the projectiles are to be affected by gravity, the firing angle can be set up by rotating the vector
  • the below also accounts for the character movement vector (as in, you run forward and fire an arrow, the arrow will fly faster - relativity)


  • an actor with a box collision represents wind (for something more nuanced, there are vector fields)
  • when an arrow enters this field, it receives a wind modifier; when it leaves, the wind modifier is taken away
  • this way there can be multiple wind effects at once and they will accumulate if overlapping
  • since vectors have both direction and magnitude, you only need a single variable here


The projectile is updated like so:

  • accounting for framerate, we accumulate the movement vector and update arrow’s velocity
  • you can disable Rotation Follows Velocity on the Projectile Movement if needed

Image from Gyazo


If you do not need any of the wind-field-nonsense, you could have it like so instead:

and

Image from Gyazo

omg wow thank you so very much I have a lot to try out now thank you