pro react_to_every_particle_change, old, new @common_blocks.inc if old eq new then return if (new mod old) eq 0 then begin ; some fewer points. we can fix that stride = fix(new/old) print, 'react:', stride, new, old for i=0,N_elements(*parti.names)-1 do $ if parti.read[i] gt 0 then begin *parti.d[i] = (*parti.d[i])[0:*:stride] endif return endif for i=0,N_elements(*parti.names)-1 do begin parti.d[i] = ptr_new(0.) parti.read[i] = 0 endfor return end