Losing Rotation change from Collision?

Get help using Construct 2

Post » Sun Apr 14, 2013 9:35 am

I have a bunch of Sprites in a box with Physics applied, the walls are solids. Super basic... I have each Sprite set to "Prevent Rotation: No" but they won't rotate... if I delete one and rebuild it I get Rotation back from Collision with other Sprites and Walls but after making some changes in other areas my Sprites stop Rotating like they should... Having to rebuild to get back Rotation is getting very tedious because the Sprites control other things with their motion.

How do I get my Rotation back? It helps the random movement of my Sprites quite a bit even though they are just square.

Thanks!
B
10
S
4
G
2
Posts: 133
Reputation: 2,667

Post » Sun Apr 14, 2013 10:04 am

This is not an issue I've ever seen. Post your capx and we'll take a look.
B
56
S
15
G
10
Posts: 910
Reputation: 11,942

Post » Sun Apr 14, 2013 9:05 pm

https://dl.dropboxusercontent.com/u/39000273/Clean%20Test.capx

Here you go! When I first built this the "Emitters" would rotate on impacts as expected... Then I went in and manually adjusted the rotation of each object to see if the starting rotation effected the direction the velocity was applied. After that I've lost the rotation from collision that the Emitters had before.

The first time this happened I deleted all Emitters and rebuilt them... rotation came back. I manually randomized the starting rotation between each emitter and again lost the rotation change on physical impacts!

The goal is to be able to fill as much of the faded color area with solid color block as possible without any overlapping. I have a much improved concept for preventing overlaps that I have not yet implemented.

Thanks!!
B
10
S
4
G
2
Posts: 133
Reputation: 2,667

Post » Sun Apr 14, 2013 9:31 pm

It's your density. Setting it to zero basically makes it a physical anomaly, and the engine can't figure out what to do with it. Density should always be set to something.
B
56
S
15
G
10
Posts: 910
Reputation: 11,942

Post » Sun Apr 14, 2013 10:58 pm

Oh thanks! Happy it was something simple... That makes a lot of sense though because the tweaks I was doing at the time were in an attempt to keep the objects from slowing down. It failed and I came up with another way but never though to reset the density. Thanks for taking a look!
B
10
S
4
G
2
Posts: 133
Reputation: 2,667


Return to How do I....?

Who is online

Users browsing this forum: austinblackbelt and 33 guests