I'm using facebook sdk 7.18.0 with Unity.
When I Build And Run, it opens in a browser window and this error is shown.
FileNotFoundExceptin: Could not load file or assembly 'Facebook.Unity.Canvas' or one of its dependencies
But when I run the unity project by clicking the Play button, it works fine.
Is this because, Facebook sdk for unity doesn't support running in the browser?
Appreciate any help to resolve this issue.
Related
I build on unity successfully
if I run and build on unity it works
but when I run index.html on browser from build folder;
first it has been blocked by CORS policy I created a chrome shortcut disables security
then I got
Uncaught ReferenceError: unityFramework is not defined at HTMLScriptElement.n.onload
I looked into it and some said that to disable compression but I got more errors:
dont know much about webGL and not sure if its a problem on unity or browser
pls help
ps:my unity version is 2020.1.0f1
Browsers won't load javascripts (.js files) from a file system directly. You have to host them on a server. Running the server on your local machine is fine (it's what Unity does).
Using Unity 5.2.3.
Using Android SDK Rev. 23.1.1
Using Google Play Game Services Package 0.9.31a (Services Version 8.4.0) for unity.
Using AdMob 3.0.1
Using Vungle (can't link, stackoverflow not allowing more than 2 links)
Note: I am using AdMob and Vungle separately with Play game services.
I have integrated Play game services with my app and that's work fine but whenever I try to include any other packages like AdMob or Vungle following happens.
AdMob: I have included the package, whenever Compile or Reopen the project play-services-basement-8.4.0 get deleted, Play Games Package has Resolve Client Jars and I am 100% sure that to blame.
Vungle: I configured Vungle Package as described in their documentation but again whenever I compile or reopen the Project several of Vungle files along with Vungle's main file Assets/Plugins/Android/libs/"android-support-v4.jar" get deleted. Again maybe Resolve Client Jars to blame.
In both cases above, I have manually copied the missing files and include them while Unity was closed but those were gone as soon as project opens.
I have issued a bug report with Unity but they said they can't help with 3rd party and they don't have issue on Unity's end.
Please Help and let me know any additional information, ill be happy to assist you.
Regards,
Since PlayServicesResolver just find dependency by rules and copy "NEWEST" to project folder and Google Play Games already have dependency on support-library-v4 23.1.+. , we can not resolve this within Unity Plugin.
I would recommend:
As work around, you can navigate to Assets>Google Play Services>Settings>uncheck-"enable background resolution"
and manually copy support library from
$sdk/extras/android/m2repository/com/android/support/support-v4/21.0.3/support-v4-21.0.3.aar
to
Assets/Plugins/Android, and run Assets>Google Play Services>Resolve Client Jars and keep 21.0.3"
This will leave "older version" of "android-support-v4.jar", but Google Play Games might not work with this version of "android-support-v4.jar".
Can you please try this?
Thanks!
I'm trying to implement mobile application using Ionic. I'm following this, but unfortunately logging in doesn't work on real device. It works fine in the browser and the emulator. I did every step from the tutorial, I did the tutorial 2-3 times and still get the same error.
I am logged in successfully on my device but then I see the following screen:
I already have both urls as redirect urls in my application settings in FB.
http://localhost:5000/oauthcallback.html
https://www.facebook.com/connect/login_success.html
I tried to debug OpenFB with alerts. I can see "cordova events" alert but then I have alerts on the first lines of loginWindow_loadStartHandler and loginWindow_exitHandler but they are not executed. I guess that the problem is there but I have no idea how to fix it.
if (runningInCordova) {
alert("cordova events");
loginWindow.addEventListener('loadstart', loginWindow_loadStartHandler);
loginWindow.addEventListener('exit', loginWindow_exitHandler);
}
Also I have some questions about Ionic and Phonegap.
I use Ubuntu and I am trying to build iOS and Android applications.
My application's structure is:
app/
hooks/
platforms/
plugins/
scss/
www/
Also I have InAppBrowser plugin:
cordova plugin add org.apache.cordova.inappbrowser
but this plugin is not part of app/www folder.
I am trying to build a phonegap application in their site. I made a .rar file of the app/www folder content and upload it. Everything seems to be fine. But in Phonegap site when I click PLUGINS, I see This application has no plugins. How should I add inappbrowser to the application, maybe that is the reason why my FB authentication doesn't work. If I build the whole app folder, again I see the same message - This application has no plugins.
So when create an archive file of the content for Phonegap, which folder I should archive - the whole app folder with all subfolders or only app/www? What is the correct flow? Also how crossplatform app should now about added plugins?
I ran into this issue today, if someone is still looking for the solution for this:
loginWindow.addEventListener('loadstart',
loginWindow_loadStartHandler);
is implemented in the js file, but the loadstart event never fires on my Android (but works on WindowsPhone cordova javascript app), instead i added:
loginWindow.addEventListener('loadstop',
loginWindow_loadStartHandler);
,which works on both Android and WP (with InAppBrowser 1.2.0), IOS test is still ahead.
I'm trying to test my Facebook integration for a FB Canvas game that I'm working on. When I launch the player I see the following message in the console:
loading dll: /rsrc/unity/lib/sdk_5.0/CanvasFacebook.dll
Failed downloading /rsrc/unity/lib/sdk_5.0/CanvasFacebook.dll
and if I look in the apache logs I see a request for /rsrc/unity/lib/sdk_5.0/CanvasFacebook.dll
I have the same problem using the 4.3.x version of the Facebook SDK.
I'm using Unity editor 4.3 and testing in Chrome on OSX.
Am I missing a DLL or a reference in MonoDevelop?
It sounds like you hit build and run for the Unity webplayer. This launches your game in a web browser hosted off your local filesystem. For security purposes, the SDK must be running on Facebook canvas when run in a web browser. You'll need to set up a Facebook app, instructions are here: https://developers.facebook.com/docs/unity
Alternatively, you can test in the Unity editor by hitting the play button.
I found sencha touch interesting andafter trying a default app in web, wanted to do some app for mobile devices. I was trying to wrap sencha touch with phonegap in eclipse for android by following the steps as mentioned in (this link) http://bgmemo.com/tutorial-sencha-touch-and-phonegap/. But as soon as i launch emulator a white screen with name android appears and within seconds i get error as "The Requested file was not found./android_asset/www/index.html(no such file directory) (file:///android_asset//www//index.html)". I am not getting errors in console. Any solutions plz?
1)I have already tried (this)http://www.robertkehoe.com/2013/01/fix-for-phonegap-connection-to-server-was-unsuccessful/
The entire Sencha touch project should be in www folder. Then the application will be launched. You can write script to compile your sencha touch project and then copy the project contents to www.
The directory 'www' is the entry for the hybrid applicatoin. Try this and let me know.