On Fri, 29 Jan 1999 12:23:51 -0600 Brad Scroggins <bscroggins@MEV.NET> writes: >hello > > Hello, I am attempting to impliment a system to where every x number of >seconds a message (like a global notice or message) would come up giving >those new to our mud a little help. The notice needs to just split out >random messages every so often. But also impliment a way for those who have >been around the mud a few times to be able to turn it off. > >Any help / suggestions / LOL's are welcome Define a PRF_NEWBIE in structs.h Add the name for it in constants.c comm.c: char *rnd_help_msg[] = { "Newbie Help Message 1\r\n", "Newbie Help Message 2\r\n", "Newbie Help Message 3\r\n", "Newbie Help Message 4\r\n", "Newbie Help Message 5\r\n" }; #define MAX_RND_HELP_MSG 4 // This is 4 because number() is from 0 to 4 Stick this block of code somewhere in comm.c that is called often(The only one I can think of might be pulse_violence, but whatever is called frequently int sendmsg = number(0, 10); if(sendmsg == 1){ for(d=descriptor_list; d; d=d->next){ if(PRF_FLAGGED(d->character, PRF_NEWBIE)) send_to_char(rnd_help_msg[number(0, MAX_RND_HELP_MSG)], d->character); } } This prolly won't work at first, may need a bit of tweaking, but it'll give you the idea Phillip Ames | Satisfaction is not guaranteed. kirk47@juno.com | -Ferengi Rule of Acquisition #19 ICQ: 8778335 | AOL IM: Grathol http://members.xoom.com/Gowron/index.html ___________________________________________________________________ You don't need to buy Internet access to use free Internet e-mail. Get completely free e-mail from Juno at http://www.juno.com/getjuno.html or call Juno at (800) 654-JUNO [654-5866] +------------------------------------------------------------+ | Ensure that you have read the CircleMUD Mailing List FAQ: | | http://qsilver.queensu.ca/~fletchra/Circle/list-faq.html | +------------------------------------------------------------+
This archive was generated by hypermail 2b30 : 12/15/00 PST