LoginLogin

How do I move a sprite with a bg?

Root / Programming Questions / [.]

spaceturtlesCreated:
I want a sprite to move with a bg screen like how a sprite moves with another using splink and with an offset. However I need to move each sprite (in this case entities made of linked sprites) independantly and only render them with sprites when on-screen. I'm trying to achieve this for my space game which is described in my latest poll about it. Currently I have the map and character movement as well as entity creation, deletion, and child creation functions in place including an incomplete render function which renders the entities as I described. Here's a key for the incomplete version: DJ33X3KJ Controls: circle pad to move a to create an entity Entity deletion is untested. Child creation is half functional. Please help me figure out how to offset my entities properly in the render function.

The key didn't work.

The key didn't work.
It should work now.

What are you using to move the BG, if you are using BGOFS then the sprite/s will automatically move with the BG.

What are you using to move the BG, if you are using BGOFS then the sprite/s will automatically move with the BG.
Yes it does do that but I have to offset it from the center. When I try to do that though, it goes far offscreen and moves around.