Top Down Scrolling Game with background problem
debugdesign
Member Posts: 886
Hi Guys,
I have a top down scrolling game similar to Ikari warriors.
- My background image is 960 x 3200
- I have constrained my player to the centre of the screen
- when up/down/left right is pressed the bg scrolls in opposite direction
Problems:
- I need to stop the background before the blackness (I tried walls but didn't collide?)
- When scrolling up, when the background is at about 2000 px through it disappears
- When the background stops (if you can help) the actor is to carry on to the edge of the viewable area.
Any help is greatly appreciated. I have membership and can't wait to start submitting my games.
Thanks in advance
Ian
I have a top down scrolling game similar to Ikari warriors.
- My background image is 960 x 3200
- I have constrained my player to the centre of the screen
- when up/down/left right is pressed the bg scrolls in opposite direction
Problems:
- I need to stop the background before the blackness (I tried walls but didn't collide?)
- When scrolling up, when the background is at about 2000 px through it disappears
- When the background stops (if you can help) the actor is to carry on to the edge of the viewable area.
Any help is greatly appreciated. I have membership and can't wait to start submitting my games.
Thanks in advance
Ian
Comments
ie: constrain attribute: background.selfpositionX to 240 (which would be in the middle of the screen) since width is 480
Also, you can loop your background by going into the scene editor, and attributes, and click the checkbox so it "wraps position y, and wraps position x, then for your player you can either constrain the actor so it stays in between the screen or create walls, and uncheck moveable so they stay in one spot, and the actor can't move past the walls
Hope this helps! I couldn't quite understand all your questions, so hope this helps a bit
You can have bigger backgrounds, but you'll need to stack them next to each other.
I have also broken the background into sections of 960x1000. However I can move up through them but when my character move down again the initial panel has disappeared. Is there anyway of keeping it from disappearing?
Also, I am adding invisible elements over the top of trees and buildings to stop the player from running over the top of them but if they are all invisible its hard to see where they are.
I suppose I could make them all visible until I have completed the level build then go through them one by one changing the visible status to 'no' but is there a way to add them to a layer and then make the whole layer disappear?
Thanks again!
I have a few mines on the ground and they are on a layer that has the scrollable as 'no' and then in the actor properties I have set the movable to 'no' set it still moves up and down with the actor... is there any way of fixing this to the background as as it moves the mine moves?
Thanks