How to make an scrolling layer (Easy way)

2

Attached Files

The following files have been attached to this tutorial:

.capx

Stats

4,412 visits, 6,073 views

Tools

Translations

This tutorial hasn't been translated.

License

This tutorial is licensed under CC BY 4.0. Please refer to the license text if you wish to reuse, share or remix the content contained within this tutorial.

Published on 17 Mar, 2017. Last updated 19 Feb, 2019

1) First you need to create an sprite, lets call it camera.

2) add ScrollTo behavior to Camera object.

3)Create a Global number named UpDown.

4)create events as below

5)Done.

.CAPX
  • 5 Comments

  • Order by
Want to leave a comment? Login or Register an account!
  • THANK YOU. The Capx really isn't necessary just follow the screenshot exactly. Now it makes total sense and I learned alot.

    YOU NEED A GLOBAL VARIABLE CALLED: UpDown

    It's the only thing not in the screenshot.

    Also note that lines 4/5 are "System -> Compare two values"

    THANKS DUDE :)

    • I also found it necessary to create a specific sprite called ScrollSizer -- which was a like a group for my many scrolling sprites.

      If that is off screen, disable bottom scroll.

      This example ONLY worked with one single scroll object, not many, as it would put ALL of them on the bottom. I suppose I could detect some offsets, or something -- there are many ways to handle this.

  • And how can you scroll horizontally? I tried to do the same but with the X instead of the Y and it doesn't work

  • error on the zip

  • error open the capx