STOR can absorb radiation particles (#978)

This commit is contained in:
jm211
2024-12-02 12:15:18 -05:00
committed by jacob1
parent f3c73c8658
commit 68a8b055e3

View File

@@ -66,7 +66,9 @@ static int update(UPDATE_FUNC_ARGS)
if (rx || ry)
{
auto r = pmap[y+ry][x+rx];
if ((ID(r))>=NPART || !r)
if (!r)
r= sim->photons[y+ry][x+rx];
if (!r)
continue;
if (!parts[i].tmp && !parts[i].life && TYP(r)!=PT_STOR && !(elements[TYP(r)].Properties&TYPE_SOLID) && (!parts[i].ctype || TYP(r)==parts[i].ctype))
{