On Mon, Aug 05, 2002 at 10:43:59PM +0200, Peter d wrote: >needs and my circlemud version.. but i can't get the bribe command to work, >it only says bribe who.. here's the piece of code.. > > if (CMD_IS("bribe")){ - if (argument != "lorkhan"){ + if(strn_cmp(argument, "lorkhan", strlen(argument)) { > send_to_char(ch, "Bribe who?\r\n"); - } else if (argument == "lorkhan"){ + } else if (!strn_cmp(argument, "lorkhan", strlen(argument)) { This else-if is redundant, btw, they're either the same or they aren't. This also allows for the player to abbreviate lorkhan. -me -- +---------------------------------------------------------------+ | 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