Should I scale the elements of my menus in my game with % or px (javascript, canvas oop game development)?
So, I'm currently developing a game with vanilla JS (and my libraries), using the JS canvas, of course. For menus, title screens, and the like, HTML elements are usually used.
For example, if I'm programming a start button for the title screen, should I do it with width: 100x … or width: 50% (of the canvas). I want it to look good on all screens, and I also want to publish it for mobile later (React?), so what's the best way to do this?
Mfg White Bread
Hello Weissbrot965,
In percent, so that the corresponding elements responsive to the different screen sizes.
Ben
Don’t you think this might be distorted on some screens or look like that? Mf