public ChobbylaLocalListener(Chobbyla chobbyla, SteamClientHelper steam, ulong initialConnectLobbyID) { LastUserAction = DateTime.Now; this.chobbyla = chobbyla; this.steam = steam; steam.Listener = this; this.initialConnectLobbyID = initialConnectLobbyID; serializer = new CommandJsonSerializer(Utils.GetAllTypesWithAttribute <ChobbyMessageAttribute>()); tts = TextToSpeechBase.Create(); steam.JoinFriendRequest += SteamOnJoinFriendRequest; steam.OverlayActivated += SteamOnOverlayActivated; steam.SteamOnline += () => { SendSteamOnline(); }; steam.SteamOffline += () => { SendSteamOffline(); }; discordController = new DiscordController(GlobalConst.ZeroKDiscordID, GlobalConst.SteamAppID.ToString()); discordController.OnJoin += DiscordOnJoinCallback; discordController.OnDisconnected += DiscordOnDisconnectedCallback; discordController.OnError += DiscordOnErrorCallback; discordController.OnReady += DiscordOnReadyCallback; discordController.OnRequest += DiscordOnRequestCallback; discordController.OnSpectate += DiscordOnSpectateCallback; timer = new Timer((o) => OnTimerTick(), this, 500, 500); }