- Home /
 
 
               Question by 
               TrackpadStudios · Oct 09, 2012 at 11:58 PM · 
                camerarandomorientation  
              
 
              Random camera orientation
I want the cameras orientation to be randomized at the start of the game, in order to disorient any repeat players. But I only want the x axis to be randomized, I don't want them to start out staring at the sky, or at the ground. Any suggestions?
               Comment
              
 
               
               
               Best Answer 
              
 
              Answer by Eric5h5 · Oct 09, 2012 at 11:59 PM
Assuming you meant "y axis":
 transform.Rotate (Vector3.up * Random.Range(0.0, 360.0));
 
              Right, sorry, not thinking right today. Worked perfectly =D
Your answer
 
             Follow this Question
Related Questions
Make a camera collision 1 Answer
How to make camera position relative to a specific target. 1 Answer
Switch to a random camera 1 Answer