CleverRaven / Cataclysm-DDA

Cataclysm - Dark Days Ahead. A turn-based survival game set in a post-apocalyptic world.
http://cataclysmdda.org
Other
10.59k stars 4.16k forks source link

Using diary with records of killed mon_endless_hunger causes game-locking error #61445

Closed Sutremaine closed 2 years ago

Sutremaine commented 2 years ago

Describe the bug

DEBUG : invalid monster type id "mon_endless_hunger"

FUNCTION : const T& generic_factory::obj(const string_id&) const [with T = mtype] FILE : src/generic_factory.h LINE : 448 VERSION : edb21b9

Attempting to access or read diary entries with kill lists containing Endless Hungers causes a json error, as does accessing the normal kill list. On some entries, tapping the Space button repeatedly does not clear the error, leaving the game stuck on that screen.

Steps to reproduce

Have an older experimental version (25th August in this case), update to more recent version (1st October). Have Endless Hunger kills, from before and after date of older version. Access diary or kill screen in more recent version.

Expected behavior

No error.

Screenshots

No response

Versions and configuration

Additional context

I doubt it's the stuff in mods_personal doing it, since that was active in my last game update, but here you go anyway?

cdda modded item list.txt

NetSysFire commented 2 years ago

You got quite a few mods there. Can you try and reproduce it with just the default mods? Spawn and kill it with debug powers and then use the diary.

GuardianDll commented 2 years ago

How you can kill one in natural way?

Sutremaine commented 2 years ago

I can't spawn the monster on the recent version (either 1st October or the most current e39079b) because it doesn't exist anywhere any more. Restoring it to the nether.json monster file fixes this error, but that's not enough by itself because if it does get spawned it'll be missing its death effect and special attack. So I removed any reference to those two things and popped it into the currently-empty obsolete.json. The creature entry still needs some details for the bestiary, and it'd probably be a good idea to give it a weight of one gram. Without its death effect it leaves a corpse that weighs nothing, which will probably cause some problem somewhere at some point.

PR to make those changes and put it in the "obsolete" file?