x


How do I keep the angle of a box?

I have a cube I want to use as my 2d character in a platform game.

I want to make it so that the rotation of the cube NEVER changes so that when a slope comes along he will fall down without falling to the left or right.

more ▼

asked Jun 12 '10 at 11:52 PM

user-3012 (google) gravatar image

user-3012 (google)
11 1 2

(comments are locked)
10|3000 characters needed characters left

1 answer: sort oldest

I assume your cube has a rigidbody assigned? Rigidbodies have a property "freezeRotation" that prevents them from being rotated by the physics engine.

http://unity3d.com/support/documentation/ScriptReference/Rigidbody-freezeRotation.html

more ▼

answered Jun 13 '10 at 12:34 AM

felix. gravatar image

felix.
1.9k 18 23 46

(comments are locked)
10|3000 characters needed characters left
Your answer
toggle preview:

Up to 2 attachments (including images) can be used with a maximum of 524.3 kB each and 1.0 MB total.

Follow this question

By Email:

Once you sign in you will be able to subscribe for any updates here

By RSS:

Answers

Answers and Comments

Topics:

x2158
x125

asked: Jun 12 '10 at 11:52 PM

Seen: 350 times

Last Updated: Jun 13 '10 at 12:46 AM