problems with instantiating a moving prefab.
Hello, I develop an endless runner, in this game, a character in the center can move to the right or to the left to dodge the obstacles, and the scenery moves back towards the player to create the impression of movement of the character. the scenery and the "track" can be deleted behind the camera and in front of the character ad infinitum, each course track is triggered online, or the player can move and each set is triggered in columns on the right and on the left. each decor is instantiated with respect to the end coordinates of the last decor column. it's the same principle as for the race track. at the start everything is going well, there is no offset, but the more in advance, the more there seems to be a coordinate offset in the instantiation and the sets overlap more and more. you can see in the Screenshots that after playing 30 sec / 1 min the decorations are totally on top of each other, so in addition to having decorations that are no longer well placed, there are so many objects in the scene which I pass from 130 fps (on average at the start) to 20 then 10 then 0 .. do you have a solution? I can put screens of my code if you want.
Your answer
Follow this Question
Related Questions
Random Obstacle spawn (Infinite Runner) 1 Answer
EventTrigger on button not recognizing instantsiated player 1 Answer
Instantiation of my GameObjects spell (from other script) 0 Answers
Keep position of CharacterController relative to rotating platform 0 Answers
How to edit new clone properties? 1 Answer