Re: [CODE] Tried and failed this function...

From: Andrew (object@alphalink.com.au)
Date: 11/26/98


>dur += (strlen(arg2)-2);
>eff += (strlen(arg2)-1);
>targ += strlen(arg2);

Ok, well you want to find out three values from arg2 right? How bout
something like this...

if(strlen(arg2) != 3)
   send_to_char("Incorrect Syntax.");
dur = atoi(*arg2[0]);
eff = atoi(*arg2[1]);
targ = atoi(*arg2[2]);
sprintf(buf, "Ok. Values: dur = %d, eff = %d, targ = %d.", dur, eff, targ);
send_to_char(buf);

Does that look right?

-- Andrew

| Andrew Ritchie, object@alphalink.com.au.


     +------------------------------------------------------------+
     | Ensure that you have read the CircleMUD Mailing List FAQ:  |
     | http://democracy.queensu.ca/~fletcher/Circle/list-faq.html |
     +------------------------------------------------------------+



This archive was generated by hypermail 2b30 : 12/15/00 PST