Quantcast
Channel: Questions in topic: "facebook-sdk-unity"
Viewing all 786 articles
Browse latest View live

Unity: Is there any alternative to facebook SDK for facebook ads attribution?

$
0
0
We have a Unity mobile game. We will be showing ads for it on facebook audience network. Now in the past when we tried this, the CPI started out good and then got terrible.. Facebook have told us that to avoid this we need to have the facebook sdk installed in our game. ... But the facebook Unity SDK is the bane of my existence. In every project Ive added it to over the years, I have spent so many days bashing my face against the brick wall of getting it to build and run, and when it does the weird workaround solution is incredibly fragile. ... My question is.. Do we really need the SDK? What do devs using game engines without an SDK provided by facebook do? Is there an API we can call? Surely the SDK itself is calling some api to do the attribution which allows facebook to optimise the CPI for the ads. Can we just call that? ... At this point I would try any alternative.

WebGL Facebook SDK error, “FB is not defined”

$
0
0
Hello, I’m having trouble integrating facebook login in a game I'm working on and I truly don't know what I'm doing wrong, it works fine when I test it on the editor, but it throws an error when I try the build that says "exception thrown: ReferenceError: FB is not defined". this is my script: using System.Collections; using System.Collections.Generic; using UnityEngine; using Facebook.Unity; using UnityEngine.UI; public class fbLogin : MonoBehaviour { public Text name; public Image image; public Text Mail; void Awake() { if (!FB.IsInitialized) { FB.Init(SetInit, OnHideUnity); } else { FB.ActivateApp(); } } void SetInit() { if (FB.IsInitialized) { FB.ActivateApp(); Debug.Log("FB INITIALIZED"); } else { Debug.Log("ERROR UNITIALIZING"); } } void OnHideUnity(bool IsGameShown) { if (!IsGameShown) { Time.timeScale = 0; } else { Time.timeScale = 1; } } public void FBlogin() { List permissions = new List(); permissions.Add("public_profile"); FB.LogInWithReadPermissions(permissions, authCallBack); } void authCallBack(IResult result) { if (result.Error != null) { Debug.Log(result.Error); } else { if (FB.IsLoggedIn) { Debug.Log("LOGGED TO FB"); //gets Info FB.API("/me?fields=first_name,email", HttpMethod.GET, displayUserName); FB.API("/me/picture?type=square&height=128&width=128", HttpMethod.GET, displayProfilePic); } else { Debug.Log("NOT LOGGED TO FB"); } } } void displayUserName(IResult result) { if (result.Error != null) { Debug.Log(result.Error); } else { name.text = result.ResultDictionary["first_name"].ToString(); Mail.text = result.ResultDictionary["email"].ToString(); } } void displayProfilePic(IGraphResult result) { if (result.Texture != null) { image.sprite = Sprite.Create(result.Texture, new Rect(0,0,128,128),Vector2.zero); } else { Debug.Log("Error getting image"); } } } I don't know if it is a mistake on my script or if I have to setup something else on the facebook developers site. I'm using Unity 2020.10f1, Facebook sdk v8.1.0.

Regarding Facebook Friends Profile Pictures.

$
0
0
Background: I am creating a Leaderboard of Facebook friends in unity. Question: Can we download and save the images of Facebook Friends on the device of the user for the purpose of reuse? I would like to store the images of the FBFriends on the user's device so that there is no need to download the same pictures everytime the game is restarted. Is it legal to do so? I asked the same question in Facebook Developers forums but I did not get any response. Kindly guide me. How do devs build a leaderboard of Facebook friends normally? Thankyou.

How do I change my email address when I log in with Facebook?

$
0
0
Hi. I started working with Unity some time ago and made my account through Facebook. I recently had an issue where I lost access to my main email address and had to update it across services that I use. I've changed it on Facebook, but when I use it to log into Unity, it still shows my old one. When I go into settings to change it, it asks me to confirm my Unity ID password. Since I always log with Facebook, I don't even know if I've ever been asked to make such. If I try to reset the password, it offers to do it using my old email, so it's an enchanted circle. I have SMS authentication activated but that doesn't seem to help me. I filed a request to support 12 days ago and I haven't heard back. I thought this would be some simple issue they can assist with, but now I'm not sure. Should I just make another account and start over? I don't have anything tied to it YET. I have assets I want to activate but I can't do it before I have a secure account. Any advice would be appreciated, thanks.

Trouble Getting Facebook Profile Picture

$
0
0
I'm working with the Facebook SDK. I am trying to grab a user's profile picture. I use the following code:

if (FB.IsLoggedIn) { FB.API("me/picture?type=med", HttpMethod.GET, StorePicture); }
Where StorePicture is some callback function. When I do this I get a generic rainbow picture, which I assume means I am hitting the wrong endpoint. As far as I can tell, either "me" is incorrect (which makes sense) or I need an access token. If I need to hit a different endpoint, what do I replace "me" with, and if I need an access token, where do I get it and where do I put it? Any help would be appreciated.

Unity Animation timeline. Really?!,Animation timeline.. serious?!

$
0
0
Hi, I try to create animations (2D in his case, but I think it is all the same). My timeline reads whis way: 0.07, 0.08, 0.09, 0.10, 0.11, 1.0. Something crazy happens here? I want to move a key to 0.2, but I can not. Who was a crazy head, that created this one?

I am Facing lot of crashes in m game how to fix it?

$
0
0
Crash Details Type : java.lang.Error java.lang.Error: FATAL EXCEPTION [main] Unity version : 2018.3.3f1 Device model : OPPO CPH1989 Device fingerprint: OPPO/CPH1989/OP4C4BL1:10/QP1A.190711.020/1594884000:user/release-keys Caused by at com.unity3d.player.ReflectionHelper.nativeProxyInvoke (Native Method) at com.unity3d.player.ReflectionHelper.a (Unknown Source) at com.unity3d.player.ReflectionHelper$1.invoke (Unknown Source:6) at java.lang.reflect.Proxy.invoke (Proxy.java:1006) at $Proxy3.run (Unknown Source) at android.os.Handler.handleCallback (Handler.java:883) at android.os.Handler.dispatchMessage (Handler.java:100) at android.os.Looper.loop (Looper.java:237) at android.app.ActivityThread.main (ActivityThread.java:7830) at java.lang.reflect.Method.invoke (Native Method) at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run (RuntimeInit.java:492) at com.android.internal.os.ZygoteInit.main (ZygoteInit.java:1040) at CPU at 11 at 11 at 10 at 2.5 at 2 at 1.7 at 1.4 at 1 at 0.8 at 0.8 at 0.8 at 0.7 at 0.7 at 0.5 at 0.4 at 0.2 at 0.2 at 0.2 at 0.2 at 0.2 at 0.1 at 0.1 at 0.1 at 0.1 at 0.1 at 0.1 at 0.1 at 0.1 at 0.1

Imported Facebook SDK and can't install cocoa pods

$
0
0
Help... I Imported the Facebook SDK and my unity project is under the iOS platform. But it won't let me do anything now... A window pops up and says "Installing Cocoa pods.... gem install cocoapods --user-install WARNING: You don't have /Users/reidtaylor/.gem/ruby/2.6.0/bin in your PATH," Please Help! Thanks!

Get Facebook Profile Picture Permissions From Dev Token

$
0
0
I am trying to get a user's facebook profile picture, To do this, I call this function to log in:

public static void FacebookLogin(Action onLogInRecieved) { var permissions = new List() { "public_profile", "email", "user_friends" }; FB.LogInWithReadPermissions(permissions, onLogIn); Inst.onLoggedInAction += onLogInRecieved; }

where the relevant details are the permissions which include "public_profile" which should allow access to a user's profile picture. When I click the button that calls this code in the Unity editor, I am given a pop up that takes me to a web page where I can generate an access token. However, the permissions I get from the generated access token are only for my name and *avatar* (some cartoony picture) not my profile picture. How can I generate a token that allows me to get my profile picture?

Do i need a separate database when making a game in Unity3D With Android Games services, Apple Game Center and Facebook

$
0
0
I am creating a Mobile game in unity3D with Android Games services, Apple Game Center, and Facebook and I was wondering if I need a separate database to store different variables like boosters, currency, etc, or can I use these services to do this?

Could not resolve all files for configuration unity

$
0
0
Hi Guys. I hope you can help me. I am using some plugin for a speech recognizer. And so far it was working. But today I imported Facebook and GameAnalytics SDK and unity start to give me "Could not resolve all files for configuration unity" while build the game. When I removed the speech recognizer plugins, The error disappear. So, What can I do to overcome this problem ? Here is the full error : [link text][1] [1]: /storage/temp/180096-error.pdf

CommandInvokationFailure: Gradle build failed. Unity Build

$
0
0
Note: D:\Tahir\New\ALL\Temp\gradleOut\unityLibrary\src\main\java\com\unity3d\player\UnityPlayerActivity.java uses or overrides a deprecated API. Note: Recompile with -Xlint:deprecation for details. [:com.facebook.android.audience-network-sdk-6.4.0:] C:\Users\HP\.gradle\caches\transforms-2\files-2.1\fbc1e4faba4192a1e90fb232d4073c82\AndroidManifest.xml:5:5-51 Error: Missing 'package' key attribute on element package at [:com.facebook.android.audience-network-sdk-6.4.0:] AndroidManifest.xml:5:5-51 [:com.facebook.android.audience-network-sdk-6.4.0:] C:\Users\HP\.gradle\caches\transforms-2\files-2.1\fbc1e4faba4192a1e90fb232d4073c82\AndroidManifest.xml Error: Validation failed, exiting FAILURE: Build failed with an exception. * What went wrong: Execution failed for task ':launcher:processReleaseManifest'. > Manifest merger failed with multiple errors, see logs * Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights. * Get more help at https://help.gradle.org BUILD FAILED in 12s Picked up JAVA_TOOL_OPTIONS: -Dfile.encoding=UTF-8 UnityEngine.GUIUtility:ProcessEvent (int,intptr) ---------- ---------- CommandInvokationFailure: Gradle build failed. C:\Program Files\Java\jdk1.8.0_191\bin\java.exe -classpath "C:\gradle-5.5.1-all\gradle-5.5.1\lib\gradle-launcher-5.5.1.jar" org.gradle.launcher.GradleMain "-Dorg.gradle.jvmargs=-Xmx4096m" "assembleRelease" stderr[ Note: D:\ADS\Ads\Ads\Temp\gradleOut\unityLibrary\src\main\java\com\unity3d\player\UnityPlayerActivity.java uses or overrides a deprecated API. Note: Recompile with -Xlint:deprecation for details. [:com.facebook.android.audience-network-sdk-6.4.0:] C:\Users\HP\.gradle\caches\transforms-2\files-2.1\fbc1e4faba4192a1e90fb232d4073c82\AndroidManifest.xml:5:5-51 Error: Missing 'package' key attribute on element package at [:com.facebook.android.audience-network-sdk-6.4.0:] AndroidManifest.xml:5:5-51 [:com.facebook.android.audience-network-sdk-6.4.0:] C:\Users\HP\.gradle\caches\transforms-2\files-2.1\fbc1e4faba4192a1e90fb232d4073c82\AndroidManifest.xml Error: Validation failed, exiting FAILURE: Build failed with an exception. * What went wrong: Execution failed for task ':launcher:processReleaseManifest'. > Manifest merger failed with multiple errors, see logs * Try: Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. Run with --scan to get full insights. * Get more help at https://help.gradle.org BUILD FAILED in 12s Picked up JAVA_TOOL_OPTIONS: -Dfile.encoding=UTF-8 ] stdout[ > Task :unityLibrary:preBuild UP-TO-DATE> Task :launcher:preBuild UP-TO-DATE> Task :unityLibrary:preReleaseBuild UP-TO-DATE> Task :unityLibrary:checkReleaseManifest> Task :launcher:prepareLintJar> Task :unityLibrary:processReleaseManifest> Task :unityLibrary:compileReleaseAidl NO-SOURCE> Task :unityLibrary:packageReleaseRenderscript NO-SOURCE> Task :unityLibrary:compileReleaseRenderscript NO-SOURCE> Task :unityLibrary:generateReleaseBuildConfig> Task :unityLibrary:generateReleaseResValues> Task :unityLibrary:generateReleaseResources> Task :unityLibrary:packageReleaseResources> Task :launcher:preReleaseBuild> Task :launcher:compileReleaseAidl NO-SOURCE> Task :launcher:compileReleaseRenderscript NO-SOURCE> Task :launcher:checkReleaseManifest> Task :launcher:generateReleaseBuildConfig> Task :launcher:generateReleaseSources> Task :launcher:mainApkListPersistenceRelease> Task :launcher:generateReleaseResValues> Task :launcher:generateReleaseResources> Task :unityLibrary:generateReleaseRFile> Task :unityLibrary:prepareLintJar> Task :unityLibrary:generateReleaseSources> Task :unityLibrary:javaPreCompileRelease> Task :launcher:mergeReleaseResources> Task :launcher:createReleaseCompatibleScreenManifests> Task :unityLibrary:compileReleaseJavaWithJavac> Task :launcher:processReleaseManifest FAILED See http://g.co/androidstudio/manifest-merger for more information about the manifest merger. Deprecated Gradle features were used in this build, making it incompatible with Gradle 6.0. Use '--warning-mode all' to show the individual deprecation warnings. See https://docs.gradle.org/5.5.1/userguide/command_line_interface.html#sec:command_line_warnings 18 actionable tasks: 18 executed ] exit code: 1 UnityEditor.Android.Command.WaitForProgramToRun (UnityEditor.Utils.Program p, UnityEditor.Android.Command+WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg) (at :0) UnityEditor.Android.Command.Run (System.Diagnostics.ProcessStartInfo psi, UnityEditor.Android.Command+WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg) (at :0) UnityEditor.Android.Command.Run (System.String command, System.String args, System.String workingdir, UnityEditor.Android.Command+WaitingForProcessToExit waitingForProcessToExit, System.String errorMsg) (at :0) UnityEditor.Android.AndroidJavaTools.RunJava (System.String args, System.String workingdir, System.Action`1[T] progress, System.String error) (at :0) UnityEditor.Android.GradleWrapper.Run (UnityEditor.Android.AndroidJavaTools javaTools, System.String workingdir, System.String task, System.Action`1[T] progress) (at :0) Rethrow as GradleInvokationException: Gradle build failed UnityEditor.Android.GradleWrapper.Run (UnityEditor.Android.AndroidJavaTools javaTools, System.String workingdir, System.String task, System.Action`1[T] progress) (at :0) UnityEditor.Android.PostProcessor.Tasks.BuildGradleProject.Execute (UnityEditor.Android.PostProcessor.PostProcessorContext context) (at :0) UnityEditor.Android.PostProcessor.PostProcessRunner.RunAllTasks (UnityEditor.Android.PostProcessor.PostProcessorContext context) (at :0) Rethrow as BuildFailedException: Exception of type 'UnityEditor.Build.BuildFailedException' was thrown. UnityEditor.Android.PostProcessor.CancelPostProcess.AbortBuild (System.String title, System.String message, System.Exception ex) (at :0) UnityEditor.Android.PostProcessor.PostProcessRunner.RunAllTasks (UnityEditor.Android.PostProcessor.PostProcessorContext context) (at :0) UnityEditor.Android.PostProcessAndroidPlayer.PostProcess (UnityEditor.BuildTarget target, System.String stagingAreaData, System.String stagingArea, System.String playerPackage, System.String installPath, System.String companyName, System.String productName, UnityEditor.BuildOptions options, UnityEditor.RuntimeClassRegistry usedClassRegistry, UnityEditor.Build.Reporting.BuildReport report) (at :0) UnityEditor.Android.AndroidBuildPostprocessor.PostProcess (UnityEditor.Modules.BuildPostProcessArgs args, UnityEditor.BuildProperties& outProperties) (at :0) UnityEditor.PostprocessBuildPlayer.Postprocess (UnityEditor.BuildTargetGroup targetGroup, UnityEditor.BuildTarget target, System.String installPath, System.String companyName, System.String productName, System.Int32 width, System.Int32 height, UnityEditor.BuildOptions options, UnityEditor.RuntimeClassRegistry usedClassRegistry, UnityEditor.Build.Reporting.BuildReport report) (at <4a1b55d6b009421a9ad1d16b54b782d5>:0) UnityEngine.GUIUtility:ProcessEvent(Int32, IntPtr)

FB Data Access Expiration bug,Facebook Data Access Expiration bug

$
0
0
For some context, we use the fb-unity SDK (8.1.1) wrapper in our project and recently received a user complaint where they were not able to view some of their friends. We use the **user_friends** friends permission to fetch this list from FB. On further investigation, and using the Access Token Debugger tool from FB we found that apart from Access Token expiration another field called Data Access handles this which has a different expiration from the token, and this field had expired for these users. The suggested way to fix this is to call **reauthorizeDataAccess()**, but that is only part of the native SDKs and there is no way to call it from the wrapper SDK. There is also an issue for this https://github.com/facebook/facebook-sdk-for-unity/issues/214 Ideally, the SDK should handle refreshing this or giving a way to know if this field has expired, but we couldn't find anything in their documentation. Also, relogin refreshes the date in IOS, but not on Android. On Android, it just refreshes the token without refreshing the data expiration field. Shouldn't this be a much more widespread problem? Are we doing something wrong, or is there a workaround for this?

Follow updated guidelines to unblock Facebook marketplace.

$
0
0
The best thing is to find out the updated guidelines to unblock Facebook marketplace. In the current time, the social media marketplace is being used for ecommerce businesses. It is the most relevant place where an online entrepreneur can place their product's image to let the customers know about those. But Facebook users must consider the marketplace guidelines to avoid the need for an unlocking process. Social media has its policies that have to be executed by users to keep the system on right track and protect from an unexpected data breach. In addition to these, users may also communicate with the Facebook support team for more efficient tips to manage the marketplace. https://www.7qasearch.net/blog/unblock-my-marketplace-on-facebook/

Facebook SDK Unity : Facebook file is missing in Assets/Plugins/iOS

$
0
0
I have successfully implemented the facebooksdk for android and am now trying to build my project for iOS using xcode but there was an error. The error was that I was missing a FBSDKShareKit file. I searched in the Unity Editor and i actually was missing the file. I googled it up and its suppose to be in Assets/Plugins/iOS/Facebook but I am missing that particular Facebook folder. Any advice on this? I've followed instructions on here : https://developers.facebook.com/docs/unity/getting-started/ios i even reimported the facebook sdk unity package. there is no such file in Assets/Plugins/iOS. error: ![error message][1] [1]: /storage/temp/154624-screenshot-2020-03-20-at-45547-pm.png

Facebook SDK for Unity/Android: Change Activity (Class) Name without affecting live app?

$
0
0
I'm migrating an existing Android game that's made in Cocos2d-x into Unity. The existing Cocos2d-x game uses the Facebook SDK for logging in. In the Facebook Developer dashboard, under Android, the Class (Activity) Name is set to `com.domain.appname.GameActivity`.

I'm currently testing the Unity version. The problem is that in order to test the Facebook SDK for Unity, I need to change the Class Name to `com.facebook.unity.FBUnityDeepLinkingActivity`. The existing Cocos2d-x app is live, so if I change the Class Name, I assume the Facebook SDK will stop working for the live app.

How would I go about changing the Class Name without affecting the live app? Is it possible to have multiple Class Names?

Facebook sdk 11.0.0 not working on android device

$
0
0
Hey I'm using Unity 2019.4.17 and Facebook sdk 11.0.0 and I'm trying to make a simple login system to my mobile game. I did everything's according to this guide: https://www.youtube.com/watch?v=wrtkxIr8u5s&t=521s and it seems that everything's working fine on the editor, I'm gating message on the console that I'm logged in. The problem is when I'm trying to test my game on my android phone and the game run perfectly but nothings happen when I'm trying to login to Facebook its seems that Facebook didn't even initialize I really tried everything

How to Publish Game to Facebook Instant

$
0
0
I've been looking everywhere and can't find any updated information about this, all the posts and videos are from 3+ years ago. Is there a way to publish to Facebook Instant without using Unity Tiny? What is Unity Tiny, everywhere I've seen this question asked, people say you need Unity Tiny, but I've been able to publish to WebGL just fine. So I'm wondering if that's outdated information? I'm also not sure what SDK I need, i hear there's a Facebook Instant SDK but I can't find it, only Facebook SDK. Does Facebook SDK work fine? Also, does anyone know where I can get information on how to implement Facebook features, such as friend list and online play? Is that included in the SDK? I searched and searched but the information out there is scarce at best. Thanks.

Facebook Data deletion for Unity game

$
0
0
I'm trying to implement facebook login in my unity game using the facebook sdk. In order to test this, I need to change the status of my app in fb developers site from "development" to "live". But in order to do so, fb is asking me to update "Data Deletion Request Callback" field (screen shot below). Can someone please help with this as I don't know how to implement this? The link to "Learn more" goes [here][1] ![alt text][2] [1]: https://developers.facebook.com/docs/development/create-an-app/app-dashboard/data-deletion-callback [2]: /storage/temp/185060-datadeletion.png

What are quick steps to for cash app dispute process approach ?

$
0
0
It is imperative to execute quick steps to approach the claimed cash app dispute process. Cash app customers may initiate by clicking on the activity tab available on the cash app screen. Further, they will require choosing the transactions in the question section. In case of tech problems, they can talk to the support service team without any hassles. Such an effort will help them to overcome unexpected troubles.
Viewing all 786 articles
Browse latest View live


<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>