Tried posting in twitter or facebook via code?

No replies
lwg-prynce
User offline. Last seen 6 years 1 day ago. Offline
Joined: 11 Feb 2013

I have used GGFacebook library but It doesn't seem to work. Maybe something is wrong in my implementation because nothing appear when I click a the post button in my app.

My code works like this:

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
facebookAppID = "420230808066127"
local GGFacebook = require "GGFacebook"
local fb = GGFacebook:new(facebookAppID)
 
local function facebook()
        fb:login()
    local message = "I played the game Astro Assault and survived up to Level " .. level .. ", with a score of " .. score .. ". Wanna compete with me? Download this game now! \n http://www.facebook.com/funkysquid"
    local baseDir = system.DocumentsDirectory
    local filename = "overscreen.jpg"
 
        fb:uploadImage( message, filename, baseDir )
end
 
overscreen = display.captureScreen(true)
local baseDir = system.DocumentsDirectory
display.save( overscreen, "overscreen.jpg", baseDir )

Glad somebody could help, maybe got an Alternative rather than using GGFacebook thanks! =)