0 votes

I have a level stored in a separate scene which contains a TileMap and a Parallax Layer with 3 backgrounds. I instance that level in my main scene and just add it to the main scene parent (without any transform/offsetting).

When I make the player camera current, the backgrounds snap in place in a different location. The moment when the player camera is made current can be seen in the embedded gif.

enter image description here

To enable the player camera I have a method on my player class with the following two method calls:

func enable_camera():
  $Camera2D.limit_bottom = get_viewport_rect().size.y
  $Camera2D.current = true

What causes this behavior and how do I make the parallax backgrounds stay in the same places as in 2d scene view of the level?

My parallax layer motion scale x values are 1, 1.3, 1.5 . Just testing out those parallax layers for the first time, so I might be making some obvious mistake there.

Godot version 3.2.3
in Engine by (12 points)
edited by

did you have Mirroring??

Please log in or register to answer this question.

Welcome to Godot Engine Q&A, where you can ask questions and receive answers from other members of the community.

Please make sure to read How to use this Q&A? before posting your first questions.
Social login is currently unavailable. If you've previously logged in with a Facebook or GitHub account, use the I forgot my password link in the login box to set a password for your account. If you still can't access your account, send an email to webmaster@godotengine.org with your username.