Connect to Android in Unity


I want to connect to facebook and have the id information from user. my application is in android with Unity 3D?
Should i use Application.openURL?
Thank in advance.

If you want to hook into Facebook on Android, you’re going to need to write an Android plugin that wraps around Facebook’s native API. Frankly, it’s simply not possible to hook into Facebook’s API otherwise.

On the bright side, Unity recently announced that Facebook would be releasing a new, presumably free, package on the AssetStore, that would greatly simplify the process of integrating Facebook services in Unity games. Unfortunately, I don’t believe that library has become available yet.

But you’re not completely out of luck. The folks a Prime31 have an awesome Social Networking Plugin that makes it incredibly simple to hook your game into Facebook. The downside is that it costs $65. I’m using it on my current project, and it saved me weeks time, that I otherwise would have spent writing my own native plugin.