Alright, now i'm in the middle of making a disguise for thieves. what it does, it sets their long description to a predefined long. example, a character is disguised, another character looks and sees:
Forest
blah blah blah desc
blah blah blah desc
exits
A man stands here with a cloak on.
instead of the normal:
(race) *name* is standing here.
i'm getting weird errors that i'm not sure why.
here are the errors:
lines 419 and 420, the max length is 160, but i dont' know why it's erroring. the exbit62, i'm not sure why that's erroring as well. it's defined and did a make clean.
any thoughts?
Forest
blah blah blah desc
blah blah blah desc
exits
A man stands here with a cloak on.
instead of the normal:
(race) *name* is standing here.
i'm getting weird errors that i'm not sure why.
void do_disguise ( CHAR_DATA *ch, char *argument )
{
char arg1(MAX_INPUT_LENGTH); <--4419
char arg2(MAX_INPUT_LENGTH); <--4420
argument = one_argument(argument, arg1); <--4422
argument = one_argument(argument, arg2); <--4423
if ( IS_NPC(ch) )
return;
if (arg1[0] == '\0' || arg2[0] == '\0' ) <--4428
{
send_to_char( "Disguise <kind> < number>\n\r", ch );
send_to_char( "Help Disguise\n\r", ch );
return;
}
if ( !str_cmp(arg1, "evil")) <--4438
{
if (!str_cmp (arg2, "1")) <--4440
{
free_string (ch->long_descr);
ch->long_descr = str_dup ("^PA dark man stands here.^w\n\r");
// return;
}
}
{
AFFECT_DATA af;
ZeroMemory(&af, sizeof(AFFECT_DATA) );
af.type = skill_lookup("disguise");
af.duration = 2;
af.bDispel = DISPEL_NEVER;
af.location = APPLY_NONE;
af.bvAff = meb(AFFX_DISGUISE);
affect_to_char (ch, &af);
}
return;
}
here are the errors:
act_obj.c: In function `do_disguise':
act_obj.c:4419: parse error before `160'
act_obj.c:4420: parse error before `160'
act_obj.c:4422: warning: passing arg 2 of `one_argument' from incompatible pointer type
act_obj.c:4423: warning: passing arg 2 of `one_argument' from incompatible pointer type
act_obj.c:4428: subscripted value is neither array nor pointer
act_obj.c:4428: subscripted value is neither array nor pointer
act_obj.c:4438: warning: passing arg 1 of `str_cmp' from incompatible pointer type
act_obj.c:4440: warning: passing arg 1 of `str_cmp' from incompatible pointer type
act_obj.c:4456: `XBIT62' undeclared (first use in this function)
act_obj.c:4456: (Each undeclared identifier is reported only once
act_obj.c:4456: for each function it appears in.)
lines 419 and 420, the max length is 160, but i dont' know why it's erroring. the exbit62, i'm not sure why that's erroring as well. it's defined and did a make clean.
any thoughts?