![]() |
#1 |
Adept
Join Date: Mar 2016
Posts: 194
![]() |
Crash due to referencing object deleted by drop_near()
Rather than clutter the Vanilla board, I'll discuss my findings here. Original thread is here
In summary, there is a repeatable crash if a monster picks up an object and that object is destroyed when the monster dies due to lack of floor space. The 'birth_stacking' flag seems to be ignored (the save file in the referenced thread has stacking on'. In obj-pile.c in drop_near() there are a couple of chunks of code like this: Code:
/* Message */ msg("The %s %s.", o_name, VERB_AGREEMENT(dropped->number, "disappears", "disappear")); /* Debug */ if (player->wizard) msg("Breakage (no floor space)."); /* Failure */ if (dropped->known) { delist_object(cave_k, dropped->known); object_delete(&dropped->known); } delist_object(c, dropped); object_delete(&dropped); return; Code:
/* Don't delist an actual object if it still has a listed known object */ if ((c == cave) && cave_k->objects[obj->oidx]) return; c->objects[obj->oidx] = NULL; obj->oidx = 0; In mon_move.c in process_monster_grab_objects(), the code which performs the pick-up is Code:
square_excise_object(c, ny, nx, obj); monster_carry(c, mon, obj); square_note_spot(c, ny, nx); square_light_spot(c, ny, nx); Hopefully this helps track down this nasty |
![]() |
![]() |
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests) | |
Thread Tools | |
Display Modes | |
|
|
![]() |
||||
Thread | Thread Starter | Forum | Replies | Last Post |
borg out of sync sometimes due to lag in update on p_ptr->inventory[] | APWhite | Development | 1 | September 10, 2011 21:39 |
Ridiculous death due, in my opinion, to flawed design. | Vogrim | Vanilla | 168 | January 4, 2011 22:46 |
Amazing character but still YASD due to NAsTY monster | Thraalbee | AAR | 12 | September 11, 2010 09:13 |
object list | fyonn | Vanilla | 17 | June 23, 2010 16:04 |
28 tickets due by May 31. | PaulBlay | Development | 0 | May 5, 2009 21:26 |