README
./README · 1.7 KB
From the archive ignore.tar.gz
Download the archive « Back to the archive contents
Put the ignore.c file in your /rom/src directory.
-- Makefile
Add ignore.o to the O_FILES section.
-- act_comm.c
Somewhere up towards the top, add the line:
extern bool is_ignoring(CHAR_DATA *ch, CHAR_DATA *victim);
In the do_tell function, before the lines:
act( "&rYou tell $N '$t'&x", ch, argument, victim, TO_CHAR );
act_new("&r$n tells you '$t'&x",ch,argument,victim,TO_VICT,POS_DEAD);
victim->reply = ch;
Add:
if (is_ignoring(victim, ch))
{
sprintf(buf, "%s is ignoring you.\n\r", victim->name);
send_to_char(buf, ch);
return;
}
-- save.c
Before the line:
/* write alias */
Add:
for (pos = 0; pos < MAX_IGNORE; pos++)
{
if (ch->pcdata->ignore[pos] == NULL)
break;
fprintf(fp, "Ignore %s~\n", ch->pcdata->ignore[pos]);
}
Before the line:
KEY( "Id", ch->id, fread_number( fp ) );
Add:
if (!str_cmp( word, "Ignore"))
{
if (count >= MAX_IGNORE)
{
fread_to_eol(fp);
fMatch = TRUE;
break;
}
ch->pcdata->ignore[count] = fread_string(fp);
count++;
fMatch = TRUE;
break;
}
-- interp.c
Before the line:
{ "inventory", do_inventory, POS_DEAD, 0, LOG_NORMAL, 1 },
Add:
{ "ignore", do_ignore, POS_DEAD, 0, LOG_NORMAL, 1 },
-- interp.h
Before the line:
DECLARE_DO_FUN( do_imotd );
Add:
DECLARE_DO_FUN( do_ignore );
-- merc.h
Before the line:
#define MAX_CLASS 4
Add:
#define MAX_IGNORE (Put whatever number you want)
Before the lines:
char * alias[MAX_ALIAS];
char * alias_sub[MAX_ALIAS];
Add:
char * ignore[MAX_IGNORE];
Compile, and cross your fingers!
Any questions, e-mail them to ruiner@mail.org