public ChallengeService() : base("bnet.protocol.challenge.ChallengeService") { this.Methods = new MethodDescriptor[4]; MethodDescriptor[] methods = this.Methods; int num = (int)((UIntPtr)1); string n = "bnet.protocol.challenge.ChallengeService.ChallengePicked"; uint i = 1u; if (ChallengeService.< > f__mg$cache0 == null) { ChallengeService.< > f__mg$cache0 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <ChallengePickedResponse>); } methods[num] = new MethodDescriptor(n, i, ChallengeService.< > f__mg$cache0); MethodDescriptor[] methods2 = this.Methods; int num2 = (int)((UIntPtr)2); string n2 = "bnet.protocol.challenge.ChallengeService.ChallengeAnswered"; uint i2 = 2u; if (ChallengeService.< > f__mg$cache1 == null) { ChallengeService.< > f__mg$cache1 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <ChallengeAnsweredResponse>); } methods2[num2] = new MethodDescriptor(n2, i2, ChallengeService.< > f__mg$cache1); MethodDescriptor[] methods3 = this.Methods; int num3 = (int)((UIntPtr)3); string n3 = "bnet.protocol.challenge.ChallengeService.ChallengeCancelled"; uint i3 = 3u; if (ChallengeService.< > f__mg$cache2 == null) { ChallengeService.< > f__mg$cache2 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods3[num3] = new MethodDescriptor(n3, i3, ChallengeService.< > f__mg$cache2); }
public MethodDescriptor(string n, uint i, MethodDescriptor.ParseMethod parseMethod) { this.name = n; this.id = i; this.m_parseMethod = parseMethod; if (this.m_parseMethod == null) { BattleNet.Log.LogError("MethodDescriptor called with a null method type!"); } }
private object RPCConnection_PacketReceived(RPCConnection thisObj, BattleNetPacket packet) { using (StreamWriter sw = new StreamWriter("rpc_packets.txt", true)) { object body = packet.GetBody(); MethodDescriptor.ParseMethod parseMethod = null; string serviceDescriptor = ""; if (packet.GetHeader().ServiceId == 254) { RPCContext rPCContext; var waitingForResponse = typeof(RPCConnection).GetField("waitingForResponse", BindingFlags.NonPublic | BindingFlags.Instance).GetValue(thisObj) as Dictionary <uint, RPCContext>; if (waitingForResponse.TryGetValue(packet.GetHeader().Token, out rPCContext)) { ServiceDescriptor importedServiceById = thisObj.serviceHelper.GetImportedServiceById(rPCContext.Header.ServiceId); if (importedServiceById != null) { parseMethod = importedServiceById.GetParser(rPCContext.Header.MethodId); body = parseMethod((byte[])body); } } } else { MethodInfo dynMethod = typeof(RPCConnection).GetMethod("GetExportedServiceDescriptor", BindingFlags.NonPublic | BindingFlags.Instance); ServiceDescriptor exportedServiceDescriptor = (ServiceDescriptor)dynMethod.Invoke(thisObj, new object[] { packet.GetHeader().ServiceId }); serviceDescriptor = exportedServiceDescriptor.ToString(); if (exportedServiceDescriptor != null) { parseMethod = thisObj.serviceHelper.GetExportedServiceById(packet.GetHeader().ServiceId).GetParser(packet.GetHeader().MethodId); // sw.WriteLine("parseMethod: " + parseMethod); if (parseMethod != null) { body = parseMethod((byte[])body); } } //ServiceDescriptor exportedServiceDescriptor = thisObj.GetExportedServiceDescriptor(); } sw.WriteLine("{\n" + " \"method\": \"RPCConnection.PacketReceived\",\n" + " \"serviceDescriptor\": \"" + serviceDescriptor + "\",\n" + " \"type\": \"" + body.ToString() + "\",\n" + " \"header\": " + JsonConvert.SerializeObject(packet.GetHeader(), Formatting.Indented).Replace("\n", "\n ") + ",\n" + " \"body\": " + JsonConvert.SerializeObject(body, Formatting.Indented).Replace("\n", "\n ") + ",\n" + " \"parseMethod\": " + (parseMethod != null ? "\"" + parseMethod.ToString() + "\"" : "null") + "\n" + "}"); } return(null); }
public GameFactorySubscriberService() : base("bnet.protocol.game_master.GameFactorySubscriber") { this.Methods = new MethodDescriptor[2]; MethodDescriptor[] methods = this.Methods; int num = (int)((UIntPtr)1); string n = "bnet.protocol.game_master.GameFactorySubscriber.NotifyGameFound"; uint i = 1u; if (GameFactorySubscriberService.< > f__mg$cache0 == null) { GameFactorySubscriberService.< > f__mg$cache0 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <GameFoundNotification>); } methods[num] = new MethodDescriptor(n, i, GameFactorySubscriberService.< > f__mg$cache0); }
public NotificationListenerService() : base("bnet.protocol.notification.NotificationListener") { this.Methods = new MethodDescriptor[2]; MethodDescriptor[] methods = this.Methods; int num = (int)((UIntPtr)1); string n = "bnet.protocol.notification.NotificationListener.OnNotificationReceived"; uint i = 1u; if (NotificationListenerService.< > f__mg$cache0 == null) { NotificationListenerService.< > f__mg$cache0 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <Notification>); } methods[num] = new MethodDescriptor(n, i, NotificationListenerService.< > f__mg$cache0); }
public ResourcesService() : base("bnet.protocol.resources.Resources") { this.Methods = new MethodDescriptor[2]; MethodDescriptor[] methods = this.Methods; int num = (int)((UIntPtr)1); string n = "bnet.protocol.resources.Resources.GetContentHandle"; uint i = 1u; if (ResourcesService.< > f__mg$cache0 == null) { ResourcesService.< > f__mg$cache0 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <ContentHandle>); } methods[num] = new MethodDescriptor(n, i, ResourcesService.< > f__mg$cache0); }
public PresenceService() : base("bnet.protocol.presence.PresenceService") { this.Methods = new MethodDescriptor[5]; MethodDescriptor[] methods = this.Methods; int num = (int)((UIntPtr)1); string n = "bnet.protocol.presence.PresenceService.Subscribe"; uint i = 1u; if (PresenceService.< > f__mg$cache0 == null) { PresenceService.< > f__mg$cache0 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods[num] = new MethodDescriptor(n, i, PresenceService.< > f__mg$cache0); MethodDescriptor[] methods2 = this.Methods; int num2 = (int)((UIntPtr)2); string n2 = "bnet.protocol.presence.PresenceService.Unsubscribe"; uint i2 = 2u; if (PresenceService.< > f__mg$cache1 == null) { PresenceService.< > f__mg$cache1 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods2[num2] = new MethodDescriptor(n2, i2, PresenceService.< > f__mg$cache1); MethodDescriptor[] methods3 = this.Methods; int num3 = (int)((UIntPtr)3); string n3 = "bnet.protocol.presence.PresenceService.Update"; uint i3 = 3u; if (PresenceService.< > f__mg$cache2 == null) { PresenceService.< > f__mg$cache2 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods3[num3] = new MethodDescriptor(n3, i3, PresenceService.< > f__mg$cache2); MethodDescriptor[] methods4 = this.Methods; int num4 = (int)((UIntPtr)4); string n4 = "bnet.protocol.presence.PresenceService.Query"; uint i4 = 4u; if (PresenceService.< > f__mg$cache3 == null) { PresenceService.< > f__mg$cache3 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods4[num4] = new MethodDescriptor(n4, i4, PresenceService.< > f__mg$cache3); }
public ChallengeNotify() : base("bnet.protocol.challenge.ChallengeNotify") { this.Methods = new MethodDescriptor[5]; MethodDescriptor[] methods = this.Methods; int num = (int)((UIntPtr)1); string n = "bnet.protocol.challenge.ChallengeNotify.ChallengeUser"; uint i = 1u; if (ChallengeNotify.< > f__mg$cache0 == null) { ChallengeNotify.< > f__mg$cache0 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <ChallengeUserRequest>); } methods[num] = new MethodDescriptor(n, i, ChallengeNotify.< > f__mg$cache0); MethodDescriptor[] methods2 = this.Methods; int num2 = (int)((UIntPtr)2); string n2 = "bnet.protocol.challenge.ChallengeNotify.ChallengeResult"; uint i2 = 2u; if (ChallengeNotify.< > f__mg$cache1 == null) { ChallengeNotify.< > f__mg$cache1 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <ChallengeResultRequest>); } methods2[num2] = new MethodDescriptor(n2, i2, ChallengeNotify.< > f__mg$cache1); MethodDescriptor[] methods3 = this.Methods; int num3 = (int)((UIntPtr)3); string n3 = "bnet.protocol.challenge.ChallengeNotify.OnExternalChallenge"; uint i3 = 3u; if (ChallengeNotify.< > f__mg$cache2 == null) { ChallengeNotify.< > f__mg$cache2 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <ChallengeExternalRequest>); } methods3[num3] = new MethodDescriptor(n3, i3, ChallengeNotify.< > f__mg$cache2); MethodDescriptor[] methods4 = this.Methods; int num4 = (int)((UIntPtr)4); string n4 = "bnet.protocol.challenge.ChallengeNotify.OnExternalChallengeResult"; uint i4 = 4u; if (ChallengeNotify.< > f__mg$cache3 == null) { ChallengeNotify.< > f__mg$cache3 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <ChallengeExternalResult>); } methods4[num4] = new MethodDescriptor(n4, i4, ChallengeNotify.< > f__mg$cache3); }
public ChannelInvitationNotifyService() : base("bnet.protocol.channel_invitation.ChannelInvitationNotify") { this.Methods = new MethodDescriptor[5]; MethodDescriptor[] methods = this.Methods; int num = (int)((UIntPtr)1); string n = "bnet.protocol.channel_invitation.ChannelInvitationNotify.NotifyReceivedInvitationAdded"; uint i = 1u; if (ChannelInvitationNotifyService.< > f__mg$cache0 == null) { ChannelInvitationNotifyService.< > f__mg$cache0 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <InvitationAddedNotification>); } methods[num] = new MethodDescriptor(n, i, ChannelInvitationNotifyService.< > f__mg$cache0); MethodDescriptor[] methods2 = this.Methods; int num2 = (int)((UIntPtr)2); string n2 = "bnet.protocol.channel_invitation.ChannelInvitationNotify.NotifyReceivedInvitationRemoved"; uint i2 = 2u; if (ChannelInvitationNotifyService.< > f__mg$cache1 == null) { ChannelInvitationNotifyService.< > f__mg$cache1 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <InvitationRemovedNotification>); } methods2[num2] = new MethodDescriptor(n2, i2, ChannelInvitationNotifyService.< > f__mg$cache1); MethodDescriptor[] methods3 = this.Methods; int num3 = (int)((UIntPtr)3); string n3 = "bnet.protocol.channel_invitation.ChannelInvitationNotify.NotifyReceivedSuggestionAdded"; uint i3 = 3u; if (ChannelInvitationNotifyService.< > f__mg$cache2 == null) { ChannelInvitationNotifyService.< > f__mg$cache2 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <SuggestionAddedNotification>); } methods3[num3] = new MethodDescriptor(n3, i3, ChannelInvitationNotifyService.< > f__mg$cache2); MethodDescriptor[] methods4 = this.Methods; int num4 = (int)((UIntPtr)4); string n4 = "bnet.protocol.channel_invitation.ChannelInvitationNotify.HasRoomForInvitation"; uint i4 = 4u; if (ChannelInvitationNotifyService.< > f__mg$cache3 == null) { ChannelInvitationNotifyService.< > f__mg$cache3 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <HasRoomForInvitationRequest>); } methods4[num4] = new MethodDescriptor(n4, i4, ChannelInvitationNotifyService.< > f__mg$cache3); }
public NotificationService() : base("bnet.protocol.notification.NotificationService") { this.Methods = new MethodDescriptor[5]; MethodDescriptor[] methods = this.Methods; int num = (int)((UIntPtr)1); string n = "bnet.protocol.notification.NotificationService.SendNotification"; uint i = 1u; if (NotificationService.< > f__mg$cache0 == null) { NotificationService.< > f__mg$cache0 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods[num] = new MethodDescriptor(n, i, NotificationService.< > f__mg$cache0); MethodDescriptor[] methods2 = this.Methods; int num2 = (int)((UIntPtr)2); string n2 = "bnet.protocol.notification.NotificationService.RegisterClient"; uint i2 = 2u; if (NotificationService.< > f__mg$cache1 == null) { NotificationService.< > f__mg$cache1 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods2[num2] = new MethodDescriptor(n2, i2, NotificationService.< > f__mg$cache1); MethodDescriptor[] methods3 = this.Methods; int num3 = (int)((UIntPtr)3); string n3 = "bnet.protocol.notification.NotificationService.UnregisterClient"; uint i3 = 3u; if (NotificationService.< > f__mg$cache2 == null) { NotificationService.< > f__mg$cache2 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods3[num3] = new MethodDescriptor(n3, i3, NotificationService.< > f__mg$cache2); MethodDescriptor[] methods4 = this.Methods; int num4 = (int)((UIntPtr)4); string n4 = "bnet.protocol.notification.NotificationService.FindClient"; uint i4 = 4u; if (NotificationService.< > f__mg$cache3 == null) { NotificationService.< > f__mg$cache3 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <FindClientResponse>); } methods4[num4] = new MethodDescriptor(n4, i4, NotificationService.< > f__mg$cache3); }
public AccountNotify() : base("bnet.protocol.account.AccountNotify") { this.Methods = new MethodDescriptor[5]; MethodDescriptor[] methods = this.Methods; int num = (int)((UIntPtr)1); string n = "bnet.protocol.account.AccountNotify.NotifyAccountStateUpdated"; uint i = 1u; if (AccountNotify.< > f__mg$cache0 == null) { AccountNotify.< > f__mg$cache0 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <AccountStateNotification>); } methods[num] = new MethodDescriptor(n, i, AccountNotify.< > f__mg$cache0); MethodDescriptor[] methods2 = this.Methods; int num2 = (int)((UIntPtr)2); string n2 = "bnet.protocol.account.AccountNotify.NotifyGameAccountStateUpdated"; uint i2 = 2u; if (AccountNotify.< > f__mg$cache1 == null) { AccountNotify.< > f__mg$cache1 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <GameAccountStateNotification>); } methods2[num2] = new MethodDescriptor(n2, i2, AccountNotify.< > f__mg$cache1); MethodDescriptor[] methods3 = this.Methods; int num3 = (int)((UIntPtr)3); string n3 = "bnet.protocol.account.AccountNotify.NotifyGameAccountsUpdated"; uint i3 = 3u; if (AccountNotify.< > f__mg$cache2 == null) { AccountNotify.< > f__mg$cache2 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <GameAccountNotification>); } methods3[num3] = new MethodDescriptor(n3, i3, AccountNotify.< > f__mg$cache2); MethodDescriptor[] methods4 = this.Methods; int num4 = (int)((UIntPtr)4); string n4 = "bnet.protocol.account.AccountNotify.NotifyGameSessionUpdated"; uint i4 = 4u; if (AccountNotify.< > f__mg$cache3 == null) { AccountNotify.< > f__mg$cache3 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <GameAccountSessionNotification>); } methods4[num4] = new MethodDescriptor(n4, i4, AccountNotify.< > f__mg$cache3); }
public GameMasterService() : base("bnet.protocol.game_master.GameMaster") { this.Methods = new MethodDescriptor[16]; MethodDescriptor[] methods = this.Methods; int num = (int)((UIntPtr)1); string n = "bnet.protocol.game_master.GameMaster.JoinGame"; uint i = 1u; if (GameMasterService.< > f__mg$cache0 == null) { GameMasterService.< > f__mg$cache0 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <JoinGameResponse>); } methods[num] = new MethodDescriptor(n, i, GameMasterService.< > f__mg$cache0); MethodDescriptor[] methods2 = this.Methods; int num2 = (int)((UIntPtr)2); string n2 = "bnet.protocol.game_master.GameMaster.ListFactories"; uint i2 = 2u; if (GameMasterService.< > f__mg$cache1 == null) { GameMasterService.< > f__mg$cache1 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <ListFactoriesResponse>); } methods2[num2] = new MethodDescriptor(n2, i2, GameMasterService.< > f__mg$cache1); MethodDescriptor[] methods3 = this.Methods; int num3 = (int)((UIntPtr)3); string n3 = "bnet.protocol.game_master.GameMaster.FindGame"; uint i3 = 3u; if (GameMasterService.< > f__mg$cache2 == null) { GameMasterService.< > f__mg$cache2 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <FindGameResponse>); } methods3[num3] = new MethodDescriptor(n3, i3, GameMasterService.< > f__mg$cache2); MethodDescriptor[] methods4 = this.Methods; int num4 = (int)((UIntPtr)4); string n4 = "bnet.protocol.game_master.GameMaster.CancelGameEntry"; uint i4 = 4u; if (GameMasterService.< > f__mg$cache3 == null) { GameMasterService.< > f__mg$cache3 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods4[num4] = new MethodDescriptor(n4, i4, GameMasterService.< > f__mg$cache3); MethodDescriptor[] methods5 = this.Methods; int num5 = (int)((UIntPtr)5); string n5 = "bnet.protocol.game_master.GameMaster.GameEnded"; uint i5 = 5u; if (GameMasterService.< > f__mg$cache4 == null) { GameMasterService.< > f__mg$cache4 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NORESPONSE>); } methods5[num5] = new MethodDescriptor(n5, i5, GameMasterService.< > f__mg$cache4); MethodDescriptor[] methods6 = this.Methods; int num6 = (int)((UIntPtr)6); string n6 = "bnet.protocol.game_master.GameMaster.PlayerLeft"; uint i6 = 6u; if (GameMasterService.< > f__mg$cache5 == null) { GameMasterService.< > f__mg$cache5 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods6[num6] = new MethodDescriptor(n6, i6, GameMasterService.< > f__mg$cache5); MethodDescriptor[] methods7 = this.Methods; int num7 = (int)((UIntPtr)7); string n7 = "bnet.protocol.game_master.GameMaster.RegisterServer"; uint i7 = 7u; if (GameMasterService.< > f__mg$cache6 == null) { GameMasterService.< > f__mg$cache6 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods7[num7] = new MethodDescriptor(n7, i7, GameMasterService.< > f__mg$cache6); MethodDescriptor[] methods8 = this.Methods; int num8 = (int)((UIntPtr)8); string n8 = "bnet.protocol.game_master.GameMaster.UnregisterServer"; uint i8 = 8u; if (GameMasterService.< > f__mg$cache7 == null) { GameMasterService.< > f__mg$cache7 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NORESPONSE>); } methods8[num8] = new MethodDescriptor(n8, i8, GameMasterService.< > f__mg$cache7); MethodDescriptor[] methods9 = this.Methods; int num9 = (int)((UIntPtr)9); string n9 = "bnet.protocol.game_master.GameMaster.RegisterUtilities"; uint i9 = 9u; if (GameMasterService.< > f__mg$cache8 == null) { GameMasterService.< > f__mg$cache8 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods9[num9] = new MethodDescriptor(n9, i9, GameMasterService.< > f__mg$cache8); MethodDescriptor[] methods10 = this.Methods; int num10 = (int)((UIntPtr)10); string n10 = "bnet.protocol.game_master.GameMaster.UnregisterUtilities"; uint i10 = 10u; if (GameMasterService.< > f__mg$cache9 == null) { GameMasterService.< > f__mg$cache9 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NORESPONSE>); } methods10[num10] = new MethodDescriptor(n10, i10, GameMasterService.< > f__mg$cache9); MethodDescriptor[] methods11 = this.Methods; int num11 = (int)((UIntPtr)11); string n11 = "bnet.protocol.game_master.GameMaster.Subscribe"; uint i11 = 11u; if (GameMasterService.< > f__mg$cacheA == null) { GameMasterService.< > f__mg$cacheA = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <SubscribeResponse>); } methods11[num11] = new MethodDescriptor(n11, i11, GameMasterService.< > f__mg$cacheA); MethodDescriptor[] methods12 = this.Methods; int num12 = (int)((UIntPtr)12); string n12 = "bnet.protocol.game_master.GameMaster.Unsubscribe"; uint i12 = 12u; if (GameMasterService.< > f__mg$cacheB == null) { GameMasterService.< > f__mg$cacheB = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NORESPONSE>); } methods12[num12] = new MethodDescriptor(n12, i12, GameMasterService.< > f__mg$cacheB); MethodDescriptor[] methods13 = this.Methods; int num13 = (int)((UIntPtr)13); string n13 = "bnet.protocol.game_master.GameMaster.ChangeGame"; uint i13 = 13u; if (GameMasterService.< > f__mg$cacheC == null) { GameMasterService.< > f__mg$cacheC = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods13[num13] = new MethodDescriptor(n13, i13, GameMasterService.< > f__mg$cacheC); MethodDescriptor[] methods14 = this.Methods; int num14 = (int)((UIntPtr)14); string n14 = "bnet.protocol.game_master.GameMaster.GetFactoryInfo"; uint i14 = 14u; if (GameMasterService.< > f__mg$cacheD == null) { GameMasterService.< > f__mg$cacheD = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <GetFactoryInfoResponse>); } methods14[num14] = new MethodDescriptor(n14, i14, GameMasterService.< > f__mg$cacheD); MethodDescriptor[] methods15 = this.Methods; int num15 = (int)((UIntPtr)15); string n15 = "bnet.protocol.game_master.GameMaster.GetGameStats"; uint i15 = 15u; if (GameMasterService.< > f__mg$cacheE == null) { GameMasterService.< > f__mg$cacheE = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <GetGameStatsResponse>); } methods15[num15] = new MethodDescriptor(n15, i15, GameMasterService.< > f__mg$cacheE); }
public ChannelInvitationService() : base("bnet.protocol.channel_invitation.ChannelInvitationService") { this.Methods = new MethodDescriptor[12]; MethodDescriptor[] methods = this.Methods; int num = (int)((UIntPtr)1); string n = "bnet.protocol.channel_invitation.ChannelInvitationService.Subscribe"; uint i = 1u; if (ChannelInvitationService.< > f__mg$cache0 == null) { ChannelInvitationService.< > f__mg$cache0 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <SubscribeResponse>); } methods[num] = new MethodDescriptor(n, i, ChannelInvitationService.< > f__mg$cache0); MethodDescriptor[] methods2 = this.Methods; int num2 = (int)((UIntPtr)2); string n2 = "bnet.protocol.channel_invitation.ChannelInvitationService.Unsubscribe"; uint i2 = 2u; if (ChannelInvitationService.< > f__mg$cache1 == null) { ChannelInvitationService.< > f__mg$cache1 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods2[num2] = new MethodDescriptor(n2, i2, ChannelInvitationService.< > f__mg$cache1); MethodDescriptor[] methods3 = this.Methods; int num3 = (int)((UIntPtr)3); string n3 = "bnet.protocol.channel_invitation.ChannelInvitationService.SendInvitation"; uint i3 = 3u; if (ChannelInvitationService.< > f__mg$cache2 == null) { ChannelInvitationService.< > f__mg$cache2 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <SendInvitationResponse>); } methods3[num3] = new MethodDescriptor(n3, i3, ChannelInvitationService.< > f__mg$cache2); MethodDescriptor[] methods4 = this.Methods; int num4 = (int)((UIntPtr)4); string n4 = "bnet.protocol.channel_invitation.ChannelInvitationService.AcceptInvitation"; uint i4 = 4u; if (ChannelInvitationService.< > f__mg$cache3 == null) { ChannelInvitationService.< > f__mg$cache3 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <AcceptInvitationResponse>); } methods4[num4] = new MethodDescriptor(n4, i4, ChannelInvitationService.< > f__mg$cache3); MethodDescriptor[] methods5 = this.Methods; int num5 = (int)((UIntPtr)5); string n5 = "bnet.protocol.channel_invitation.ChannelInvitationService.DeclineInvitation"; uint i5 = 5u; if (ChannelInvitationService.< > f__mg$cache4 == null) { ChannelInvitationService.< > f__mg$cache4 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods5[num5] = new MethodDescriptor(n5, i5, ChannelInvitationService.< > f__mg$cache4); MethodDescriptor[] methods6 = this.Methods; int num6 = (int)((UIntPtr)6); string n6 = "bnet.protocol.channel_invitation.ChannelInvitationService.RevokeInvitation"; uint i6 = 6u; if (ChannelInvitationService.< > f__mg$cache5 == null) { ChannelInvitationService.< > f__mg$cache5 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods6[num6] = new MethodDescriptor(n6, i6, ChannelInvitationService.< > f__mg$cache5); MethodDescriptor[] methods7 = this.Methods; int num7 = (int)((UIntPtr)7); string n7 = "bnet.protocol.channel_invitation.ChannelInvitationService.SuggestInvitation"; uint i7 = 7u; if (ChannelInvitationService.< > f__mg$cache6 == null) { ChannelInvitationService.< > f__mg$cache6 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods7[num7] = new MethodDescriptor(n7, i7, ChannelInvitationService.< > f__mg$cache6); MethodDescriptor[] methods8 = this.Methods; int num8 = (int)((UIntPtr)8); string n8 = "bnet.protocol.channel_invitation.ChannelInvitationService.IncrementChannelCount"; uint i8 = 8u; if (ChannelInvitationService.< > f__mg$cache7 == null) { ChannelInvitationService.< > f__mg$cache7 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <IncrementChannelCountResponse>); } methods8[num8] = new MethodDescriptor(n8, i8, ChannelInvitationService.< > f__mg$cache7); MethodDescriptor[] methods9 = this.Methods; int num9 = (int)((UIntPtr)9); string n9 = "bnet.protocol.channel_invitation.ChannelInvitationService.DecrementChannelCount"; uint i9 = 9u; if (ChannelInvitationService.< > f__mg$cache8 == null) { ChannelInvitationService.< > f__mg$cache8 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods9[num9] = new MethodDescriptor(n9, i9, ChannelInvitationService.< > f__mg$cache8); MethodDescriptor[] methods10 = this.Methods; int num10 = (int)((UIntPtr)10); string n10 = "bnet.protocol.channel_invitation.ChannelInvitationService.UpdateChannelCount"; uint i10 = 10u; if (ChannelInvitationService.< > f__mg$cache9 == null) { ChannelInvitationService.< > f__mg$cache9 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods10[num10] = new MethodDescriptor(n10, i10, ChannelInvitationService.< > f__mg$cache9); MethodDescriptor[] methods11 = this.Methods; int num11 = (int)((UIntPtr)11); string n11 = "bnet.protocol.channel_invitation.ChannelInvitationService.ListChannelCount"; uint i11 = 11u; if (ChannelInvitationService.< > f__mg$cacheA == null) { ChannelInvitationService.< > f__mg$cacheA = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <ListChannelCountResponse>); } methods11[num11] = new MethodDescriptor(n11, i11, ChannelInvitationService.< > f__mg$cacheA); }
public ConnectionService() : base("bnet.protocol.connection.ConnectionService") { this.Methods = new MethodDescriptor[8]; MethodDescriptor[] methods = this.Methods; int num = (int)((UIntPtr)1); string n = "bnet.protocol.connection.ConnectionService.Connect"; uint i = 1u; if (ConnectionService.< > f__mg$cache0 == null) { ConnectionService.< > f__mg$cache0 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <ConnectResponse>); } methods[num] = new MethodDescriptor(n, i, ConnectionService.< > f__mg$cache0); MethodDescriptor[] methods2 = this.Methods; int num2 = (int)((UIntPtr)2); string n2 = "bnet.protocol.connection.ConnectionService.Bind"; uint i2 = 2u; if (ConnectionService.< > f__mg$cache1 == null) { ConnectionService.< > f__mg$cache1 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <BindResponse>); } methods2[num2] = new MethodDescriptor(n2, i2, ConnectionService.< > f__mg$cache1); MethodDescriptor[] methods3 = this.Methods; int num3 = (int)((UIntPtr)3); string n3 = "bnet.protocol.connection.ConnectionService.Echo"; uint i3 = 3u; if (ConnectionService.< > f__mg$cache2 == null) { ConnectionService.< > f__mg$cache2 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <EchoResponse>); } methods3[num3] = new MethodDescriptor(n3, i3, ConnectionService.< > f__mg$cache2); MethodDescriptor[] methods4 = this.Methods; int num4 = (int)((UIntPtr)4); string n4 = "bnet.protocol.connection.ConnectionService.ForceDisconnect"; uint i4 = 4u; if (ConnectionService.< > f__mg$cache3 == null) { ConnectionService.< > f__mg$cache3 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NORESPONSE>); } methods4[num4] = new MethodDescriptor(n4, i4, ConnectionService.< > f__mg$cache3); MethodDescriptor[] methods5 = this.Methods; int num5 = (int)((UIntPtr)5); string n5 = "bnet.protocol.connection.ConnectionService.KeepAlive"; uint i5 = 5u; if (ConnectionService.< > f__mg$cache4 == null) { ConnectionService.< > f__mg$cache4 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NORESPONSE>); } methods5[num5] = new MethodDescriptor(n5, i5, ConnectionService.< > f__mg$cache4); MethodDescriptor[] methods6 = this.Methods; int num6 = (int)((UIntPtr)6); string n6 = "bnet.protocol.connection.ConnectionService.Encrypt"; uint i6 = 6u; if (ConnectionService.< > f__mg$cache5 == null) { ConnectionService.< > f__mg$cache5 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods6[num6] = new MethodDescriptor(n6, i6, ConnectionService.< > f__mg$cache5); MethodDescriptor[] methods7 = this.Methods; int num7 = (int)((UIntPtr)7); string n7 = "bnet.protocol.connection.ConnectionService.RequestDisconnect"; uint i7 = 7u; if (ConnectionService.< > f__mg$cache6 == null) { ConnectionService.< > f__mg$cache6 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NORESPONSE>); } methods7[num7] = new MethodDescriptor(n7, i7, ConnectionService.< > f__mg$cache6); }
public AuthServerService() : base("bnet.protocol.authentication.AuthenticationServer") { this.Methods = new MethodDescriptor[8]; MethodDescriptor[] methods = this.Methods; int num = (int)((UIntPtr)1); string n = "bnet.protocol.authentication.AuthenticationServer.Logon"; uint i = 1u; if (AuthServerService.< > f__mg$cache0 == null) { AuthServerService.< > f__mg$cache0 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods[num] = new MethodDescriptor(n, i, AuthServerService.< > f__mg$cache0); MethodDescriptor[] methods2 = this.Methods; int num2 = (int)((UIntPtr)2); string n2 = "bnet.protocol.authentication.AuthenticationServer.ModuleNotify"; uint i2 = 2u; if (AuthServerService.< > f__mg$cache1 == null) { AuthServerService.< > f__mg$cache1 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods2[num2] = new MethodDescriptor(n2, i2, AuthServerService.< > f__mg$cache1); MethodDescriptor[] methods3 = this.Methods; int num3 = (int)((UIntPtr)3); string n3 = "bnet.protocol.authentication.AuthenticationServer.ModuleMessage"; uint i3 = 3u; if (AuthServerService.< > f__mg$cache2 == null) { AuthServerService.< > f__mg$cache2 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods3[num3] = new MethodDescriptor(n3, i3, AuthServerService.< > f__mg$cache2); MethodDescriptor[] methods4 = this.Methods; int num4 = (int)((UIntPtr)4); string n4 = "bnet.protocol.authentication.AuthenticationServer.SelectGameAccount_DEPRECATED"; uint i4 = 4u; if (AuthServerService.< > f__mg$cache3 == null) { AuthServerService.< > f__mg$cache3 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods4[num4] = new MethodDescriptor(n4, i4, AuthServerService.< > f__mg$cache3); MethodDescriptor[] methods5 = this.Methods; int num5 = (int)((UIntPtr)5); string n5 = "bnet.protocol.authentication.AuthenticationServer.GenerateTempCookie"; uint i5 = 5u; if (AuthServerService.< > f__mg$cache4 == null) { AuthServerService.< > f__mg$cache4 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <GenerateSSOTokenResponse>); } methods5[num5] = new MethodDescriptor(n5, i5, AuthServerService.< > f__mg$cache4); MethodDescriptor[] methods6 = this.Methods; int num6 = (int)((UIntPtr)6); string n6 = "bnet.protocol.authentication.AuthenticationServer.SelectGameAccount"; uint i6 = 6u; if (AuthServerService.< > f__mg$cache5 == null) { AuthServerService.< > f__mg$cache5 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods6[num6] = new MethodDescriptor(n6, i6, AuthServerService.< > f__mg$cache5); MethodDescriptor[] methods7 = this.Methods; int num7 = (int)((UIntPtr)7); string n7 = "bnet.protocol.authentication.AuthenticationServer.VerifyWebCredentials"; uint i7 = 7u; if (AuthServerService.< > f__mg$cache6 == null) { AuthServerService.< > f__mg$cache6 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods7[num7] = new MethodDescriptor(n7, i7, AuthServerService.< > f__mg$cache6); }
public ChannelSubscriberService() : base("bnet.protocol.channel.ChannelSubscriber") { this.Methods = new MethodDescriptor[8]; MethodDescriptor[] methods = this.Methods; int num = (int)((UIntPtr)1); string n = "bnet.protocol.channel.ChannelSubscriber.NotifyAdd"; uint i = 1u; if (ChannelSubscriberService.< > f__mg$cache0 == null) { ChannelSubscriberService.< > f__mg$cache0 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <AddNotification>); } methods[num] = new MethodDescriptor(n, i, ChannelSubscriberService.< > f__mg$cache0); MethodDescriptor[] methods2 = this.Methods; int num2 = (int)((UIntPtr)2); string n2 = "bnet.protocol.channel.ChannelSubscriber.NotifyJoin"; uint i2 = 2u; if (ChannelSubscriberService.< > f__mg$cache1 == null) { ChannelSubscriberService.< > f__mg$cache1 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <JoinNotification>); } methods2[num2] = new MethodDescriptor(n2, i2, ChannelSubscriberService.< > f__mg$cache1); MethodDescriptor[] methods3 = this.Methods; int num3 = (int)((UIntPtr)3); string n3 = "bnet.protocol.channel.ChannelSubscriber.NotifyRemove"; uint i3 = 3u; if (ChannelSubscriberService.< > f__mg$cache2 == null) { ChannelSubscriberService.< > f__mg$cache2 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <RemoveNotification>); } methods3[num3] = new MethodDescriptor(n3, i3, ChannelSubscriberService.< > f__mg$cache2); MethodDescriptor[] methods4 = this.Methods; int num4 = (int)((UIntPtr)4); string n4 = "bnet.protocol.channel.ChannelSubscriber.NotifyLeave"; uint i4 = 4u; if (ChannelSubscriberService.< > f__mg$cache3 == null) { ChannelSubscriberService.< > f__mg$cache3 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <LeaveNotification>); } methods4[num4] = new MethodDescriptor(n4, i4, ChannelSubscriberService.< > f__mg$cache3); MethodDescriptor[] methods5 = this.Methods; int num5 = (int)((UIntPtr)5); string n5 = "bnet.protocol.channel.ChannelSubscriber.NotifySendMessage"; uint i5 = 5u; if (ChannelSubscriberService.< > f__mg$cache4 == null) { ChannelSubscriberService.< > f__mg$cache4 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <SendMessageNotification>); } methods5[num5] = new MethodDescriptor(n5, i5, ChannelSubscriberService.< > f__mg$cache4); MethodDescriptor[] methods6 = this.Methods; int num6 = (int)((UIntPtr)6); string n6 = "bnet.protocol.channel.ChannelSubscriber.NotifyUpdateChannelState"; uint i6 = 6u; if (ChannelSubscriberService.< > f__mg$cache5 == null) { ChannelSubscriberService.< > f__mg$cache5 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <UpdateChannelStateNotification>); } methods6[num6] = new MethodDescriptor(n6, i6, ChannelSubscriberService.< > f__mg$cache5); MethodDescriptor[] methods7 = this.Methods; int num7 = (int)((UIntPtr)7); string n7 = "bnet.protocol.channel.ChannelSubscriber.NotifyUpdateMemberState"; uint i7 = 7u; if (ChannelSubscriberService.< > f__mg$cache6 == null) { ChannelSubscriberService.< > f__mg$cache6 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <UpdateMemberStateNotification>); } methods7[num7] = new MethodDescriptor(n7, i7, ChannelSubscriberService.< > f__mg$cache6); }
public void Update() { Queue <BattleNetPacket> battleNetPackets; Queue <BattleNetPacket> battleNetPackets1; RPCContext rPCContext; this.ProcessPendingOutboundPackets(); if (this.outBoundPackets.Count > 0) { object obj = this.outBoundPackets; Monitor.Enter(obj); try { battleNetPackets = new Queue <BattleNetPacket>(this.outBoundPackets.ToArray()); this.outBoundPackets.Clear(); } finally { Monitor.Exit(obj); } while (battleNetPackets.Count > 0) { BattleNetPacket battleNetPacket = battleNetPackets.Dequeue(); if (this.Connection == null) { this.m_logSource.LogError("##Client Connection object does not exists!##"); } else { this.Connection.QueuePacket(battleNetPacket); } } } if (this.Connection != null) { this.Connection.Update(); } if (this.incomingPackets.Count > 0) { object obj1 = this.incomingPackets; Monitor.Enter(obj1); try { battleNetPackets1 = new Queue <BattleNetPacket>(this.incomingPackets.ToArray()); this.incomingPackets.Clear(); } finally { Monitor.Exit(obj1); } while (battleNetPackets1.Count > 0) { BattleNetPacket battleNetPacket1 = battleNetPackets1.Dequeue(); Header header = battleNetPacket1.GetHeader(); this.PrintHeader(header); byte[] body = (byte[])battleNetPacket1.GetBody(); if (header.ServiceId != 254) { ServiceDescriptor exportedServiceDescriptor = this.GetExportedServiceDescriptor(header.ServiceId); if (exportedServiceDescriptor == null) { this.m_logSource.LogError(string.Concat(new object[] { "[!]Server Requested an Unsupported (Service id:", header.ServiceId, " Method id:", header.MethodId, ")" })); } else { if (this.serviceHelper.GetExportedServiceById(header.ServiceId).GetParser(header.MethodId) == null) { this.m_logSource.LogDebug(string.Concat("Incoming Packet: NULL TYPE service=", this.serviceHelper.GetExportedServiceById(header.ServiceId).Name, ", method=", this.serviceHelper.GetExportedServiceById(header.ServiceId).GetMethodName(header.MethodId))); } if (!exportedServiceDescriptor.HasMethodListener(header.MethodId)) { string str = (exportedServiceDescriptor == null || string.IsNullOrEmpty(exportedServiceDescriptor.Name) ? "<null>" : exportedServiceDescriptor.Name); this.m_logSource.LogError(string.Concat(new object[] { "[!]Unhandled Server Request Received (Service Name: ", str, " Service id:", header.ServiceId, " Method id:", header.MethodId, ")" })); } else { RPCContext rPCContext1 = new RPCContext() { Header = header, Payload = body, ResponseReceived = true }; exportedServiceDescriptor.NotifyMethodListener(rPCContext1); } } } else if (this.waitingForResponse.TryGetValue(header.Token, out rPCContext)) { ServiceDescriptor importedServiceById = this.serviceHelper.GetImportedServiceById(rPCContext.Header.ServiceId); MethodDescriptor.ParseMethod parser = null; if (importedServiceById != null) { parser = importedServiceById.GetParser(rPCContext.Header.MethodId); } if (parser == null) { if (importedServiceById == null) { this.m_logSource.LogWarning("Incoming Response: Unable to identify service id={0}", new object[] { rPCContext.Header.ServiceId }); } else { this.m_logSource.LogWarning("Incoming Response: Unable to find method for serviceName={0} method id={1}", new object[] { importedServiceById.Name, rPCContext.Header.MethodId }); int methodCount = importedServiceById.GetMethodCount(); this.m_logSource.LogDebug(" Found {0} methods", new object[] { methodCount }); for (int i = 0; i < methodCount; i++) { MethodDescriptor methodDescriptor = importedServiceById.GetMethodDescriptor((uint)i); if (methodDescriptor != null || i == 0) { this.m_logSource.LogDebug(" Found method id={0} name={1}", new object[] { i, methodDescriptor.Name }); } else { this.m_logSource.LogDebug(" Found method id={0} name={1}", new object[] { i, "<null>" }); } } } } rPCContext.Header = header; rPCContext.Payload = body; rPCContext.ResponseReceived = true; if (rPCContext.Callback != null) { rPCContext.Callback(rPCContext); } this.waitingForResponse.Remove(header.Token); } } } }
public ChannelService() : base("bnet.protocol.channel.Channel") { this.Methods = new MethodDescriptor[9]; MethodDescriptor[] methods = this.Methods; int num = (int)((UIntPtr)1); string n = "bnet.protocol.channel.Channel.AddMember"; uint i = 1u; if (ChannelService.< > f__mg$cache0 == null) { ChannelService.< > f__mg$cache0 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods[num] = new MethodDescriptor(n, i, ChannelService.< > f__mg$cache0); MethodDescriptor[] methods2 = this.Methods; int num2 = (int)((UIntPtr)2); string n2 = "bnet.protocol.channel.Channel.RemoveMember"; uint i2 = 2u; if (ChannelService.< > f__mg$cache1 == null) { ChannelService.< > f__mg$cache1 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods2[num2] = new MethodDescriptor(n2, i2, ChannelService.< > f__mg$cache1); MethodDescriptor[] methods3 = this.Methods; int num3 = (int)((UIntPtr)3); string n3 = "bnet.protocol.channel.Channel.SendMessage"; uint i3 = 3u; if (ChannelService.< > f__mg$cache2 == null) { ChannelService.< > f__mg$cache2 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods3[num3] = new MethodDescriptor(n3, i3, ChannelService.< > f__mg$cache2); MethodDescriptor[] methods4 = this.Methods; int num4 = (int)((UIntPtr)4); string n4 = "bnet.protocol.channel.Channel.UpdateChannelState"; uint i4 = 4u; if (ChannelService.< > f__mg$cache3 == null) { ChannelService.< > f__mg$cache3 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods4[num4] = new MethodDescriptor(n4, i4, ChannelService.< > f__mg$cache3); MethodDescriptor[] methods5 = this.Methods; int num5 = (int)((UIntPtr)5); string n5 = "bnet.protocol.channel.Channel.UpdateMemberState"; uint i5 = 5u; if (ChannelService.< > f__mg$cache4 == null) { ChannelService.< > f__mg$cache4 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods5[num5] = new MethodDescriptor(n5, i5, ChannelService.< > f__mg$cache4); MethodDescriptor[] methods6 = this.Methods; int num6 = (int)((UIntPtr)6); string n6 = "bnet.protocol.channel.Channel.Dissolve"; uint i6 = 6u; if (ChannelService.< > f__mg$cache5 == null) { ChannelService.< > f__mg$cache5 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods6[num6] = new MethodDescriptor(n6, i6, ChannelService.< > f__mg$cache5); MethodDescriptor[] methods7 = this.Methods; int num7 = (int)((UIntPtr)7); string n7 = "bnet.protocol.channel.Channel.AddMember"; uint i7 = 7u; if (ChannelService.< > f__mg$cache6 == null) { ChannelService.< > f__mg$cache6 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods7[num7] = new MethodDescriptor(n7, i7, ChannelService.< > f__mg$cache6); MethodDescriptor[] methods8 = this.Methods; int num8 = (int)((UIntPtr)8); string n8 = "bnet.protocol.channel.Channel.UnsubscribeMember"; uint i8 = 8u; if (ChannelService.< > f__mg$cache7 == null) { ChannelService.< > f__mg$cache7 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods8[num8] = new MethodDescriptor(n8, i8, ChannelService.< > f__mg$cache7); }
public void Update() { this.ProcessPendingOutboundPackets(); if (this.outBoundPackets.get_Count() > 0) { Queue <BattleNetPacket> queue = this.outBoundPackets; Queue <BattleNetPacket> queue2; lock (queue) { queue2 = new Queue <BattleNetPacket>(this.outBoundPackets.ToArray()); this.outBoundPackets.Clear(); } while (queue2.get_Count() > 0) { BattleNetPacket packet = queue2.Dequeue(); if (this.Connection != null) { this.Connection.QueuePacket(packet); } else { this.m_logSource.LogError("##Client Connection object does not exists!##"); } } } if (this.Connection != null) { this.Connection.Update(); } if (this.incomingPackets.get_Count() > 0) { Queue <BattleNetPacket> queue3 = this.incomingPackets; Queue <BattleNetPacket> queue4; lock (queue3) { queue4 = new Queue <BattleNetPacket>(this.incomingPackets.ToArray()); this.incomingPackets.Clear(); } while (queue4.get_Count() > 0) { BattleNetPacket battleNetPacket = queue4.Dequeue(); Header header = battleNetPacket.GetHeader(); this.PrintHeader(header); byte[] payload = (byte[])battleNetPacket.GetBody(); if (header.ServiceId == 254u) { RPCContext rPCContext; if (this.waitingForResponse.TryGetValue(header.Token, ref rPCContext)) { ServiceDescriptor importedServiceById = this.serviceHelper.GetImportedServiceById(rPCContext.Header.ServiceId); MethodDescriptor.ParseMethod parseMethod = null; if (importedServiceById != null) { parseMethod = importedServiceById.GetParser(rPCContext.Header.MethodId); } if (parseMethod == null) { if (importedServiceById != null) { this.m_logSource.LogWarning("Incoming Response: Unable to find method for serviceName={0} method id={1}", new object[] { importedServiceById.Name, rPCContext.Header.MethodId }); int methodCount = importedServiceById.GetMethodCount(); this.m_logSource.LogDebug(" Found {0} methods", new object[] { methodCount }); for (int i = 0; i < methodCount; i++) { MethodDescriptor methodDescriptor = importedServiceById.GetMethodDescriptor((uint)i); if (methodDescriptor == null && i != 0) { this.m_logSource.LogDebug(" Found method id={0} name={1}", new object[] { i, "<null>" }); } else { this.m_logSource.LogDebug(" Found method id={0} name={1}", new object[] { i, methodDescriptor.Name }); } } } else { this.m_logSource.LogWarning("Incoming Response: Unable to identify service id={0}", new object[] { rPCContext.Header.ServiceId }); } } rPCContext.Header = header; rPCContext.Payload = payload; rPCContext.ResponseReceived = true; if (rPCContext.Callback != null) { rPCContext.Callback(rPCContext); } this.waitingForResponse.Remove(header.Token); } } else { ServiceDescriptor exportedServiceDescriptor = this.GetExportedServiceDescriptor(header.ServiceId); if (exportedServiceDescriptor != null) { MethodDescriptor.ParseMethod parser = this.serviceHelper.GetExportedServiceById(header.ServiceId).GetParser(header.MethodId); if (parser == null) { this.m_logSource.LogDebug("Incoming Packet: NULL TYPE service=" + this.serviceHelper.GetExportedServiceById(header.ServiceId).Name + ", method=" + this.serviceHelper.GetExportedServiceById(header.ServiceId).GetMethodName(header.MethodId)); } if (exportedServiceDescriptor.HasMethodListener(header.MethodId)) { exportedServiceDescriptor.NotifyMethodListener(new RPCContext { Header = header, Payload = payload, ResponseReceived = true }); } else { string text = (exportedServiceDescriptor == null || string.IsNullOrEmpty(exportedServiceDescriptor.Name)) ? "<null>" : exportedServiceDescriptor.Name; this.m_logSource.LogError(string.Concat(new object[] { "[!]Unhandled Server Request Received (Service Name: ", text, " Service id:", header.ServiceId, " Method id:", header.MethodId, ")" })); } } else { this.m_logSource.LogError(string.Concat(new object[] { "[!]Server Requested an Unsupported (Service id:", header.ServiceId, " Method id:", header.MethodId, ")" })); } } } } }
public void Update() { this.ProcessPendingOutboundPackets(); if (this.outBoundPackets.Count > 0) { Queue <BattleNetPacket> queue; Queue <BattleNetPacket> outBoundPackets = this.outBoundPackets; lock (outBoundPackets) { queue = new Queue <BattleNetPacket>(this.outBoundPackets.ToArray()); this.outBoundPackets.Clear(); } while (queue.Count > 0) { BattleNetPacket packet = queue.Dequeue(); if (this.Connection != null) { this.Connection.QueuePacket(packet); } else { this.m_logSource.LogError("##Client Connection object does not exists!##"); } } } if (this.Connection != null) { this.Connection.Update(); } if (this.incomingPackets.Count > 0) { Queue <BattleNetPacket> queue3; Queue <BattleNetPacket> incomingPackets = this.incomingPackets; lock (incomingPackets) { queue3 = new Queue <BattleNetPacket>(this.incomingPackets.ToArray()); this.incomingPackets.Clear(); } while (queue3.Count > 0) { BattleNetPacket packet2 = queue3.Dequeue(); bnet.protocol.Header h = packet2.GetHeader(); this.PrintHeader(h); byte[] body = (byte[])packet2.GetBody(); if (h.ServiceId == 0xfe) { RPCContext context; if (this.waitingForResponse.TryGetValue(h.Token, out context)) { ServiceDescriptor importedServiceById = this.serviceHelper.GetImportedServiceById(context.Header.ServiceId); MethodDescriptor.ParseMethod parser = null; if (importedServiceById != null) { parser = importedServiceById.GetParser(context.Header.MethodId); } if (parser == null) { if (importedServiceById != null) { object[] args = new object[] { importedServiceById.Name, context.Header.MethodId }; this.m_logSource.LogWarning("Incoming Response: Unable to find method for serviceName={0} method id={1}", args); int methodCount = importedServiceById.GetMethodCount(); object[] objArray2 = new object[] { methodCount }; this.m_logSource.LogDebug(" Found {0} methods", objArray2); for (int i = 0; i < methodCount; i++) { MethodDescriptor methodDescriptor = importedServiceById.GetMethodDescriptor((uint)i); if ((methodDescriptor == null) && (i != 0)) { object[] objArray3 = new object[] { i, "<null>" }; this.m_logSource.LogDebug(" Found method id={0} name={1}", objArray3); } else { object[] objArray4 = new object[] { i, methodDescriptor.Name }; this.m_logSource.LogDebug(" Found method id={0} name={1}", objArray4); } } } else { object[] objArray5 = new object[] { context.Header.ServiceId }; this.m_logSource.LogWarning("Incoming Response: Unable to identify service id={0}", objArray5); } } context.Header = h; context.Payload = body; context.ResponseReceived = true; if (context.Callback != null) { context.Callback(context); } this.waitingForResponse.Remove(h.Token); } } else { ServiceDescriptor exportedServiceDescriptor = this.GetExportedServiceDescriptor(h.ServiceId); if (exportedServiceDescriptor != null) { if (this.serviceHelper.GetExportedServiceById(h.ServiceId).GetParser(h.MethodId) == null) { this.m_logSource.LogDebug("Incoming Packet: NULL TYPE service=" + this.serviceHelper.GetExportedServiceById(h.ServiceId).Name + ", method=" + this.serviceHelper.GetExportedServiceById(h.ServiceId).GetMethodName(h.MethodId)); } if (exportedServiceDescriptor.HasMethodListener(h.MethodId)) { RPCContext context2 = new RPCContext { Header = h, Payload = body, ResponseReceived = true }; exportedServiceDescriptor.NotifyMethodListener(context2); } else { string str = ((exportedServiceDescriptor == null) || string.IsNullOrEmpty(exportedServiceDescriptor.Name)) ? "<null>" : exportedServiceDescriptor.Name; this.m_logSource.LogError(string.Concat(new object[] { "[!]Unhandled Server Request Received (Service Name: ", str, " Service id:", h.ServiceId, " Method id:", h.MethodId, ")" })); } } else { this.m_logSource.LogError(string.Concat(new object[] { "[!]Server Requested an Unsupported (Service id:", h.ServiceId, " Method id:", h.MethodId, ")" })); } } } } }
public FriendsService() : base("bnet.protocol.friends.FriendsService") { this.Methods = new MethodDescriptor[13]; MethodDescriptor[] methods = this.Methods; int num = (int)((UIntPtr)1); string n = "bnet.protocol.friends.FriendsService.SubscribeToFriends"; uint i = 1u; if (FriendsService.< > f__mg$cache0 == null) { FriendsService.< > f__mg$cache0 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <SubscribeToFriendsResponse>); } methods[num] = new MethodDescriptor(n, i, FriendsService.< > f__mg$cache0); MethodDescriptor[] methods2 = this.Methods; int num2 = (int)((UIntPtr)2); string n2 = "bnet.protocol.friends.FriendsService.SendInvitation"; uint i2 = 2u; if (FriendsService.< > f__mg$cache1 == null) { FriendsService.< > f__mg$cache1 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods2[num2] = new MethodDescriptor(n2, i2, FriendsService.< > f__mg$cache1); MethodDescriptor[] methods3 = this.Methods; int num3 = (int)((UIntPtr)3); string n3 = "bnet.protocol.friends.FriendsService.AcceptInvitation"; uint i3 = 3u; if (FriendsService.< > f__mg$cache2 == null) { FriendsService.< > f__mg$cache2 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods3[num3] = new MethodDescriptor(n3, i3, FriendsService.< > f__mg$cache2); MethodDescriptor[] methods4 = this.Methods; int num4 = (int)((UIntPtr)4); string n4 = "bnet.protocol.friends.FriendsService.RevokeInvitation"; uint i4 = 4u; if (FriendsService.< > f__mg$cache3 == null) { FriendsService.< > f__mg$cache3 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods4[num4] = new MethodDescriptor(n4, i4, FriendsService.< > f__mg$cache3); MethodDescriptor[] methods5 = this.Methods; int num5 = (int)((UIntPtr)5); string n5 = "bnet.protocol.friends.FriendsService.DeclineInvitation"; uint i5 = 5u; if (FriendsService.< > f__mg$cache4 == null) { FriendsService.< > f__mg$cache4 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods5[num5] = new MethodDescriptor(n5, i5, FriendsService.< > f__mg$cache4); MethodDescriptor[] methods6 = this.Methods; int num6 = (int)((UIntPtr)6); string n6 = "bnet.protocol.friends.FriendsService.IgnoreInvitation"; uint i6 = 6u; if (FriendsService.< > f__mg$cache5 == null) { FriendsService.< > f__mg$cache5 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods6[num6] = new MethodDescriptor(n6, i6, FriendsService.< > f__mg$cache5); MethodDescriptor[] methods7 = this.Methods; int num7 = (int)((UIntPtr)7); string n7 = "bnet.protocol.friends.FriendsService.AssignRole"; uint i7 = 7u; if (FriendsService.< > f__mg$cache6 == null) { FriendsService.< > f__mg$cache6 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods7[num7] = new MethodDescriptor(n7, i7, FriendsService.< > f__mg$cache6); MethodDescriptor[] methods8 = this.Methods; int num8 = (int)((UIntPtr)8); string n8 = "bnet.protocol.friends.FriendsService.RemoveFriend"; uint i8 = 8u; if (FriendsService.< > f__mg$cache7 == null) { FriendsService.< > f__mg$cache7 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <GenericFriendResponse>); } methods8[num8] = new MethodDescriptor(n8, i8, FriendsService.< > f__mg$cache7); MethodDescriptor[] methods9 = this.Methods; int num9 = (int)((UIntPtr)9); string n9 = "bnet.protocol.friends.FriendsService.ViewFriends"; uint i9 = 9u; if (FriendsService.< > f__mg$cache8 == null) { FriendsService.< > f__mg$cache8 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <ViewFriendsResponse>); } methods9[num9] = new MethodDescriptor(n9, i9, FriendsService.< > f__mg$cache8); MethodDescriptor[] methods10 = this.Methods; int num10 = (int)((UIntPtr)10); string n10 = "bnet.protocol.friends.FriendsService.UpdateFriendState"; uint i10 = 10u; if (FriendsService.< > f__mg$cache9 == null) { FriendsService.< > f__mg$cache9 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods10[num10] = new MethodDescriptor(n10, i10, FriendsService.< > f__mg$cache9); MethodDescriptor[] methods11 = this.Methods; int num11 = (int)((UIntPtr)11); string n11 = "bnet.protocol.friends.FriendsService.UnsubscribeToFriends"; uint i11 = 11u; if (FriendsService.< > f__mg$cacheA == null) { FriendsService.< > f__mg$cacheA = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods11[num11] = new MethodDescriptor(n11, i11, FriendsService.< > f__mg$cacheA); MethodDescriptor[] methods12 = this.Methods; int num12 = (int)((UIntPtr)12); string n12 = "bnet.protocol.friends.FriendsService.RevokeAllInvitations"; uint i12 = 12u; if (FriendsService.< > f__mg$cacheB == null) { FriendsService.< > f__mg$cacheB = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods12[num12] = new MethodDescriptor(n12, i12, FriendsService.< > f__mg$cacheB); }
public ChannelOwnerService() : base("bnet.protocol.channel.ChannelOwner") { this.Methods = new MethodDescriptor[7]; MethodDescriptor[] methods = this.Methods; int num = (int)((UIntPtr)1); string n = "bnet.protocol.channel.ChannelOwner.GetChannelId"; uint i = 1u; if (ChannelOwnerService.< > f__mg$cache0 == null) { ChannelOwnerService.< > f__mg$cache0 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <GetChannelIdResponse>); } methods[num] = new MethodDescriptor(n, i, ChannelOwnerService.< > f__mg$cache0); MethodDescriptor[] methods2 = this.Methods; int num2 = (int)((UIntPtr)2); string n2 = "bnet.protocol.channel.ChannelOwner.CreateChannel"; uint i2 = 2u; if (ChannelOwnerService.< > f__mg$cache1 == null) { ChannelOwnerService.< > f__mg$cache1 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <CreateChannelResponse>); } methods2[num2] = new MethodDescriptor(n2, i2, ChannelOwnerService.< > f__mg$cache1); MethodDescriptor[] methods3 = this.Methods; int num3 = (int)((UIntPtr)3); string n3 = "bnet.protocol.channel.ChannelOwner.JoinChannel"; uint i3 = 3u; if (ChannelOwnerService.< > f__mg$cache2 == null) { ChannelOwnerService.< > f__mg$cache2 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <JoinChannelResponse>); } methods3[num3] = new MethodDescriptor(n3, i3, ChannelOwnerService.< > f__mg$cache2); MethodDescriptor[] methods4 = this.Methods; int num4 = (int)((UIntPtr)4); string n4 = "bnet.protocol.channel.ChannelOwner.FindChannel"; uint i4 = 4u; if (ChannelOwnerService.< > f__mg$cache3 == null) { ChannelOwnerService.< > f__mg$cache3 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <FindChannelResponse>); } methods4[num4] = new MethodDescriptor(n4, i4, ChannelOwnerService.< > f__mg$cache3); MethodDescriptor[] methods5 = this.Methods; int num5 = (int)((UIntPtr)5); string n5 = "bnet.protocol.channel.ChannelOwner.GetChannelInfo"; uint i5 = 5u; if (ChannelOwnerService.< > f__mg$cache4 == null) { ChannelOwnerService.< > f__mg$cache4 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <GetChannelInfoResponse>); } methods5[num5] = new MethodDescriptor(n5, i5, ChannelOwnerService.< > f__mg$cache4); MethodDescriptor[] methods6 = this.Methods; int num6 = (int)((UIntPtr)6); string n6 = "bnet.protocol.channel.ChannelOwner.SubscribeChannel"; uint i6 = 6u; if (ChannelOwnerService.< > f__mg$cache5 == null) { ChannelOwnerService.< > f__mg$cache5 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <SubscribeChannelResponse>); } methods6[num6] = new MethodDescriptor(n6, i6, ChannelOwnerService.< > f__mg$cache5); }
public GameUtilitiesService() : base("bnet.protocol.game_utilities.GameUtilities") { this.Methods = new MethodDescriptor[11]; MethodDescriptor[] methods = this.Methods; int num = (int)((UIntPtr)1); string n = "bnet.protocol.game_utilities.GameUtilities.ProcessClientRequest"; uint i = 1u; if (GameUtilitiesService.< > f__mg$cache0 == null) { GameUtilitiesService.< > f__mg$cache0 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <ClientResponse>); } methods[num] = new MethodDescriptor(n, i, GameUtilitiesService.< > f__mg$cache0); MethodDescriptor[] methods2 = this.Methods; int num2 = (int)((UIntPtr)2); string n2 = "bnet.protocol.game_utilities.GameUtilities.PresenceChannelCreated"; uint i2 = 2u; if (GameUtilitiesService.< > f__mg$cache1 == null) { GameUtilitiesService.< > f__mg$cache1 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods2[num2] = new MethodDescriptor(n2, i2, GameUtilitiesService.< > f__mg$cache1); MethodDescriptor[] methods3 = this.Methods; int num3 = (int)((UIntPtr)3); string n3 = "bnet.protocol.game_utilities.GameUtilities.GetPlayerVariables"; uint i3 = 3u; if (GameUtilitiesService.< > f__mg$cache2 == null) { GameUtilitiesService.< > f__mg$cache2 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <GetPlayerVariablesResponse>); } methods3[num3] = new MethodDescriptor(n3, i3, GameUtilitiesService.< > f__mg$cache2); MethodDescriptor[] methods4 = this.Methods; int num4 = (int)((UIntPtr)5); string n4 = "bnet.protocol.game_utilities.GameUtilities.GetLoad"; uint i4 = 5u; if (GameUtilitiesService.< > f__mg$cache3 == null) { GameUtilitiesService.< > f__mg$cache3 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <ServerState>); } methods4[num4] = new MethodDescriptor(n4, i4, GameUtilitiesService.< > f__mg$cache3); MethodDescriptor[] methods5 = this.Methods; int num5 = (int)((UIntPtr)6); string n5 = "bnet.protocol.game_utilities.GameUtilities.ProcessServerRequest"; uint i5 = 6u; if (GameUtilitiesService.< > f__mg$cache4 == null) { GameUtilitiesService.< > f__mg$cache4 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <ServerResponse>); } methods5[num5] = new MethodDescriptor(n5, i5, GameUtilitiesService.< > f__mg$cache4); MethodDescriptor[] methods6 = this.Methods; int num6 = (int)((UIntPtr)7); string n6 = "bnet.protocol.game_utilities.GameUtilities.NotifyGameAccountOnline"; uint i6 = 7u; if (GameUtilitiesService.< > f__mg$cache5 == null) { GameUtilitiesService.< > f__mg$cache5 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NORESPONSE>); } methods6[num6] = new MethodDescriptor(n6, i6, GameUtilitiesService.< > f__mg$cache5); MethodDescriptor[] methods7 = this.Methods; int num7 = (int)((UIntPtr)8); string n7 = "bnet.protocol.game_utilities.GameUtilities.NotifyGameAccountOffline"; uint i7 = 8u; if (GameUtilitiesService.< > f__mg$cache6 == null) { GameUtilitiesService.< > f__mg$cache6 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NORESPONSE>); } methods7[num7] = new MethodDescriptor(n7, i7, GameUtilitiesService.< > f__mg$cache6); MethodDescriptor[] methods8 = this.Methods; int num8 = (int)((UIntPtr)10); string n8 = "bnet.protocol.game_utilities.GameUtilities.GetAllValuesForAttribute"; uint i8 = 10u; if (GameUtilitiesService.< > f__mg$cache7 == null) { GameUtilitiesService.< > f__mg$cache7 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <GetAllValuesForAttributeResponse>); } methods8[num8] = new MethodDescriptor(n8, i8, GameUtilitiesService.< > f__mg$cache7); }
public AccountService() : base("bnet.protocol.account.AccountService") { this.Methods = new MethodDescriptor[37]; MethodDescriptor[] methods = this.Methods; int num = (int)((UIntPtr)12); string n = "bnet.protocol.account.AccountService.GetGameAccount"; uint i = 12u; if (AccountService.< > f__mg$cache0 == null) { AccountService.< > f__mg$cache0 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <GameAccountBlob>); } methods[num] = new MethodDescriptor(n, i, AccountService.< > f__mg$cache0); MethodDescriptor[] methods2 = this.Methods; int num2 = (int)((UIntPtr)13); string n2 = "bnet.protocol.account.AccountService.GetAccount"; uint i2 = 13u; if (AccountService.< > f__mg$cache1 == null) { AccountService.< > f__mg$cache1 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <GetAccountResponse>); } methods2[num2] = new MethodDescriptor(n2, i2, AccountService.< > f__mg$cache1); MethodDescriptor[] methods3 = this.Methods; int num3 = (int)((UIntPtr)14); string n3 = "bnet.protocol.account.AccountService.CreateGameAccount"; uint i3 = 14u; if (AccountService.< > f__mg$cache2 == null) { AccountService.< > f__mg$cache2 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <GameAccountHandle>); } methods3[num3] = new MethodDescriptor(n3, i3, AccountService.< > f__mg$cache2); MethodDescriptor[] methods4 = this.Methods; int num4 = (int)((UIntPtr)15); string n4 = "bnet.protocol.account.AccountService.IsIgrAddress"; uint i4 = 15u; if (AccountService.< > f__mg$cache3 == null) { AccountService.< > f__mg$cache3 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods4[num4] = new MethodDescriptor(n4, i4, AccountService.< > f__mg$cache3); MethodDescriptor[] methods5 = this.Methods; int num5 = (int)((UIntPtr)20); string n5 = "bnet.protocol.account.AccountService.CacheExpire"; uint i5 = 20u; if (AccountService.< > f__mg$cache4 == null) { AccountService.< > f__mg$cache4 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NORESPONSE>); } methods5[num5] = new MethodDescriptor(n5, i5, AccountService.< > f__mg$cache4); MethodDescriptor[] methods6 = this.Methods; int num6 = (int)((UIntPtr)21); string n6 = "bnet.protocol.account.AccountService.CredentialUpdate"; uint i6 = 21u; if (AccountService.< > f__mg$cache5 == null) { AccountService.< > f__mg$cache5 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NORESPONSE>); } methods6[num6] = new MethodDescriptor(n6, i6, AccountService.< > f__mg$cache5); MethodDescriptor[] methods7 = this.Methods; int num7 = (int)((UIntPtr)22); string n7 = "bnet.protocol.account.AccountService.FlagUpdate"; uint i7 = 22u; if (AccountService.< > f__mg$cache6 == null) { AccountService.< > f__mg$cache6 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <CredentialUpdateResponse>); } methods7[num7] = new MethodDescriptor(n7, i7, AccountService.< > f__mg$cache6); MethodDescriptor[] methods8 = this.Methods; int num8 = (int)((UIntPtr)23); string n8 = "bnet.protocol.account.AccountService.GetWalletList"; uint i8 = 23u; if (AccountService.< > f__mg$cache7 == null) { AccountService.< > f__mg$cache7 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <GetWalletListResponse>); } methods8[num8] = new MethodDescriptor(n8, i8, AccountService.< > f__mg$cache7); MethodDescriptor[] methods9 = this.Methods; int num9 = (int)((UIntPtr)24); string n9 = "bnet.protocol.account.AccountService.GetEBalance"; uint i9 = 24u; if (AccountService.< > f__mg$cache8 == null) { AccountService.< > f__mg$cache8 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <GetEBalanceResponse>); } methods9[num9] = new MethodDescriptor(n9, i9, AccountService.< > f__mg$cache8); MethodDescriptor[] methods10 = this.Methods; int num10 = (int)((UIntPtr)25); string n10 = "bnet.protocol.account.AccountService.Subscribe"; uint i10 = 25u; if (AccountService.< > f__mg$cache9 == null) { AccountService.< > f__mg$cache9 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <SubscriptionUpdateResponse>); } methods10[num10] = new MethodDescriptor(n10, i10, AccountService.< > f__mg$cache9); MethodDescriptor[] methods11 = this.Methods; int num11 = (int)((UIntPtr)26); string n11 = "bnet.protocol.account.AccountService.Unsubscribe"; uint i11 = 26u; if (AccountService.< > f__mg$cacheA == null) { AccountService.< > f__mg$cacheA = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods11[num11] = new MethodDescriptor(n11, i11, AccountService.< > f__mg$cacheA); MethodDescriptor[] methods12 = this.Methods; int num12 = (int)((UIntPtr)27); string n12 = "bnet.protocol.account.AccountService.GetEBalanceRestrictions"; uint i12 = 27u; if (AccountService.< > f__mg$cacheB == null) { AccountService.< > f__mg$cacheB = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <GetEBalanceRestrictionsResponse>); } methods12[num12] = new MethodDescriptor(n12, i12, AccountService.< > f__mg$cacheB); MethodDescriptor[] methods13 = this.Methods; int num13 = (int)((UIntPtr)30); string n13 = "bnet.protocol.account.AccountService.GetAccountState"; uint i13 = 30u; if (AccountService.< > f__mg$cacheC == null) { AccountService.< > f__mg$cacheC = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <GetAccountStateResponse>); } methods13[num13] = new MethodDescriptor(n13, i13, AccountService.< > f__mg$cacheC); MethodDescriptor[] methods14 = this.Methods; int num14 = (int)((UIntPtr)31); string n14 = "bnet.protocol.account.AccountService.GetGameAccountState"; uint i14 = 31u; if (AccountService.< > f__mg$cacheD == null) { AccountService.< > f__mg$cacheD = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <GetGameAccountStateResponse>); } methods14[num14] = new MethodDescriptor(n14, i14, AccountService.< > f__mg$cacheD); MethodDescriptor[] methods15 = this.Methods; int num15 = (int)((UIntPtr)32); string n15 = "bnet.protocol.account.AccountService.GetLicenses"; uint i15 = 32u; if (AccountService.< > f__mg$cacheE == null) { AccountService.< > f__mg$cacheE = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <GetLicensesResponse>); } methods15[num15] = new MethodDescriptor(n15, i15, AccountService.< > f__mg$cacheE); MethodDescriptor[] methods16 = this.Methods; int num16 = (int)((UIntPtr)33); string n16 = "bnet.protocol.account.AccountService.GetGameTimeRemainingInfo"; uint i16 = 33u; if (AccountService.< > f__mg$cacheF == null) { AccountService.< > f__mg$cacheF = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <GetGameTimeRemainingInfoResponse>); } methods16[num16] = new MethodDescriptor(n16, i16, AccountService.< > f__mg$cacheF); MethodDescriptor[] methods17 = this.Methods; int num17 = (int)((UIntPtr)34); string n17 = "bnet.protocol.account.AccountService.GetGameSessionInfo"; uint i17 = 34u; if (AccountService.< > f__mg$cache10 == null) { AccountService.< > f__mg$cache10 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <GetGameSessionInfoResponse>); } methods17[num17] = new MethodDescriptor(n17, i17, AccountService.< > f__mg$cache10); MethodDescriptor[] methods18 = this.Methods; int num18 = (int)((UIntPtr)35); string n18 = "bnet.protocol.account.AccountService.GetCAISInfo"; uint i18 = 35u; if (AccountService.< > f__mg$cache11 == null) { AccountService.< > f__mg$cache11 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <GetCAISInfoResponse>); } methods18[num18] = new MethodDescriptor(n18, i18, AccountService.< > f__mg$cache11); MethodDescriptor[] methods19 = this.Methods; int num19 = (int)((UIntPtr)36); string n19 = "bnet.protocol.account.AccountService.ForwardCacheExpire"; uint i19 = 36u; if (AccountService.< > f__mg$cache12 == null) { AccountService.< > f__mg$cache12 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods19[num19] = new MethodDescriptor(n19, i19, AccountService.< > f__mg$cache12); }
public AuthClientService() : base("bnet.protocol.authentication.AuthenticationClient") { this.Methods = new MethodDescriptor[15]; MethodDescriptor[] methods = this.Methods; int num = (int)((UIntPtr)1); string n = "bnet.protocol.authentication.AuthenticationClient.ModuleLoad"; uint i = 1u; if (AuthClientService.< > f__mg$cache0 == null) { AuthClientService.< > f__mg$cache0 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <ModuleLoadRequest>); } methods[num] = new MethodDescriptor(n, i, AuthClientService.< > f__mg$cache0); MethodDescriptor[] methods2 = this.Methods; int num2 = (int)((UIntPtr)2); string n2 = "bnet.protocol.authentication.AuthenticationClient.ModuleMessage"; uint i2 = 2u; if (AuthClientService.< > f__mg$cache1 == null) { AuthClientService.< > f__mg$cache1 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <ModuleMessageRequest>); } methods2[num2] = new MethodDescriptor(n2, i2, AuthClientService.< > f__mg$cache1); MethodDescriptor[] methods3 = this.Methods; int num3 = (int)((UIntPtr)3); string n3 = "bnet.protocol.authentication.AuthenticationClient.AccountSettings"; uint i3 = 3u; if (AuthClientService.< > f__mg$cache2 == null) { AuthClientService.< > f__mg$cache2 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <AccountSettingsNotification>); } methods3[num3] = new MethodDescriptor(n3, i3, AuthClientService.< > f__mg$cache2); MethodDescriptor[] methods4 = this.Methods; int num4 = (int)((UIntPtr)4); string n4 = "bnet.protocol.authentication.AuthenticationClient.ServerStateChange"; uint i4 = 4u; if (AuthClientService.< > f__mg$cache3 == null) { AuthClientService.< > f__mg$cache3 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <ServerStateChangeRequest>); } methods4[num4] = new MethodDescriptor(n4, i4, AuthClientService.< > f__mg$cache3); MethodDescriptor[] methods5 = this.Methods; int num5 = (int)((UIntPtr)5); string n5 = "bnet.protocol.authentication.AuthenticationClient.LogonComplete"; uint i5 = 5u; if (AuthClientService.< > f__mg$cache4 == null) { AuthClientService.< > f__mg$cache4 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <LogonResult>); } methods5[num5] = new MethodDescriptor(n5, i5, AuthClientService.< > f__mg$cache4); MethodDescriptor[] methods6 = this.Methods; int num6 = (int)((UIntPtr)6); string n6 = "bnet.protocol.authentication.AuthenticationClient.MemModuleLoad"; uint i6 = 6u; if (AuthClientService.< > f__mg$cache5 == null) { AuthClientService.< > f__mg$cache5 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <MemModuleLoadRequest>); } methods6[num6] = new MethodDescriptor(n6, i6, AuthClientService.< > f__mg$cache5); MethodDescriptor[] methods7 = this.Methods; int num7 = (int)((UIntPtr)10); string n7 = "bnet.protocol.authentication.AuthenticationClient.LogonUpdate"; uint i7 = 10u; if (AuthClientService.< > f__mg$cache6 == null) { AuthClientService.< > f__mg$cache6 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <LogonUpdateRequest>); } methods7[num7] = new MethodDescriptor(n7, i7, AuthClientService.< > f__mg$cache6); MethodDescriptor[] methods8 = this.Methods; int num8 = (int)((UIntPtr)11); string n8 = "bnet.protocol.authentication.AuthenticationClient.VersionInfoUpdated"; uint i8 = 11u; if (AuthClientService.< > f__mg$cache7 == null) { AuthClientService.< > f__mg$cache7 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <VersionInfoNotification>); } methods8[num8] = new MethodDescriptor(n8, i8, AuthClientService.< > f__mg$cache7); MethodDescriptor[] methods9 = this.Methods; int num9 = (int)((UIntPtr)12); string n9 = "bnet.protocol.authentication.AuthenticationClient.LogonQueueUpdate"; uint i9 = 12u; if (AuthClientService.< > f__mg$cache8 == null) { AuthClientService.< > f__mg$cache8 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <LogonQueueUpdateRequest>); } methods9[num9] = new MethodDescriptor(n9, i9, AuthClientService.< > f__mg$cache8); MethodDescriptor[] methods10 = this.Methods; int num10 = (int)((UIntPtr)13); string n10 = "bnet.protocol.authentication.AuthenticationClient.LogonQueueEnd"; uint i10 = 13u; if (AuthClientService.< > f__mg$cache9 == null) { AuthClientService.< > f__mg$cache9 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <NoData>); } methods10[num10] = new MethodDescriptor(n10, i10, AuthClientService.< > f__mg$cache9); MethodDescriptor[] methods11 = this.Methods; int num11 = (int)((UIntPtr)14); string n11 = "bnet.protocol.authentication.AuthenticationClient.GameAccountSelected"; uint i11 = 14u; if (AuthClientService.< > f__mg$cacheA == null) { AuthClientService.< > f__mg$cacheA = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <GameAccountSelectedRequest>); } methods11[num11] = new MethodDescriptor(n11, i11, AuthClientService.< > f__mg$cacheA); }
public FriendsNotify() : base("bnet.protocol.friends.FriendsNotify") { this.Methods = new MethodDescriptor[8]; MethodDescriptor[] methods = this.Methods; int num = (int)((UIntPtr)1); string n = "bnet.protocol.friends.FriendsNotify.NotifyFriendAdded"; uint i = 1u; if (FriendsNotify.< > f__mg$cache0 == null) { FriendsNotify.< > f__mg$cache0 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <FriendNotification>); } methods[num] = new MethodDescriptor(n, i, FriendsNotify.< > f__mg$cache0); MethodDescriptor[] methods2 = this.Methods; int num2 = (int)((UIntPtr)2); string n2 = "bnet.protocol.friends.FriendsNotify.NotifyFriendRemoved"; uint i2 = 2u; if (FriendsNotify.< > f__mg$cache1 == null) { FriendsNotify.< > f__mg$cache1 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <FriendNotification>); } methods2[num2] = new MethodDescriptor(n2, i2, FriendsNotify.< > f__mg$cache1); MethodDescriptor[] methods3 = this.Methods; int num3 = (int)((UIntPtr)3); string n3 = "bnet.protocol.friends.FriendsNotify.NotifyReceivedInvitationAdded"; uint i3 = 3u; if (FriendsNotify.< > f__mg$cache2 == null) { FriendsNotify.< > f__mg$cache2 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <InvitationNotification>); } methods3[num3] = new MethodDescriptor(n3, i3, FriendsNotify.< > f__mg$cache2); MethodDescriptor[] methods4 = this.Methods; int num4 = (int)((UIntPtr)4); string n4 = "bnet.protocol.friends.FriendsNotify.NotifyReceivedInvitationRemoved"; uint i4 = 4u; if (FriendsNotify.< > f__mg$cache3 == null) { FriendsNotify.< > f__mg$cache3 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <InvitationNotification>); } methods4[num4] = new MethodDescriptor(n4, i4, FriendsNotify.< > f__mg$cache3); MethodDescriptor[] methods5 = this.Methods; int num5 = (int)((UIntPtr)5); string n5 = "bnet.protocol.friends.FriendsNotify.NotifySentInvitationAdded"; uint i5 = 5u; if (FriendsNotify.< > f__mg$cache4 == null) { FriendsNotify.< > f__mg$cache4 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <InvitationNotification>); } methods5[num5] = new MethodDescriptor(n5, i5, FriendsNotify.< > f__mg$cache4); MethodDescriptor[] methods6 = this.Methods; int num6 = (int)((UIntPtr)6); string n6 = "bnet.protocol.friends.FriendsNotify.NotifySentInvitationRemoved"; uint i6 = 6u; if (FriendsNotify.< > f__mg$cache5 == null) { FriendsNotify.< > f__mg$cache5 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <InvitationNotification>); } methods6[num6] = new MethodDescriptor(n6, i6, FriendsNotify.< > f__mg$cache5); MethodDescriptor[] methods7 = this.Methods; int num7 = (int)((UIntPtr)7); string n7 = "bnet.protocol.friends.FriendsNotify.NotifyUpdateFriendState"; uint i7 = 7u; if (FriendsNotify.< > f__mg$cache6 == null) { FriendsNotify.< > f__mg$cache6 = new MethodDescriptor.ParseMethod(ProtobufUtil.ParseFromGeneric <UpdateFriendStateNotification>); } methods7[num7] = new MethodDescriptor(n7, i7, FriendsNotify.< > f__mg$cache6); }