mlangsdorf / Cataclysm-DDA

Cataclysm - Dark Days Ahead. A fork/variant of Cataclysm Roguelike by Whales.
http://en.cataclysmdda.com/
Other
1 stars 1 forks source link

json fuel failing implementation #20

Closed mlangsdorf closed 6 years ago

mlangsdorf commented 6 years ago

I would like to add cata_optional things to veh_type.h, mimicking the structure of itype.h. What I've got looks good and sensible to me. But it is crashing with src/optional.h:45: const T &cata::optional::get() const [T = vpslot_engine]: Assertion `full' failed.

mlangsdorf commented 6 years ago

You can't deference pointers that you didn't allocate because you were too lazy to double check you were using the right flag string in the if statement.