Hey all,
I’m looking to write something in C# that will work as follows. The user touches a point on the screen (temporarily mapped to a mouse button press) and a petal will float in the opposite direction of the input so long as it is within the effective radius.
Imagine that the user touches a point on the screen and it generates a gust of wind towards the petal - pushing it along. Of course the force of the wind will weaken with distance.
I haven’t started writing anything yet, I’m still trying to figure out how to do it all. I imagine that I’ll be using some sort of Raycast that extends in a 360 degree radius around the Input point. If it collides with the petal (a rigidbody) there will be some sort of Rigidbody.Addforce effect that pushes the petal.
Does this sound like I’m on the right track or do you think I should be investigating other keywords?
Just to be clear, I’m not asking for code - just whether you think I’m on the right track for what I want to accomplish.