From: Fire Subject: Mercury 2.0b Date: 10/22/00 Opening Statement: This is an OLC module that allows players to send e-mails from inside the game. The original idea was from an Implementer on the circlemud where I am the head coder. You may contact him at: Brad Carps a.k.a Oberon I did not release this as a patch for many reasons. First, I hate them. Second, I hate them. And third, they really, really suck. Seriously, I have found it much easier to install snippets than to hand-patch huge pieces of code, especially when it is hard to tell where the code goes, since you can't see the working file the patch was based on. Please keep in mind: I based most of this module on the existing OLC modules found in OasisOLCv2.0. I have recently updated the OLC to OasisOLCv2.0-pre12 however no changes to this module were necessary. The original version was located in interpreter.c in the nanny() function. However, I got tired of having all those unnecessary CON_x's, and so I ported it to it's own file and hacked it into Oasis. I also have Aedit and Hedit installed on the code base this module originated from. For the most part, that will not make much of a difference, but just in case I thought I should mention it. Assumptions: You are editing a stock, or close to stock MUD with OasisOLC 2.0. If anything has been changed, please keep that in mind while you add this. STANDARD DISCLAIMER: ######################################################################### 1. I am not responsible for this code. It is provided free of charge to the public, if you have problems with it or improve upon it, please contact me so that I can change it in the future. I will not come and install it for you, so please don't insult your intelligence by asking me to. 2. This is not a cure-all. Installing this snippet will not cause your dog to suddenly stop peeing the carpets, your cat to stop hacking up furballs, nor your MUD to suddenly become famous and full of friendly faces. It is basically one of those "wonderful" little tidbits that make each MUD a little different from the others. 3. This code will probably ruin your life. There is an Artificial Intelligence hidden deep inside the code that will spring to life when you boot up the game. It will chase you down, drag you into the game and play with your naked corpse. Your little sister will suddenly start hating you, you will begin chain smoking and spending your free time in the corner muttering to yourself. Your best friend will become the "Pizza Boy" who will undoubtedly see you more often than your family and co-workers. 4. In case you didn't notice the reference in Statement 1, this code is copyrighted in as much as it does not interfere with the original DIKU, CircleMUD or OasisOLC copyrights. If you wish to update this code contact me BEFORE you release it to others. I will not stand in the way of progress, but this was not an easy feature to code for me and it would be an insult for you to claim it as your own (not to mention the copyright infringement). ######################################################################### END OF DISCLAIMER (still love 'em :P) Since this is the README, I will add a little more information on the different tweaks I have added to support this module. On Euridia (the MUD I developed Mercury on), I installed ASCII pfiles, which makes new additions to the playerfiles easy and does not require frequent pwipes. Oberon wanted players to enter their e-mail addresses during character, so I copied the way the game detects and saves passwords to structs.h, db.c and interpreter.c. I included the information on how to do this to your own MUD in the snippet, but since this requires a player wipe when using binary player files, it is not a requirement. Basically, this is two snippets combined into one. Throughout the snippet you will notice the option of using the player's defined e-mail address, or something else. If you decided not to add to your struct char_player_data, it will not cripple Mercury in any way (provided you follow the snippet closely). This module requires sendmail, which may make it useless for Windows users. If someone would like to help me make it more portable, please contact me via e-mail to discuss it with me before releasing a 'fix'. Since the protocol for sending e-mails is so complicated, I decided not to try to write my own scaled-down version of sendmail. Such a project would definitely be a huge undertaking and is unnecessary when command- line e-mail handlers already exist. There are of course versions of sendmail and the like for Windows, but you will have to figure out for yourself the proper commands needed to send information to them. Unless I receive obvious reports of repeatable bugs, I do not plan on updating this code. I have bug-tested it thoroughly and fixed everything I could find. Further updates will be simply to keep it current with the popular version of Oasis. Many other fields are applicable, but in the spirit of circlemud I wanted to leave that up to the final users. I would like to thank the people on the circlemud mailing list who helped me through the first stages of this project. Their insight and expertise made it possible for me to go from using a perl script to parsing the information straight to sendmail, bypassing the original perl script. Specifically: Peter Ajamian (Re: [CIRCLE] execvp and the rest...) The Merciless Lord of Everything a.k.a. Sir Alec Guinness (Re: [CIRCLE] execvp and the rest...) Finally, this module was created and tested on an antiquated Linux server. Other operating systems may find it problematic. Feel free to send me the modifications you used to make it work on your system. I always give fair credit where it is due. (PSST! Look up ^ :P) I tested this snippet before releasing it, first without the GET_EMAIL option, and then with it. Everything went smoothly so I can guarantee that this will work, provided you are on a Linux server and follow the snippet exactly. Good luck, and enjoy! Shane P. Lee 5:45 AM 10/22/00