Example #1
0
 public GoogleVoice(string username, string password)
 {
     try
     {
         voiceConnection = new Voice(username, password);
         mostRecent = new SharpVoice.Message();
         mostRecent.ID = "";
     }
     catch (Exception e)
     {
         Console.WriteLine("Failed To Login: "+e.Message);
     }
     userPresent = true;
 }
Example #2
0
 public string alertFeed(out bool canReply, out string simulateResponse)
 {
     simulateResponse = null;
     canReply = false;
     if (userPresent)
     {
         if (mostRecent.ID != voiceConnection.mostRecent.ID)
         {
             canReply = true;
             mostRecent = voiceConnection.mostRecent;
             return mostRecent.displayNumber + " said " + mostRecent.Text;
         }
         
     }
     return null;
 }