Re: [newbie] arena.txt

From: iron fist (ironfist@texas.net)
Date: 06/16/02


SoulReaper Is here wrote:

> besides from the undefined symbols like buf, buf1, buf2
> i get undefined structure in arena.c hall_of_fame_element
> i get not allowed type in function find_game_winner in arena.c
>
> i get undefined symbol name
> and undefined symbol date
> undefined symbol award
>
> i believe the error is caused by this code from utils.h because i get
> declaration syntax error from arena.h
>
> struct hall_of_fame_element {
>    char name[MAX_NAME_LENGTH+1];
>    char lastname[MAX_NAME_LENGTH+1];
>    time_t date;
>    long award;
>    struct  hall_of_fame_element *next;
> };

You need to declare:

char buf1[MAX_STRING_LENGTH];
char buf2[MAX_STRING_LENGTH];
... etc at the top of each function which uses those arrays.

For the hall_of_fame_element, that looks like it is declared right.
Make sure it is in arena.h, not utils.h, and only one copy of it.

Also, make sure that arena.h is included in arena.c, comm.c
act.wizard.c and fight.c, or whereever else you need it.

Also, you could try the command:  make clean and then
type make again to make sure it recompiles everything.
(make clean deletes the .o files)


R.M.
ironfist@texas.net

--
   +---------------------------------------------------------------+
   | FAQ: http://qsilver.queensu.ca/~fletchra/Circle/list-faq.html |
   | Archives: http://post.queensu.ca/listserv/wwwarch/circle.html |
   | Newbie List:  http://groups.yahoo.com/group/circle-newbies/   |
   +---------------------------------------------------------------+



This archive was generated by hypermail 2b30 : 06/25/03 PDT