Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

AppGameKit Classic Chat / Facebook login problematic in iOS

Author
Message
Ancient Lady
Valued Member
20
Years of Service
User Offline
Joined: 17th Mar 2004
Location: Anchorage, Alaska, USA
Posted: 2nd Sep 2013 22:59 Edited at: 5th Sep 2013 21:14
EDIT: This also has been fixed. It turned out to be a missing letter in the plist file. One flippin' character was all it took to make things not work!

I was testing, just to get a Facebook login button to work.

The Facebook ID I used is for my WIP which is a registered game with Facebook in sandbox state (posts to my page are only visible to me, but they do happen, but aren't being tested here).

In iOS 6.1 on my iPad (which has the Facebook app installed) after doing the setup and calling agk::FacebookLogin(), I get a page that says "You have already authorized <app name>" with a pair of cancel and ok buttons. No matter which button I press, I get a white screen with blue bar at top with a cancel button. Clicking on the cancel button takes me to my Facebook app.

On my iOS 6.1 iPod Touch without the Facebook app, it brings up a Facebook login and then I get the "You have already...." message. Clicking on either button drops me in Safari with the error message "Safari cannot open the page because the address is invalid.".

I run into the same events when the same code, in Tier 1, is run through a Player.

Cheers,
Ancient Lady
AGK Community Tester and AppGameKit Master
xGEKKOx
AGK Master
15
Years of Service
User Offline
Joined: 7th Dec 2008
Location: Italy
Posted: 3rd Sep 2013 03:03
Facebook is changed 30 days ago and iOS too.
Be careful, your APP will be rejected on each error / message you show to users of connected / not connected.
So if it don't work, better you exclude Facebook from your APP, until you use OBJ C.
I worked a month to solve the question.
Now i share all the apps, under the same Facebook app called "GG GAMES".
So i don't have to do anything new each time i start a new app.

Long life to Steve!
Ancient Lady
Valued Member
20
Years of Service
User Offline
Joined: 17th Mar 2004
Location: Anchorage, Alaska, USA
Posted: 3rd Sep 2013 05:42
xGEKKOx, thank you. I do appreciate all the Objective C/C++ interface stuff that you have posted.

But one of my objectives with my WIP is to publish in Android as well. I would like to be able to use the same code in all my projects (as I currently am) and not have to make too many platform specific bits (one of the strengths of AGK).

Also, the Tier 1 Facebook stuff not work (even though I am not using it) might be an issue for people who do want to use it.

And, if it is in there, it should work.

It is not impossible that the iOS issues are because of changes in iOS and/or Facebook. I am keeping my iOS devices in iOS 6.1. iOS 7 hasn't been out enough for me to believe that everyone has upgraded (it isn't showing up as an option on my devices, so I'm guessing it is still in beta).

Cheers,
Ancient Lady
AGK Community Tester and AppGameKit Master
xGEKKOx
AGK Master
15
Years of Service
User Offline
Joined: 7th Dec 2008
Location: Italy
Posted: 3rd Sep 2013 07:02
Yes, i wanted only to be sure you do not upload codes with 108 with facebook, the app will be rejected until the fix or a workaround.

Long life to Steve!
xCept
21
Years of Service
User Offline
Joined: 15th Dec 2002
Location:
Posted: 3rd Sep 2013 08:45 Edited at: 3rd Sep 2013 08:48
The built-in Facebook/Twitter support is definitely buggy at best. I think it may still work in some cases on devices using iOS 4.x or 5.x, but I didn't have much luck when I played around with it.

In one app, where sharing wasn't important nor expected, I just customized Facebook's dialog URL for sharing a post with an image then opened the URL in a browser. However, as I recall there are issues with this method in that the posts may be set to 'private' by default (but it's been awhile since I checked).



I did similar with Twitter.
Ancient Lady
Valued Member
20
Years of Service
User Offline
Joined: 17th Mar 2004
Location: Anchorage, Alaska, USA
Posted: 3rd Sep 2013 16:09
I very well may end up publishing with the light versions until this gets fixed. Then, if/when it gets fixed, I'll update the app and add it back.

It would be very nice if this was fixed properly.

Cheers,
Ancient Lady
AGK Community Tester and AppGameKit Master
Ancient Lady
Valued Member
20
Years of Service
User Offline
Joined: 17th Mar 2004
Location: Anchorage, Alaska, USA
Posted: 4th Sep 2013 21:11
xCept, what do you put for the redirect_uri parameter?

The Facebook pages are not very clear on this.

Cheers,
Ancient Lady
AGK Community Tester and AppGameKit Master
Paul Johnston
TGC Developer
21
Years of Service
User Offline
Joined: 16th Nov 2002
Location: United Kingdom
Posted: 5th Sep 2013 19:28
Quote: "Safari cannot open the page because the address is invalid"


This can be caused by the "URL Types" field in the info.plist file being incorrect. For example the AppGameKit player app has


and then the FacebookAppID field set to 358083327620324.
Ancient Lady
Valued Member
20
Years of Service
User Offline
Joined: 17th Mar 2004
Location: Anchorage, Alaska, USA
Posted: 5th Sep 2013 21:13
I just noticed that I was missing one number in the URL Types field.

Sometimes copy-paste doesn't get all that you want.

I got the 'You have already authorized ...' message and pressed the OK button. And it went back to the actual app, which is a great improvement. And it reports a successful Facebook Login.

And the PostToMyWall command worked like a gem. It would be nice to have a version that just posted without asking for extra input (like Candy Crush and games of that sort).

AWESOME!!!!

It's amazing how a single character can mess you up in computers.

Cheers,
Ancient Lady
AGK Community Tester and AppGameKit Master
JimHawkins
14
Years of Service
User Offline
Joined: 26th Jul 2009
Location: Hull - UK
Posted: 6th Sep 2013 02:30
Quote: "It's amazing how a single character can mess you up in computers."


Right! Somewhere in 480,000 lines of code I discovered yesterday a bug in our language lab code when in demo mode (restricted) that was caused by >= as opposed to >

Those nasty little characters are hiding there ready to eat us.

-- Jim - When is there going to be a release?
anwserman
12
Years of Service
User Offline
Joined: 20th May 2011
Location: Wisconsin
Posted: 3rd Nov 2013 22:58
Ancient Lady,
Can you post a snippit of your code that you use to get Facebook integration working? I'm just wondering because I haven't used any social networking features of AppGameKit and I've heard it's spotty at best

Hi there. My name is Dug. I have just met you, and I love you.
Ancient Lady
Valued Member
20
Years of Service
User Offline
Joined: 17th Mar 2004
Location: Anchorage, Alaska, USA
Posted: 4th Nov 2013 04:12
answerman, are you working in Tier 2 or Tier 1?

My code is in Tier 2 and arranged differently than you would in Tier 1 because of how Tier 2 works with the agk::Sync() command.

Cheers,
Ancient Lady
AGK Community Tester and AppGameKit Master
anwserman
12
Years of Service
User Offline
Joined: 20th May 2011
Location: Wisconsin
Posted: 4th Nov 2013 05:48
Ah. I thought you were working in Tier1 (that's what I use).
I've been looking through posts and was researching it. For iOS I notices I have to get an app ID and publish to my phone before I can test with Facebook--all important things to know beforehand lol

Hi there. My name is Dug. I have just met you, and I love you.
Ancient Lady
Valued Member
20
Years of Service
User Offline
Joined: 17th Mar 2004
Location: Anchorage, Alaska, USA
Posted: 4th Nov 2013 15:03
You can't test anything in Facebook until you have an account with them and register the app that you are going to use.

With Android devices, it also requires providing some information that you generate with Eclipse when you create an APK and sign it. And that can all be down without actually doing anything with Google.

With iOS, you actually have to start the process with Apple and register your app with iTunes to get an Apple id that you can then register with your app at Facebook. So, you have to make the commitment to spend the bucks to register as an Apple iOS Developer ($99 USD /year for as long as you want your apps to be published).

So, it is sort of easier and cheaper to do full tests with an Android device. Once you have the code working in that, the same code will work for iOS as long as you set up the project properly and use the right package name in the code when you connect.

One of the things Apple will pretty much insist on is that you have a website that customers can go to to contact you if they have issues.

Cheers,
Ancient Lady
AGK Community Tester and AppGameKit Master
anwserman
12
Years of Service
User Offline
Joined: 20th May 2011
Location: Wisconsin
Posted: 4th Nov 2013 22:48
Ok. I do have an Android tablet I could test/develop on. I do have the iOS program too. I'll try it with Android.
Also, what version of AppGameKit should be used? 1.78 or the betas?

Hi there. My name is Dug. I have just met you, and I love you.
Ancient Lady
Valued Member
20
Years of Service
User Offline
Joined: 17th Mar 2004
Location: Anchorage, Alaska, USA
Posted: 4th Nov 2013 23:54
If you want to use any sort of Facebook stuff, it must be v10819 (the latest 108, which is where the social media stuff was added).

Cheers,
Ancient Lady
AGK Community Tester and AppGameKit Master
anwserman
12
Years of Service
User Offline
Joined: 20th May 2011
Location: Wisconsin
Posted: 5th Nov 2013 03:10
Ah thank you. Since we're on a similar topic, any fun quirks with in-app purchases? I saw threads that state that it's mostly good to go (with iOS at least).

Hi there. My name is Dug. I have just met you, and I love you.
Ancient Lady
Valued Member
20
Years of Service
User Offline
Joined: 17th Mar 2004
Location: Anchorage, Alaska, USA
Posted: 5th Nov 2013 04:36
I haven't done anything with in-app purchases. But others have. Try opening up another thread asking about and see what you get.

Cheers,
Ancient Lady
AGK Community Tester and AppGameKit Master

Login to post a reply

Server time is: 2024-05-03 15:43:46
Your offset time is: 2024-05-03 15:43:46