Facebook as an extension

Excellent. Thanks! I’ve created a ticket to track this: https://github.com/defold/extension-facebook/issues/4

@Mathias_Westerdahl has been working on this extension recently to update it and move it from the engine to an extension.

2 Likes

Yes, this is our old (internal) example. We’ve merely moved the code outside of the engine.
What permissions you wish to use is individual per app basis.

In the Facebook official documentation they’re using publish_to_groups: doc

And here is a list of their supported permissions

2 Likes

Thanks. I updated to use publish_to_groups -permissions and I no longer get the error messages. Using the show_dialog() function only seems to make a successful login to facebook but did not open the share to feed -dialog as I expected.

Is there something I’m missing to make a share to facebook feed working?

1 Like

Ok, good that it worked.

As for sharing, when pressing the “Share” button in the test project, you’ll invoke this code:

First:


then it will call this function:

3 Likes

We made small stability improvements for the facebook extension.
For the old facebook (4.x) extension the latest version is 1.6
https://github.com/defold/extension-facebook/archive/1.6.zip
For the new extension is 2.2.5:
https://github.com/defold/extension-facebook/archive/2.2.5.zip

3 Likes

The new release 2.2.7 of Facebook extension with Deferred Deep Linking functionality.

4 Likes

We just made a pre-release of a new version of the Facebook extension available for testing. The new version is based on the latest Facebook SDK version 5.9.0. It fixes login issues on iOS 13 (although this is also partially dependant on the upcoming Defold 1.2.164 release).

Please help us test the extension by adding the following two dependencies to your game.project file:

3 Likes

tried to build LyL with this dependencies and got:

list of all dependencies
2019-11-06_14-22-39

Seems, with FB 2.2.7 and extension-gps “master” the same. Previous workable build I’ve made with FB 1.4

Thanks. Could I please ask you to lock down more of your dependency versions? It’s very hard to promise any kind of stability when you depend on master.zip since that can change without notice. Please use these instead:

Ok, thanks, will try build with

Tried. The same result.

The bundle complete only if I remove admob extension. Seems admob (https://github.com/Lerg/extension-admob/) is compatible only with old Facebook extension :\

Let me try a couple of things here as well.

1 Like

Yeah, so both the Facebook extension and the AdMob extension use and include a jar for com.android.support.customtabs. This and the other support libs should probably be moved to a base extension.

@Dragosha can you please share the list of dependencies you have when AdMob and Facebook works together?

2 Likes

My latest app on store builded with this dependencies:
https://github.com/britzl/defold-googleanalytics/archive/master.zip,
https://github.com/PlayFab/LuaSdk/raw/master/Defold/PlayFabClientSdk.zip,
https://github.com/AGulev/defreview/archive/master.zip,
https://github.com/britzl/monarch/archive/2.15.1.zip,
https://github.com/defold/extension-facebook/archive/v1.4.zip,
https://github.com/Lerg/extension-admob/archive/master.zip,
https://github.com/defold/extension-firebase-core/archive/master.zip,
https://github.com/defold/extension-gpgs/archive/master.zip,
https://github.com/defold/extension-gps/archive/master.zip,
https://github.com/defold/extension-iap/archive/master.zip

and also https://github.com/Dragosha/defoldgamecenter as project folder.

1 Like

Which list of dependencies need to build latest release FB extension now?
I’ve tried this as mention in updated docs:

https://github.com/defold/extension-facebook/archive/2.2.7.zip,
https://github.com/defold/android-base-extensions/releases/download/1.0.0/support-v4-27.0.2.zip,
https://github.com/defold/android-base-extensions/releases/download/1.0.0/support-v7-27.0.2.zip

list of all included (removed admob for pure experiment)
https://github.com/britzl/defold-googleanalytics/archive/master.zip,
https://github.com/PlayFab/LuaSdk/raw/master/Defold/PlayFabClientSdk.zip,
https://github.com/AGulev/defreview/archive/master.zip,
https://github.com/britzl/monarch/archive/2.15.1.zip,
https://github.com/defold/extension-gpgs/archive/17.0.0.zip,
https://github.com/defold/extension-iap/archive/1.0.1.zip,

result:

Failed building Android resources to R.java: warning: string 'com_facebook_loginview_logged_in_using_facebook_f1gender' has no default translation.
C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.cardview-v7-27.0.2\values\values.xml:7: error: Attribute "cardBackgroundColor" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.cardview-v7-27.0.2\values\values.xml:7: error: Attribute "cardCornerRadius" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.cardview-v7-27.0.2\values\values.xml:7: error: Attribute "cardElevation" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.cardview-v7-27.0.2\values\values.xml:7: error: Attribute "cardMaxElevation" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.cardview-v7-27.0.2\values\values.xml:7: error: Attribute "cardUseCompatPadding" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.cardview-v7-27.0.2\values\values.xml:7: error: Attribute "cardPreventCornerOverlap" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.cardview-v7-27.0.2\values\values.xml:7: error: Attribute "contentPadding" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.cardview-v7-27.0.2\values\values.xml:7: error: Attribute "contentPaddingLeft" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.cardview-v7-27.0.2\values\values.xml:7: error: Attribute "contentPaddingRight" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.cardview-v7-27.0.2\values\values.xml:7: error: Attribute "contentPaddingTop" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.cardview-v7-27.0.2\values\values.xml:7: error: Attribute "contentPaddingBottom" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:3: error: Attribute "drawerArrowStyle" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:4: error: Attribute "height" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:5: error: Attribute "isLightTheme" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:6: error: Attribute "title" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:71: error: Attribute "navigationMode" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:78: error: Attribute "displayOptions" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:86: error: Attribute "subtitle" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:86: error: Attribute "titleTextStyle" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:86: error: Attribute "subtitleTextStyle" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:86: error: Attribute "icon" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:86: error: Attribute "logo" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:86: error: Attribute "divider" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:86: error: Attribute "background" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:86: error: Attribute "backgroundStacked" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:86: error: Attribute "backgroundSplit" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:86: error: Attribute "customNavigationLayout" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:86: error: Attribute "homeLayout" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:86: error: Attribute "progressBarStyle" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:86: error: Attribute "indeterminateProgressStyle" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:86: error: Attribute "progressBarPadding" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:86: error: Attribute "itemPadding" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:86: error: Attribute "hideOnContentScroll" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:86: error: Attribute "contentInsetStart" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:86: error: Attribute "contentInsetEnd" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:86: error: Attribute "contentInsetLeft" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:86: error: Attribute "contentInsetRight" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:86: error: Attribute "contentInsetStartWithNavigation" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:86: error: Attribute "contentInsetEndWithActions" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:86: error: Attribute "elevation" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:86: error: Attribute "popupTheme" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:90: error: Attribute "closeItemLayout" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:91: error: Attribute "initialActivityCount" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:91: error: Attribute "expandActivityOverflowButtonDrawable" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:92: error: Attribute "buttonPanelSideLayout" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:92: error: Attribute "listLayout" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:92: error: Attribute "multiChoiceItemLayout" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:92: error: Attribute "singleChoiceItemLayout" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:92: error: Attribute "listItemLayout" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:92: error: Attribute "showTitle" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:93: error: Attribute "srcCompat" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:93: error: Attribute "tint" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:93: error: Attribute "tintMode" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:107: error: Attribute "tickMark" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:107: error: Attribute "tickMarkTint" has already been defined

C:\Users\isunt\AppData\Local\Temp\bob_bundle_tmp1590016241240099912\extensions\facebook\com.android.support.appcompat-v7-27.0.2\values\values.xml:107: error: Attribute "tickMarkTintMode" has already been defined

....
removed for post size resone

Latest version is 2.3.1. It depends on:

I will make a separate post later today about changes to the Android base extension dependencies to bring some clarity. Sorry for the temporary confusion.

2 Likes

it works!

2 Likes

Build error when tried to make iOS bundle:

Ah, that’s because the 2.3.x version needs the 1.2.164 server.
We’re scheduled to release a new version today, in the mean time, you can use https://build-stage.defold.com

You need both the new version and the new server, we’re working on it…

1 Like