how to make camera-window?

0 favourites
  • 6 posts
From the Asset Store
Get Ready for the New Wave of "Bottom Screen" Games!
  • Hello, can you please tell me how to make a camera for the player so that it does not move vertically when jumping? and if the player crossed the top or bottom border of the screen, only then was there an offset. (like in classic 8-bit games)

    approximately as in the screenshots:

    https://i.postimg.cc/QMXVCdSh/1233.gif[/img]

    https://i.postimg.cc/Kzjz7pdW/12332.gif[/img]

    Tagged:

  • Hi.

    You don't need to hang the scrolling behavior on the player. Create a separate sprite for the camera and move it relative to the player according to your conditions.

    Here are different examples with camera, see how it is implemented there.

    howtoconstructdemos.com/category/camera

  • Hey! Here's how to achieve that classic 8-bit camera lock in Construct 3:

    Clamp Camera Movement: Use the "System > Clamp" behavior on your camera's Y position. Set the minimum and maximum values to restrict vertical movement within the desired range.

    Track Player Horizontally: Use the "Lerping" function or similar to smoothly follow the player's X position while keeping the camera centered.

    Trigger Offset on Borders: When the player reaches the top or bottom borders (check Y position), adjust the camera's Y position slightly to create the offset effect.

    These are the basics, but you can adjust them for your specific needs. There might be tutorials online for "Construct 3 camera lock" that show this in detail.

    Good luck building your game!

  • Thank you, but I can’t achieve what I need.

    In general, there is a square (sprite, camera) I place the player inside it, so I need the player, when he touches any of the edges, to push this square. How can I do that?

    (by the way, I use construct 2)

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Thank you, but I can’t achieve what I need.

    In general, there is a square (sprite, camera) I place the player inside it, so I need the player, when he touches any of the edges, to push this square. How can I do that?

    (by the way, I use construct 2)

    Hi. I wrote above how to do it. But you were persistent and described your task more clearly.

    Here is my simple example.

    If you don't have C3, you can open this example even in the free version and transfer everything to C2.

    File c3p

  • Wow, thanks a lot!

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)