*************************************************************** D R A G O N B A L L Z D I M E N S I O N Snippet- Newbie Info Channel V 1.1 *************************************************************** Dragonball Z Dimension Snippet Version 1.1 Author: David Piner and/or Andra Email: Dapiner@yahoo.com <---Not that long http://dbzmud.net/index.htm Date: November 27, 2001 Circle Version: Beta Patch Level 17 Version 3 Should work with most any. Requirements: n/a really Introduction Many muds out there have a semi useful "newbie" channel that gives new players information on what to do. S What it Does It give your mud a notice to new players every tick about what to do. After such a level then they will no longer see it. Credit You do not have to put my name on your login screen or create a shrine in my honor. All you have to do is put my name in your credit file or email me. You don't have to give me a whole line, maybe just like 'we also would like to thank ...' and put me somewhere. I worked hard on this and would like just a little bit of credit, wouldn't you? Also note if you use Andra's version of the function, credit him to! Auto-Patch I can not stand autopatch. The only good auto patch is OLC on stock code. After that you have to look through + and - and try to get an idea where they go. So these is a manual patch (and not that big). Disclaimer Not responible for what it does to your mud REMEMBER ALWAYS BACKUP. Thanks. History V 1.1 - Added the externs I forgot Code There are two ways to go about doing the function this. Choose according to your taste. Place __ONE__ of these functions in a file. Like act.other.c First at the top place: extern struct char_data *character_list; extern struct room_data *world; Then near the bottom add one or the other... ---------------- Function A --------------------- /* check_newbie A function that sends info to new players. This is by Dragonball Z Dimension MUD The original Version */ void check_newbie(void) { struct char_data *i, *next_char; int message; /* characters */ for (i = character_list; i; i = next_char) { next_char = i->next; if (GET_LEVEL(i) == 1) { message = number(1, 6); if (message == 1) send_to_char("Automatic Newbie Help: Test Message! a\r\n", i); if (message == 2) send_to_char("Automatic Newbie Help: Test Message! b \r\n", i); if (message == 3) send_to_char("Automatic Newbie Help: Test Message! c\r\n", i); if (message == 4) send_to_char("Automatic Newbie Help: Test Message! d\r\n", i); if (message == 5) send_to_char("Automatic Newbie Help: Test Message! e\r\n", i); if (message == 6) send_to_char("Automatic Newbie Help: Test Message! f\r\n", i); } } } ------------------------------------------------- ---------------- Function B --------------------- /* check_newbie A function that sends info to new players. This is Ramsey Stone (AKA Andra) function on how to go about it */ char *newbiemsgs[7] = { "Newbie: Test Messsage A", "Newbie: Test Messsage B", "Newbie: Test Messsage C", "Newbie: Test Messsage D", "Newbie: Test Messsage E", "Newbie: Test Messsage F", "Newbie: Test Messsage G", "Newbie: Test Messsage H" }; void check_newbie(void) { struct char_data *i, *next_char; char message[MAX_STRING_LENGTH]; /* characters */ for (i = character_list; i; i = next_char) { next_char = i->next; if (GET_LEVEL(i) == 1) { message = number(1, 6); sprintf(message, "%s\r\n", newbiemsgs[number(0,7)]); send_to_char(message, i); } } } ------------------------------------------------- Save and close that file (act.other.c or whatever you used) One last place to edit..... Open up comm.c At the top where the externs are add..... void check_newbie(void); Then go down some to void heartbeart. This is where it will be called at. Add under point_update(); (That way it will be called once per tick) check_newbie(); save comm.c, close, and recompile and hope it works! YOUR DONE!!!!!! Only thing left to do is rename the newbie function NOTICE: Not responbile for what this does. This is for entertainment only. Not all systems are alike, nor all code so you may have problems. I will not be able to help you unless you want me to send you your code that is windows comptbile (Which I wouldn't accept because its yours, you worked hard on it, why would you give it away?) FAQ A. How can I add it where it will heal the newbie? Question is, which function are you useing and do you want it random? If you are useing my function (which would work for it being random much easier) then do this: Random: Place GET_HIT(i) = GET_MAX_HIT(i); under one/two of the messages. Fixed: Place GET_HIT(i) = GET_MAX_HIT(i): at the bottem in side of the GET_LEVEL(i) If you are useing Andra's... Fixed: Place GET_HIT(i) = GET_MAX_HIT(i); in the GET_LEVEL(i) part. Random: Use the random number to call it. B. What if I wanted to add more messages. My Version: In the number(1, 6); add on to 6 then add a case like.... if (message == 7) send_to_char("Automatic Newbie Help: Test Message! f\r\n", i); Andra Version Add a case to number() Add a case to the array Increase the number in the array C. Couldn't you make it a switch? Yes Closeing I ask that if you come up with any form of nice improvment to circle please submit it to the ftp site. Even if you can't skell (pun intended on spell) I do not want no one takeing this and makeing it something else and say ' orignaly by: David Piner, please credit him.' Make your own. It toke me along time to figure this out. However if you wish to create a plug-in please email me at dapiner@yahoo.com. Thanks David Piner 'The Bard that Could' With alternate way to do it by Andra dapiner@yahoo.com