Hi. I have a scrolling game with a frame of 10,000 x 6,000. I'm using the "layer object" to get a parallax effect. I have space ships that fly across the background, travelling the whole 10,000px from left to right. They do this slowly, using a rubberball movement set in one direction. I want them to be destroyed when they leave the 10,000px area.
So, I've got "if x position of spaceship is greater than 10000 > destroy spaceship". The problem is, that the x position of the spaceship seems to be always relative to the scrolling frame in some weird way.
When I run the game with the debugger, the x position of the ship slowly increases as it moves to the right. But the speed that it increases by shoots up when I move my character (and hence the screen) to the left. If I move my character to the right, the x position of the ship actually decreases, even though the ship is still moving to the right (offscreen). I have a lot of ships, and as a result, they tend to get destroyed in weird clumps, mainly if my character happens to be on the right end of the map.
Is there a way to get the x position of an active object that is absolute (aka relative to the frame), and won't be affected by scrolling or character movement? Checking/unchecking "follow the frame" doesn't seem to affect this. Also, using the "destroy if too far from frame" option doesn't seem to be solution, because it seems to destroy things when they are off-*screen*, and not just off-*frame*.