I made a layer “Restart” wicth include text, buttons menu, text, tiled…
When the player fail, i would like to scroll the layer “Restart” from the top of the screen and maybe, add a fade effect.
I didn’t found a way to do that.
I found the exemple of scroll layer for parallax but the scroll depends from the player. Not sure is the good method.
Thank you for your help.
Just put the “Reset” layer’s camera at the bottom, and when you want to show it make the layer visible and start moving the camera upwards. You don’t need the player position at all, just leave the camera there
I’m mega newbie.
I don’t understand, how can i add “Restart” layer’s camera at the bottom in Gdevelop 5 ?
I didn’t found add camera in the events “layers and camera” nor more how to add a mouvement.
It’s a bit hard to explain, as you have to know how layers and cameras work, and it is not explained in the wiki
Basically each layer is a different world with their custom cameras, you can have a game layer with all the world objects in it and a camera following the player, but have another layer with the GUI/Menu and it will remain in the same position because you aren’t moving the camera for this layer.
Here is an example (the menu layer is hidden in the editor), as you can see you don’t move the layer but move the camera in the opossite direction, a calssic trick used in 3D programming/OpenGL :
MoveLayer.zip (372 KB)
(I’ve taken some pictures from internet as is, don’t use them in your projects!)
You understood my request. Your example is great and helpfull.
Lizard-13, thank you !!!