I am trying to mimic one game that was written for phaser 2. i am trying to mimic because it handles screen resizing and all that so perfectly and i want the same behaviour for phaser 3.
This is what I found in that game’s code i am trying to mimic.
Thanks for your suggestion. I need help with one more thing and this is the most important part. If you look at this game (tacit) , when you go to portrait mode, it doesn’t show the game in a portrait mode, but still shows in landscape mode even if you’re in a portrait mode. So if you’re in a portrait mode, you still have to rotate the screen in order to play.
It shows the game in portrait mode directly which just is bad because it shows the game in a bad shape. So is there a way to show the game in a portrait mode as on that game link I posted?
The way this is handled in that game link is the following code:
Using FIT is even worse. The only (at least a little bit help) was ENVELOP. Should i be using any other things aside FIT just to mimic the above website ?
Remove all the scale configuration except width and height. Check the game in portrait and landscape orientations. The whole game should fit within the viewport. Not an exact fit, but without overflowing. If it overflows, stop here and adjust the viewport.
If you want to use FIT or autoCenter, add those. Now the game should fit exactly within the viewport or container. If it doesn’t, stop here and adjust your HTML/CSS.
If you want to fake orientation lock (like Tacit), you can rotate the scene’s main camera “against” the orientation rotation. Start with scalemanager/orientation check.
I am still suffering from this. Could you help me correct the code? You can add whatever you want and just upload the updated version. I’d really appreciate it since I can’t still find the solution.
Yeah, Thanks @samme . I think I made it work. Last issue i got remaining is the following link: maybe you can take a look: Typeroots not working on ubuntu