Angles

PiCkstix

New Member
Reaction score
18
If a ball were to hit a wall and bounce back, what would be the best formula to use?

eg. A ball hits a wall at 90 degrees, what formula would I use to give it the most realistic "bounce off" angle?

Thanks,
PiCk
 

PiCkstix

New Member
Reaction score
18
Ok I have figured out a simple way of doing SOME of the angles that lie towards a positive angle where you can just go Angle - 135' and it will work np.

For the other angles it seems very unusual and would need to use Angle + 135' which I am struggling to fit in...

I will check the link now...

EDIT: I am doing mine in GUI and to be honest, I hardly understand anything about JASS... :)
I am closing to a conclusion and might find this out but, any help will be nice...
 

Waaaaagh

I lost all my rep and my title being a jerk
Reaction score
70
velocity x/y tracking will help you so much here. Then, check for lack of pathability at little offsets, like (x+xspeed,y) and (x,y+yspeed), and if the first one isn't pathable, flip the x velocity, if the second isn't, flip the y velocity.
 
General chit-chat
Help Users
  • No one is chatting at the moment.

      The Helper Discord

      Staff online

      Members online

      Affiliates

      Hive Workshop NUON Dome World Editor Tutorials

      Network Sponsors

      Apex Steel Pipe - Buys and sells Steel Pipe.
      Top