Cataclysm-dda: Game crashes when using the 'd' (full description of resulting item) function in the crafting interface.

Created on 3 Sep 2020  路  5Comments  路  Source: CleverRaven/Cataclysm-DDA

Describe the bug

Game crashes after trying to filter the crafting recipes with the 'd' function. (Only the 'd' function is bugged).

a2

Versions and configuration

Build: 10973
Graphics Version: Undeadpeople
Game Language: English [en]
Mods loaded: [
Dark Days Ahead [dda],
Aftershock [aftershock],
Magiclysm [magiclysm],
Mythological Replicas [nw_pack],
DinoMod [DinoMod],
Mythical Martial Arts [MMA],
[DeadPeople] Zombie Revival Indicator [DP_ZOMBIE_REVIVAL_INDICATOR],
No Fungal Monsters [No_Fungi],
Disable NPC Needs [no_npc_food]
]
(S2 - Confirmed) <Crash / Freeze> Performance Crafting / Construction / Recipes Info / User Interface

Most helpful comment

It's expensive to generate the description of every item you can craft, so this is a known risk of this feature (that's why it warns you that it might be slow). But perhaps we could improve the situation by at least giving some visual feedback as to progress.

All 5 comments

Cannot reproduce. Which search term did you use to cause crash?

Analyzing it better i noticed that it's not exactly a crash, it's a (really weird) 10-20 seconds freeze (that i previously assumed was a crash), it's probably happening because i'm playing the game in a old setup: intel i3 2120, and 4gb ram (really slow frequency), so probably this 'd' function is doing something weird in the code, that makes the game freeze for a while in slower processors, i assume? The other options works instantly.

I created a fresh world (no mods) with a fresh character and the 'd' function only freezes for 2-3 seconds, i assume it's because of the drastically smaller amount of possible crafting recipes in this new character if compared to the previous one. Really weird, i dont experience this kind of behaviour in anything in the entire game using this old pc setup.

Update: I unlocked all recipes using the debug menu in this new character and indeed the freeze went from 2-3 sec to 10-20, so it's more of a optimization problem (only in this particular 'd' function), not a crash.

It's expensive to generate the description of every item you can craft, so this is a known risk of this feature (that's why it warns you that it might be slow). But perhaps we could improve the situation by at least giving some visual feedback as to progress.

what this probably needs is for the algorithm to be resumable, and to be able to early-return after so many steps so that visual updates and refreshes can happen upstream while the search is still in progress.

Or we might be able to do it via a progress callback of some kind?

Was this page helpful?
0 / 5 - 0 ratings