I went to the snippets page and downloaded the snippet for having charisma
affecting agg mobs. Anyways i did what it told me to do and this is what
i got from it:
gcc -c -g -O -Wall -fno-strict-prototypes mobact.c
mobact.c: In function `mobile_activity':
mobact.c:70: parse error before `void'
mobact.c:33: warning: `ch' might be used uninitialized in this function
This is the coding:
...
extern struct str_app_type str_app[];
#define MOB_AGGR_TO_ALIGN (MOB_AGGR_EVIL | MOB_AGGR_NEUTRAL |
MOB_AGGR_GOOD)
void mobile_activity(void)
{
register struct char_data *ch, *next_ch, *vict;
struct obj_data *obj, *best_obj;
int door, found, max;
memory_rec *names;
extern int no_specials;
if (MOB_FLAGGED(ch, MOB_AGGRESSIVE | MOB_AGGR_TO_ALIGN))
{
found = FALSE;
for (vict = world[ch->in_room].people; vict && !found;
vict = vict->next_in_room)
{
if (IS_NPC(vict) || !CAN_SEE(ch, vict) || PRF_FLAGGED(vict,
PRF_NOHASSLE))
continue;
if (MOB_FLAGGED(ch, MOB_WIMPY) && AWAKE(vict))
continue;
if (!MOB_FLAGGED(ch, MOB_AGGR_TO_ALIGN) ||
(MOB_FLAGGED(ch, MOB_AGGR_EVIL) && IS_EVIL(vict)) ||
(MOB_FLAGGED(ch, MOB_AGGR_NEUTRAL) && IS_NEUTRAL(vict)) ||
(MOB_FLAGGED(ch, MOB_AGGR_GOOD) && IS_GOOD(vict)))
{
if (number(0, 20) <= GET_CHA(vict))
{
act("$n looks at $N with an indifference.",
FALSE, ch, 0, vict, TO_NOTVICT);
act("$N looks at you with an indifference.",
FALSE, vict, 0, ch, TO_CHAR);
} else
{
hit(ch, vict, TYPE_UNDEFINED);
found = TRUE;
}
}
}
}
ACMD(do_get);
for (ch = character_list; ch; ch = next_ch) {
next_ch = ch->next;
...
Any help would be appreciated. Thanks.
-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-
| Ryan Guthrie |
| guthrie@henge.com |
-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-#-
+-----------------------------------------------------------+
| Ensure that you have read the CircleMUD Mailing List FAQ: |
| http://cspo.queensu.ca/~fletcher/Circle/list_faq.html |
| Or send 'info circle' to majordomo@cspo.queensu.ca |
+-----------------------------------------------------------+
This archive was generated by hypermail 2b30 : 12/18/00 PST