This site requires JavaScript, please enable it in your browser!
Greenfoot back

Report as inappropriate.

polle presents ...


Side scroll demo

Some scenarios require the background to move.
Here is a demo that shows gow to side-scroll the
background image.
If you need this for your own scenario, download the source and have a look.

12998 views / 1176 in the last 7 days

5 votes | 0 in the last 7 days

Tags: demo with-source sidescroll

This scenario is a member of: Scrolling games

open in greenfoot
Your browser does not support the canvas tag.
A new version of this scenario was uploaded on Mon Aug 04 09:07:26 UTC 2008


I look at the code and i somewhat understand it. Yet i change something like the dimension (I change it all the way through) it compiles, i look at the scenario and get a gray Run, Act, Pause set and the game is like a 1mm square box. Do you know whats wrong? And the only way to get it back to normal is to delete the class and re-copy original.


Nevermind. I was didnt change the image extension from .gif to .jpg. Spent 1 and a half weeks on it then the dude next to me was like you need to change the extension....


@lirki At one of my scenarios I got the same mistake with this squarebox. For some reason everything works in Greenfoot. But as soon as I export it to .jar there is this stupid square instead of my game. Maybe it's a bug in Greenfoot


@GameCode, best thing to do is create a new discussion (Discuss tab at the top of the gallery page) and talk about the problem, and give a link to your scenario. Probably it is actually something that you are doing wrong...


Hi. I found this scenario very useful, but I can't figure out, what should I change in code to make background scroll vertically. Can anyone help, please?


easiest scrolling demo I've seen yet


I want this code: Where do I find him?

Want to leave a comment? You must first log in.

Who likes this?

fejfo SoldierBob Sydberg ardeearam davemib123