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

2017/9/7

Platform runner

saltyscrub saltyscrub

2017/9/7

#
Hi, I was wondering how I could make an endless platform runner. I was wondering how I could make the map endless and how I could make the character stick to the walls using gravity. I don't have much experience with Greenfoot so I would like help to have some help with this. The game I am trying to make is inspired by a mobile game called Gravity Guy
danpost danpost

2017/9/7

#
An endless map is just an unbounded world in which a tiled (in a matter of speaking) background image can be made to move with all actors considered to be in the game moving with the background. Usually, this happens when the main actor is found to be outside its given bounds and the adjustments are to correct the placement of that actor (so that it remains within the limits of the bounds set for it. This is essentially scrolling the world and the world object will usually perform that function. I have done some tutorials both on scrolling and on gravity which may give you some insight on how to proceed. They can be found here. Since I am not really familiar with Gravity Guy, I cannot say whether they give precisely what you need. I get the impression that gravity, in your case, may change its directional force to any one of the four ordinal directions. Adding a field to track which one is currently active and utilizing it to control gravity properly would be necessary, in that case.
You need to login to post a reply.