I've heard it used to be a bug that got fixed on 2021, but I'm not sure if its back or if it's an issue with my project. I'm trying to play music and sound effects at certain parts of my game, but it simply has 0 audio(and yes, I've checked the tab isn't muted)
when I open the browser's console, it throws this error:
And when I switch from any system in the build settings to WEB within unity, I get these:
The audios work fine on Windows, Linux and Android. I've tried only adding an iframe to my game once the user clicks a button on the page, thinking it could be the old issue where the browser blocks autoplays until the user click the page but it also didn't fix it.
Any ideas?
Related
I'm a newbie start making my game on Unity. Current stage is testing with Facebook and make a leader board from it.
Currently I'm using Unity 5.1.1f1 Personal Edition and Facebook SDK 7.0.2 beta because SDK 6.2.2 doesn't work with Unity 5.1.
I've watched this guy's tutorial (youtube's link) on how to integrate Facebook SDK with Unity. The Facebook login panel is very weird on my game screen (My game is made for iPhone portrait orientation). Below is the link to the screenshot.
http://i.stack.imgur.com/78qdh.png
You can see the Box is not responsive with screen size. If I didn't set game screen to "Maximize On Play" I can't press the "Login" button. I tried to find how to change its size or design but I've found none.
The second problem is I have tried build this project and deploy on my iPhone with iOS 8.4. Every time I press "Facebook Login" button, nothing came up and the app crashed.
I don't know this is beta problem or what but it's kinda basic function of this SDK.. just login and it's not functional as it should be.
That Legacy UI which you are seeing in Unity Editor has nothing to do with IOS build. your App will redirect to Facebook page/App for Login Authentication. So in editor you can just set game view to free aspects from top left and use login controls by resizing your game view. and regarding other issue please provide code which you are using for Login button. and try to log to know why is your game crashing.
I have a game based on libgdx that's hosted online.
It runs great on desktop but on mubile it depends on the phone's size.
The game is usually a bit too big and it's quite some trouble to try to make it fit the whole screen.
I have an option to put the game fullscreen, but I'd like for the game to automatically be fullscreen IF it's online AND on a mobile device.
However I haven't found anything to help me with that in libgdx's library, any ideas?
(edit, added code, I didn't show code in the first place because the solution may be in doin php redirection if there's nothing better... then I'd have 2 version of the code, one for desktop and the other one would automatically be fullscreen, for mobile... but having all the source code twice just for an "if" looks overkill to me...)
Here's how I can see wether the game runs on a web page, android or desktop :
(Gdx.app.getType() == ApplicationType.WebGL)
But more then knowing that it's on WebGL, I want to know if the web page ran from a cell phone or tablet or from a desktop.
thanks
I'm deploying a unity3d webplayer, and the new right panel (Ticker) in Facebook can prompt dialog in Like, and Recommend etc. However, those dialog gets cut off and hidden by the unity app. This seems like a known issue since early days, is there a good solution.
I have a fairly standard ASP.Net web application which is used via mobile safari on the iPhone.
Some users who have a link to the web application placed on their desktop via profile are reporting that when navigating between pages (which I do on the server with Response.Redirect after specific events or via standard anchor tags in other cases (no target specified)) that Safari opens a new window instead of reusing the existing window.
Because of this, any login token/cookie etc (i'm using the built-in ASP.Net membership stuff), is now gone for that new browser window and the login prompt is shown.
The problem doesn't happen every time, and I can't seem to replicate it on my device (but i'm not deploying the shortcut via profile)
As you can probably imagine, it's quite frustrating for the users to have to log in every time, and you can't fix an issue you can't replicate.
My question is, has anyone heard of this issue and/or know a workaround?
The app is NOT iPhone specific, that is, it is used in a full desktop browser as well, and the logins stay like you'd expect there - and the same window is reused repeatedly.
I've considered a few possibilities, but have been drawing a blank as far as what might be causing this or how I can resolve it.
Do you have any iPhone meta tags set (to remove the url bar or the toolbar, for instance?) If you do, the phone will assume it's a native web app, and urls will open in a new safari window, like they would for any other native app.
If you are taking advantage of using the web app in full screen mode (where it is bookmarked to the launch screen next to native apps) you can prevent it from jumping out of fullscreen mode by and in to safari replacing type links with javascript.
location.href = '/yourPath';
This is a nifty trick which even works if you are linking to an outside URL, like doing an OAuth to Facebook and back.
I have a blog post on this here: http://www.aaroncoleman.net/post/2011/07/29/Keeping-iPhone-Web-App-in-Fullscreen-mode-from-Homescreen-Launcher.aspx
Sorry for the long explanation. Thanks in advance to all who are taking their time.
I am an Ubuntu user who has set up Titanium Developer on a MacMini in order to build an app for the iPhone (and ultimately some other platforms).
Rather than having any local code built in, the app simply points to my website. To do that, all I needed to do was change Titanium's tiapp.xml file to include my website URL. I wrote no other code, nor did I need to include any other files. It simply compiled and ran in the emulator without a hitch.
I've got just one problem: I need to upload files to my website and Apple, as most of you know, has disabled the input field type=file. I've got it working in all other browsers. The action simply calls a php file and passes the file info.
If I didn't have an app, and someone was just manually navigating to my site with the iPhone's Safari browser, I could get around the problem by using CliqCliq, which is a very cool iPhone app. Basically, I use JavaScript window.open() to launch CliqCliq's QuickPic browser in a second Safari window. The user chooses a file; QuickPic uploads it; and the user is returned to the second Safari window that I launched with window.open(). The user closes the window and Safari returns them to the first window (i.e., my website).
The problem is that my website is being shown in my app. (By the way, I don't have my developer license yet, even though I signed up a few weeks ago, and I can't test this in the emulator because I can't install QuickPic into it, I assume.) I wanted to repeat the same steps, described in the previous paragraph, using an iFrame but that didn't seem to work (i.e., the iFrame was blank despite my designating a src). I also tried having a hidden window by using old-fashioned frames and setting the col-width to 0. That also did not work (i.e., Safari, if I recall correctly, opened a separate window).
I'm working a little blind, since I can't test anything on the iPhone, but I figure I have two options: I can either find a way to launch a QuickPic in an iFrame -or- I can find some way to incorporate the Apple toolkit file chooser into the Titanium app.
The problem with the first option -- but again, I don't know until I can try this on the iPhone -- is that I assume both apps (mine and CliqCliq's) could not run at the same time. Even if I had a hidden window, invisible iFrame, etc., the moment it launches QuickPic, I assume my app would quit(?).
The problem with the second option is that I don't have clue as to how to incorporate a file picker into my app by using Titanium (keeping in mind, everyone, that I know very little). Brian at CliqCliq has even offered to give me some code if I can't make Apple's file picker work but again, I'm not sure what to do next.
What do you folks think? What's the best method? And, what's the easiest thing for a simpleton to do?
Thanks.
<input type="file"> is not supported on the iPhone. You'll need to use Titanium's APIs, specifically the Media one (openPhotoGallery or showCamera).
As a side note, Apple reportedly rejects apps that are just a webview displaying a website. You may want to consider putting most of the app code in local storage and using AJAX to fetch content.