
-----------------------------------
NeutronX
Tue Nov 06, 2007 8:49 pm

Help with making the screen scroll
-----------------------------------
I am making a racing game that requires the cars to move to the right of the screen. When a car gets to a certain point, I want the screen to scroll to the side which means that I can see new parts of the map. It is 2-D and I want the screen to stop scrolling at a certain amount. For example if 2000 pixels where scrolled right, then I want it to stop scrolling. Can someone please send me a code to do tjhis for me? Thanks in advanced!

-----------------------------------
Euphoracle
Tue Nov 06, 2007 8:55 pm

RE:Help with making the screen scroll
-----------------------------------
Offset all your drawing, and if something is out of screen bounds, don't draw it at all.  Very simply really :p

-----------------------------------
NeutronX
Tue Nov 06, 2007 8:58 pm

Re: Help with making the screen scroll
-----------------------------------
I want the object which i can move myself more to the side and when it goes to a certain point it will scroll the screen

-----------------------------------
Euphoracle
Tue Nov 06, 2007 9:24 pm

RE:Help with making the screen scroll
-----------------------------------
Then check if it is past XX% of the screen, and if it is, increase your offset to scroll it, and if they are less than YY%|YY