コード例 #1
0
        public static SquadMsg GenerateMessageFromSquadResponse(SquadResponse response, LeaderboardController lbc)
        {
            SqmSquadData sqmSquadData = new SqmSquadData();

            sqmSquadData.Id = response.SquadId;
            Squad orCreateSquad = lbc.GetOrCreateSquad(sqmSquadData.Id);

            orCreateSquad.FromObject(response.SquadData);
            return(new SquadMsg
            {
                SquadData = sqmSquadData,
                RespondedSquad = orCreateSquad
            });
        }