Scrolling (in all directions) game
Hi, I'm making a classical RPG. I already have the main screen, the stats, inventory, etc., and the walking hero (but he is walking in the air). Now I need a background, I've been told tile-based backgrounds is the best for huge games. I don't think mine is gonna be that big so I'm planning to do it art-based. But how can I make the screen to follow my hero, for example, if he goes up screen goes up, if he goes right screen goes right. Can anyone tell me how to do this?
Thanks in advance
You have to work with X and Y factors
Every tile has its own coordinates, which you specify in the database. If the house of the hero is:
and the hero is at
then he is standing next to the house, Everytime you let your hero walk, it has to update in the database of the player on which coordinates he is at.
I hope you understand what i mean, i have build a similar system, which is very very time-consuming. Considering the time you have to build the game, and how much queries it has to load from the database.
July 10th, 2006, 05:56 AM
Here is a good explanation of the theory of scrolling. But it is within the context of tile-based games:
You really should read all of those tutorials from the start. Someone already gave you this link.
:: My blip.fm tunes :: Web Design Feeds :: Web Dev Feeds :: CheatSheets :: PHP :: MySQL :: 13 Moon FB App.
"All matter is merely energy condensed to a slow vibration. We are all one consciousness experiencing itself - subjectively. There is no such thing as death, life is only a dream. We are the imaginations of ourselves."
- Bill Hicks
"Truth is hidden in the subtle nature of the heart of everything, although it is invisible. One cannot see it from inside and neither from the surface. One can only live and experience it."
- Heart Sutra
July 12th, 2006, 04:57 AM
maybe have a look at The scrolling game development kit.
The allegro game programming library also has functions for scrolling the screen.
The link b3n gave is good as well.
Vi Veri Veniversum Vivus Vici.