diff --git a/src/simulation/Simulation.cpp b/src/simulation/Simulation.cpp index 5a28bba9a..2decc24a3 100644 --- a/src/simulation/Simulation.cpp +++ b/src/simulation/Simulation.cpp @@ -4292,7 +4292,8 @@ killed: } r = get_wavelength_bin(&parts[i].ctype); - if (r == -1) { + if (r == -1 || !(parts[i].ctype&0x3FFFFFFF)) + { kill_part(i); continue; }