Unity Google 계정 연동
1. GPGS를 다운로드 (최신버전의 경우 에러가 잡히는 경우가 있음)
1-1) Admob과 import에서 충돌이 일어날 수 있음 해결법 -> link
1-2) Asset -> PlayServiceResolver -> AndroidResolver -> Resolve 해야함
1-3) Window -> GooglePlaySetup 해야함
2. Source Code
using GooglePlayGames;
void Start()
{
PlayGamesPlatform.DebugLogEnabled = true;
PlayGamesPlatform.Activate();
}
public void Login()
{
Social.localUser.Authenticate((bool success) =>
{
if(success)
Debug.Log("Id : " + Social.localUser.id + " , name : " + Social.localUser.userName );
}
}
3. You tube link
https://www.youtube.com/watch?v=e1Ma6zRd3wA
1-1) Admob과 import에서 충돌이 일어날 수 있음 해결법 -> link
1-2) Asset -> PlayServiceResolver -> AndroidResolver -> Resolve 해야함
1-3) Window -> GooglePlaySetup 해야함
2. Source Code
using GooglePlayGames;
void Start()
{
PlayGamesPlatform.DebugLogEnabled = true;
PlayGamesPlatform.Activate();
}
public void Login()
{
Social.localUser.Authenticate((bool success) =>
{
if(success)
Debug.Log("Id : " + Social.localUser.id + " , name : " + Social.localUser.userName );
}
}
3. You tube link
https://www.youtube.com/watch?v=e1Ma6zRd3wA
댓글
댓글 쓰기