- Home /
Question by
WesterlyCarrot9 · Apr 18, 2013 at 10:02 PM ·
c#javascriptmovementobjecty axis
Simple way to make an object go up and down?(Y axis)
Hello! What would be a simple way to make an object go up and down on the Y axis? My idea is to have 3 boxes that go up and down and i try to jump on them while they are on the air. Thanks!
Comment
Best Answer
Answer by kmeboe · Apr 18, 2013 at 10:08 PM
You can cause objects to move by modifying their transform positions. In order to do this over time, typically you would create a script that does this in its Update() method.
Here are some pages that should get you started:
http://docs.unity3d.com/Documentation/ScriptReference/Transform.html
http://docs.unity3d.com/Documentation/ScriptReference/MonoBehaviour.Update.html
http://docs.unity3d.com/Documentation/ScriptReference/Time-deltaTime.html
Good luck!