Camera scroll back to beginning?

TouchTiltGamesTouchTiltGames Member Posts: 1,162
edited November -1 in Working with GS (Mac)
Has anyone seen a tutorial on how to scroll the camera back to the default position after it's moved away? I have a game that after something happens off screen, it jarringly jumps back to the start, but I'm wondering if it's possible to have the camera scroll back instead of jumping back.

Cheers!

Comments

  • HachikoHachiko Member Posts: 330
    probably with interpolate instead of change attribute.
  • TouchTiltGamesTouchTiltGames Member Posts: 1,162
    Yeah just trying to figure out how to get it to scroll back instead of jump back with Interpolate.
  • TouchTiltGamesTouchTiltGames Member Posts: 1,162
    Anyone tried to scroll the camera back to the default location using Interpolate?
  • HachikoHachiko Member Posts: 330
    within an instance, interpolate camera.origin.X to an X of your choice and (if needed) interpolate camera.origin.Y to an Y of your choice.
    Set the time for fast or slow movement of the camera.
  • TouchTiltGamesTouchTiltGames Member Posts: 1,162
    Hey thanks Hachiko,

    I tried scene.Camera.Origin.Y To: scene.Camera.Origin.Y -600 (because I want it to scroll back down) but that still jumps down instead of scrolling. It's an Interpolate and on an instance...
  • TouchTiltGamesTouchTiltGames Member Posts: 1,162
    Ok nevermind I got it :) It wasn't working because I had other attributes on that instance.

    One question though - the camera will scroll down but keeps going lol, do you know how to make it stop or do I just have to get the -Y coordinates right to the botttom?

    Thanks a lot for your help.
  • TouchTiltGamesTouchTiltGames Member Posts: 1,162
    Ok nevermind, yeah I just had to specify the exact -Y pixel to get it to stop. Thanks again.
  • HachikoHachiko Member Posts: 330
    Glad it worked :)
Sign In or Register to comment.