For those of you who have ever MUDded, you know what an MOTD is. For those of you who don't.. It's basically a welcome message.
When you log on it sends you whatever lines as your welcome message..
If you don't know where it is, it's in Client.GetPacket() and its above the following lines:
Code:
SendPacket(General.MyPackets.GeneralData(MyChar.UID, 0, 0, 0, 75));
There = true;
Simply replace the welcome lines (above the 2 lines stated above) with :
Code:
System.IO.StreamReader tr = new System.IO.StreamReader(System.Windows.Forms.Application.StartupPath + @"\MOTD.txt");
string A = null;
while((A = tr.ReadLine()) != null ) {
SendPacket(General.MyPackets.SendMsg(MessageId, "System", MyChar.Name, A, 2000));
}
tr.Close();
Then in your Debug folder (or whatever folder your server starts from) add a file called MOTD.txt, and edit it, save it. Now when you want a new welcome message, instead of editing it in your source then recompiling and restarting, you only need edit this file and save it.
Simple, I know, but I have had a look at several sources and none of them do this; so there you have it.