Пример #1
0
        private void Connect()
        {
            Close();

            ws = new WebSocket(link);

            ws.OnMessage += (sender, e) =>
            {
                messageReceived = true;

                MessageHandling.HandleMsg(e.Data);
            };

            ws.Connect();

            try
            {
                ws.Send(initialMsgOnlyAlerts);
            }
            catch
            {
                //
            }
        }
Пример #2
0
        static void Main(string[] args)
        {
            MessageHandling.Init(new AlertDiscordHandling());

            Bot.MainAsync(args).ConfigureAwait(false).GetAwaiter().GetResult();
        }