examine.c

umud/CMD/examine.c · 773 B

From the archive umud1.13.tar.gz

Download the archive   « Back to the archive contents

#ifndef	lint
static	char RCSid[] = "$Header: /home/mjr/hacks/umud/CMD/RCS/examine.c,v 1.2 91/10/22 11:28:50 mjr Exp $";
#endif

/* configure all options BEFORE including system stuff. */
#include	"config.h"


#include	"mud.h"
#include	"match.h"
#include	"vars.h"
#include	"look.h"

/*
TinyMUD-like "examine"
*/

/* ARGSUSED */

cmd_examine(argc,argv,who,aswho)
int	argc;
char	*argv[];
char	*who;
char	*aswho;
{
	char *loc = ut_loc(who);

	if(argc > 1) {
		int	x;
		int	mflg;
		char	ob[MAXOID];

		for(x = 1; x < argc; x++) {
			if(matchlocal(who,argv[x],loc,MTCH_UNIQ|MTCH_MEOK|MTCH_NONLOC|MTCH_QUIET,ob) 
					&& matchlocal(who,argv[x],loc,MTCH_FRST,ob))
				continue;
			do_examine(who,aswho,ob);
		}
		return(0);
	} else {
		do_examine(who,aswho,loc);
		return(0);
	}
}

Site Stats

Snippets: 1791
Codebases: 571