On Thu, Oct 10, 2002 at 07:23:51AM -0400, Justin Adler wrote: > const char *to_vict = NULL, *to_room = NULL; Don't read this too literally. In C it is used to declare a "string" constant. Really, it is a pointer to a constant character, initially pointed to the NULL address. > to_vict = "You feel your strength wither!"; That sentence is a string constant. It is compiled directly into the executable and loaded into memory when the MUD is started. The command you reference is repointing *to_vict to the string constant that contains the sentence. More specifically, it is setting the address marker (pointer) named to_vict to be equal to the address containing the first character of the chosen string constant. I think. But then again, I'm just a hack too... -- { IRL(Jeremy_Stanley); PGP(9E8DFF2E4F5995F8FEADDC5829ABF7441FB84657); SMTP(fungi@yuggoth.org); IRC(fungi@irc.yuggoth.org#ccl); ICQ(114362511); AIM(dreadazathoth); YAHOO(crawlingchaoslabs); FINGER(fungi@yuggoth.org); MUD(Nergel@mud.yuggoth.org:2325); WWW(http://fungi.yuggoth.org/); } -- +---------------------------------------------------------------+ | FAQ: http://qsilver.queensu.ca/~fletchra/Circle/list-faq.html | | Archives: http://post.queensu.ca/listserv/wwwarch/circle.html | | Newbie List: http://groups.yahoo.com/group/circle-newbies/ | +---------------------------------------------------------------+
This archive was generated by hypermail 2b30 : 06/25/03 PDT