On Mon, Aug 05, 2002 at 10:51:32PM -0400, J wrote:
> I'm using a standard ol' argument in a function, like so...
> 
> void do_bla( CHAR_DATA *ch, char *argument )
> 
> Then, in the function, the value of argument isn't changed or messed with or
> anything, and I have an ifcheck for the argument, like so...
> 
>     if ( argument == "whatever" )
> 
> Then, I try the mud with my argument being whatever, and... the ifcheck
> isn't triggered.

Because that's now how you compare strings in C.
Try again with the right syntax and you'll be fine.

The whole source-code is full of string-comparing if-statements,
it won't be difficult to find one which shows you the way.

Edwin

-- 
Edwin Groothuis      |            Personal website: http://www.MavEtJu.org
[EMAIL PROTECTED]    |    Weblog: http://www.mavetju.org/weblog/weblog.php 
bash$ :(){ :|:&};:   | Interested in MUDs? http://www.FatalDimensions.org/

Reply via email to