Why facebook sdk won't work with ejecta and cocoonJS?

Discussion and feedback on Construct 2

Post » Sun Aug 10, 2014 9:29 am

Hi,
I would like to understand why we can't have facebook working with ejecta or cocoonJS.
I know that CocoonJS have included facebook sdk but I would like to understand what is the technical reason we didn't add facebook possibilities in cocoonJS construct2 plugin?
I really want to understand because if it's just a matter of time to adapt the plugin to make facebook work i will take this time.
Please let me know, facebook integration is really important in mobile games and I suffer of this lack.
Thank you
B
14
S
4
G
2
Posts: 190
Reputation: 3,938

Post » Sun Aug 10, 2014 9:36 am

Cause cocoonJS has their own facebook support ;) I'm not sure about Ejecta.
Image Image iTunes: Match3 | Google Play: Match3
B
93
S
32
G
30
Posts: 1,095
Reputation: 27,510

Post » Sun Aug 10, 2014 11:23 am

Ok, but before I start working on it, I want to be sure there is no limitation between construct2 and cocoonJs to make a facebook plugin.
@Ashley any idea about this point?
B
14
S
4
G
2
Posts: 190
Reputation: 3,938

Post » Sun Aug 10, 2014 11:27 am

There's no limitation to making your own plugin for it.. Ashley tends to care more about Intel Crosswalk than Ludei's CocoonJS due to the past history of Ludei's reliability when it comes to plugin updates, etc.
Image
B
81
S
16
G
4
Posts: 501
Reputation: 8,934

Post » Fri Aug 15, 2014 7:32 am

@Ashley I think what @beufreecasse is asking is why the Facbook plugin provided by C2 does not work natively in things like CocoonJS? Therefore getting to the existing technical issue without loosing time getting there himself.

If the C2 Facebook plugin worked on the mobile platforms it would mean we wouldn't have use whatever support was provided by the mobile wrappers. Therefore one implementation for each wrapper.

Clay.io was the only thing that 'use to' work on mobile devices. However, it involved copying some of it's plugin files into the C2 exported zip. That now seems to not work either on CocoonJS 2.0.2
ImageImageImageImageImage
B
19
S
5
G
1
Posts: 614
Reputation: 2,542

Post » Fri Aug 15, 2014 12:39 pm

CocoonJS is not a real browser which makes it very difficult to support third party APIs that assume there is a real browser present. Does it work in PhoneGap or Crosswalk?
Scirra Founder
B
387
S
230
G
87
Posts: 24,245
Reputation: 192,210

Post » Fri Aug 15, 2014 1:45 pm

@Ashley I did get phonegap to work through my facebook plugin. Phonegap has a window.open function that let's you reference the URL address. So I open a window for login and have it call Localhost upon error or login. Then depending on the URL I grab the userid and app token for Ajax calls to the facebook api, or I trigger an on login failed. Either way I then close the window from the app and it's seamless. Does cocoonjs have a similar window.open function that we can reference the URL address?
www.h1k3.tech

We are here for you!
B
87
S
22
G
16
Posts: 715
Reputation: 16,765

Post » Fri Aug 15, 2014 11:48 pm

It looks like they do to me.

https://doc.ludei.com/2.0.2/CocoonJS_Ap ... pp.js.html

Code: Select all
 /**
325      * Opens a given URL using a system service that is able to open it. For example, open a HTTP URL using the system WebBrowser.+
326      * @function
327      * @param {string} url The URL to be opened by a system service.
328      */
329     CocoonJS.App.openURL = function (url) {
330         if (CocoonJS.App.nativeExtensionObjectAvailable) {
331             return CocoonJS.makeNativeExtensionObjectFunctionCall("IDTK_APP", "openURL", arguments, true);
332         }
333         else if (!navigator.isCocoonJS) {
334             window.open(url, '_blank');
335         }
336     }


but I could be wrong..

Also now the plugin is opensource (https://github.com/ludei/Construct-2-plugin) we could add one or does it need to be added at the compiler level?
ImageImageImageImageImage
B
19
S
5
G
1
Posts: 614
Reputation: 2,542

Post » Sun Aug 17, 2014 10:29 pm

@TheWyrm I don't suppose you know if this will allow us to track the URL as it changes from facebook.com back to Localhost?
www.h1k3.tech

We are here for you!
B
87
S
22
G
16
Posts: 715
Reputation: 16,765

Post » Mon Aug 18, 2014 11:54 am

@lanceal No idea. I'm just muddling myself through all this and trying to be helpful ;)
ImageImageImageImageImage
B
19
S
5
G
1
Posts: 614
Reputation: 2,542

Next

Return to Construct 2 General

Who is online

Users browsing this forum: dwtiger, tarek2 and 2 guests