Skip to content

Commit

Permalink
Removed some excess code
Browse files Browse the repository at this point in the history
  • Loading branch information
P-Toby committed May 30, 2018
1 parent a2435fb commit b728233
Show file tree
Hide file tree
Showing 2 changed files with 0 additions and 53 deletions.
8 changes: 0 additions & 8 deletions AlpacaPBeM/TurnReceiver.cs
Expand Up @@ -39,14 +39,6 @@ public void GetTurn(string gameName, string pwd)
inbox.Open(FolderAccess.ReadOnly);

int count = inbox.Count();

for (int i = 0; i < inbox.Count; i++)
{
var message = inbox.GetMessage(i);
Console.WriteLine("Subject: {0}", message.Subject);
}


bool foundGame = false;
for (int i = count-1; i > 0; --i)
{
Expand Down
45 changes: 0 additions & 45 deletions AlpacaPBeM/TurnSender.cs
Expand Up @@ -65,50 +65,5 @@ public void SendTurn(string gameName, string pwd)
Console.WriteLine(ex.ToString());
}
}

//public void SendTurn(string gameName)
//{
// try
// {
// MailMessage Mail = new MailMessage();
// SmtpClient Server = new SmtpClient(Settings.Default["UsrSMTPServer"].ToString());
// Mail.From = new MailAddress(Settings.Default["Email"].ToString());
// Mail.To.Add(Settings.Default["TurnEmail"].ToString());
// Mail.Subject = "Turn from AlpacaPBeM";
// Mail.Body = "Sending turn from AlpacaPBeM!";

// string ordersPath = System.IO.Path.Combine(Settings.Default["Savedgames"].ToString(), gameName);
// string []dirFiles = Directory.GetFiles(ordersPath);
// bool fileFound = false;
// foreach (var file in dirFiles)
// {
// if(file.Contains(".2h"))
// {
// Console.WriteLine("Found 2h file " + file);
// Mail.Attachments.Add(new Attachment(file));
// fileFound = true;
// break;
// }
// }
// if (!fileFound)
// {
// Console.WriteLine("2h file not found!");
// }
// else
// {
// Server.Port = 587;
// Server.Credentials = new System.Net.NetworkCredential(Settings.Default["Email"].ToString(), Settings.Default["Password"].ToString());
// Server.EnableSsl = true;
// Server.Send(Mail);

// Console.WriteLine("Attempting to send mail");
// }

// }
// catch (Exception ex)
// {
// Console.WriteLine(ex.ToString());
// }
//}
}
}

0 comments on commit b728233

Please sign in to comment.