Godot 4.3.stable
I have a vertical game area of 720x1080 and 2 parallax layers for the background layer and a layer of bushes. I used clamp to keep my player inside the game area so that they’re not able to leave the area when moving. There’s also camera2D on the player scene as a child of CharacterBody2D.
My issue now is that when the player moves on the x-axis the background will continue to move, revealing the space beyond the boundaries of the game area. But the player will be blocked from going any further than the clamped area. The player also can only move within the area defined by the clamp function I think? When they’ve walked a certain distance up/down they’ll get blocked from moving further.
The idea is that the player can walk infinitely along the grass area on the y-axis, with the background/bushes moving, but still stay within the confines of the bushes when moving on the x-axis. If I remove camera2D from the player scene, the viewport does stay within the game area, chracter cannot move out of the sides, but they will disappear from the top and bottom of the screen. There is also no parallax scrolling when moving.
I’ve no idea how to move on from here, this is my first attempt to make something outside of tutorials.
Any help is appreciated!