coterie.c
demise/src/coterie.c · 24.6 KB
From the archive dodbackup-final.tar.gz
Download the archive « Back to the archive contents
/***************************************************************************
* Original Diku Mud copyright (C) 1990, 1991 by Sebastian Hammer, *
* Michael Seifert, Hans Henrik St{rfeldt, Tom Madsen, and Katja Nyboe. *
* *
* Merc Diku Mud improvments copyright (C) 1992, 1993 by Michael *
* Chastain, Michael Quan, and Mitchell Tse. *
* *
* In order to use any part of this Merc Diku Mud, you must comply with *
* both the original Diku license in 'license.doc' as well the Merc *
* license in 'license.txt'. In particular, you may not remove either of *
* these copyright notices. *
* *
* Much time and thought has gone into this software and you are *
* benefitting. We hope that you share your changes too. What goes *
* around, comes around. *
***************************************************************************/
/***************************************************************************
* God Wars Mud improvements copyright (C) 1994, 1995, 1996 by Richard *
* Woolcock. This mud is NOT to be copied in whole or in part, or to be *
* run without the permission of Richard Woolcock. Nobody else has *
* permission to authorise the use of this code. *
***************************************************************************/
#if defined(macintosh)
#include <types.h>
#else
#include <sys/types.h>
#endif
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <time.h>
#include "merc.h"
void
do_coterie (CHAR_DATA * ch, char *argument)
{
CHAR_DATA *victim;
CHAR_DATA *gch;
char arg[MIL];
char buf[MSL];
char *strtime;
int value;
/* Remove the first 'word' from the entered string, and copy it into
* arg.
*/
argument = one_argument (argument, arg);
/* Removes the tildes from argument for file-saving purposes. */
smash_tilde (argument);
/* Only vampires should be able to form coteries. */
if (IS_NPC (ch))
{
send_to_char ("Huh?\n\r", ch);
return;
}
if (strlen (ch->pcdata->coterie) > 1 && strlen (ch->pcdata->leader) > 1
&& !str_cmp (ch->name, ch->pcdata->leader)
&& !IS_MORE (ch, MORE_LEADER))
{
stc ("For some reason you lost your leadership, that is now fixed.\n\r",
ch);
SET_BIT (ch->more, MORE_LEADER);
}
if (arg[0] == '\0' || !str_cmp (arg, "info"))
{
if (strlen (ch->pcdata->coterie) > 1 && strlen (ch->pcdata->leader) > 1
&& strlen (ch->pcdata->cot_time) > 1)
{
/* Show the name of the coterie, and who founded it. */
sprintf (buf, "\n\r#7The %s coterie, lead by %s:#n\n\r",
ch->pcdata->coterie, ch->pcdata->leader);
send_to_char (buf, ch);
send_to_char
("#R------------------------------+-----------------------------------------------------------#n\n\r",
ch);
send_to_char
("#L[#7 Name #L] [#7 Rank #L] #R|#L [ #7Hits #L] [ #7Mana #L] [ #7Move #L] [ #7Exp #L] [ #7Status#L ]#n\n\r",
ch);
for (gch = char_list; gch != NULL; gch = gch->next)
{
if (IS_NPC (gch))
continue;
if (strlen (gch->pcdata->coterie) < 2)
continue;
if (strlen (gch->pcdata->cot_time) < 2)
continue;
if (strlen (gch->pcdata->leader) < 2)
continue;
if (str_cmp (ch->pcdata->leader, gch->pcdata->leader))
continue;
if (str_cmp (ch->pcdata->cot_time, gch->pcdata->cot_time))
continue;
if (!str_cmp (ch->pcdata->coterie, gch->pcdata->coterie))
{
sprintf (buf,
"#L[#7%-16s#L]#n #L[#7%8s#L]#R |#n #L[#7 %6d #L]#n #L[#7 %6d #L]#n #L[#7 %6d #L]#n #L[ #7%10ld #L]#n #L[#7 %-3d #L]#n\n\r",
capitalize (gch->name),
IS_MORE (gch, MORE_LEADER) ? " Leader " :
IS_MORE (gch,
MORE_CHAMPION) ? "Champion" : " Member ",
gch->hit, gch->mana, gch->move, gch->exp,
gch->race);
send_to_char (buf, ch);
}
}
send_to_char
("#R------------------------------+-----------------------------------------------------------\n\r",
ch);
send_to_char ("#7For more information type 'coterie help'.\n\r",
ch);
send_to_char
("#R------------------------------------------------------------------------------------------\n\r",
ch);
return;
}
/* If the player doesn't belong to a coterie, then display the
* information about how they can create one.
*/
send_to_char
("#R--------------------------------------------------------------------------------\n\r",
ch);
send_to_char
("#L -= #7Coterie Options #L=-\n\r", ch);
send_to_char
("#R--------------------------------------------------------------------------------\n\r",
ch);
send_to_char ("#7CHAMPION : #LMake a member into a champion.\n\r", ch);
send_to_char ("#7FOUND : #LFounds a new Coterie.\n\r", ch);
send_to_char ("#7INDUCT : #LInducts a member into your coterie.\n\r",
ch);
send_to_char ("#7INFO : #LLists information on your coterie.\n\r",
ch);
send_to_char ("#7LEAVE : #LLeaves your current Coterie.\n\r", ch);
send_to_char ("#7OUTCAST : #LOutcasts a member from your coterie.\n\r",
ch);
send_to_char ("#7READY : #LCoterie rules are completed.\n\r", ch);
send_to_char
("#R--------------------------------------------------------------------------------\n\r",
ch);
return;
}
/* This allows a member to leave the coterie they currently belong to. */
if (!str_cmp (arg, "leave"))
{
/* Check if the person is actually a coterie member. */
if (strlen (ch->pcdata->coterie) < 2 ||
strlen (ch->pcdata->cot_time) < 2 ||
strlen (ch->pcdata->leader) < 2)
{
send_to_char ("But you are not a member of any coterie!\n\r", ch);
return;
}
/* Check each player in the char_list for a match. */
for (gch = char_list; gch != NULL; gch = gch->next)
{
if (IS_NPC (gch))
continue;
if (strlen (gch->pcdata->coterie) < 2)
continue;
if (strlen (gch->pcdata->leader) < 2)
continue;
if (strlen (gch->pcdata->cot_time) < 2)
continue;
if (ch == gch)
continue;
if (str_cmp (ch->pcdata->leader, gch->pcdata->leader))
continue;
if (str_cmp (ch->pcdata->cot_time, gch->pcdata->cot_time))
continue;
if (!str_cmp (ch->pcdata->coterie, gch->pcdata->coterie))
{
/* If the leader leaves their own coterie, then it will
* be disbanded, and all other online members kicked out.
*/
if (IS_MORE (ch, MORE_LEADER))
{
act ("#RInfo#g->#7 $n#0 has disbanded the coterie.#n", ch,
NULL, gch, TO_VICT);
free_string (gch->pcdata->coterie);
gch->pcdata->coterie = str_dup ("");
free_string (gch->pcdata->leader);
gch->pcdata->leader = str_dup ("");
}
else
act ("#RInfo#g->#7 $n#0 has left the coterie.#n", ch, NULL,
gch, TO_VICT);
}
}
if (IS_MORE (ch, MORE_LEADER))
send_to_char ("You disband the coterie.\n\r", ch);
else
send_to_char ("You leave the coterie.\n\r", ch);
REMOVE_BIT (ch->more, MORE_CHAMPION);
free_string (ch->pcdata->coterie);
ch->pcdata->coterie = str_dup ("");
free_string (ch->pcdata->leader);
ch->pcdata->leader = str_dup ("");
REMOVE_BIT (ch->more, MORE_LEADER);
return;
}
/* This allows someone to found a new coterie. */
if (!str_cmp (arg, "found"))
{
/* You cannot already belong to a coterie. */
if (strlen (ch->pcdata->coterie) > 1)
{
send_to_char ("But you are already the member of a coterie!\n\r",
ch);
return;
}
if (ch->max_hit < 15000 || ch->max_mana < 10000 || ch->max_move < 10000)
{
send_to_char
("You must have 15k hp, 10k mana, 10k move to form a coterie.\n\r",
ch);
return;
}
if (argument[0] == '\0')
{
send_to_char ("What do you wish to call your coterie?\n\r", ch);
return;
}
if (strlen (argument) < 5 || strlen (argument) > 40)
{
send_to_char
("Your coterie name should be between 5 and 40 characters long.\n\r",
ch);
return;
}
/* Calculate and store the time the coterie was created. Two
* coteries of the same name created by the same person at different
* times are considered different coteries to prevent a single coterie
* having different rules for different members.
*/
strtime = ctime (¤t_time);
strtime[strlen (strtime) - 1] = '\0';
free_string (ch->pcdata->cot_time);
ch->pcdata->cot_time = str_dup (strtime);
send_to_char ("You have founded a new coterie!\n\r", ch);
free_string (ch->pcdata->coterie);
ch->pcdata->coterie = str_dup (argument);
free_string (ch->pcdata->leader);
ch->pcdata->leader = str_dup (ch->name);
SET_BIT (ch->more, MORE_LEADER);
REMOVE_BIT (ch->more, MORE_CHAMPION);
free_string (ch->pcdata->cot_sides);
if (strlen (ch->side) < 2)
ch->pcdata->cot_sides = str_dup ("None");
else
ch->pcdata->cot_sides = str_dup (ch->side);
free_string (ch->pcdata->cot_clans);
if (strlen (ch->clan) < 2)
ch->pcdata->cot_clans = str_dup ("Caitiff");
else
ch->pcdata->cot_clans = str_dup (ch->clan);
/* Wipe any discipline limitations/requirements from any previous
* coteries the player might have belonged to.
*/
for (value = COT_BANNED; value <= COT_MAX; value++)
{
ch->pcdata->cot_min[value] = 0;
}
ch->pcdata->cot_min[COT_GENERATION] = 13;
return;
}
if (!str_cmp (arg, "induct"))
{
/* You cannot induct someone unless you actually belong to a
* coterie.
*/
if (strlen (ch->pcdata->coterie) < 2 ||
strlen (ch->pcdata->cot_time) < 2 ||
strlen (ch->pcdata->cot_clans) < 2 ||
strlen (ch->pcdata->cot_sides) < 2 ||
strlen (ch->pcdata->leader) < 2)
{
send_to_char ("But you are not a member of any coterie!\n\r", ch);
return;
}
if (!IS_MORE (ch, MORE_LEADER) && !IS_MORE (ch, MORE_CHAMPION))
{
send_to_char
("Only a coterie leader or champion can induct new members.\n\r",
ch);
return;
}
if (!IS_MORE (ch, MORE_CHAMPION) && IS_MORE (ch, MORE_LEADER))
{
send_to_char
("Your coterie has not yet been completely set up.\n\r", ch);
return;
}
if (argument[0] == '\0')
{
send_to_char ("Who do you wish to induct?\n\r", ch);
return;
}
if ((victim = get_char_room (ch, argument)) == NULL)
{
send_to_char ("They aren't here.\n\r", ch);
return;
}
/* Only player vampires are allowed in the coterie. */
if (IS_NPC (victim))
{
send_to_char ("Not on NPC's.\n\r", ch);
return;
}
/* You cannot induct someone who is already in the coterie! */
if (strlen (victim->pcdata->coterie) > 1 &&
strlen (victim->pcdata->leader) > 1 &&
strlen (victim->pcdata->cot_time) > 1 &&
!str_cmp (ch->pcdata->coterie, victim->pcdata->coterie) &&
!str_cmp (ch->pcdata->cot_time, victim->pcdata->cot_time) &&
!str_cmp (ch->pcdata->leader, victim->pcdata->leader))
{
send_to_char ("They are already a member of your coterie.\n\r", ch);
return;
}
/* People already in other coteries have to leave before joining
* another one.
*/
if (strlen (victim->pcdata->coterie) > 1)
{
send_to_char ("You cannot induct an unwilling person.\n\r", ch);
return;
}
/* Unwilling people cannot be forced to join. */
if (!IS_IMMUNE (victim, IMM_VAMPIRE))
{
send_to_char ("You cannot induct an unwilling person.\n\r", ch);
return;
}
act ("You induct $N into your coterie.", ch, NULL, victim, TO_CHAR);
act ("$n inducts you into $s coterie.", ch, NULL, victim, TO_VICT);
/* Check each player in the char_list for a match. */
for (gch = char_list; gch != NULL; gch = gch->next)
{
if (IS_NPC (gch))
continue;
if (strlen (gch->pcdata->coterie) < 2)
continue;
if (strlen (gch->pcdata->cot_time) < 2)
continue;
if (strlen (gch->pcdata->leader) < 2)
continue;
if (str_cmp (ch->pcdata->leader, gch->pcdata->leader))
continue;
if (str_cmp (ch->pcdata->cot_time, gch->pcdata->cot_time))
continue;
if (!str_cmp (ch->pcdata->coterie, gch->pcdata->coterie))
act ("#RInfo#g->#7 $N#0 has been inducted to the coterie!#n", gch,
NULL, victim, TO_CHAR);
}
/* Clear all their coterie values and replace them with the
* values of a coterie member.
*/
free_string (victim->pcdata->coterie);
victim->pcdata->coterie = str_dup (ch->pcdata->coterie);
free_string (victim->pcdata->cot_time);
victim->pcdata->cot_time = str_dup (ch->pcdata->cot_time);
free_string (victim->pcdata->leader);
victim->pcdata->leader = str_dup (ch->pcdata->leader);
free_string (victim->pcdata->cot_clans);
victim->pcdata->cot_clans = str_dup (ch->pcdata->cot_clans);
free_string (victim->pcdata->cot_sides);
victim->pcdata->cot_sides = str_dup (ch->pcdata->cot_sides);
REMOVE_BIT (victim->more, MORE_CHAMPION);
REMOVE_BIT (victim->more, MORE_LEADER);
/* The new member has the same discipline requirements as the
* person who inducted them.
*/
for (value = COT_BANNED; value <= COT_MAX; value++)
{
victim->pcdata->cot_min[value] = ch->pcdata->cot_min[value];
}
return;
}
if (!str_cmp (arg, "outcast"))
{
/* You cannot outcast someone unless you actually belong to their
* coterie, and even then only a select few can do it.
*/
if (strlen (ch->pcdata->coterie) < 2 ||
strlen (ch->pcdata->cot_time) < 2 ||
strlen (ch->pcdata->leader) < 2)
{
send_to_char ("But you are not a member of any coterie!\n\r", ch);
return;
}
if (!IS_MORE (ch, MORE_LEADER) && !IS_MORE (ch, MORE_CHAMPION))
{
send_to_char
("Only a coterie leader or champion can outcast members.\n\r",
ch);
return;
}
if (!IS_MORE (ch, MORE_CHAMPION) && IS_MORE (ch, MORE_LEADER))
{
send_to_char
("Your coterie has not yet been completely set up.\n\r", ch);
return;
}
/* Find the person to be outcast, and check that they are valid. */
if (argument[0] == '\0')
{
send_to_char ("Who do you wish to outcast?\n\r", ch);
return;
}
if ((victim = find_char_world (ch, argument)) == NULL)
{
send_to_char ("They aren't here.\n\r", ch);
return;
}
if (IS_NPC (victim))
{
send_to_char ("Not on NPC's.\n\r", ch);
return;
}
if (victim == ch)
{
send_to_char ("You cannot outcast yourself.\n\r", ch);
return;
}
if (strlen (victim->pcdata->coterie) < 2 ||
strlen (victim->pcdata->cot_time) < 2 ||
strlen (victim->pcdata->leader) < 2)
{
send_to_char ("They are not a member of your coterie.\n\r", ch);
return;
}
if (str_cmp (ch->pcdata->leader, victim->pcdata->leader))
{
send_to_char ("They are not a member of your coterie.\n\r", ch);
return;
}
if (str_cmp (ch->pcdata->coterie, victim->pcdata->coterie))
{
send_to_char ("They are not a member of your coterie.\n\r", ch);
return;
}
if (str_cmp (ch->pcdata->cot_time, victim->pcdata->cot_time))
{
send_to_char ("They are not a member of your coterie.\n\r", ch);
return;
}
if (IS_MORE (victim, MORE_LEADER) || IS_MORE (victim, MORE_CHAMPION))
{
send_to_char ("You can only outcast regular members.\n\r", ch);
return;
}
act ("You outcast $N from the coterie.", ch, NULL, victim, TO_CHAR);
act ("$n outcasts you from the coterie.", ch, NULL, victim, TO_VICT);
/* Clear the person's coterie values, as they are no longer a
* coterie member.
*/
free_string (victim->pcdata->coterie);
victim->pcdata->coterie = str_dup ("");
free_string (victim->pcdata->cot_time);
victim->pcdata->cot_time = str_dup ("None");
free_string (victim->pcdata->leader);
victim->pcdata->leader = str_dup ("");
free_string (victim->pcdata->cot_clans);
victim->pcdata->cot_clans = str_dup ("All");
free_string (victim->pcdata->cot_sides);
victim->pcdata->cot_sides = str_dup ("All");
REMOVE_BIT (victim->more, MORE_CHAMPION);
for (value = COT_BANNED; value <= COT_MAX; value++)
{
victim->pcdata->cot_min[value] = 0;
}
/* Inform remaining members that their coterie has lost a member. */
for (gch = char_list; gch != NULL; gch = gch->next)
{
if (IS_NPC (gch))
continue;
if (!IS_VAMPIRE (gch))
continue;
if (strlen (gch->pcdata->coterie) < 2)
continue;
if (strlen (gch->pcdata->cot_time) < 2)
continue;
if (strlen (gch->pcdata->leader) < 2)
continue;
if (str_cmp (ch->pcdata->leader, gch->pcdata->leader))
continue;
if (str_cmp (ch->pcdata->cot_time, gch->pcdata->cot_time))
continue;
if (!str_cmp (ch->pcdata->coterie, gch->pcdata->coterie))
act ("#RInfo#g->#7 $N#0 has been kicked out of the coterie!#n",
gch, NULL, victim, TO_CHAR);
}
return;
}
/* This allows a coterie leader to make someone into a champion - a
* person who has the ability to recruit new members. A sort of
* sub-leader.
*/
if (!str_cmp (arg, "champion"))
{
if (strlen (ch->pcdata->coterie) < 2 ||
strlen (ch->pcdata->cot_time) < 2 ||
strlen (ch->pcdata->cot_clans) < 2 ||
strlen (ch->pcdata->cot_sides) < 2 ||
strlen (ch->pcdata->leader) < 2)
{
send_to_char ("But you are not a member of any coterie!\n\r", ch);
return;
}
if (!IS_MORE (ch, MORE_LEADER))
{
send_to_char
("Only a coterie leader can make someone a champion.\n\r", ch);
return;
}
if (!IS_MORE (ch, MORE_CHAMPION))
{
send_to_char
("Your coterie has not yet been completely set up.\n\r", ch);
return;
}
/* Find the person to be made a champion, and check they are valid. */
if (argument[0] == '\0')
{
send_to_char ("Who do you wish to make into a champion?\n\r", ch);
return;
}
if ((victim = get_char_world (ch, argument)) == NULL)
{
send_to_char ("They aren't here.\n\r", ch);
return;
}
if (IS_NPC (victim))
{
send_to_char ("Not on NPC's.\n\r", ch);
return;
}
if (victim == ch)
{
send_to_char ("You cannot make yourself a champion!\n\r", ch);
return;
}
/* You can only make members of your own coterie into a champion. */
if (strlen (victim->pcdata->coterie) < 2 ||
strlen (victim->pcdata->cot_time) < 2 ||
strlen (victim->pcdata->leader) < 2)
{
send_to_char ("They are not a member of your coterie.\n\r", ch);
return;
}
if (str_cmp (ch->pcdata->leader, victim->pcdata->leader))
{
send_to_char ("They are not a member of your coterie.\n\r", ch);
return;
}
if (str_cmp (ch->pcdata->coterie, victim->pcdata->coterie))
{
send_to_char ("They are not a member of your coterie.\n\r", ch);
return;
}
if (str_cmp (ch->pcdata->cot_time, victim->pcdata->cot_time))
{
send_to_char ("They are not a member of your coterie.\n\r", ch);
return;
}
/* Inform all members of the coterie that the person has been
* made/unmade a champion.
*/
if (!IS_MORE (victim, MORE_CHAMPION))
{
act ("You make $N a coterie champion.", ch, NULL, victim, TO_CHAR);
act ("$n makes you a coterie champion.", ch, NULL, victim, TO_VICT);
sprintf (buf, "#RInfo#g->#7 $N #0has been made a champion!#n");
SET_BIT (victim->more, MORE_CHAMPION);
}
else
{
act ("You remove $N's coterie champion position.", ch, NULL, victim,
TO_CHAR);
act ("$n removes your coterie champion position.", ch, NULL, victim,
TO_VICT);
sprintf (buf,
"#RInfo#g->#7 $N#0 is no longer a coterie champion!#n");
REMOVE_BIT (victim->more, MORE_CHAMPION);
}
for (gch = char_list; gch != NULL; gch = gch->next)
{
if (IS_NPC (gch))
continue;
if (strlen (gch->pcdata->coterie) < 2)
continue;
if (strlen (gch->pcdata->cot_time) < 2)
continue;
if (strlen (gch->pcdata->leader) < 2)
continue;
if (str_cmp (ch->pcdata->leader, gch->pcdata->leader))
continue;
if (str_cmp (ch->pcdata->cot_time, gch->pcdata->cot_time))
continue;
if (!str_cmp (ch->pcdata->coterie, gch->pcdata->coterie))
act (buf, gch, NULL, victim, TO_CHAR);
}
return;
}
/* This is used when the coterie rules are complete and the coterie
* is ready to take on new members.
*/
if (!str_cmp (arg, "ready"))
{
if (strlen (ch->pcdata->coterie) < 2 ||
strlen (ch->pcdata->cot_time) < 2 ||
strlen (ch->pcdata->leader) < 2)
{
send_to_char ("But you are not a member of any coterie!\n\r", ch);
return;
}
if (!IS_MORE (ch, MORE_LEADER))
{
send_to_char
("Only a coterie leader can say when the coterie is ready.\n\r",
ch);
return;
}
if (IS_MORE (ch, MORE_CHAMPION))
{
send_to_char ("But your coterie has already been completed!\n\r",
ch);
return;
}
SET_BIT (ch->more, MORE_CHAMPION);
send_to_char ("Your coterie is now ready to accept new members!\n\r",
ch);
return;
}
/* The 'coterie' command on its own lists the coterie options, unless
* you already belong to a coterie in which case you won't have reached
* this point.
*/
send_to_char
("#R--------------------------------------------------------------------------------\n\r",
ch);
send_to_char
("#L -= #7Coterie Options #L=-\n\r", ch);
send_to_char
("#R--------------------------------------------------------------------------------\n\r",
ch);
send_to_char ("#7CHAMPION : #LMake a member into a champion.\n\r", ch);
send_to_char ("#7FOUND : #LFounds a new Coterie.\n\r", ch);
send_to_char ("#7INDUCT : #LInducts a member into your coterie.\n\r", ch);
send_to_char ("#7INFO : #LLists information on your coterie.\n\r", ch);
send_to_char ("#7LEAVE : #LLeaves your current Coterie.\n\r", ch);
send_to_char ("#7OUTCAST : #LOutcasts a member from your coterie.\n\r",
ch);
send_to_char ("#7READY : #LCoterie rules are completed.\n\r", ch);
send_to_char
("#R--------------------------------------------------------------------------------\n\r",
ch);
return;
}
void
do_ctalk (CHAR_DATA * ch, char *argument)
{
CHAR_DATA *victim;
DESCRIPTOR_DATA *d;
char buf[MSL];
if (IS_NPC (ch))
return;
if (strlen (ch->pcdata->coterie) < 2 || strlen (ch->pcdata->leader) < 2)
{
send_to_char ("But you don't belong to a coterie!\n\r", ch);
return;
}
if (argument[0] == '\0')
{
send_to_char ("Coterie-talk what?\n\r", ch);
return;
}
if (!IS_IMMORTAL (ch))
{
char verb[MIL];
sprintf (verb, "cot talk");
if (IS_HEAD (ch, LOST_TONGUE))
{
sprintf (buf, "You can't %s without a tongue!\n\r", verb);
send_to_char (buf, ch);
return;
}
if (IS_EXTRA (ch, GAGGED))
{
sprintf (buf, "You can't %s with a gag on!\n\r", verb);
send_to_char (buf, ch);
return;
}
if (!IS_NPC (ch) && IS_SET (ch->act, PLR_SILENCE))
{
sprintf (buf, "You can't %s.\n\r", verb);
send_to_char (buf, ch);
return;
}
if (ch->in_room != NULL
&& IS_SET (ch->in_room->added_flags, ROOM2_SILENCE))
{
sprintf (buf, "You can't cot talk.\n\r");
send_to_char (buf, ch);
return;
}
if (ch->in_room != NULL
&& IS_SET (ch->in_room->room_flags, ROOM_SILENCE))
{
sprintf (buf, "You can't cot talk.\n\r");
send_to_char (buf, ch);
return;
}
}
if (IS_SET (ch->deaf, CHANNEL_COTTALK))
REMOVE_BIT (ch->deaf, CHANNEL_COTTALK);
if (IS_MORE (ch, MORE_LEADER))
act ("#y-=#7$n#y=-#n '#R$t#n'.", ch, argument, NULL, TO_CHAR);
else
act ("#y-#7$n#y-#n '#R$t#n'.", ch, argument, NULL, TO_CHAR);
for (d = descriptor_list; d != NULL; d = d->next)
{
if (d->connected != CON_PLAYING)
continue;
if ((victim = d->character) == NULL)
continue;
if (IS_NPC (victim))
continue;
if (IS_SET (victim->deaf, CHANNEL_COTTALK))
continue;
if (get_trust (victim) < 12 && !IS_LINKSYS (victim))
{
if (strlen (victim->pcdata->coterie) < 2)
continue;
if (strlen (victim->pcdata->leader) < 2)
continue;
if (str_cmp (ch->pcdata->coterie, victim->pcdata->coterie))
continue;
if (str_cmp (ch->pcdata->leader, victim->pcdata->leader))
continue;
}
if (IS_MORE (ch, MORE_LEADER))
act ("#y-=#7$n#y=-#n '#R$t#n'.", ch, argument, victim, TO_VICT);
else if (IS_MORE (ch, MORE_CHAMPION))
act ("#y-+#7$n#y+-#n '#R$t#n'.", ch, argument, victim, TO_VICT);
else
act ("#y-#7$n#y-#n '#R$t#n'.", ch, argument, victim, TO_VICT);
}
return;
}