Mario Bros. Type Scrolling

Welcome to our brand new Clickteam Community Hub! We hope you will enjoy using the new features, which we will be further expanding in the coming months.

A few features including Passport are unavailable initially whilst we monitor stability of the new platform, we hope to bring these online very soon. Small issues will crop up following the import from our old system, including some message formatting, translation accuracy and other things.

Thank you for your patience whilst we've worked on this and we look forward to more exciting community developments soon!

Clickteam.
  • Hey Clickteam,

    I have a few mini games that have the normal type of scrolling where the camera follows the player. This works great when I'm not scaling upwards or jumping on a spring. In Super Mario World, when Mario jumps on a spring, the camera is not attached to Mario. The screen is static and you can see Mario jump. I want to do something like this. What's the best way to center my scrolling not on my player but my player's progression? Thanks Clickers!

    Edit: Now that I think about it, do you think its as easy as deactivating one type of camera or repositioning the camera? Such as when Mario is flying with cape, the scrolling is set to player, but when Mario is jumping on spring, camera is set somewhere different. Maybe I'm way off, just thinking.

    Edited 2 times, last by Emerson3 (November 13, 2015 at 1:52 PM).

  • Yeah! I remember doing something like that a long time ago. I always had the game scrolling based on player position but only if flag 1 was on. If it was off it followed another object...i think it was a small cutscene i did when a hidden bandit shot an arrow or something. So the game scrolled with the arrow ìnstead. Not sure this is what you mean though :D so turning flag off stopped the scrolling

  • Hey Klownzilla,

    Yeah, something like that. I probably sound confusing. But I have a platforming level where the player scales upwards by jumping on platforms. There's one section where the player jumps from a spring onto a horizontally moving platform. Since the camera is set on the player, the jumping looks dizzying going up and down every time the player hits the spring. A flag would probably work great. Thanks Klownzilla!

  • I usually use a hidden object for camera. Set camera object to x of Player & set center of screen to camera object. That way you won`t affect the y-movement of the Player.
    Is that what you`re looking for?

  • I got very curious now, since i have played a lot of Super Mario :P
    What do you mean the camera does not follow when you use a spring? As far as I remember, the camera was pretty much always centered on Mario, as long as the camera would not go off the level (?)

  • I think you're referring to an "easing" type effect. The way I do it, is to have a seperate object called "Camera", set center display to the camera object, then set the "Camera" object's x and y positions, each individually with this:

    ( 8.99 * X( "Camera" ) + X( "Player Controller" ) ) / 9.99

    That above line is what is put into the "Set x coordinate" option, of the objects position. You do X and Y seperately. The "Player Controller" is whatever you're using to "move around" with, like your player sprite. This makes a nice smooth camera effect, so it's not super glued to your character.

  • Thanks for responding Kentronisk.

    Let's say on Super Mario World, you jump on a spring and don't press the jump button and Mario just bounces up and down repetitively. The camera(screen) doesn't go up and down with him. That's what I'm trying to accomplish when I'm on a Spring. The way I have the level built is the platform that the player is jumping to is not off the screen, just a little higher so that a spring is needed. It's a timed jump since the player is jumping on a moving platform. Many testers of my level get on the spring and jump a few times before they try to move forward, but when they jump the camera stays with the player and it just looks a little dizzying. I hope I make sense.

  • The flag approach might be simplest. Just have the screen Y position update only if your Flag is OFF. Then if the player happens to jump on a spring, turn the Flag ON. When you press jump AND Flag is ON (meaning you are in a "bouncing on spring" state), turn the Flag OFF. This would make it so any time you are in a bouncing on spring state, the camera will not update its Y position. But when you actually jump from a spring, the camera will update Y again.

    Please login to see this link.

Participate now!

Don’t have an account yet? Register yourself now and be a part of our community!