Make a object always appear behing another object
So, in my game the main camera can revolve around a specific object in the middle of the scene, a planet actually.
All I want to do is to create a spawn point to spawn spaceships from time to time, but I don't want to make them just simply appear in the middle of nowhere, I want to move this point so it always be in the opposite side of the camera, behind the planet.
Any ideas of how it should work?
P.S: English it's not my first language, so sorry for any mistakes.
Answer by rjth · Nov 28, 2016 at 02:42 PM
You could create an empty GameObject as a child of your camera. Than offset this empty GO so that it is behind the planet (I assume the planet is always in the centre of your camera). Than use the transform.position of this empty GO as the spawn point.