Re: [NEWBIE][CODE] I can't see whats wrong with this.

From: Geoff Davis (azrael@laker.net)
Date: 12/05/00


Hi:

> I really can't see whats wrong with this. Every time I try to type link
the
> Mud crashes and says 'Signal 11' Any help is appreciated

[-snip-]
>   int r_mortal_link_room = 11100

It looks here like you're assigning a room vnum to r_mortal_link_room.
I would also reccomend changing the type to room_vnum, although that
has nothing to do with your crash, as that is the type used for room vnums.

[-snip-]
>     char_to_room(ch, r_mortal_link_room);

Hmm... Now you're passing the room vnum to char_to_room. The second
argument to this function ought to be a room rnum, not vnum.

[-snip-]

Have a look at real_room() in db.c, and grep for real_room in your source
files for ideas. Also check out structs.h, in the types section (search for
room_rnum), as it explains (very) briefly the differences between the
*_rnum and *_vnum types.


Hope this helps.

-Geoff

--
   +---------------------------------------------------------------+
   | FAQ: http://qsilver.queensu.ca/~fletchra/Circle/list-faq.html |
   | Archives: http://post.queensu.ca/listserv/wwwarch/circle.html |
   +---------------------------------------------------------------+



This archive was generated by hypermail 2b30 : 04/11/01 PDT