What would be an example of code that would allow someone to spawn an object at a fixed distance. I want it to spawn on the right side of the world (world size 800x600) and the object moves to the left.
With 'addObject(new ActorClassName(), xLocation, yLocation)', the 'xLocation' value would be 799 at the right edge of the world. 'move(-1);' ( or 'setLocation(getX()-1, getY());' ) in the act method of the actor class will make the actor move left.
In your world class, add an int instance object field for a spawn timer. In the act method of the world class, increment the timer, then check to see if it is 50 or not. If it is, reset the timer to zero and spawn an actor.