Ok, I'm stuck here... My mud seems to be crashing randomly when players enter into battle, mortal or immortal. It only started happening after I implemented a haste spell, I'm having trouble working out why this would've affected it, anyway heres a gdb listing... Script started on Sat May 23 12:01:44 1998 [root@localhost circle30bpl12]# gdb ./bin/circle ./lib/core GDB is free software and you are welcome to distribute copies of it under certain conditions; type "show copying" to see the conditions. There is absolutely no warranty for GDB; type "show warranty" for details. GDB 4.16 (i586-unknown-linux), Copyright 1996 Free Software Foundation, Inc... Core was generated by `bin/circle -q 4000'. Program terminated with signal 11, Segmentation fault. Reading symbols from /lib/libc.so.5.3.12...done. Reading symbols from /lib/ld-linux.so.1...done. #0 0x806b394 in hit (ch=0x82de580, victim=0x0, type=-1) at fight.c:826 826 if (ch->in_room != victim->in_room) { (gdb) back #0 0x806b394 in hit (ch=0x82de580, victim=0x0, type=-1) at fight.c:826 #1 0x806ba8c in perform_violence () at fight.c:1073 #2 0x804a2a9 in heartbeat (pulse=1760) at comm.c:781 #3 0x804a211 in game_loop (mother_desc=4) at comm.c:753 #4 0x8049748 in init_game (port=4000) at comm.c:300 #5 0x80496c6 in main (argc=3, argv=0xbffffaac) at comm.c:263 #6 0x80493bb in ___crt_dummy__ () (gdb) list 821 extern struct dex_app_type dex_app[]; 822 823 int backstab_mult(int level); 824 825 /* Do some sanity checking, in case someone flees, etc. */ 826 if (ch->in_room != victim->in_room) { 827 if (FIGHTING(ch) && FIGHTING(ch) == victim) 828 stop_fighting(ch); 829 return; 830 } (gdb) list 831 832 /* Find the weapon type (for display purposes only) */ 833 if (wielded && GET_OBJ_TYPE(wielded) == ITEM_WEAPON) 834 w_type = GET_OBJ_VAL(wielded, 3) + TYPE_HIT; 835 else { 836 if (IS_NPC(ch) && (ch->mob_specials.attack_type != 0)) 837 w_type = ch->mob_specials.attack_type + TYPE_HIT; 838 else 839 w_type = TYPE_HIT; 840 } (gdb) quit [root@localhost circle30bpl12]# exit exit Script done on Sat May 23 12:02:46 1998 The haste spell I added simply sets the player's AFF_HASTE, and in perform_violence I added 2 checks. if IS_AFFECTED (ch, AFF_HASTE) hit(ch, FIGHTING(ch)....etc) and then in my dual-wield code. if IS_AFFECTED (ch, AFF_HASTE) hit2(blah blah...) I know the problem isn't in my dual wield code another thing I noticed, is that it ALWAYS happens when in a group, and only sometimes when fightning solo. Oh yeah, it only happens when the victim is mortally wounded, if that helps (?) Thanks in advance. Owen. +------------------------------------------------------------+ | Ensure that you have read the CircleMUD Mailing List FAQ: | | http://democracy.queensu.ca/~fletcher/Circle/list-faq.html | +------------------------------------------------------------+
This archive was generated by hypermail 2b30 : 12/15/00 PST