Hi guys, I am met with 2 issues today.
1) For my filechooser object, I can hide it with opacity, or throw it off the screen, then execute a .click javascript on my sprite to open a filechooser. However, how do I make it so, similar to the button itself, when you choose a file, it shows the filename. IE: image.png <-.. What I plan to do is to have a sprite to serve as the container, and add a label inside the container, and on image upload, I'll set the label's text to the image's name, <- Anyone have any idea what's the action for setting the text to the image name or if this is actually achievable?
2) How can I detect the layout of landscape? I want it so my game can only be played in portrait mode, but as I can't force a user to fullscreen, or have control over what browser they might be using (Safari doesn't support fullscreen). What I plan to do is if you're playing in landscape, I'll pause the game and have a sprite asking you to rotate your screen, once rotated it'll unpause the game.
Thanks!