20 posts
• Page **2** of **2** • 1, **2**

**Posts:**5,290**Reputation:**70,991

B

92
S

32
G

109
@Thanks R0j0hound.

I'm still getting some weird behaviour with this solution. It seems like i get like this (and like the image above) no matter what I do. All the wide angles seem off and I'm not getting an exit angle at the same angle if they are perpendicular to the surface angle.

Any idea of what i need to adjust? The problem seems to be with the exit angle.

2*ang_surface-ang_in seems to be the problem. Needs adjusting back to isometric?

I'm still getting some weird behaviour with this solution. It seems like i get like this (and like the image above) no matter what I do. All the wide angles seem off and I'm not getting an exit angle at the same angle if they are perpendicular to the surface angle.

Any idea of what i need to adjust? The problem seems to be with the exit angle.

2*ang_surface-ang_in seems to be the problem. Needs adjusting back to isometric?

**Posts:**977**Reputation:**12,626

B

40
S

17
G

17
Here's my current test for the adjusting of the normal for bouncing:

https://dl.dropboxusercontent.com/u/542 ... oTest.capx

You can drag everything around, and the red line is the visual normal and the blue line is the the corrected normal.

The issue as you describe is when the angle the balls travel are perpendicular to the blue normal. Which would mean it's there is no perpendicular motion to reflect so it doesn't bounce.

Mid typing this I re-uploaded the file with an idea that seems to work. It takes both the surface angle and the angle of the ball and doubles the y component before calculating the bounce. Then it halves the y component of the resulting angle.

So if you end up using the normal from the ray caster plugin just add or subtract 90 (it doesn't affect the math) from that the get the surface angle.

https://dl.dropboxusercontent.com/u/542 ... oTest.capx

You can drag everything around, and the red line is the visual normal and the blue line is the the corrected normal.

The issue as you describe is when the angle the balls travel are perpendicular to the blue normal. Which would mean it's there is no perpendicular motion to reflect so it doesn't bounce.

Mid typing this I re-uploaded the file with an idea that seems to work. It takes both the surface angle and the angle of the ball and doubles the y component before calculating the bounce. Then it halves the y component of the resulting angle.

So if you end up using the normal from the ray caster plugin just add or subtract 90 (it doesn't affect the math) from that the get the surface angle.

**Posts:**5,290**Reputation:**70,991

B

92
S

32
G

109
R0J0hound wrote:Here's my current test for the adjusting of the normal for bouncing:

Mid typing this I re-uploaded the file with an idea that seems to work. It takes both the surface angle and the angle of the ball and doubles the y component before calculating the bounce. Then it halves the y component of the resulting angle.

Seemed like that was the issue. Took a look at your example file and now the angles makes sense. Thanks for a lot for your help!

**Posts:**977**Reputation:**12,626

B

40
S

17
G

17
20 posts
• Page **2** of **2** • 1, **2**

## Who is online |

Users browsing this forum: brunopalermo and 33 guests |