コード例 #1
0
ファイル: LoginUtils.cs プロジェクト: notcarksss/BotBits
 public static Task <Client> ArmorGamesRoomLoginAsync(string gameId, string userId, string token)
 {
     return(PlayerIOAsync.AuthenticateAsync(
                gameId,
                "secure",
                new Dictionary <string, string>
     {
         { "userId", userId },
         { "authToken", token }
     },
                null));
 }
コード例 #2
0
 public static Task <T> WithPublicConnectionAsync <T>(this IPlayerIOGame <T> playerIOGame, string userId)
 {
     return(PlayerIOAsync.ConnectAsync(playerIOGame.GameId, "public", userId, null, null, null)
            .Then(task => playerIOGame.Login.WithClient(task.Result))
            .ToSafeTask());
 }