Answer is in the Manual.
How would I generate a new object based on player location?
I'm working on a project using the Roll-a-ball tutorial project as a template. I removed the walls and the pickups (along with any corresponding scripts), so now I only have the player and the plane serving as the ground. The only functionality is the player moving around with the camera following it. I am trying to write a script that would generate a new plane identical to the one at origin whenever the player reaches the end (outer 10% or so?) of the current plane. The plane should be generated in the direction the ball is currently rolling, and the ball should roll seamlessly from one plane to another.
I am pretty new to scripting and generating objects using scripting, so please prioritize using code that is easy to understand rather than the most efficient.
You should first include the code you have written for yourself.
Look up Instantiate in the Scripting Reference.
Follow this Question
Related Questions
Question about procedural forest/grass generation 1 Answer
Why is my camera rolling around like a ball? 3 Answers
2 player Roll a Ball 0 Answers
Roll a Ball script error?! 2 Answers
How to automatically generate a new int with a specific name? 1 Answer