Best ingame scrolling?

Hi all,

I am working on a simple Jump and Run game. Now I am a bit stuck with smooth scrolling. The following things I’ve tried:

  • moving the whole game, so as the player seems to run, stop when collision occurs
  • applying a linear velocity to the player, scrolling at a certain point with transition.

Actually both did work, but I am not really satisfied. What’s the best way of doing permanent scrolling?

Thanks for your inputs! [import]uid: 90610 topic_id: 15999 reply_id: 315999[/import]

I’m oversimplifying here, but your question is like asking “What is the best car?”. That depends on wether you want to race, haul cargo, take 7 kids, show off, etc…

There is no single answer for scrolling either: it depends on the setup of your game. What I would definitely recommend is the following: design your whole game including the game logic to work in absolute coördinates, and then implement a sort of camera system that controls what is visible onscreen and how.

My personal preferred way is using a tilemap designed in Tiled and doing my collisions in math, not physics. [import]uid: 70134 topic_id: 15999 reply_id: 59397[/import]

thanks for your reply thomas6! I know that my question is very general.

I’ve made games with tiles, also collisions with math. I might do that again.

The camera thing sounds interesting, I guess I need to do some thinking there. [import]uid: 90610 topic_id: 15999 reply_id: 59435[/import]

http://developer.anscamobile.com/code/billy-cart-corona
for the camera [import]uid: 79135 topic_id: 15999 reply_id: 59853[/import]

thanks a lot for that link andrew! [import]uid: 90610 topic_id: 15999 reply_id: 61525[/import]