From: "Torgny Bjers" <artovil@ARCANEREALMS.ORG> > On 02-10-13 21.48, "Kevin Dethlefs" <demortes@MSN.COM> wrote: > > > Every time someone dies, it seems to go like this. Person dies, gets > > transported to the spirit world, type's "look" and mud crashes... now this > > is output from gdb and syslog: > > > > Syslog: > > Oct 13 14:35:16 :: SYSERR: Mob using > > '((victim)->player_specials->saved.pref)' at fight.c:689. > > Oct 13 14:35:19 :: SYSERR: Illegal value(s) passed to char_to_room. (Room: > > -1/192 Ch: 0x81e2228 > > Obviously the player (hopefully the victim) has not been inited properly, or > something to that effect, since they do not have player_specials(). Perhaps > this line appears when mobs are the victim? In that case, just stick an > IS_NPC(victim) around that stuff. > looking at the code at [1] http://www.circlemud.org/pub/CircleMUD/contrib/code/players/spirit-world.txt there _should_ already be an if check for IS_NPC. The problem is more likely in the char_to_room() line in the snippet: char_to_room(ch, real_room(number(SPIRIT_MIN, SPIRIT_MAX))); If the rooms between SPIRIT_MIN and SPIRIT_MAX doesn't exist, real_room() returns NOWHERE -> thus the log message above. > > GDB: > > #0 0x8096d97 in command_wtrigger (actor=0x81e2228, cmd=0x8105c1c "look", > > argument=0xbffffa9c "") at dg_triggers.c:874 > > #1 0x80a7ffc in command_interpreter (ch=0x81e2228, argument=0xbffffa98 > > "look") > > at interpreter.c:646 > > #2 0x807c7ba in game_loop (mother_desc=3) at comm.c:856 > > #3 0x807bf9f in init_game (port=3625) at comm.c:480 > > #4 0x807bc7d in main (argc=3, argv=0xbffffde8) at comm.c:355 > > What does the snippet do in fight.c prior to, and when, it sends the victim > to the spirit world? Also, the first frame in the debugger output comes > from dg_triggers.c:874, perhaps you should check out why command_wtrigger > coredumps? Could it be that you're sending an extracted char to a new room, > and thus passing some odd data to command_wtrigger or something to that > effect? It's not a null, obviously, since actor has data in it... Just > guesses, can't do much more without seeing the code, but you might want to > try to stick some logs in fight.c around the affected code, and in > dg_triggers.c, to see what's going on exactly, or use gdb to print the stuff > out if that makes more sense to you. > Actually dg_triggers.c:874 is more than likely to be if (!actor || !SCRIPT_CHECK(&world[IN_ROOM(actor)], WTRIG_COMMAND)) which will crash if IN_ROOM(actor) is NOWHERE. In short, to fix the problem, adjust SPIRIT_MIN and SPIRIT_MAX to a range of rooms that actually exists. Welcor [1] It's common courtesy to at least put a link to the snippet into the post, so helpers have a chance to see what the problem is. -- +---------------------------------------------------------------+ | 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