I have two platforms that will generate offscreen. The platforms will move to the left to give the illusion that the character is moving right.
My problem: when the new platforms generate, they don't follow the same rules as the platforms that start on screen. The ones that start on screen are platform one and platform two. The ones generated off screen are these same platforms.
On jump, the platforms move at a set speed. On collision, all platforms stop moving. This works for the first few jumps but as the new objects are generated, they don't stop moving on collision. And unfortunately, it's only *some* of the time they will stop moving. Sometimes they move, sometimes they don't. What gives?
The created objects are either platform one or platform two.