Take the 2-minute tour ×
Game Development Stack Exchange is a question and answer site for professional and independent game developers. It's 100% free, no registration required.

What's the best and simple way to post score from my game to Facebook and Twitter with store link in cocos2d-x?

share|improve this question
    
I'm not sure if it's the best way, but both FB and twitter provided API for these actions. you can open a TCP connection to their server and send a request based on their API –  Ali.S May 9 '12 at 12:44
add comment

1 Answer 1

Twitter has a developer portal, where you'll probably want to check out the REST API. Specifically the POST statuses/update endpoint. Because this API is HTTP-based, you'll need a way to make such requests from your game. This question on SO addresses that subject, with suggestions such as curlpp.

Facebook has a similar set of APIs available, described on their developer portal. Unfortunately most of their actual documentation is behind a Facebook login wall, so I won't link it directly. But if you search for "facebook api post to wall" you get several results, including direct links to the graph API documentation for posting and this SO question.

Facebook has JavaScript, Objective-C and Java-based APIs.

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.