How come the bullet bounce isn't accurate?

Get help using Construct 2

Post » Fri Dec 05, 2014 9:34 pm

If I have a square box with bullet behavior that bounces off a solid object that is also square, the reflected angles eventually become inaccurate. Why is this?
How can I get accurate bouncing?
B
43
S
19
G
65
Posts: 1,097
Reputation: 37,931

Post » Tue Dec 09, 2014 12:02 am

You possibly can get better results by doing something like this if you only have vertical and horizontal walls:
viewtopic.php?f=147&t=63297&p=542366&hilit=bounce#p542366

Corners are a bit odd with the ball, but square against square should work well.
B
92
S
32
G
106
Posts: 5,272
Reputation: 69,455

Post » Tue Dec 09, 2014 8:46 am

My case is a bit unusual, so I had to work out my own collision detection. I managed to get it bouncing accurately by calculating a projection vector for each axis, and flipping the motion with the shorter projection.
B
43
S
19
G
65
Posts: 1,097
Reputation: 37,931


Return to How do I....?

Who is online

Users browsing this forum: guannstar, odiusfly and 22 guests