Fixes #517 - Add a button with the ability to hide/single layers
The Supertux level editor did not have a button to hide individual layers. Now this button is at the end of each layer menu. The button does not appear on the selected layer, as it does not make sense to hide the selected layer. When someone decides to hide a layer other than the selected one and then switches to it, that layer is shown again. In addition, after hiding a layer, if the hidden layer menu is opened again, instead of the hide layer button, a show layer button appears. The default opacity of 0.5 was kept as the default, so that users do not find it strange or have to press this implemented button.
Closes #517
Co-authored-by: Filipe Oleacu [email protected]
Looking good, code-wise. Haven't tested it.
It works, but for some reason the background shifts in the Y axis (editor only)
Can you clarify this or send a screenshot?
Can you clarify this or send a screenshot?
https://github.com/user-attachments/assets/62af012f-3eec-409e-86b2-6c13484538f0
The sector size is calculated from the sizes of solid tilemaps. Is it possible that when you hide the only solid tilemap, then something gets goofed there?
https://github.com/user-attachments/assets/f9fa6d9e-5f7e-442e-9abe-b7528124bbba
I think the problem has nothing to do with what I did, but that it was already an old problem considering that this happens without my code, as you can see in the video above.
firstly, every single object has a "hide layer" option, which doesnt do anything.
https://github.com/user-attachments/assets/c420217c-10b8-4aad-8901-20c95b26f1b1
third. this pr has a issue regarding backgrounds moving based on a tilemap is solid or not. This issue is unique to this pr as it doesn't happen on latest master