- Home /
 
               Question by 
               Seeseemelk · Mar 20, 2011 at 06:29 PM · 
                positionobjectinfront  
              
 
              Position in front of an object?
How can I get the position a little bit in front of an object?
    positieVoor = transform.position + Vector3.forward;
               Comment
              
 
               
               
               Best Answer 
              
 
              Answer by Jake-L · Mar 20, 2011 at 06:34 PM
Try
positieVoor=transform.position+transform.forward
nice. Adding if you want to face the object as well // Rotate the object so it keeps looking at the target
transform.LookAt(target);
Answer by Enyph-Games · Nov 21, 2016 at 07:26 PM
You can also create an empty gameobject and position it in front of the object and then just reference that empty gameobject
Your answer
 
 
             Follow this Question
Related Questions
A node in a childnode? 1 Answer
Saving Object Position in Float NOT Object 1 Answer
Moving an object 0 Answers
 koobas.hobune.stream
koobas.hobune.stream 
                       
               
 
			 
                