- Home /
how to make a moving object
Hey guys,
I'm making a game for school, but i want to put so scary moments in it. what i want to do is, to make an object move from one place to an other place when i move past a trigger. But i don't know how to do that? i'm not that good with unity3d, hopefully can you guys help me.
thx
Answer by Sisso · Oct 08, 2012 at 08:14 PM
It is simple. These two links there's more that you will need:
Answer by cagezero · Oct 08, 2012 at 08:50 PM
It seems like you are asking two questions here:
How to use triggers
How to perform basic movement operations
Triggers - Triggers are managed by Colliders. I would start by reading this: http://docs.unity3d.com/Documentation/Components/class-BoxCollider.html
Basic Movement - There are a variety of different ways to move objects in Unity. Two common methods are Transform.translate and Vector3.MoveTowards. Another option is to use a package like iTween that can help manage moving objects around the screen for you.